[ https://issues.apache.org/jira/browse/SYNAPSE-365?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12611124#action_12611124 ]
Jasper Spoel commented on SYNAPSE-365: -------------------------------------- Hi Asankha, The samples all seem to work nicely. And that's probably my problem. Everything runs fine with the axis2 server on port 9000, but i don't use that. I have a normal RESTful service running on the server machine, this service outputs in plain xml. This service is easily accessible through a webbrowser or curl like applications. As soon as i try to use synapse as a proxy in the fashion of the above comments, synapse crashes. Any ideas? Thanks in advance, Jasper > REST support not working in synapse 1.2 > --------------------------------------- > > Key: SYNAPSE-365 > URL: https://issues.apache.org/jira/browse/SYNAPSE-365 > Project: Synapse > Issue Type: Bug > Components: Endpoints, Proxy Services, Transports > Reporter: Jasper Spoel > Assignee: Asankha C. Perera > Fix For: NIGHTLY > > > When submitting a GET request to a synapse proxy service that points to a > REST webservice > AND Content-Type is not text/xml or application/xml the error: "Cannot create > DocumentElement without destination EPR" comes out. (e.g try to approach the > service proxy with a webbrowers and it will do this) > configuration is as follows: > <definitions xmlns="http://ws.apache.org/ns/synapse"> > <proxy name="Forwarder"> > <target> > <endpoint> > <address uri="http://localhost:11111/MyService/echo" > format="get"/> > </endpoint> > <outSequence> > <send/> > </outSequence> > </target> > </proxy> > </definitions> > If the message is send with the 'correct' content-type like for example so: > curl -G -H "Content-Type: text/xml" http://localhost:8280/Forwarder/mediate > Synapse gives me the following output: > 2008-06-18 15:10:59,714 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG ServerHandler HTTP connection [/0:0:0:0:0:0:0:1%0:56697]: Connected > 2008-06-18 15:10:59,732 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG ServerHandler HTTP connection [/0:0:0:0:0:0:0:1%0:56697]: GET > /soap/Forwarder/mediate HTTP/1.1 > 2008-06-18 15:10:59,780 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG headers >> GET /soap/Forwarder/mediate HTTP/1.1 > 2008-06-18 15:10:59,780 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG headers >> User-Agent: curl/7.16.3 (powerpc-apple-darwin9.0) > libcurl/7.16.3 OpenSSL/0.9.7l zlib/1.2.3 > 2008-06-18 15:10:59,780 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG headers >> Host: localhost:8280 > 2008-06-18 15:10:59,780 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG headers >> Accept: */* > 2008-06-18 15:10:59,780 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG headers >> Content-Type:application/xml > 2008-06-18 15:10:59,797 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG TransportUtils createSOAPEnvelope using Builder (class > org.apache.axis2.builder.ApplicationXMLBuilder) selected from type > (application/xml) > 2008-06-18 15:10:59,841 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG SynapseMessageReceiver Synapse received a new message for message > mediation... > 2008-06-18 15:10:59,841 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG SynapseMessageReceiver Received To: null > 2008-06-18 15:10:59,841 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG SynapseMessageReceiver SOAPAction: null > 2008-06-18 15:10:59,843 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG SynapseMessageReceiver WSA-Action: null > 2008-06-18 15:10:59,845 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG Axis2SynapseEnvironment Injecting MessageContext > 2008-06-18 15:10:59,845 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG Axis2SynapseEnvironment Using Main Sequence for injected message > 2008-06-18 15:10:59,845 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG SequenceMediator Start : Sequence <main> > 2008-06-18 15:10:59,845 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG SequenceMediator Sequence <SequenceMediator> :: mediate() > 2008-06-18 15:10:59,846 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG LogMediator Start : Log mediator > 2008-06-18 15:10:59,846 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > INFO LogMediator To: , MessageID: urn:uuid:27AA6F4DF24676A7641213794659778, > Direction: request > 2008-06-18 15:10:59,846 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG LogMediator End : Log mediator > 2008-06-18 15:10:59,846 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG DropMediator Start : Drop mediator > 2008-06-18 15:10:59,852 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG DropMediator End : Drop mediator > 2008-06-18 15:10:59,852 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG SequenceMediator End : Sequence <main> > 2008-06-18 15:10:59,853 [10.0.0.12-equilibrium.local] [HttpServerWorker-1] > DEBUG ServerWorker Sending 202 Accepted response for MessageID : > urn:uuid:27AA6F4DF24676A7641213794659778 response written : null response > will follow : true acked : false forced ack : false > 2008-06-18 15:10:59,862 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG ServerHandler HTTP connection [localhost/0:0:0:0:0:0:0:1%0:56697]: > Output ready > 2008-06-18 15:10:59,863 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG ServerHandler HTTP connection [localhost/0:0:0:0:0:0:0:1%0:56697]: > Content encoder [chunk-coded; completed: true] > 2008-06-18 15:10:59,864 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG ServerHandler HTTP connection [localhost/0:0:0:0:0:0:0:1%0:56697]: > Response ready > 2008-06-18 15:10:59,865 [10.0.0.12-equilibrium.local] [I/O dispatcher 5] > DEBUG ServerHandler HTTP connection [closed]: Closed -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]