]
Tristan Tarrant updated ISPN-8867:
----------------------------------
Status: Resolved (was: Pull Request Sent)
Fix Version/s: 9.2.0.Final
Resolution: Done
REST server fails to convert between text formats and octet-stream
------------------------------------------------------------------
Key: ISPN-8867
URL:
https://issues.jboss.org/browse/ISPN-8867
Project: Infinispan
Issue Type: Bug
Affects Versions: 9.2.0.CR3
Reporter: Gustavo Fernandes
Assignee: Gustavo Fernandes
Fix For: 9.2.0.Final
Using the default cache with no MediaType configuration:
The following request returns error 500:
{noformat}
curl -v -u user:pass -XPUT -H "Content-type: application/xml" -d
"<root>element</root>"
http://localhost:8080/rest/default/1
{noformat}
The following request succeds:
{noformat}
curl -v -u user:pass -XPUT -H "Content-type: application/json" -d '{
"name": "test"}'
http://localhost:8080/rest/default/2
{noformat}
But when reading it back it returns "[B@26197e2f" instead of the inserted
document.
{noformat}
curl -v -u user:pass -H "Content-type: text/plain"
http://localhost:8080/rest/default/2
{noformat}