<div dir="ltr"><div><div><div><div><div><div><div>Hi all,<br><br></div>With the ongoing encoding revamp work on Infinispan, time to decide how to handle the rest server. <br><br></div>The rest server currently stores along with each entry, a string representing the MimeType of that entry, which allows the user to POST/PUT each entry with its own format. <br><br></div>At request time, using the accept header, the user can request the entry in a particular format, and the rest server internally extracts the mime type from the entry and converts it accordingly.<br><br></div><div>The issue with this approach is, apart from the extra space required, it makes it challenging to expose via rest anything less trivial than put/get. Think for example querying, consistent hash calculations, stream operations: all those features will have a hard time dealing with a cache where each entry has a different format.<br></div><div><br></div>Proposal:<br><br></div>Remove this behavior completely. For a certain cache, all entries will be homogeneous, just like <br>Hot Rod, Memcached and embedded. The user can optionally configure the MimeType at cache level.<br><br></div><div>Impacts:<br></div><div><br></div><div>- It may be required for users to add the media type configuration to the cache, if supporting<br></div><div>multiple formats is required;<br></div><div>- Migrating from 9.1 to 9.2 may require re-populating the cache if multiple formats are being used;<br></div><div>- From the API perspective, I don&#39;t expect any change: POST/PUT with multiple formats should be still supported, as the internal transcoding should convert them on the fly to the unified configured format.<br><br><br></div><div>Thoughts?<br></div><div><br><br></div></div></div>