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

Correct retrieving deserializer / serializer from the bean context #859

Merged
merged 2 commits into from
Jun 20, 2024

Conversation

dstepanov
Copy link
Contributor

No description provided.

@dstepanov dstepanov requested a review from graemerocher June 6, 2024 07:56
if (injectionPoint instanceof ArgumentInjectionPoint<?, ?> argumentInjectionPoint) {
Argument typeParameter = argumentInjectionPoint.getArgument().getTypeParameters()[0];
DefaultSerdeRegistry defaultSerdeRegistry = serdeRegistry.get();
return (S) defaultSerdeRegistry.findSerializer(typeParameter);
Copy link
Contributor

Choose a reason for hiding this comment

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

does it need a call to createSpecific?

if (injectionPoint instanceof ArgumentInjectionPoint<?, ?> argumentInjectionPoint) {
Argument typeParameter = argumentInjectionPoint.getArgument().getTypeParameters()[0];
DefaultSerdeRegistry defaultSerdeRegistry = serdeRegistry.get();
return (S) defaultSerdeRegistry.findDeserializer(typeParameter);
Copy link
Contributor

Choose a reason for hiding this comment

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

does it need a call to createSpecific?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes

def deserializer = beanContext.getBean(Argument.of(Serializer, Argument.mapOf(String, Object)))

then:
deserializer
Copy link
Contributor

Choose a reason for hiding this comment

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

add tests that actually use the serialiser/deserializer to serialize

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added

@dstepanov dstepanov requested a review from graemerocher June 20, 2024 07:35
Copy link

@graemerocher graemerocher merged commit 3e6e150 into 2.10.x Jun 20, 2024
17 checks passed
@graemerocher graemerocher deleted the correl branch June 20, 2024 08:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants