Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[#6363] improvment(bundle-gcp): Shade some GCP IAM classes in gcp-bundles to avoid possible conflict #6364

Merged
merged 2 commits into from
Jan 26, 2025

Conversation

yuqi1129
Copy link
Contributor

What changes were proposed in this pull request?

Shade some GCP, gcp and probobuf classes to avoid conflicts with GCP IAM classes.

Why are the changes needed?

To avoid possible class conflicts.

Fix: #6363

Does this PR introduce any user-facing change?

N/A.

How was this patch tested?

existing UTs and ITs.

@yuqi1129 yuqi1129 self-assigned this Jan 24, 2025
@yuqi1129 yuqi1129 requested a review from FANNG1 January 26, 2025 01:51
@FANNG1
Copy link
Contributor

FANNG1 commented Jan 26, 2025

In your enviroment, there are some existing GCP IAM classes conflict with the GCP IAM classes in gcp-bundle?

@@ -42,6 +42,12 @@ tasks.withType(ShadowJar::class.java) {
relocate("com.google.common", "org.apache.gravitino.gcp.shaded.com.google.common")
relocate("com.fasterxml", "org.apache.gravitino.gcp.shaded.com.fasterxml")
relocate("org.eclipse.jetty", "org.apache.gravitino.gcp.shaded.org.eclipse.jetty")
Copy link
Contributor

Choose a reason for hiding this comment

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

why not shade the package in gcp module too?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Gravitino server will use gcp-bundle for Hadoop catalog only. The conflict only exists in Gravitino server now, so do you mean you need to also consider module gcp for future use case?

Copy link
Contributor

Choose a reason for hiding this comment

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

OH, seems no requrirement.

@@ -42,6 +42,12 @@ tasks.withType(ShadowJar::class.java) {
relocate("com.google.common", "org.apache.gravitino.gcp.shaded.com.google.common")
relocate("com.fasterxml", "org.apache.gravitino.gcp.shaded.com.fasterxml")
relocate("org.eclipse.jetty", "org.apache.gravitino.gcp.shaded.org.eclipse.jetty")
relocate("com.google.protobuf", "org.apache.gravitino.gcp.shaded.com.google.protobuf")
relocate("io.grpc", "org.apache.gravitino.gcp.shaded.io.grpc")
Copy link
Contributor

Choose a reason for hiding this comment

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

please keep in alphabetical order

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@yuqi1129
Copy link
Contributor Author

In your enviroment, there are some existing GCP IAM classes conflict with the GCP IAM classes in gcp-bundle?

Yes, the module authorizaion-gcp-iam will also contain some common class that conflicts with gcp-bundle

@tengqm
Copy link
Contributor

tengqm commented Jan 26, 2025

lgtm

@FANNG1 FANNG1 merged commit 578adde into apache:main Jan 26, 2025
27 checks passed
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.

[Improvement] Shade GCP IAM related class in module bundles-gcp to avoid conflicts with gcp-authorization
3 participants