Author: mmusaji
Date: 2013-07-15 09:53:10 -0400 (Mon, 15 Jul 2013)
New Revision: 17780
Modified:
thirdparty/cxf/branches/cxf-2.6.6.jbossorg-1-bz-984470/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPDestination.java
thirdparty/cxf/branches/cxf-2.6.6.jbossorg-1-bz-984470/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java
Log:
[BZ984470] Merged in CXF-5116
Modified:
thirdparty/cxf/branches/cxf-2.6.6.jbossorg-1-bz-984470/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java
===================================================================
---
thirdparty/cxf/branches/cxf-2.6.6.jbossorg-1-bz-984470/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java 2013-07-15
10:37:16 UTC (rev 17779)
+++
thirdparty/cxf/branches/cxf-2.6.6.jbossorg-1-bz-984470/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java 2013-07-15
13:53:10 UTC (rev 17780)
@@ -217,14 +217,14 @@
if (inMessage == null) {
LOG.fine("Create a new message for processing");
inMessage = new MessageImpl();
+ ExchangeImpl exchange = new ExchangeImpl();
+ exchange.setInMessage(inMessage);
setupMessage(inMessage,
config,
context,
req,
resp);
- ExchangeImpl exchange = new ExchangeImpl();
- exchange.setInMessage(inMessage);
exchange.setSession(new HTTPSession(req));
((MessageImpl)inMessage).setDestination(this);
} else {
@@ -265,13 +265,15 @@
req,
resp);
+ final Exchange exchange = inMessage.getExchange();
DelegatingInputStream in = new DelegatingInputStream(req.getInputStream()) {
public void cacheInput() {
- if (!cached && inMessage.getExchange().getOutMessage() == null)
{
+ if (!cached && exchange.isOneWay()) {
//For one-ways, we need to cache the values of the
HttpServletRequest
//so they can be queried later for things like paths and schemes
//and such like that.
- inMessage.put(HTTP_REQUEST, new HttpServletRequestSnapshot(req));
+ //Please note, exchange used to always get the "current"
message
+ exchange.getInMessage().put(HTTP_REQUEST, new
HttpServletRequestSnapshot(req));
}
super.cacheInput();
}
Modified:
thirdparty/cxf/branches/cxf-2.6.6.jbossorg-1-bz-984470/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPDestination.java
===================================================================
---
thirdparty/cxf/branches/cxf-2.6.6.jbossorg-1-bz-984470/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPDestination.java 2013-07-15
10:37:16 UTC (rev 17779)
+++
thirdparty/cxf/branches/cxf-2.6.6.jbossorg-1-bz-984470/rt/transports/http-jetty/src/main/java/org/apache/cxf/transport/http_jetty/JettyHTTPDestination.java 2013-07-15
13:53:10 UTC (rev 17780)
@@ -335,12 +335,12 @@
if (inMessage == null) {
inMessage = new MessageImpl();
+ ExchangeImpl exchange = new ExchangeImpl();
+ exchange.setInMessage(inMessage);
setupMessage(inMessage, context, req, resp);
((MessageImpl)inMessage).setDestination(this);
- ExchangeImpl exchange = new ExchangeImpl();
- exchange.setInMessage(inMessage);
exchange.setSession(new HTTPSession(req));
}
Show replies by date