response mime type

classic Classic list List threaded Threaded
4 messages Options
sekaijin sekaijin
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

response mime type

hi,

I use a tool that automatically parse xml or json responses when the mime / type is properly informed.

Jolokia but the answer is plain / text why not using application / json?

do I set jolokia to use application / json?

thank
JYT
Tester Tester
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: response mime type

Read the documentation:

http://jolokia.org/reference/html/protocol.html#request-response

Search for "application/json" on this page.
sekaijin sekaijin
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: response mime type

Thank I've trying
GET /read/fr.aphp.ati.eai.hermes:type=admin,name=hermes-environnement?mimeType=application/json

it works fine.

A+JYT
sekaijin sekaijin
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: response mime type

In reply to this post by Tester
Hi,

I come back to this discussion because, when I'm reading the doc I find that a detail is not very homogeneous.

in the doc: https://jolokia.org/reference/html/agents.html
Section: JEE Agent (WAR)
a parameter is present to set the default mimeType
mimeType MIME to use for the JSON responses Default: text / plain
Allowing in JEE to configure application/json as default

As for the agent: OSGi Agents
this configuration is impossible.

to make things uniform I think this parameter should be present for all agents.

A+JYT
Loading...