Search in sources :

Example 51 with EndpointImpl

use of org.apache.cxf.jaxws.EndpointImpl in project cxf by apache.

the class ProviderJMSContinuationTest method startServers.

@BeforeClass
public static void startServers() throws Exception {
    startBusAndJMS(ProviderJMSContinuationTest.class);
    Object implementor = new HWSoapMessageDocProvider();
    String address = "jms:queue:test.jmstransport.text?replyToQueueName=test.jmstransport.text.reply";
    EndpointImpl ep = (EndpointImpl) Endpoint.create(implementor);
    ep.getInInterceptors().add(new IncomingMessageCounterInterceptor());
    ep.setBus(bus);
    ep.getFeatures().add(cff);
    ep.publish(address);
}
Also used : EndpointImpl(org.apache.cxf.jaxws.EndpointImpl) BeforeClass(org.junit.BeforeClass)

Example 52 with EndpointImpl

use of org.apache.cxf.jaxws.EndpointImpl in project cxf by apache.

the class SoapJmsSpecTest method startServers.

@BeforeClass
public static void startServers() throws Exception {
    startBusAndJMS(SoapJmsSpecTest.class);
    publish("jms:queue:test.cxf.jmstransport.queue2", new GreeterSpecImpl());
    publish("jms:queue:test.cxf.jmstransport.queue5", new GreeterSpecWithPortError());
    EndpointImpl ep = (EndpointImpl) Endpoint.create(null, new GreeterSpecImpl());
    ep.setBus(bus);
    ep.getFeatures().add(new GZIPFeature());
    ep.getFeatures().add(cff);
    ep.publish("jms:queue:test.cxf.jmstransport.queue6");
}
Also used : GZIPFeature(org.apache.cxf.transport.common.gzip.GZIPFeature) GreeterSpecImpl(org.apache.cxf.jms.testsuite.services.GreeterSpecImpl) EndpointImpl(org.apache.cxf.jaxws.EndpointImpl) GreeterSpecWithPortError(org.apache.cxf.jms.testsuite.services.GreeterSpecWithPortError) BeforeClass(org.junit.BeforeClass)

Example 53 with EndpointImpl

use of org.apache.cxf.jaxws.EndpointImpl in project cxf by apache.

the class AbstractVmJMSTest method publish.

public static void publish(String address, Object impl) {
    EndpointImpl ep = (EndpointImpl) Endpoint.create(impl);
    ep.setBus(bus);
    ep.getFeatures().add(cff);
    ep.publish(address);
}
Also used : EndpointImpl(org.apache.cxf.jaxws.EndpointImpl)

Example 54 with EndpointImpl

use of org.apache.cxf.jaxws.EndpointImpl in project cxf by apache.

the class MissingQualification1226Test method lookForMissingNamespace.

@Test
public void lookForMissingNamespace() throws Exception {
    EndpointImpl endpoint = getBean(EndpointImpl.class, "helloWorld");
    Document d = getWSDLDocument(endpoint.getServer());
    NodeList schemas = assertValid("//xsd:schema[@targetNamespace='http://nstest.helloworld']", d);
    Element schemaElement = (Element) schemas.item(0);
    String ef = schemaElement.getAttribute("elementFormDefault");
    assertEquals("qualified", ef);
}
Also used : EndpointImpl(org.apache.cxf.jaxws.EndpointImpl) NodeList(org.w3c.dom.NodeList) Element(org.w3c.dom.Element) Document(org.w3c.dom.Document) AbstractCXFSpringTest(org.apache.cxf.test.AbstractCXFSpringTest) Test(org.junit.Test)

Example 55 with EndpointImpl

use of org.apache.cxf.jaxws.EndpointImpl in project cxf by apache.

the class UTServer method run.

protected void run() {
    DoubleItPortTypeImpl implementor = new DoubleItPortTypeImpl();
    implementor.setEnforcePrincipal(false);
    String address = "http://localhost:" + PORT + "/DoubleItUsernameToken3";
    EndpointImpl jaxWsEndpoint = (EndpointImpl) Endpoint.publish(address, implementor);
    Map<String, Object> properties = new HashMap<>();
    properties.put("action", "UsernameToken");
    properties.put("passwordCallbackClass", "org.apache.cxf.systest.ws.common.UTPasswordCallback");
    WSS4JInInterceptor wss4jInInterceptor = new WSS4JInInterceptor(properties);
    jaxWsEndpoint.getServer().getEndpoint().getInInterceptors().add(wss4jInInterceptor);
}
Also used : DoubleItPortTypeImpl(org.apache.cxf.systest.ws.common.DoubleItPortTypeImpl) HashMap(java.util.HashMap) EndpointImpl(org.apache.cxf.jaxws.EndpointImpl) WSS4JInInterceptor(org.apache.cxf.ws.security.wss4j.WSS4JInInterceptor)

Aggregations

EndpointImpl (org.apache.cxf.jaxws.EndpointImpl)66 QName (javax.xml.namespace.QName)14 Bean (org.springframework.context.annotation.Bean)10 Bus (org.apache.cxf.Bus)9 Test (org.junit.Test)9 BeforeClass (org.junit.BeforeClass)7 Endpoint (javax.xml.ws.Endpoint)5 URL (java.net.URL)4 HashMap (java.util.HashMap)4 LoggingInInterceptor (org.apache.cxf.ext.logging.LoggingInInterceptor)4 LoggingOutInterceptor (org.apache.cxf.ext.logging.LoggingOutInterceptor)4 Feature (org.apache.cxf.feature.Feature)4 JaxWsServerFactoryBean (org.apache.cxf.jaxws.JaxWsServerFactoryBean)4 SOAPBinding (javax.xml.ws.soap.SOAPBinding)3 SpringBusFactory (org.apache.cxf.bus.spring.SpringBusFactory)3 EndpointInfo (org.apache.cxf.service.model.EndpointInfo)3 IOException (java.io.IOException)2 ArrayList (java.util.ArrayList)2 JAXBException (javax.xml.bind.JAXBException)2 XMLStreamException (javax.xml.stream.XMLStreamException)2