Hi, I want to get data from Request Header's attributes. Before routing request to this Web Service class I am getting RequestHeader attributes in a filter. After authenticating this data using spring-Security framework I am forwarding this request to my webservice class.In that filter I am getting all desired data.But when I am forwarding that request to my webservice. In this webservice class I again wan't that Request Header Attributes. Which I am not able to get from @HeaderParam.
Please help . Regards, Ragini -----Original Message----- From: Sergey Beryozkin [mailto:[EMAIL PROTECTED] Sent: Thursday, November 27, 2008 9:22 PM To: [email protected] Subject: Re: [Jax-rs]How to get Request Header in webservice > Do you an HTTP header in the request body named 'userId' ? I meant not the actual 'body' of the request, but the whole raw HTTP request..., sorry about the confusion if any > Hi > > Do you an HTTP header in the request body named 'userId' ? > > CXF 2.2-SNAPSHOT supports 1.0 api > > Cheers, Sergey > > ----- Original Message ----- > From: "Ragini Bajpai" <[EMAIL PROTECTED]> > To: <[email protected]> > Sent: Thursday, November 27, 2008 3:44 PM > Subject: [Jax-rs]How to get Request Header in webservice > > > > Hi, > > I want to access Request Header data in the following piece of code.This > method is in webservice class which is mapped in > cxf-webservice.xml under <jaxrs:server/> bean. > @POST > @Path("/placeOrder") > public Response placeOrder(@HeaderParam("userId") String userId) { > String userIdString = userId; > } > > Here I am getting userId null. > I am using CXF-2.1.2 which is supporting jsr311-api-0.8. > When I tried to take jsr311-api-1.0.jar then my war is not getting deployed. > > Please help me. This is very urgent... > > Regards, > Ragini > > > >
