Package org.apache.uima.ducc.transport.event

Examples of org.apache.uima.ducc.transport.event.SubmitReservationReplyDuccEvent


        replyJobEvent.setProperties(cancelJobEvent.getProperties());
        exchange.getIn().setBody(replyJobEvent);
      }
      if(obj instanceof SubmitReservationDuccEvent) {
        SubmitReservationDuccEvent submitReservationEvent = exchange.getIn().getBody(SubmitReservationDuccEvent.class);
        SubmitReservationReplyDuccEvent replyReservationEvent = new SubmitReservationReplyDuccEvent();
        replyReservationEvent.setProperties(submitReservationEvent.getProperties());
        exchange.getIn().setBody(replyReservationEvent);
      }
      if(obj instanceof CancelReservationDuccEvent) {
        CancelReservationDuccEvent cancelReservationEvent = exchange.getIn().getBody(CancelReservationDuccEvent.class);
        CancelReservationReplyDuccEvent replyReservationEvent = new CancelReservationReplyDuccEvent();
        replyReservationEvent.setProperties(cancelReservationEvent.getProperties());
        exchange.getIn().setBody(replyReservationEvent);
      }
      if(obj instanceof SubmitServiceDuccEvent) {
        SubmitServiceDuccEvent submitServiceEvent = exchange.getIn().getBody(SubmitServiceDuccEvent.class);
        SubmitServiceReplyDuccEvent replyServiceEvent = new SubmitServiceReplyDuccEvent();
View Full Code Here


     * @return True if the DUCC grants the reservation.
     */
  public boolean execute()
    {   
        SubmitReservationDuccEvent      ev    = new SubmitReservationDuccEvent(requestProperties);
        SubmitReservationReplyDuccEvent reply = null;
       
        try {
            reply = (SubmitReservationReplyDuccEvent) dispatcher.dispatchAndWaitForDuccReply(ev);
        } catch (Exception e) {
            message("Reservation not submitted:", e.getMessage());
            return false;
        } finally {
            dispatcher.close();
        }

        /*
         * process reply (gets friendlyId and messages.
         */
        boolean rc = extractReply(reply);

        if ( rc ) {
          nodeList = reply.getProperties().getProperty(UiOption.ReservationNodeList.pname());
        }
       
        if((nodeList.trim()).length() == 0) {
          Properties properties = reply.getProperties();
            if(properties != null) {
              String key = ReservationReplyProperties.key_message;
              if(properties.containsKey(key)) {
                info = properties.getProperty(key);
              }
View Full Code Here

TOP

Related Classes of org.apache.uima.ducc.transport.event.SubmitReservationReplyDuccEvent

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.