Package org.servicemix.jbi.container

Examples of org.servicemix.jbi.container.ActivationSpec


        File path = new File("target/test-classes/xbean");
        XBeanComponent component = new XBeanComponent();
        JBIContainer container = new JBIContainer();
        container.init();
        container.start();
        container.activateComponent(new ActivationSpec("xbean", component));
        component.getServiceUnitManager().deploy("xbean", path.getAbsolutePath());
        component.start("xbean");
        component.stop("xbean");
        component.getServiceUnitManager().shutDown("xbean");
        component.getServiceUnitManager().undeploy("xbean", path.getAbsolutePath());
View Full Code Here


              }
              }
          };
        }

        senderContainer.activateComponent(new ActivationSpec("sender", sender));
        senderContainer.activateComponent(new ActivationSpec("receiver", receiver));
       
        tt.execute(new TransactionCallback() {
        public Object doInTransaction(TransactionStatus status) {
                try {
                    sender.sendMessages(numMessages, syncSend);
View Full Code Here

    protected void setUp() throws Exception {
        container = new JBIContainer();
        container.init();
        container.start();
        SenderComponent component = new SenderComponent();
        container.activateComponent(new ActivationSpec("sender", component));
        channel = component.getDeliveryChannel();
    }
View Full Code Here

        DocumentFragment fragment = installContext.getInstallationDescriptorExtension();

        // lets load this from Spring...
        Map map = applicationContext.getBeansOfType(ActivationSpec.class, false, false);
        for (Iterator iter = map.values().iterator(); iter.hasNext(); ) {
            ActivationSpec spec = (ActivationSpec) iter.next();
        }
    }
View Full Code Here

        URL url = Thread.currentThread().getContextClassLoader().getResource("addNumbers/xbean.xml");
        File path = new File(url.toURI());
        path = path.getParentFile();
        XFireComponent component = new XFireComponent();
        component.init(null);
        container.activateComponent(new ActivationSpec("xfire", component));
        component.getServiceUnitManager().deploy("addNumbers", path.getAbsolutePath());
        component.start("addNumbers");

        QName serviceName = new QName("http://foo.bar.com", "AddNumbers");
        String file = "request.xml";
View Full Code Here

     * @return a message exchange factory
     */
    public MessageExchangeFactory createExchangeFactory() {
        MessageExchangeFactoryImpl result = createMessageExchangeFactory();
        result.setContext(context);
        ActivationSpec activationSpec = context.getActivationSpec();
        if (activationSpec != null) {
            String componentName = context.getComponentNameSpace().getName();
            // lets auto-default the container-routing information
            QName serviceName = activationSpec.getDestinationService();
            if (serviceName != null) {
                result.setServiceName(serviceName);
                log.info("default destination serviceName for " + componentName + " = " + serviceName);
            }
            QName interfaceName = activationSpec.getDestinationInterface();
            if (interfaceName != null) {
                result.setInterfaceName(interfaceName);
                log.info("default destination interfaceName for " + componentName + " = " + interfaceName);
            }
            QName operationName = activationSpec.getDestinationOperation();
            if (operationName != null) {
                result.setOperationName(operationName);
                log.info("default destination operationName for " + componentName + " = " + operationName);
            }
            String endpointName = activationSpec.getDestinationEndpoint();
            if (endpointName != null) {
                boolean endpointSet = false;
                log.info("default destination endpointName for " + componentName + " = " + endpointName);
                if (serviceName != null && endpointName != null) {
                    endpointName = endpointName.trim();
View Full Code Here

    /**
     * Provides the JBI container used for message dispatch.
     */
    public ServiceMixClientFacade(JBIContainer container) throws JBIException {
        this(container, new ActivationSpec());
    }
View Full Code Here

     * Create a RemoteServiceMixClient
     * @param uri
     *
     */
    public RemoteServiceMixClient(String uri){
        this(uri,new ActivationSpec());
    }
View Full Code Here

          getSubscriptionManager().dispatchToSubscribers(exchange);
        }
       
        if (!foundRoute) {
            boolean throwException = true;
            ActivationSpec activationSpec = exchange.getActivationSpec();
            if (activationSpec != null) {
                throwException = activationSpec.isFailIfNoDestinationEndpoint();
            }
            if (throwException) {
                throw new MessagingException("Could not find route for exchange: " + exchange + " for service: " + exchange.getService() + " and interface: "
                        + exchange.getInterfaceName());
            } else if (exchange.getMirror().getSyncState() == MessageExchangeImpl.SYNC_STATE_SYNC_SENT) {
View Full Code Here

                }
            }
            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);
                        }
View Full Code Here

TOP

Related Classes of org.servicemix.jbi.container.ActivationSpec

Copyright © 2018 www.massapicom. 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.