Return-Path: Delivered-To: apmail-incubator-cxf-issues-archive@locus.apache.org Received: (qmail 84480 invoked from network); 2 Nov 2006 02:39:38 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 2 Nov 2006 02:39:38 -0000 Received: (qmail 68551 invoked by uid 500); 2 Nov 2006 02:39:49 -0000 Delivered-To: apmail-incubator-cxf-issues-archive@incubator.apache.org Received: (qmail 68511 invoked by uid 500); 2 Nov 2006 02:39:49 -0000 Mailing-List: contact cxf-issues-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: cxf-dev@incubator.apache.org Delivered-To: mailing list cxf-issues@incubator.apache.org Received: (qmail 68502 invoked by uid 99); 2 Nov 2006 02:39:49 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Nov 2006 18:39:49 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Nov 2006 18:39:37 -0800 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id C962D7142FC for ; Wed, 1 Nov 2006 18:39:17 -0800 (PST) Message-ID: <9861380.1162435157822.JavaMail.root@brutus> Date: Wed, 1 Nov 2006 18:39:17 -0800 (PST) From: "willem Jiang (JIRA)" To: cxf-issues@incubator.apache.org Subject: [jira] Assigned: (CXF-197) javax.xml.ws.handler.MessageContext.HTTP_REQUEST_HEADERS and HTTP_RESPONSE_HEADERS can't work In-Reply-To: <18028789.1162435156580.JavaMail.root@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ http://issues.apache.org/jira/browse/CXF-197?page=all ] willem Jiang reassigned CXF-197: -------------------------------- Assignee: willem Jiang > javax.xml.ws.handler.MessageContext.HTTP_REQUEST_HEADERS and HTTP_RESPONSE_HEADERS can't work > ---------------------------------------------------------------------------------------------- > > Key: CXF-197 > URL: http://issues.apache.org/jira/browse/CXF-197 > Project: CXF > Issue Type: Bug > Reporter: willem Jiang > Assigned To: willem Jiang > Fix For: 2.0-M1 > > > I'm porting a RESTy service from Celtix 1.something to CXF and have noticed some differences in the way the HTTP protocol headers are handled. > For example, in a service implemented using a Provider, I've tried getting the headers from the MessageContext like this: > ctx.get(javax.xml.ws.handler.MessageContext.HTTP_REQUEST_HEADERS); > This returns null though. Calling: > Map>hdrs = ctx.get (org.apache.cxf.message.Message.PROTOCOL_HEADERS); > works though and I can get the headers ok. > I also need to set the response headers and should be able to set a header like this: > Map>hdrs = ctx.get (javax.xml.ws.handler.MessageContext.HTTP_RESPONSE_HEADERS); > hdrs.put(headerName, headerValue); > and have it added to the outgoing response. However, as above using the MessageContext property does not return anything. I've tried using the org.apache.cxf.message.Message property like this > Map>hdrs = ctx.get (org.apache.cxf.message.Message.PROTOCOL_HEADERS); > hdrs.put(headerName, headerValue); > but there's no sign that the header has been correctly added. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira