-
Notifications
You must be signed in to change notification settings - Fork 176
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
[master] Bug 551815: When an entity with an aggregate with all fields set to null is changed to null for the aggregate field then Eclipselink executes a bogus no-op SQL update statement #536
base: master
Are you sure you want to change the base?
Conversation
… set to null is changed to null for the aggregate field then Eclipselink executes a bogus no-op SQL update statement Signed-off-by: Eduardo Perez Ureta <[email protected]>
return true; | ||
} | ||
final Set<java.lang.reflect.Field> fields = getAllFields(new HashSet<java.lang.reflect.Field>(), o.getClass()); | ||
for (final java.lang.reflect.Field f : fields) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If Object o
is not null and contains no fields, then return true
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that is intended as there should not be any difference. Do you see any problem in that behavior?
...ipselink.core.test/src/org/eclipse/persistence/testing/models/aggregate/SimpleAggregate.java
Show resolved
Hide resolved
...k.core.test/src/org/eclipse/persistence/testing/models/aggregate/SimpleAggregateProject.java
Show resolved
Hide resolved
380cbb3
to
5c56125
Compare
How does this deal with fields marked '@transient'? What if app uses annotations on methods and not on fields? ie eclipselink can trigger getter which in turn returns something different from what is stored in the field.. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
instead of direct reflection, appropriate accessors and possibly objectbuilder should be used
5c56125
to
0feb9cb
Compare
@lukasj I have changed the code to use ObjectBuilder instead. Is it OK now? |
0feb9cb
to
fc72bd2
Compare
fc72bd2
to
194db07
Compare
194db07
to
0addc8c
Compare
Could You please fix year in the copyright header:
same case for #606 |
c7d2d4c
to
a407560
Compare
No description provided.