0

I am unable to read the xml value from @QueryParam using restful service in mule.

@Path("/hello")
public class Resttest {
@GET
@Produces("text/xml")
public String sayHelloWithUri(@QueryParam("body") String g) {
System.out.println("............................wdwedfwfw2"+g);
return g;
}

request xml : http://< mydomain>:8080/jersey/hello/?body=< ?xml version="1.0" encoding="UTF-8" ?>< Options>< Option>car< /Option>< Option>Bike< /Option>< /Options>

Kalyan Nemani
  • 79
  • 2
  • 6

1 Answers1

0

What is the Mule configuration you're using?

It works with this one:

<flow name="TesstFlow">
    <http:inbound-endpoint address="http://localhost:8080/jersey/" method="GET" />
    <jersey:resources>
        <component class="Resttest" />
    </jersey:resources>
    <logger level="WARN"/>
</flow> 
Seba
  • 1