Examples of EndpointResolver


Examples of org.apache.servicemix.jbi.api.EndpointResolver

        Map properties = new HashMap();
        properties.put("name", "James");

        QName service = new QName("http://servicemix.org/cheese", "receiver");
        EndpointResolver resolver = client.createResolverForService(service);
        client.send(resolver, null, properties, "<hello>world</hello>");

        receiver.getMessageList().assertMessagesReceived(1);
    }
View Full Code Here

Examples of org.apache.servicemix.jbi.api.EndpointResolver

        ServiceMixClient clientWithXStream = (ServiceMixClient) context.getBean("clientWithXStream");

        Map properties = new HashMap();
        properties.put("name", "James");

        EndpointResolver resolver = clientWithXStream.createResolverForService(service);
        TestBean bean = new TestBean();
        bean.setName("James");
        bean.setLength(12);
        bean.getAddresses().addAll(Arrays.asList(new String[] {"London", "LA"}));
View Full Code Here

Examples of org.apache.servicemix.jbi.api.EndpointResolver

    protected void assertRequestUsingMapAndPOJOByServiceName(QName service) throws Exception {
        Map properties = new HashMap();
        properties.put("name", "James");

        EndpointResolver resolver = client.createResolverForService(service);
        Object response = client.request(resolver, null, properties, "<hello>world</hello>");

        assertNotNull("Should have returned a non-null response!", response);
       
        LOGGER.info("Received result: {}", response);
View Full Code Here

Examples of org.apache.servicemix.jbi.api.EndpointResolver

public class CacheTest extends TestSupport {

    private static transient Logger logger = LoggerFactory.getLogger(CacheTest.class);

    public void testCache() throws Exception {
        EndpointResolver cachedService = client.createResolverForService(new QName("http://servicemix.org/cheese/", "myService"));
        EndpointResolver service = client.createResolverForService(new QName("http://servicemix.org/cheese/", "myServiceImpl"));

        Object object = client.request(cachedService, null, null, "<foo id='123'/>");
        if (object instanceof Node) {
            object = new DOMSource((Node) object);
        }
View Full Code Here

Examples of org.apache.servicemix.jbi.api.EndpointResolver

        Map properties = new HashMap();
        properties.put("name", "James");

        QName service = new QName("http://servicemix.org/cheese/", "receiver");
        EndpointResolver resolver = client.createResolverForService(service);
        client.send(resolver, null, properties, "<hello>world</hello>");

        receiver.getMessageList().assertMessagesReceived(1);
    }
View Full Code Here

Examples of org.apache.servicemix.jbi.api.EndpointResolver

        ServiceMixClient client = (ServiceMixClient) context.getBean("clientWithXStream");

        Map properties = new HashMap();
        properties.put("name", "James");

        EndpointResolver resolver = client.createResolverForService(service);
        TestBean bean = new TestBean();
        bean.setName("James");
        bean.setLength(12);
        bean.getAddresses().addAll(Arrays.asList(new String[] {"London", "LA"}));
View Full Code Here

Examples of org.apache.servicemix.jbi.api.EndpointResolver

    protected void assertRequestUsingMapAndPOJOByServiceName(QName service) throws Exception {
        Map properties = new HashMap();
        properties.put("name", "James");

        EndpointResolver resolver = (EndpointResolver)client.createResolverForService(service);
        Object response = client.request(resolver, null, properties, "<hello>world</hello>");

        assertNotNull("Should have returned a non-null response!", response);
       
        logger.info("Received result: {}", response);
View Full Code Here

Examples of org.apache.servicemix.jbi.api.EndpointResolver

            if (theEndpoint == null) {
                // lets use the resolver on the activation spec if
                // applicable
                ActivationSpec activationSpec = exchange.getActivationSpec();
                if (activationSpec != null) {
                    EndpointResolver destinationResolver = activationSpec.getDestinationResolver();
                    if (destinationResolver != null) {
                        try {
                            EndpointFilter filter = createEndpointFilter(context, exchange);
                            theEndpoint = (InternalEndpoint) destinationResolver.resolveEndpoint(context, exchange, filter);
                        } catch (JBIException e) {
                            throw new MessagingException("Failed to resolve endpoint: " + e, e);
                        }
                    }
                }
View Full Code Here

Examples of org.apache.servicemix.jbi.api.EndpointResolver

        Map properties = new HashMap();
        properties.put("name", "James");

        QName service = new QName("http://servicemix.org/cheese/", "receiver");
        EndpointResolver resolver = client.createResolverForService(service);
        client.send(resolver, null, properties, "<hello>world</hello>");

        receiver.getMessageList().assertMessagesReceived(1);
    }
View Full Code Here

Examples of org.apache.servicemix.jbi.api.EndpointResolver

        ServiceMixClient client = (ServiceMixClient) context.getBean("clientWithXStream");

        Map properties = new HashMap();
        properties.put("name", "James");

        EndpointResolver resolver = client.createResolverForService(service);
        TestBean bean = new TestBean();
        bean.setName("James");
        bean.setLength(12);
        bean.getAddresses().addAll(Arrays.asList(new String[] {"London", "LA"}));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.