You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
JSONFormatter with PdxInstance(Impl) loses type metadata, id, among other things: Object (using PDX serializer) -> PDX (using JSONFormatter.toJSON(:PdxInstance)) -> JSON (using JSONFormatter.fromJSON(..)) -> PDX (using PdxInstance.getObject()) -> PdxInstance (expect Object here)
PdxInstance.getObject() cannot handle Java 8 types in general (e.g. Optional), JSR-310 (Time) types in particular, and parameter names even though Jackson does
I suspect Apache Geode will not work with Jackson 3, which is based on Java 8 by default, due to serialization issues
PDX is not properly extensible (e.g. you cannot "configure" the static ObjectMapper used by PdxInstanceImpl in the getObject() method, which is blocker issue for many JSON doc types).
The text was updated successfully, but these errors were encountered:
jxblum
changed the title
Consider replacing JSONFormatter with a new PdxJsonObjectMapper
[OPTIONAL] Consider replacing JSONFormatter with a new PdxJsonObjectMapper
Aug 5, 2023
Currently, the Apache Geode
JSONFormatter
class (source) andPdxInstance
types (e.g.PdxInstanceImpl
) has the following problems:JSONFormatter
cannot handle (top-level) JSON arraysJSONFormatter
cannot handle JSON type metadata (when activating JacksonObjectMapper
default typing)JSONFormatter
withPdxInstance(Impl)
loses type metadata, id, among other things:Object (using PDX serializer) -> PDX (using JSONFormatter.toJSON(:PdxInstance)) -> JSON (using JSONFormatter.fromJSON(..)) -> PDX (using PdxInstance.getObject()) -> PdxInstance (expect Object here)
PdxInstance.getObject()
cannot handle Java 8 types in general (e.g.Optional
), JSR-310 (Time) types in particular, and parameter names even though Jackson doesObjectMapper
used byPdxInstanceImpl
in thegetObject()
method, which is blocker issue for many JSON doc types).The text was updated successfully, but these errors were encountered: