Hi Jasper, Please see the answers in-line;
On Wed, Jun 18, 2008 at 8:26 PM, Jasper Spoel <[EMAIL PROTECTED]> wrote: > Hi Ruwan, > > thanx for the tips, You are welcome. > but since i'm fairly new to this i have 2 questions on your answer: > > 1. where should i create this JIRA issue (url) https://issues.apache.org/jira/secure/Dashboard.jspa > > 2. and when creating, i'm not really sure what the issue is....or are you > suggesting i should post the log and all there? Just state that the REST support on Synapse 1.2 is not working, and attach the error log (which you get initially - "Cannot create document element ...." ) and state what you have done. That is it. Thanks for the cooperation Jasper. Thanks, Ruwan > > > thanx in advance, > Jasper > > > On Jun 18, 2008, at 16:15 , Ruwan Linton wrote: > > Hi Jasper, >> >> I found this is to be an issue on the 1.2 release and I have already got >> it >> fixed on my local machine, you may go ahead and create a JIRA issue for >> this. This is a trivial fix but need to test for regressions before >> committing and hence will commit the fix on tomorrow. >> >> Thanks a lot for pointing this out. >> >> Thanks, >> Ruwan >> >> On Wed, Jun 18, 2008 at 6:48 PM, Jasper Spoel <[EMAIL PROTECTED]> >> wrote: >> >> Sorry forgot the log >>> here it is. >>> >>> >>> >>> >>> >>> On Jun 18, 2008, at 14:55 , Ruwan Linton wrote: >>> >>> Are you sending a pox (HTTP POST) request or a REST (HTTP GET) request to >>> >>>> the ws? >>>> >>>> Can you please attach the complete log and the configuration that you >>>> have >>>> been using so that I can reproduce this issue. >>>> >>>> By the way: you may try application/xml as the content type as well. >>>> >>>> Thanks, >>>> Ruwan >>>> >>>> On Wed, Jun 18, 2008 at 3:48 PM, Jasper Spoel <[EMAIL PROTECTED]> >>>> wrote: >>>> >>>> Hi there, >>>> >>>>> >>>>> i've run a few tests and it seems like the Cannot create >>>>> DocumentElement >>>>> error corresponds to the Content-Type i use. >>>>> When i force the content-type to be text/xml i don't get the error, but >>>>> i >>>>> don't get a response from the actual service either. >>>>> in short, judging from the DEBUG statements, with content-type set to >>>>> text/xml synapse gets to the point of http status code 202 (Accepted), >>>>> [ >>>>> HttpServerWorker-16] DEBUG ServerWorker Sending 202 Accepted response >>>>> for >>>>> MessageID : urn:uuid:389AA5DEAE6E9B61391213783928075 response written : >>>>> null >>>>> response will follow : true acked : false forced ack : false >>>>> ] >>>>> >>>>> hope this helps in pinpointing my problem. >>>>> >>>>> thanx again! >>>>> Jasper >>>>> >>>>> >>>>> On Jun 18, 2008, at 11:56 , Jasper Spoel wrote: >>>>> >>>>> First of all, >>>>> >>>>> >>>>>> Ruwan, thanx a bunch for responding this fast. >>>>>> first thing i noted that was different from what i've tried already is >>>>>> that you access the url at soap/Forwarder/mediate >>>>>> i didn't try the "mediate" part. So slapping myself to the head and >>>>>> trying >>>>>> again with the suggested configuration i sadly ran into >>>>>> a problem i had before. >>>>>> >>>>>> The error i get back is: Cannot create DocumentElement without >>>>>> destination >>>>>> EPR >>>>>> >>>>>> this error is the reason i thought my problem lies somewhere with >>>>>> ws-addressing. >>>>>> the service would normally answer with plain xml. Something like: >>>>>> >>>>>> <servers> >>>>>> <server>Testing</server> >>>>>> </servers> >>>>>> >>>>>> any ideas? >>>>>> >>>>>> as a side note: >>>>>> I spotted the paths /soap and /rest in the configuration file for >>>>>> axis2....when can this /rest path be used. >>>>>> /soap seems to be the path that's always used....any gems on that ? >>>>>> >>>>>> >>>>>> On Jun 18, 2008, at 10:38 , Ruwan Linton wrote: >>>>>> >>>>>> Hi Jasper, >>>>>> >>>>>> >>>>>>> I have modified the cofig to fit the service name as "Forwarder" >>>>>>> please >>>>>>> see >>>>>>> the change in the following configuration; >>>>>>> >>>>>>> <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> >>>>>>> >>>>>>> >>>>>>> You can access this service with the URL >>>>>>> http://localhost:8280/soap/Forwarder/mediate >>>>>>> >>>>>>> Thanks, >>>>>>> Ruwan >>>>>>> >>>>>>> On Wed, Jun 18, 2008 at 2:04 PM, Ruwan Linton < >>>>>>> [EMAIL PROTECTED]> >>>>>>> wrote: >>>>>>> >>>>>>> Hi Jasper, >>>>>>> >>>>>>> >>>>>>>> You should be able to do this very easily with Synapse; by creating >>>>>>>> the >>>>>>>> proxy service proxying the actual service. Please try the following >>>>>>>> configuration and get back to us on any questions and problems. >>>>>>>> >>>>>>>> <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 you want to change the message format to the actual service >>>>>>>> (MyService) >>>>>>>> to any other than REST change the format attribute to one of the >>>>>>>> soap11/soap12/pox as appropriate. >>>>>>>> >>>>>>>> Looking forward to your feedback .... >>>>>>>> >>>>>>>> Thanks, >>>>>>>> Ruwan >>>>>>>> >>>>>>>> >>>>>>>> On Wed, Jun 18, 2008 at 1:36 PM, Jasper Spoel < >>>>>>>> [EMAIL PROTECTED]> >>>>>>>> wrote: >>>>>>>> >>>>>>>> Hi, >>>>>>>> >>>>>>>> >>>>>>>>> i'm quite new to Apache synapse and i'm trying to get it up and >>>>>>>>> running. >>>>>>>>> In short, the samples and all work fine. >>>>>>>>> My problems begin when i try to access a REST service of my own as >>>>>>>>> an >>>>>>>>> endpoint. >>>>>>>>> I was wondering if anyone felt up to it to post the simplest >>>>>>>>> configuration >>>>>>>>> for synapse possible for my particular case. >>>>>>>>> >>>>>>>>> What i try to do: >>>>>>>>> >>>>>>>>> i want the outside world to use the address for synapse only, so >>>>>>>>> the >>>>>>>>> services behind it should be transparant for the originating party. >>>>>>>>> suppose my own service is at: >>>>>>>>> http://localhost:11111/MyService/echo >>>>>>>>> >>>>>>>>> i would like clients to connect to http://localhost:8280/Forwarder >>>>>>>>> >>>>>>>>> which should send through the message without any alteration to the >>>>>>>>> MyService service >>>>>>>>> and consequently send back the response from MyService to the >>>>>>>>> client >>>>>>>>> asking for the info. >>>>>>>>> >>>>>>>>> Somehow i just can't get it to work. >>>>>>>>> i get the feeling it has something to do with ws-addressing, but >>>>>>>>> i'm >>>>>>>>> not >>>>>>>>> sure. >>>>>>>>> >>>>>>>>> So what would be the configuration for this for synapse >>>>>>>>> and if there are any, what are the requirements for the message >>>>>>>>> and/or >>>>>>>>> the >>>>>>>>> client. >>>>>>>>> >>>>>>>>> Thanx in advance, >>>>>>>>> Jasper >>>>>>>>> >>>>>>>>> >>>>>>>>> >>>>>>>>> >>>>>>>> -- >>>>>>>> Ruwan Linton >>>>>>>> http://wso2.org - "Oxygenating the Web Services Platform" >>>>>>>> http://ruwansblog.blogspot.com/ >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>> >>>>>>> >>>>>>> -- >>>>>>> Ruwan Linton >>>>>>> http://wso2.org - "Oxygenating the Web Services Platform" >>>>>>> http://ruwansblog.blogspot.com/ >>>>>>> >>>>>>> >>>>>>> >>>>>> >>>>>> >>>>>> >>>>> >>>> -- >>>> Ruwan Linton >>>> http://wso2.org - "Oxygenating the Web Services Platform" >>>> http://ruwansblog.blogspot.com/ >>>> >>>> >>> >>> >>> >> >> -- >> Ruwan Linton >> http://wso2.org - "Oxygenating the Web Services Platform" >> http://ruwansblog.blogspot.com/ >> > > -- Ruwan Linton http://wso2.org - "Oxygenating the Web Services Platform" http://ruwansblog.blogspot.com/
