Skip to content
Permalink
Browse files
Get the grizzly container tests to pass.
git-svn-id: https://svn.apache.org/repos/asf/cxf/trunk@1543896 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
dkulp committed Nov 20, 2013
1 parent 68489a7 commit 32aea3448fb46e59714b824251a5d3da206b4216
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 3 deletions.
@@ -23,6 +23,7 @@
import javax.xml.ws.spi.http.HttpExchange;
import javax.xml.ws.spi.http.HttpHandler;

import org.apache.cxf.binding.soap.wsdl.extensions.SoapAddress;
import org.apache.cxf.service.model.EndpointInfo;
import org.apache.cxf.wsdl.http.AddressType;

@@ -53,6 +54,8 @@ public void handle(HttpExchange exchange) throws IOException {
ei.setAddress(contextPath + path);
if (ei.getExtensor(AddressType.class) != null) {
ei.getExtensor(AddressType.class).setLocation(contextPath + path);
} else if (ei.getExtensor(SoapAddress.class) != null) {
ei.getExtensor(SoapAddress.class).setLocationURI(contextPath + path);
}
}
}
@@ -23,12 +23,13 @@
import javax.xml.ws.spi.http.HttpContext;

import org.apache.cxf.Bus;
import org.apache.cxf.binding.soap.SoapTransportFactory;
import org.apache.cxf.service.model.EndpointInfo;
import org.apache.cxf.transport.Destination;
import org.apache.cxf.transport.DestinationFactory;
import org.apache.cxf.transport.http.HTTPTransportFactory;
import org.apache.cxf.transport.http.DestinationRegistryImpl;

public class JAXWSHttpSpiTransportFactory extends HTTPTransportFactory implements DestinationFactory {
public class JAXWSHttpSpiTransportFactory extends SoapTransportFactory implements DestinationFactory {

private HttpContext context;
private JAXWSHttpSpiDestination destination;
@@ -40,7 +41,7 @@ public JAXWSHttpSpiTransportFactory(HttpContext context) {

public Destination getDestination(EndpointInfo endpointInfo, Bus bus) throws IOException {
if (destination == null) {
destination = new JAXWSHttpSpiDestination(bus, registry, endpointInfo);
destination = new JAXWSHttpSpiDestination(bus, new DestinationRegistryImpl(), endpointInfo);
// set handler into the provided HttpContext, our Destination hook into the server container
HttpHandlerImpl handler = new HttpHandlerImpl(destination);
context.setHandler(handler);
@@ -82,6 +82,11 @@
<artifactId>${cxf.servlet-api.artifact}</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-javamail_1.4_spec</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>

0 comments on commit 32aea34

Please sign in to comment.