Details
-
Bug
-
Resolution: Done
-
Major
-
11.0.0.Final
-
None
-
DataGrid Sprint #45
Description
The old-style eviction attributes (storage-type, eviction-strategy, eviction-type, size) are available programmatically both via memory() and via memory().heapConfiguration(), and changes to either the new attributes or to the legacy attributes should update all of them.
The builder does not expose heapConfiguration(), but parsing a JSON with a legacy configuration (e.g. {"local-cache":{ "memory":{"object":{"size":5000}}}}) will set those attributes directly.
Additionally, the XSD does not include values OBJECT and BINARY for the storage attribute, but the parser accepts them, and serializing a configuration will sometimes write them in the XML. In theory we can replace OBJECT with HEAP, but we can't do the same trick with BINARY because we don't know the media type in the builder (it depends on the user marshaller). This may change in the future, but it's better if we preserve the actual values for now.