Skip to content

[#5756] Bug Fix : Warehouse parameter systematically required - #5923

Merged
jerryshao merged 13 commits into
apache:mainfrom
fsalhi2:issue-5756
Dec 23, 2024
Merged

[#5756] Bug Fix : Warehouse parameter systematically required #5923
jerryshao merged 13 commits into
apache:mainfrom
fsalhi2:issue-5756

Conversation

@fsalhi2

@fsalhi2 fsalhi2 commented Dec 19, 2024

Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

Removed the systematic validations in Iceberg Config and modified the instantiation of the warehouse attribute and uri attribute in the IcebergCatalogWrapper to conform with the new possibility (REST).

Why are the changes needed?

The bug was blocking the creation of a rest catalog.

Fix: #5756

Does this PR introduce any user-facing change?

No

How was this patch tested?

./gradlew build && compileDistribution && assembleDistribution + creation of the docker image there : https://hub.docker.com/r/fsalhi2/gravitino

Started gravitino with such configs :

### Gravitino General Settings

gravitino.auxService.names = iceberg-rest
gravitino.iceberg-rest.classpath = iceberg-rest-server/libs, iceberg-rest-server/conf

### HTTP Server

gravitino.iceberg-rest.host = 0.0.0.0
gravitino.iceberg-rest.httpPort = 9001

### Storage

gravitino.iceberg-rest.io-impl = org.apache.iceberg.aws.s3.S3FileIO
gravitino.iceberg-rest.s3-access-key-id = XXXXX
gravitino.iceberg-rest.s3-secret-access-key = XXXXXX
gravitino.iceberg-rest.s3-path-style-access = true
gravitino.iceberg-rest.s3-endpoint = http://minio:9000/
gravitino.iceberg-rest.s3-region = us-east-1

### JDBC

gravitino.iceberg-rest.catalog-backend = jdbc
gravitino.iceberg-rest.uri = jdbc:mysql://mysql:3306/
gravitino.iceberg-rest.warehouse = s3://lake/catalog
gravitino.iceberg-rest.jdbc.user = root
gravitino.iceberg-rest.jdbc.password = XXXXXX
gravitino.iceberg-rest.jdbc-driver = com.mysql.cj.jdbc.Driver

Was able to create a catalog through Web UI and start working on the scheme.

Comment thread gradle.properties
WAREHOUSE,
"Iceberg catalog warehouse config",
false /* immutable */,
null, /* defaultValue */

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could have prevented this kind of obvious errors if we apply a stricter coding style.
Can you help also wrap line 76?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like that this is not updated yet?

…ments in Properties Metadata for Iceberg Catalog\nTesting that warehouse is not blank if necessary for some type of catalog for Iceberg.
@fsalhi2

fsalhi2 commented Dec 21, 2024

Copy link
Copy Markdown
Contributor Author

@FANNG1 @tengqm The changes have been done.

@tengqm

tengqm commented Dec 22, 2024

Copy link
Copy Markdown
Contributor

lgtm

Comment thread gradle.properties Outdated

# version that is going to be updated automatically by releases
version = 0.8.0-incubating-SNAPSHOT
version = 0.7.0-incubating-SNAPSHOT

@FANNG1 FANNG1 Dec 22, 2024

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please don't update the properties in gradle.properties, version is updated when we start releasing a new version.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is fixed now, thanks for the feedback

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

revert pythonVersion too?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oops sorry, that's done

@FANNG1

FANNG1 commented Dec 22, 2024

Copy link
Copy Markdown
Contributor

LGTM except one comments

@jerryshao

Copy link
Copy Markdown
Contributor

Merging to main branch, thanks @fsalhi2 for your contribution.

@jerryshao
jerryshao merged commit 441e6ed into apache:main Dec 23, 2024
Abyss-lord pushed a commit to Abyss-lord/gravitino that referenced this pull request Dec 23, 2024
…pache#5923)

### What changes were proposed in this pull request?

Removed the systematic validations in Iceberg Config and modified the
instantiation of the warehouse attribute and uri attribute in the
IcebergCatalogWrapper to conform with the new possibility (REST).

### Why are the changes needed?

The bug was blocking the creation of a rest catalog.

Fix: [apache#5756](apache#5756)

### Does this PR introduce _any_ user-facing change?

No

### How was this patch tested?

./gradlew build && compileDistribution && assembleDistribution +
creation of the docker image there :
https://hub.docker.com/r/fsalhi2/gravitino

Started gravitino with such configs : 

```
### Gravitino General Settings

gravitino.auxService.names = iceberg-rest
gravitino.iceberg-rest.classpath = iceberg-rest-server/libs, iceberg-rest-server/conf

### HTTP Server

gravitino.iceberg-rest.host = 0.0.0.0
gravitino.iceberg-rest.httpPort = 9001

### Storage

gravitino.iceberg-rest.io-impl = org.apache.iceberg.aws.s3.S3FileIO
gravitino.iceberg-rest.s3-access-key-id = XXXXX
gravitino.iceberg-rest.s3-secret-access-key = XXXXXX
gravitino.iceberg-rest.s3-path-style-access = true
gravitino.iceberg-rest.s3-endpoint = http://minio:9000/
gravitino.iceberg-rest.s3-region = us-east-1

### JDBC

gravitino.iceberg-rest.catalog-backend = jdbc
gravitino.iceberg-rest.uri = jdbc:mysql://mysql:3306/
gravitino.iceberg-rest.warehouse = s3://lake/catalog
gravitino.iceberg-rest.jdbc.user = root
gravitino.iceberg-rest.jdbc.password = XXXXXX
gravitino.iceberg-rest.jdbc-driver = com.mysql.cj.jdbc.Driver
```

Was able to create a catalog through Web UI and start working on the
scheme.
Abyss-lord pushed a commit to Abyss-lord/gravitino that referenced this pull request Dec 29, 2024
…pache#5923)

### What changes were proposed in this pull request?

Removed the systematic validations in Iceberg Config and modified the
instantiation of the warehouse attribute and uri attribute in the
IcebergCatalogWrapper to conform with the new possibility (REST).

### Why are the changes needed?

The bug was blocking the creation of a rest catalog.

Fix: [apache#5756](apache#5756)

### Does this PR introduce _any_ user-facing change?

No

### How was this patch tested?

./gradlew build && compileDistribution && assembleDistribution +
creation of the docker image there :
https://hub.docker.com/r/fsalhi2/gravitino

Started gravitino with such configs : 

```
### Gravitino General Settings

gravitino.auxService.names = iceberg-rest
gravitino.iceberg-rest.classpath = iceberg-rest-server/libs, iceberg-rest-server/conf

### HTTP Server

gravitino.iceberg-rest.host = 0.0.0.0
gravitino.iceberg-rest.httpPort = 9001

### Storage

gravitino.iceberg-rest.io-impl = org.apache.iceberg.aws.s3.S3FileIO
gravitino.iceberg-rest.s3-access-key-id = XXXXX
gravitino.iceberg-rest.s3-secret-access-key = XXXXXX
gravitino.iceberg-rest.s3-path-style-access = true
gravitino.iceberg-rest.s3-endpoint = http://minio:9000/
gravitino.iceberg-rest.s3-region = us-east-1

### JDBC

gravitino.iceberg-rest.catalog-backend = jdbc
gravitino.iceberg-rest.uri = jdbc:mysql://mysql:3306/
gravitino.iceberg-rest.warehouse = s3://lake/catalog
gravitino.iceberg-rest.jdbc.user = root
gravitino.iceberg-rest.jdbc.password = XXXXXX
gravitino.iceberg-rest.jdbc-driver = com.mysql.cj.jdbc.Driver
```

Was able to create a catalog through Web UI and start working on the
scheme.
danhuawang pushed a commit to danhuawang/gravitino that referenced this pull request Jun 9, 2026
…pache#5923)

### What changes were proposed in this pull request?

Removed the systematic validations in Iceberg Config and modified the
instantiation of the warehouse attribute and uri attribute in the
IcebergCatalogWrapper to conform with the new possibility (REST).

### Why are the changes needed?

The bug was blocking the creation of a rest catalog.

Fix: [apache#5756](apache#5756)

### Does this PR introduce _any_ user-facing change?

No

### How was this patch tested?

./gradlew build && compileDistribution && assembleDistribution +
creation of the docker image there :
https://hub.docker.com/r/fsalhi2/gravitino

Started gravitino with such configs : 

```
### Gravitino General Settings

gravitino.auxService.names = iceberg-rest
gravitino.iceberg-rest.classpath = iceberg-rest-server/libs, iceberg-rest-server/conf

### HTTP Server

gravitino.iceberg-rest.host = 0.0.0.0
gravitino.iceberg-rest.httpPort = 9001

### Storage

gravitino.iceberg-rest.io-impl = org.apache.iceberg.aws.s3.S3FileIO
gravitino.iceberg-rest.s3-access-key-id = XXXXX
gravitino.iceberg-rest.s3-secret-access-key = XXXXXX
gravitino.iceberg-rest.s3-path-style-access = true
gravitino.iceberg-rest.s3-endpoint = http://minio:9000/
gravitino.iceberg-rest.s3-region = us-east-1

### JDBC

gravitino.iceberg-rest.catalog-backend = jdbc
gravitino.iceberg-rest.uri = jdbc:mysql://mysql:3306/
gravitino.iceberg-rest.warehouse = s3://lake/catalog
gravitino.iceberg-rest.jdbc.user = root
gravitino.iceberg-rest.jdbc.password = XXXXXX
gravitino.iceberg-rest.jdbc-driver = com.mysql.cj.jdbc.Driver
```

Was able to create a catalog through Web UI and start working on the
scheme.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug report] The API for creating an Iceberg catalog has a deprecated parameter "warehouse" that is required in the HTTP payload

4 participants