Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 0 additions & 16 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,6 @@ jobs:
- { modules: lib/trino-filesystem-azure, profile: cloud-tests }
- { modules: lib/trino-filesystem-gcs, profile: cloud-tests }
- { modules: lib/trino-filesystem-s3, profile: cloud-tests }
- { modules: lib/trino-hdfs, profile: cloud-tests }
- { modules: plugin/trino-bigquery }
- { modules: plugin/trino-bigquery, profile: cloud-tests-2 }
- { modules: plugin/trino-cassandra }
Expand Down Expand Up @@ -564,27 +563,13 @@ jobs:
&& ! (contains(matrix.modules, 'trino-filesystem-azure') && contains(matrix.profile, 'cloud-tests'))
&& ! (contains(matrix.modules, 'trino-filesystem-gcs') && contains(matrix.profile, 'cloud-tests'))
&& ! (contains(matrix.modules, 'trino-filesystem-s3') && contains(matrix.profile, 'cloud-tests'))
&& ! (contains(matrix.modules, 'trino-hdfs') && contains(matrix.profile, 'cloud-tests'))
run: $MAVEN test ${MAVEN_TEST} -pl ${{ matrix.modules }} ${{ matrix.profile != '' && format('-P {0}', matrix.profile) || '' }}
# Additional tests for selected modules
- name: HDFS file system cache isolated JVM tests
id: tests-hdfs-isolated
if: contains(matrix.modules, 'trino-hdfs')
run: |
$MAVEN test ${MAVEN_TEST} -pl :trino-hdfs -P test-isolated-jvm-suites
- name: Hadoop FileSystem Cloud Tests
id: tests-hdfs
env:
AWS_ACCESS_KEY_ID: ${{ vars.TRINO_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.TRINO_AWS_SECRET_ACCESS_KEY }}
AWS_REGION: ${{ vars.TRINO_AWS_REGION }}
S3_BUCKET: ${{ vars.TRINO_S3_BUCKET }}
S3_BUCKET_ENDPOINT: "s3.${{ vars.TRINO_AWS_REGION }}.amazonaws.com"
if: >-
contains(matrix.modules, 'trino-hdfs') && contains(matrix.profile, 'cloud-tests') &&
(env.CI_SKIP_SECRETS_PRESENCE_CHECKS != '' || env.AWS_ACCESS_KEY_ID != '' || env.AWS_SECRET_ACCESS_KEY != '')
run: |
$MAVEN test ${MAVEN_TEST} -pl :trino-hdfs -P cloud-tests
- name: S3 FileSystem Cloud Tests
id: tests-s3
env:
Expand Down Expand Up @@ -802,7 +787,6 @@ jobs:
has-failed-tests: >-
${{ steps.tests.outcome == 'failure'
|| steps.tests-hdfs-isolated.outcome == 'failure'
|| steps.tests-hdfs.outcome == 'failure'
|| steps.tests-s3.outcome == 'failure'
|| steps.tests-azure.outcome == 'failure'
|| steps.tests-gcs.outcome == 'failure'
Expand Down
5 changes: 3 additions & 2 deletions docs/src/main/sphinx/connector/delta-lake.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,9 @@ The connector supports accessing the following file systems:
* [](/object-storage/file-system-s3)
* [](/object-storage/file-system-hdfs)

You must enable and configure the specific file system access. [Legacy
support](file-system-legacy) is not recommended and will be removed.
Enable and configure the file system that your catalog uses. Use
`fs.hadoop.enabled` only for HDFS; see [legacy file system
support](file-system-legacy) for migration details.

### Delta Lake general configuration properties

Expand Down
5 changes: 3 additions & 2 deletions docs/src/main/sphinx/connector/hive.md
Original file line number Diff line number Diff line change
Expand Up @@ -342,8 +342,9 @@ The connector supports accessing the following file systems:
* [](/object-storage/file-system-s3)
* [](/object-storage/file-system-hdfs)

You must enable and configure the specific file system access. [Legacy
support](file-system-legacy) is not recommended and will be removed.
Enable and configure the file system that your catalog uses. Use
`fs.hadoop.enabled` only for HDFS; see [legacy file system
support](file-system-legacy) for migration details.

(hive-fte-support)=
### Fault-tolerant execution support
Expand Down
5 changes: 3 additions & 2 deletions docs/src/main/sphinx/connector/hudi.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,9 @@ The connector supports accessing the following file systems:
* [](/object-storage/file-system-s3)
* [](/object-storage/file-system-hdfs)

You must enable and configure the specific file system access. [Legacy
support](file-system-legacy) is not recommended and will be removed.
Enable and configure the file system that your catalog uses. Use
`fs.hadoop.enabled` only for HDFS; see [legacy file system
support](file-system-legacy) for migration details.

## SQL support

Expand Down
5 changes: 3 additions & 2 deletions docs/src/main/sphinx/connector/iceberg.md
Original file line number Diff line number Diff line change
Expand Up @@ -278,8 +278,9 @@ The connector supports accessing the following file systems:
* [](/object-storage/file-system-s3)
* [](/object-storage/file-system-hdfs)

You must enable and configure the specific file system access. [Legacy
support](file-system-legacy) is not recommended and will be removed.
Enable and configure the file system that your catalog uses. Use
`fs.hadoop.enabled` only for HDFS; see [legacy file system
support](file-system-legacy) for migration details.

## Type mapping

Expand Down
4 changes: 3 additions & 1 deletion docs/src/main/sphinx/connector/lakehouse.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,9 @@ The connector supports accessing the following file systems:
* [](/object-storage/file-system-s3)
* [](/object-storage/file-system-hdfs)

You must enable and configure the specific file system access.
Enable and configure the file system that your catalog uses. Use
`fs.hadoop.enabled` only for HDFS; see [legacy file system
support](file-system-legacy) for migration details.

## Examples

Expand Down
19 changes: 8 additions & 11 deletions docs/src/main/sphinx/object-storage.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,8 @@ system support.
- Activate the [native implementation for S3 storage
support](/object-storage/file-system-s3). Defaults to `false`.
* - `fs.hadoop.enabled`
- Activate [support for HDFS](/object-storage/file-system-hdfs) and [legacy
support for other file systems](file-system-legacy) using the HDFS
libraries. Defaults to `false`.
- Activate [support for HDFS](/object-storage/file-system-hdfs) using the
HDFS libraries. Defaults to `false`.
:::

(file-system-native)=
Expand All @@ -68,21 +67,19 @@ for use.
(file-system-legacy)=
## Legacy file system support

The default behavior uses legacy libraries that originate from the Hadoop
ecosystem. It should only be used for accessing the Hadoop Distributed File
The HDFS libraries are used for accessing the Hadoop Distributed File
System (HDFS):

- [](/object-storage/file-system-hdfs)

All four connectors can use the deprecated `hive.*` properties for access to
other object storage system as *legacy* support. These properties will be
removed in a future release. Additional documentation is available with the Hive
connector and relevant migration guides pages:
Legacy object storage support through `fs.hadoop.enabled` and deprecated
`hive.*` properties is no longer available. Use the native implementations for
Azure Storage, Google Cloud Storage, and S3. If you are migrating older catalog
configurations, refer to the following guides:

- [](/connector/hive)
- [Azure Storage migration from hive.azure.* properties](fs-legacy-azure-migration)
- [Google Cloud Storage migration from hive.gcs.* properties](fs-legacy-gcs-migration)
- [S3 migration from hive.s3.* properties](fs-legacy-s3-migration)
- [S3 migration from hive.s3.* properties](fs-legacy-s3-migration)

(object-storage-other)=
## Other object storage support
Expand Down
16 changes: 9 additions & 7 deletions docs/src/main/sphinx/object-storage/file-system-azure.md
Original file line number Diff line number Diff line change
Expand Up @@ -148,17 +148,19 @@ storage accounts:
(fs-legacy-azure-migration)=
## Migration from legacy Azure Storage file system

Trino includes legacy Azure Storage support to use with a catalog using the
Delta Lake, Hive, Hudi, or Iceberg connectors. Upgrading existing deployments to
the current native implementation is recommended. Legacy support is deprecated
and will be removed.
Previous Trino releases included a legacy Azure Storage file system
implementation used by catalogs configured with `fs.hadoop.enabled` and
`hive.azure.*` properties. That legacy support has been removed. Use the
native Azure file system implementation.

To migrate a catalog to use the native file system implementation for Azure,
make the following edits to your catalog configuration:

1. Add the `fs.native-azure.enabled=true` catalog configuration property.
2. Configure the `azure.auth-type` catalog configuration property.
3. Refer to the following table to rename your existing legacy catalog
2. If your catalog enabled `fs.hadoop.enabled` only for legacy Azure Storage
access, remove that property.
3. Configure the `azure.auth-type` catalog configuration property.
4. Refer to the following table to rename your existing legacy catalog
configuration properties to the corresponding native configuration
properties. Supported configuration values are identical unless otherwise
noted.
Expand Down Expand Up @@ -186,7 +188,7 @@ make the following edits to your catalog configuration:
-
:::

4. Remove the following legacy configuration properties if they exist in your
5. Remove the following legacy configuration properties if they exist in your
catalog configuration:

* `hive.azure.abfs-storage-account`
Expand Down
12 changes: 7 additions & 5 deletions docs/src/main/sphinx/object-storage/file-system-gcs.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,16 +91,18 @@ Cloud Storage:
(fs-legacy-gcs-migration)=
## Migration from legacy Google Cloud Storage file system

Trino includes legacy Google Cloud Storage support to use with a catalog using
the Delta Lake, Hive, Hudi, or Iceberg connectors. Upgrading existing
deployments to the current native implementation is recommended. Legacy support
is deprecated and will be removed.
Previous Trino releases included a legacy Google Cloud Storage file system
implementation used by catalogs configured with `fs.hadoop.enabled` and
`hive.gcs.*` properties. That legacy support has been removed. Use the native
Google Cloud Storage file system implementation.

To migrate a catalog to use the native file system implementation for Google
Cloud Storage, make the following edits to your catalog configuration:

1. Add the `fs.native-gcs.enabled=true` catalog configuration property.
2. Refer to the following table to rename your existing legacy catalog
2. If your catalog enabled `fs.hadoop.enabled` only for legacy Google Cloud
Storage access, remove that property.
3. Refer to the following table to rename your existing legacy catalog
configuration properties to the corresponding native configuration
properties. Supported configuration values are identical unless otherwise
noted.
Expand Down
14 changes: 8 additions & 6 deletions docs/src/main/sphinx/object-storage/file-system-s3.md
Original file line number Diff line number Diff line change
Expand Up @@ -290,16 +290,18 @@ Example JSON configuration:
(fs-legacy-s3-migration)=
## Migration from legacy S3 file system

Trino includes legacy Amazon S3 support to use with a catalog using the Delta
Lake, Hive, Hudi, or Iceberg connectors. Upgrading existing deployments to the
current native implementation is recommended. Legacy support is deprecated and
will be removed.
Previous Trino releases included a legacy Amazon S3 file system implementation
used by catalogs configured with `fs.hadoop.enabled` and `hive.s3.*`
properties. That legacy support has been removed. Use the native S3 file
system implementation.

To migrate a catalog to use the native file system implementation for S3, make
the following edits to your catalog configuration:

1. Add the `fs.native-s3.enabled=true` catalog configuration property.
2. Refer to the following table to rename your existing legacy catalog
2. If your catalog enabled `fs.hadoop.enabled` only for legacy S3 access,
remove that property.
3. Refer to the following table to rename your existing legacy catalog
configuration properties to the corresponding native configuration
properties. Supported configuration values are identical unless otherwise
noted.
Expand Down Expand Up @@ -395,7 +397,7 @@ the following edits to your catalog configuration:
-
:::

1. Remove the following legacy configuration properties if they exist in your
4. Remove the following legacy configuration properties if they exist in your
catalog configuration:

* `hive.s3.storage-class`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,13 +80,7 @@ protected void setup(Binder binder)
newOptionalBinder(binder, HdfsFileSystemLoader.class);

if (config.isHadoopEnabled()) {
HdfsFileSystemLoader loader = new HdfsFileSystemLoader(
getProperties(),
!config.isNativeAzureEnabled(),
!config.isNativeGcsEnabled(),
!config.isNativeS3Enabled(),
catalogName,
context);
HdfsFileSystemLoader loader = new HdfsFileSystemLoader(getProperties(), catalogName, context);

loader.configure().forEach((name, securitySensitive) ->
consumeProperty(new ConfigPropertyMetadata(name, securitySensitive)));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,7 @@ final class HdfsFileSystemLoader
private final HdfsClassLoader classLoader;
private final Object manager;

public HdfsFileSystemLoader(
Map<String, String> config,
boolean azureEnabled,
boolean gcsEnabled,
boolean s3Enabled,
String catalogName,
ConnectorContext context)
public HdfsFileSystemLoader(Map<String, String> config, String catalogName, ConnectorContext context)
{
Class<?> clazz = tryLoadExistingHdfsManager();

Expand Down Expand Up @@ -73,8 +67,8 @@ public HdfsFileSystemLoader(
}

try (var _ = new ThreadContextClassLoader(classLoader)) {
manager = clazz.getConstructor(Map.class, boolean.class, boolean.class, boolean.class, String.class, ConnectorContext.class)
.newInstance(config, azureEnabled, gcsEnabled, s3Enabled, catalogName, context);
manager = clazz.getConstructor(Map.class, String.class, ConnectorContext.class)
.newInstance(config, catalogName, context);
}
catch (ReflectiveOperationException e) {
throw new RuntimeException(e);
Expand Down
Loading