Package org.mule.api.endpoint

Examples of org.mule.api.endpoint.InboundEndpoint


    {
        super.validateConstruct();

        if (messageSource instanceof InboundEndpoint)
        {
            final InboundEndpoint inboundEndpoint = (InboundEndpoint) messageSource;

            if (!inboundEndpoint.getExchangePattern().equals(MessageExchangePattern.REQUEST_RESPONSE))
            {
                throw new FlowConstructInvalidException(
                    MessageFactory.createStaticMessage("HttpProxy only works with a request-response inbound endpoint."),
                    this);
            }
View Full Code Here


    }

    public void testValidListener() throws Exception
    {
        Service service = getTestService("orange", Orange.class);
        InboundEndpoint endpoint = muleContext.getEndpointFactory().getInboundEndpoint(
            getTestEndpointURI());

        getConnector().registerListener(endpoint, getSensingNullMessageProcessor(), service);
    }
View Full Code Here

    }

    @Override
    protected Bridge buildFlowConstruct(MuleContext muleContext) throws MuleException
    {
        InboundEndpoint inboundEndpoint = getOrBuildInboundEndpoint(muleContext);
        OutboundEndpoint outboundEndpoint = getOrBuildOutboundEndpoint(muleContext);

        if (transacted)
        {
            setTransactionFactoriesIfNeeded(inboundEndpoint, outboundEndpoint);
View Full Code Here

    public void testEmbeddedEndpoint() throws Exception
    {
        EndpointBuilder b = muleContext.getRegistry().lookupEndpointBuilder("endpoint1");
        assertNotNull(b);
        InboundEndpoint ep = b.buildInboundEndpoint();
        assertEquals("/request", ep.getEndpointURI().getPath());
    }
View Full Code Here

    public void testServletEndpoint() throws Exception
    {
        EndpointBuilder b = muleContext.getRegistry().lookupEndpointBuilder("endpoint2");
        assertNotNull(b);
        InboundEndpoint ep = b.buildInboundEndpoint();
        assertEquals("/response", ep.getEndpointURI().getPath());
    }
View Full Code Here

    /**
     * Test polling frequency set on a connector.
     */
    public void testConnectorPollingFrequency() throws Exception
    {
        InboundEndpoint endpoint = getTestInboundEndpoint("mock");
        Service service = getTestService("apple", Apple.class);
        FtpConnector connector = (FtpConnector)getConnector();
        MessageReceiver receiver = connector.createReceiver(service, endpoint);
        assertEquals("Connector's polling frequency must not be ignored.", POLLING_FREQUENCY,
            ((FtpMessageReceiver)receiver).getFrequency());
View Full Code Here

    {
        Map<Object, Object> props = new HashMap<Object, Object>();
        // Endpoint wants String-typed properties
        props.put(FtpConnector.PROPERTY_POLLING_FREQUENCY, String.valueOf(POLLING_FREQUENCY_OVERRIDE));
       
        InboundEndpoint endpoint = getTestInboundEndpoint("mock", null, null, null, props, null);

        Service service = getTestService("apple", Apple.class);
        FtpConnector connector = (FtpConnector)getConnector();
        MessageReceiver receiver = connector.createReceiver(service, endpoint);
        assertEquals("Polling frequency endpoint override must not be ignored.", POLLING_FREQUENCY_OVERRIDE,
View Full Code Here

                // outbound router but will be passed back as a result
                eventContext.setStopFurtherProcessing(true);
                return wsdlFileContents;
            }
            MuleContext muleContext = eventContext.getMuleContext();
            InboundEndpoint webServiceEndpoint =
                muleContext.getEndpointFactory().getInboundEndpoint(this.wsdlEndpoint);

            MuleMessage replyWSDL = eventContext.requestEvent(webServiceEndpoint, eventContext.getTimeout());

            wsdlString = replyWSDL.getPayloadAsString();
View Full Code Here

        assertSame(responseEvent.getMessage(), response);
    }

    public void testInboundEndpointCreation() throws MuleException
    {
        InboundEndpoint endpoint = client.createInboundEndpoint(TEST_URI, TEST_MEP);
        assertEquals(TEST_URI, endpoint.getEndpointURI().getUri().toString());
        assertEquals(TEST_MEP, endpoint.getExchangePattern());
    }
View Full Code Here

        {
            trans = TransformerUtils.getTransformers(transformers, muleContext);
        }

        MuleSession session = new DefaultMuleSession(service, muleContext);
        InboundEndpoint endpoint = getDefaultClientEndpoint(service, message.getPayload(), true);
        MuleEvent event = new DefaultMuleEvent(message, endpoint, session);

        if (logger.isDebugEnabled())
        {
            logger.debug("MuleClient sending event direct to: " + componentName + ". MuleEvent is: " + event);
View Full Code Here

TOP

Related Classes of org.mule.api.endpoint.InboundEndpoint

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.