Package org.drools.grid.io

Examples of org.drools.grid.io.Message


        BlockingMessageResponseHandler blockHandler = new BlockingMessageResponseHandler();

        cv.sendMessage( "hello",
                        blockHandler );

        Message msg = blockHandler.getMessage(100, 5000 );
        System.out.println( msg.getBody() );

        cv.endConversation();
        if ( acc.isOpen() ) {
            acc.close();
        }
View Full Code Here


        this.receivedMessage = receivedMessage;
        this.conversationManager = conversationManager;
    }

    public void respond(Object body) {
        Message msg = new MessageImpl( this.conversationId,
                                       this.senderId,
                                       recipientId,
                                       -1,
                                       receivedMessage.getRequestId(),
                                       body );
View Full Code Here

                                MessageReceiverHandler handler) {
        int requestId = -1;
        if ( handler != null ) {
            requestId = this.requestId.getAndIncrement();
        }
        Message msg = new MessageImpl( this.conversationId,
                                       this.senderId,
                                       recipientId,
                                       requestId,
                                       -1,
                                       body );
View Full Code Here

    }

    @Override
    public void messageReceived(IoSession session,
                                Object object) throws Exception {
        Message msg = (Message) object;
        Conversation conversation = new ConversationImpl( null, //TODO this should not be null, but we currently have no concept of a ConversationManager on the Acceptor
                                                          msg.getConversationId(),
                                                          this.senderId,
                                                          msg.getSenderId(),
                                                          this.dispathListener,
                                                          msg,
                                                          new MinaIoWriter( session ),
                                                          null );
        this.messageHandler.messageReceived( conversation,
View Full Code Here

        this.receivedMessage = receivedMessage;
        this.conversationManager = conversationManager;
    }

    public void respond(Object body) {
        Message msg = new MessageImpl( this.conversationId,
                                       this.senderId,
                                       recipientId,
                                       -1,
                                       receivedMessage.getRequestId(),
                                       body );
View Full Code Here

                                MessageReceiverHandler handler) {
        int requestId = -1;
        if ( handler != null ) {
            requestId = this.requestId.getAndIncrement();
        }
        Message msg = new MessageImpl( this.conversationId,
                                       this.senderId,
                                       recipientId,
                                       requestId,
                                       -1,
                                       body );
View Full Code Here

        BlockingMessageResponseHandler blockHandler = new BlockingMessageResponseHandler();

        cv.sendMessage( "hello",
                        blockHandler );

        Message msg = blockHandler.getMessage( 5000 );
        System.out.println( msg.getBody() );

        cv.endConversation();
        if ( acc.isOpen() ) {
            acc.close();
        }
View Full Code Here

        BlockingMessageResponseHandler blockHandler = new BlockingMessageResponseHandler();

        cv.sendMessage( "hello",
                        blockHandler );

        Message msg = blockHandler.getMessage( 5000 );
        System.out.println( msg.getBody() );

        cv.endConversation();
        if ( acc.isOpen() ) {
            acc.close();
        }
View Full Code Here

    }

    @Override
    public void messageReceived(IoSession session,
                                Object object) throws Exception {
        Message msg = (Message) object;
        Conversation conversation = new ConversationImpl( null, //TODO this should not be null, but we currently have no concept of a ConversationManager on the Acceptor
                                                          msg.getConversationId(),
                                                          this.senderId,
                                                          msg.getSenderId(),
                                                          this.dispathListener,
                                                          msg,
                                                          new MinaIoWriter( session ),
                                                          null );
View Full Code Here

    }

    @Override
    public void messageReceived(IoSession session,
                                Object object) throws Exception {
        Message msg = (Message) object;
        Conversation conversation = new ConversationImpl( null, //TODO this should not be null, but we currently have no concept of a ConversationManager on the Acceptor
                                                          msg.getConversationId(),
                                                          this.senderId,
                                                          msg.getSenderId(),
                                                          this.dispathListener,
                                                          msg,
                                                          new MinaIoWriter( session ),
                                                          null );
        if (msg instanceof ExceptionMessage){
View Full Code Here

TOP

Related Classes of org.drools.grid.io.Message

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.