-
Enhancement
-
Resolution: Done
-
Major
-
None
-
None
-
None
Several enhancements will need to be made to the Hot Rod protocol to work with transcoding:
Cache Writes (key + value)
- Cache write operations that include values should have an optional parameter to be able to define the MIME type of the key and value that is being written. When the optional parameter is sent to the server, it will enable the server to implicitly discover what the types of the key+value are.
- Once the first cache write has determined the key+value types, the clients do not need to send them again. If the client sends different types for the same cache, it should either result in the server ignoring it or an error (the former is preferable).
- To avoid sending unnecessary data, advanced clients could cache the key+value type for a given cache after the first write request and then don't send it again.
Cache reads
- Any operation that involves retrieving data should optionally take the type that the value should be transcoded to when returning it back to the client. This enables data to be read in different formats.
- Within these operations, write operations that return previous values should be included.