/** * Sets the axis operation to the message context. If axis operation is already set in the message context take it * from there. If not take the axis operation from axis service. * * @param msgContext messageContext message context * @param axisService axis service */ private static void setAxisOperation(MessageContext msgContext, AxisService axisService) { if (msgContext.getAxisOperation() == null && axisService != null) { AxisOperation axisOperation = findOperation(axisService, msgContext); msgContext.setAxisOperation(axisOperation); } }
private void validateBrokerWSEventingOperation(MessageContext msgContext) { if (msgContext.getAxisOperation() == null) { AxisService service = msgContext.getAxisService(); AxisOperation pubOperation = getPublishOperation(service); msgContext.setAxisOperation(pubOperation); } }
private void validateBrokerWSEventingOperation(MessageContext msgContext) { if (msgContext.getAxisOperation() == null) { AxisService service = msgContext.getAxisService(); AxisOperation pubOperation = getPublishOperation(service); msgContext.setAxisOperation(pubOperation); } }
private void validateMsgBoxStoreOperation(MessageContext msgContext) { if (msgContext.getAxisOperation() == null) { AxisService service = msgContext.getAxisService(); AxisOperation storeMsgOperation = getMessageBoxOperation(service); msgContext.setAxisOperation(storeMsgOperation); } }
private void validateMsgBoxStoreOperation(MessageContext msgContext) { if (msgContext.getAxisOperation() == null) { AxisService service = msgContext.getAxisService(); AxisOperation storeMsgOperation = getMessageBoxOperation(service); msgContext.setAxisOperation(storeMsgOperation); } }
public void registerMessageContext(MessageContext msgContext, OperationContext operationContext) throws AxisFault { msgContext.setAxisOperation(this); operationContext.addMessageContext(msgContext); msgContext.setOperationContext(operationContext); if (operationContext.isComplete()) { operationContext.cleanup(); } }
protected MessageContext buildMessageContext(String opName) throws AxisFault { MessageContext msgCtx = new MessageContext(); AxisService svc = getAxisService(); msgCtx.setAxisService(svc); msgCtx.setAxisOperation(getAxisOperation(svc, opName)); return msgCtx; }
public void registerMessageContext(MessageContext msgContext, OperationContext operationContext) throws AxisFault { msgContext.setAxisOperation(this); operationContext.addMessageContext(msgContext); msgContext.setOperationContext(operationContext); if (operationContext.isComplete()) { operationContext.cleanup(); } }
/** * @param msgctx * @throws org.apache.axis2.AxisFault */ public InvocationResponse invoke(MessageContext msgctx) throws AxisFault { if ((msgctx.getAxisService() != null) && (msgctx.getAxisOperation() == null)) { AxisOperation axisOperation = findOperation(msgctx.getAxisService(), msgctx); if (axisOperation != null) { if (LoggingControl.debugLoggingAllowed && log.isDebugEnabled()) { log.debug(msgctx.getLogIDString() + " " + Messages.getMessage("operationfound", axisOperation .getName().getLocalPart())); } msgctx.setAxisOperation(axisOperation); //setting axisMessage into messageContext msgctx.setAxisMessage(axisOperation.getMessage( WSDLConstants.MESSAGE_LABEL_IN_VALUE)); } } return InvocationResponse.CONTINUE; } }
/** * @param msgctx * @throws org.apache.axis2.AxisFault */ public InvocationResponse invoke(MessageContext msgctx) throws AxisFault { if ((msgctx.getAxisService() != null) && (msgctx.getAxisOperation() == null)) { AxisOperation axisOperation = findOperation(msgctx.getAxisService(), msgctx); if (axisOperation != null) { if (LoggingControl.debugLoggingAllowed && log.isDebugEnabled()) { log.debug(msgctx.getLogIDString() + " " + Messages.getMessage("operationfound", axisOperation .getName().getLocalPart())); } msgctx.setAxisOperation(axisOperation); //setting axisMessage into messageContext msgctx.setAxisMessage(axisOperation.getMessage( WSDLConstants.MESSAGE_LABEL_IN_VALUE)); } } return InvocationResponse.CONTINUE; } }
if (axisOperation != null) { if (msgContext.getAxisOperation() == null) { msgContext.setAxisOperation(axisOperation);
public static void dispatchAndVerify(MessageContext msgContext) throws AxisFault { String extendedURIBasedDispatcher = System.getProperty("ei.extendedURIBasedDispatcher"); if (extendedURIBasedDispatcher == null) { requestDispatcher.invoke(msgContext); } else { try { invokeMethod.invoke(dispatcherInstance, msgContext); } catch (IllegalAccessException | InvocationTargetException e) { throw new AxisFault(e.getMessage()); } } AxisService axisService = msgContext.getAxisService(); if (axisService != null) { httpLocationBasedDispatcher.invoke(msgContext); if (msgContext.getAxisOperation() == null) { requestURIOperationDispatcher.invoke(msgContext); } AxisOperation axisOperation; if ((axisOperation = msgContext.getAxisOperation()) != null) { AxisEndpoint axisEndpoint = (AxisEndpoint) msgContext.getProperty(WSDL2Constants.ENDPOINT_LOCAL_NAME); if (axisEndpoint != null) { AxisBindingOperation axisBindingOperation = (AxisBindingOperation) axisEndpoint .getBinding().getChild(axisOperation.getName()); msgContext.setProperty(Constants.AXIS_BINDING_OPERATION, axisBindingOperation); } msgContext.setAxisOperation(axisOperation); } } }
public void registerOperationContext(MessageContext msgContext, OperationContext operationContext) throws AxisFault { msgContext.setAxisOperation(this); msgContext.getConfigurationContext().registerOperationContext(msgContext.getMessageID(), operationContext); operationContext.addMessageContext(msgContext); msgContext.setOperationContext(operationContext); if (operationContext.isComplete()) { operationContext.cleanup(); } }
/** * @param context The OperationContext */ public void setOperationContext(OperationContext context) { // allow setting the fields to null // useful when extracting the messge context from the object graph operationContext = context; this.setParent(operationContext); if (operationContext != null) { if (serviceContext == null) { setServiceContext(operationContext.getServiceContext()); } else { if (operationContext.getParent() != serviceContext) { throw new AxisError("ServiceContext in OperationContext does not match !"); } } this.setAxisOperation(operationContext.getAxisOperation()); } }
public void registerOperationContext(MessageContext msgContext, OperationContext operationContext) throws AxisFault { msgContext.setAxisOperation(this); msgContext.getConfigurationContext().registerOperationContext(msgContext.getMessageID(), operationContext); operationContext.addMessageContext(msgContext); msgContext.setOperationContext(operationContext); if (operationContext.isComplete()) { operationContext.cleanup(); } }
/** * @param context The OperationContext */ public void setOperationContext(OperationContext context) { // allow setting the fields to null // useful when extracting the messge context from the object graph operationContext = context; this.setParent(operationContext); if (operationContext != null) { if (serviceContext == null) { setServiceContext(operationContext.getServiceContext()); } else { if (operationContext.getParent() != serviceContext) { throw new AxisError("ServiceContext in OperationContext does not match !"); } } this.setAxisOperation(operationContext.getAxisOperation()); } }
public MessageContext createMessageContext() throws AxisFault { MessageContext msgContext = listener.createMessageContext(); if (service != null) { msgContext.setAxisService(service); // find the operation for the message, or default to one Parameter operationParam = service.getParameter(BaseConstants.OPERATION_PARAM); QName operationQName = ( operationParam != null ? BaseUtils.getQNameFromString(operationParam.getValue()) : BaseConstants.DEFAULT_OPERATION); AxisOperation operation = service.getOperation(operationQName); if (operation != null) { msgContext.setAxisOperation(operation); msgContext.setAxisMessage( operation.getMessage(WSDL2Constants.MESSAGE_LABEL_IN)); msgContext.setSoapAction("urn:" + operation.getName().getLocalPart()); } } return msgContext; } }
public MessageContext createMessageContext() throws AxisFault { MessageContext msgContext = listener.createMessageContext(); if (service != null) { msgContext.setAxisService(service); // find the operation for the message, or default to one Parameter operationParam = service.getParameter(BaseConstants.OPERATION_PARAM); QName operationQName = ( operationParam != null ? BaseUtils.getQNameFromString(operationParam.getValue()) : BaseConstants.DEFAULT_OPERATION); AxisOperation operation = service.getOperation(operationQName); if (operation != null) { msgContext.setAxisOperation(operation); msgContext.setAxisMessage( operation.getMessage(WSDL2Constants.MESSAGE_LABEL_IN)); msgContext.setSoapAction("urn:" + operation.getName().getLocalPart()); } } return msgContext; } }
private static void dispatchAndVerify(MessageContext msgContext) throws AxisFault { RequestURIBasedDispatcher requestDispatcher = new RequestURIBasedDispatcher(); requestDispatcher.invoke(msgContext); AxisService axisService = msgContext.getAxisService(); if (axisService != null) { HTTPLocationBasedDispatcher httpLocationBasedDispatcher = new HTTPLocationBasedDispatcher(); httpLocationBasedDispatcher.invoke(msgContext); if (msgContext.getAxisOperation() == null) { RequestURIOperationDispatcher requestURIOperationDispatcher = new RequestURIOperationDispatcher(); requestURIOperationDispatcher.invoke(msgContext); } AxisOperation axisOperation; if ((axisOperation = msgContext.getAxisOperation()) != null) { AxisEndpoint axisEndpoint = (AxisEndpoint) msgContext.getProperty(WSDL2Constants.ENDPOINT_LOCAL_NAME); if (axisEndpoint != null) { AxisBindingOperation axisBindingOperation = (AxisBindingOperation) axisEndpoint .getBinding().getChild(axisOperation.getName()); msgContext.setProperty(Constants.AXIS_BINDING_OPERATION, axisBindingOperation); } msgContext.setAxisOperation(axisOperation); } } }
private static void dispatchAndVerify(MessageContext msgContext) throws AxisFault { RequestURIBasedDispatcher requestDispatcher = new RequestURIBasedDispatcher(); requestDispatcher.invoke(msgContext); AxisService axisService = msgContext.getAxisService(); if (axisService != null) { HTTPLocationBasedDispatcher httpLocationBasedDispatcher = new HTTPLocationBasedDispatcher(); httpLocationBasedDispatcher.invoke(msgContext); if (msgContext.getAxisOperation() == null) { RequestURIOperationDispatcher requestURIOperationDispatcher = new RequestURIOperationDispatcher(); requestURIOperationDispatcher.invoke(msgContext); } AxisOperation axisOperation; if ((axisOperation = msgContext.getAxisOperation()) != null) { AxisEndpoint axisEndpoint = (AxisEndpoint) msgContext.getProperty(WSDL2Constants.ENDPOINT_LOCAL_NAME); if (axisEndpoint != null) { AxisBindingOperation axisBindingOperation = (AxisBindingOperation) axisEndpoint .getBinding().getChild(axisOperation.getName()); msgContext.setProperty(Constants.AXIS_BINDING_OPERATION, axisBindingOperation); } msgContext.setAxisOperation(axisOperation); } } }