[infinispan-issues] [JBoss JIRA] (ISPN-8867) REST server fails to convert between text formats and octet-stream

Gustavo Fernandes (JIRA) issues at jboss.org
Thu Feb 22 07:29:00 EST 2018


Gustavo Fernandes created ISPN-8867:
---------------------------------------

             Summary: 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
            Reporter: Gustavo Fernandes
            Assignee: Gustavo Fernandes


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 at 26197e2f" instead of the inserted document.
{noformat}
curl -v -u user:pass -H "Content-type: text/plain"  http://localhost:8080/rest/default/2
{noformat}




--
This message was sent by Atlassian JIRA
(v7.5.0#75005)


More information about the infinispan-issues mailing list