Hi

It's strange indeed. Well, with JAXWS these are not query parameters,
they're extracted from a soap body, so no surprise here. What I'm not
sure about is why we see one query parameter lost when a GET request is
used.

I'm still thinking that it's lost earlier.

Are you using a combined JAXWS-JAXRS service ? 

Can you please post a complete sample JAXRS code and a request URI and a
config sample so that we can investigate ? 

Cheers, Sergey

-----Original Message-----
From: Dawa Sherpa [mailto:[EMAIL PROTECTED] 
Sent: 12 November 2008 19:32
To: [email protected]
Subject: Re: JAXRS UriInfo problem

The problem only occurs when i am trying to use jax-rs api. I have other
services which uses the jax-ws and the parameters seems to get through
to
them without a problem.


@WebService(name = "testService")
@SOAPBinding(style = Style.RPC, use = Use.LITERAL)
public interface testService {
    public void printParams(@WebParam(name = "param1") String param1,
            @WebParam(name = "param2") String param2);
}


Works .. but

@Path("/testService")
public interface testService {
    @GET
    @Path("/printParams")
     public void printParams(@QueryParam("param1") String param1,
@QueryParam("param2"));
}

Does not work. Only the first param could be used .


Everything else is the same for both these services.

Dawa
On Wed, Nov 12, 2008 at 10:20 AM, Sergey Beryozkin <
[EMAIL PROTECTED]> wrote:

> Hi
>
> So the problem occurs much earlier then.
> CXF does not modify HttpServletRequest as far as I'm aware so if it's
not
> available there then it's lost elsewhere
>
> May be you can debug ? Or provide more info on the overall
infrastructure
> you're usingthen it might help
>
> Cheers, Sergey
>
>
>  Hi Sergey,
>>
>> Thanks for the reply.
>>
>> I am using apache-cxf 2.1.3.
>>
>> Using "@Context HttpServletRequest request" did not help. It does the
same
>> thing.
>>
>> Here is the result  for a request   :
>> <server>/<path>/<service-name>?param1=value1&param2=value2
>>
>> request.getRequestURI()  .. prints <path>/svc/<service-name>
>> request.getQueryString() .. print param1=value1
>>
>>
>>
>> Dawa :-D
>>
>>
>> On Wed, Nov 12, 2008 at 9:55 AM, Sergey Beryozkin <
>> [EMAIL PROTECTED]> wrote:
>>
>>  I haven't tried tomcat though but jetty, but I tries uri info
injected as
>>> a
>>> field and as a parameter. Will having
>>> @Context HttpServletRequest request
>>>
>>> in your code help ? So that you could try and get the info you need
>>> directly from a request ?
>>>
>>> Cheers, Sergey
>>>
>>>
>>>
>>>  Hi
>>>>
>>>> What CXF version you're using ? I did a quick try with 2.2-SNAPSHOT
and
>>>> I
>>>> have no problems at all retrieving multiple query parameters from a
>>>> UriInfo...
>>>>
>>>> Cheers, Sergey
>>>>
>>>>
>>>> Dawa Sherpa wrote:
>>>>
>>>>
>>>>> I am trying to use apache-cxf 's REST service. However, jax-rs
seems to
>>>>> be doing something bad to my URLs .. I only get the first query
>>>>> parameter that is passed to the request. Is this a bug or am I
missing
>>>>> some configuration ?
>>>>>
>>>>> Eg. If I pass <server>/svc/something?param1=value1&param2=value2
>>>>> When print out
>>>>> UriInfo.getRequestURI() , I get
<server>/svc/something?param1=value1
>>>>>
>>>>> and ofcourse, when I do getQueryParameters, I only get the first
one .
>>>>> Please help
>>>>>
>>>>>
>>>>> On Tue, 2008-11-11 at 12:03 -0800, Perch24 wrote:
>>>>>
>>>>>  We recently upgraded to CXF 2.1.3 from 2.1.2. After the upgrade
we
>>>>>> noticed
>>>>>> that JMS conduits with a reply to queue were not always working
if we
>>>>>> had
>>>>>> multiple instances running. I didn't dive into the problem real
deep,
>>>>>> but
>>>>>> rather just removed the reply to queue config so that it would
use a
>>>>>> temporary queue. That fixed the problem.
>>>>>>
>>>>>> It looks like to me that the new implemenation of the JMS conduit
is
>>>>>> broken
>>>>>> if you have multiple instances of a conduit running against the
same
>>>>>> reply
>>>>>> to queue. It's possible that this could be fixed with the new
Spring
>>>>>> configuration, but it is not backwards compatible with 2.1.2.
>>>>>> I'm posting this to list first to see if anyone else has seen
this.
>>>>>> Let
>>>>>> me
>>>>>> know if you would like me to open a defect.
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>>  --
>>>> View this message in context:
>>>>
http://www.nabble.com/CXF-2.1.3-JMS-Conduit-tp20447067p20465355.html
>>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>>
>>>>
>>>>
>>>
>>
>

Reply via email to