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/

Reply via email to