-
Notifications
You must be signed in to change notification settings - Fork 166
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
Integration support for glueSchemaRegistry #206
Comments
There is the logic like this in the component:
So, you can build that Does it make sense? |
The message that we receive is of type |
That's not related. Please, elaborate. |
Sorry - Message payload is of type |
Since you point to the code in the
It is just a fact that you need to do something similar to create See docs for more info: https://docs.spring.io/spring-integration/docs/current/reference/html/message-transformation.html#transformer-annotation. Your story sounds more like StackOverflow question. Anyway: what is your code? How do you send that |
I am using spring cloud steam with |
OK. That's much better and thank you for more info. Does that convert your data correctly using its Avro approach? Maybe there is a chance that you can share with us a simple project revealing the problem? |
@artembilan - Thanks for your help through this. |
I see in your code Side question: is it really correct to convert via Apache Avro first and then re-convert with that Glue Schema? |
How about to use an |
Forget my previous question: it is not related since it talks about Apache Kafka. So, here is a doc: https://docs.aws.amazon.com/glue/latest/dg/schema-registry-integrations.html#schema-registry-integrations-kds. And they indeed shows that we have to use I guess as the fix we can add an option to inject a Let me double check the code how proposed workaround can work! |
So, if you produce a
It always expects conversion to be done to the |
I'm able to supply
|
I see your point. Meanwhile as another workaround, in addition to what we have so far with you about
|
Thanks, @artembilan - The suggestion that you provided above worked. Is there a way to get the schema and partition key like the way we are getting in |
Sorry, not sure in your question. I assumed since you have managed to create a Please, share what you have so far and how you provide the
I'm not sure from where to take that The AWS official doc shows only this for KPL sample:
They also have this sample:
The docs is still the one I have shared before: https://docs.aws.amazon.com/glue/latest/dg/schema-registry-integrations.html#schema-registry-integrations-kds |
I have pushed my latest code to the sample repo here. Currently to validate the changes I have hardcoded the |
Not sure what you want to hear from me since there is nothing what the framework can help, but there is indeed cannot be.
So, we got only the Perhaps you can inject a
And that one may give you an access to the As the fix for this issue I definitely going to expose a |
Thank you @artembilan |
Fixes spring-projects/spring-integration-aws#206 * Provide a Glue Schema support for `KplMessageHandler`. When `UserRecord` is built from the request message, a `glueSchemaExpression` is evaluated to supply into a `UserRecord` to produce. The `GlueSchemaRegistryConfiguration` must be supplied into a `KinesisProducerConfiguration` * Fix the `buildPutRecordRequest()` algorithm to copy the data from the `UserRecord` in the request message payload instead of false-leading expression evaluations and conversions from the request message **Cherry-pick to `2.5.x`**
Fixes spring-projects/spring-integration-aws#206 * Provide a Glue Schema support for `KplMessageHandler`. When `UserRecord` is built from the request message, a `glueSchemaExpression` is evaluated to supply into a `UserRecord` to produce. The `GlueSchemaRegistryConfiguration` must be supplied into a `KinesisProducerConfiguration` * Fix the `buildPutRecordRequest()` algorithm to copy the data from the `UserRecord` in the request message payload instead of false-leading expression evaluations and conversions from the request message **Cherry-pick to `2.5.x`**
Hi there,
I'm trying to integrate glueSchemaRegistry with Kinesis using KPL/KCL.
Upon debugging the code I came across these lines of code and found that we don't have a way to pass the schema along the
UserRecord
which is callingKinesisProducer.addUserRecord()
. The following piece of code is never execute because of null schema object.The text was updated successfully, but these errors were encountered: