-
Notifications
You must be signed in to change notification settings - Fork 233
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
Flink app hosted in AWS trying to publish to GCP and throwing NPE at com.google.auth.oauth2.InternalAwsSecurityCredentialsSupplier.retrieveResource #1538
Comments
pom.xml: `
` |
I'm curious if it's not related to #1408 |
@lsirac This is probably something that you are more familiar with. Potentially dealing with Workload Identity Federation. |
hi, we were able to diagnose the issue. I haven't found a way to fix/patch transportFactory on existing ExternalAccountCredentials object. solution for this is to use different Flink connector that is correctly setting up credentials from local ADC via provider function. |
Thanks for the context and explanation. It seems like using a different Flink connector (PubSubSinkV2) is probably the suggested workaround for this unless that brings other a different set of issues. I'm not too sure context of serializing the Credentials via Serializable or why transportFactory is marked as transient. |
Environment details
We are using Flink 1.19 with Java 11 hosted on an EC2 in AWS environment and trying to publish messages to GCP pub/sub. We are using Workload Identity Federation to exchange tokens between AWS and GCP.
We are using PubSubSink connector from Flink Docs: https://nightlies.apache.org/flink/flink-docs-release-1.19/docs/connectors/datastream/pubsub/#pubsub-sink
Our code only generate some mock data and let the connector publish without any complex logic, only for validation.
Stack trace
The error looks in this line of the code inside this repo:
com.google.auth.oauth2.InternalAwsSecurityCredentialsSupplier.retrieveResource(InternalAwsSecurityCredentialsSupplier.java:204)
How can we solve this?
Thanks!
The text was updated successfully, but these errors were encountered: