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

MappingRelationalConverter Add Converter Condition #1876

Closed
wants to merge 5 commits into from
Closed

MappingRelationalConverter Add Converter Condition #1876

wants to merge 5 commits into from

Conversation

ngocnhan-tran1996
Copy link
Contributor

Issue: #1842

Please tell me if I miss something

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Sep 7, 2024
@schauder schauder self-assigned this Sep 12, 2024
Copy link
Contributor

@schauder schauder left a comment

Choose a reason for hiding this comment

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

When I build the project with

./mvnw clean verify 

I get the following Error:

[INFO] Running org.springframework.data.relational.core.conversion.MappingRelationalConverterUnitTests
[ERROR] Tests run: 12, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.078 s <<< FAILURE! -- in org.springframework.data.relational.core.conversion.MappingRelationalConverterUnitTests
[ERROR] org.springframework.data.relational.core.conversion.MappingRelationalConverterUnitTests.shouldApplyGenericTypeConverter -- Time elapsed: 0.006 s <<< ERROR!
java.lang.ClassCastException: class java.lang.String cannot be cast to class org.springframework.data.relational.core.conversion.MappingRelationalConverterUnitTests$GenericClass (java.lang.String is in module java.base of loader 'bootstrap'; org.springframework.data.relational.core.conversion.MappingRelationalConverterUnitTests$GenericClass is in unnamed module of loader 'app')
	at org.springframework.data.relational.core.conversion.MappingRelationalConverterUnitTests.shouldApplyGenericTypeConverter(MappingRelationalConverterUnitTests.java:224)
	at java.base/java.lang.reflect.Method.invoke(Method.java:580)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1596)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1596)

@ngocnhan-tran1996
Copy link
Contributor Author

@schauder

I updated my code, please review

@schauder schauder linked an issue Sep 16, 2024 that may be closed by this pull request
schauder pushed a commit that referenced this pull request Sep 16, 2024
schauder added a commit that referenced this pull request Sep 16, 2024
Restructure test.
Remove redundant code.
Formatting.

Original pull request #1876
See #1842
schauder pushed a commit that referenced this pull request Sep 16, 2024
schauder added a commit that referenced this pull request Sep 16, 2024
Restructure test.
Remove redundant code.
Formatting.

Original pull request #1876
See #1842
schauder pushed a commit that referenced this pull request Sep 16, 2024
schauder added a commit that referenced this pull request Sep 16, 2024
Restructure test.
Remove redundant code.
Formatting.

Original pull request #1876
See #1842
@schauder
Copy link
Contributor

Thanks, that is merged.

@schauder schauder closed this Sep 16, 2024
@schauder schauder added type: regression A regression from a previous release and removed status: waiting-for-triage An issue we've not yet triaged labels Sep 16, 2024
@schauder schauder added this to the 3.2.11 (2023.1.11) milestone Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: regression A regression from a previous release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ConversionFailedException on generic Entity Id and custom converter
3 participants