-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Closed
Milestone
Description
Looks like transient
Fields are only ignored in cases if there is no explicit or just visible accessors, and as such Field like this:
public class Sizable {
public transient int size; // lazily calculated
public int getSize() {
...
}
}
would actually try to use field size
for setting value during deserialization. Without getSize()
it would, however, be dropped despite being visible otherwise.
While this is not often problem with POJOs it is problematic with many JDK types (and probably some 3rd party libraries); and intent was never to "pull in" such Fields. It does, for example, break handling of LinkedList
for JDK 17 and above, in cases where it (or sub-class) is to be serialized "as POJO".
So, for 2.15 let's prune these Fields.
Metadata
Metadata
Assignees
Labels
No labels