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

Revise simple query and update value conversion #1384

Closed
mp911de opened this issue May 25, 2023 · 0 comments
Closed

Revise simple query and update value conversion #1384

mp911de opened this issue May 25, 2023 · 0 comments
Labels
type: bug A general bug

Comments

@mp911de
Copy link
Member

mp911de commented May 25, 2023

Right now, we do not correctly convert simple values associated with properties. For example:

class Foo {
  long bar;
}

Query.query(Criteria.where("bar").is(1))

The bar value remains integer and Cassandra rejects such a value because it does not match the column type.

Out of #1383, we discovered that we do not apply conversion for values associated with a property although we have all metadata in place.

Also, repository queries apply conversion twice which might interfere with double value conversion. Beyond that, double-conversion is not necessary. We should fix the issue.

@mp911de mp911de added the type: bug A general bug label May 25, 2023
mp911de added a commit that referenced this issue May 25, 2023
We now defer simple value conversion in the converter to ensure we're converting all complex values first. We also apply conversion if the value isn't assignable to the requested target type.

We removed double-conversion from part-tree queries to avoid duplicate conversion.

Closes #1384
mp911de added a commit that referenced this issue May 25, 2023
Add missing generics. Inline superfluous methods.

See #1384
mp911de added a commit that referenced this issue May 25, 2023
Add missing generics. Inline superfluous methods.

See #1384
mp911de added a commit that referenced this issue May 25, 2023
We now defer simple value conversion in the converter to ensure we're converting all complex values first. We also apply conversion if the value isn't assignable to the requested target type.

We removed double-conversion from part-tree queries to avoid duplicate conversion.

Closes #1384
mp911de added a commit that referenced this issue May 25, 2023
Add missing generics. Inline superfluous methods.

See #1384
@mp911de mp911de added this to the 4.0.7 (2022.0.7) milestone May 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug A general bug
Projects
None yet
Development

No branches or pull requests

1 participant