@Override protected void serializeSpecificEndpointProperties(EndpointDefinition endpointDefinition, OMElement element) { if (SynapseConstants.FORMAT_POX.equals(endpointDefinition.getFormat())) { element.addAttribute(fac.createOMAttribute("format", null, "pox")); } else if (SynapseConstants.FORMAT_GET.equals(endpointDefinition.getFormat())) { element.addAttribute(fac.createOMAttribute("format", null, "get")); } else if (SynapseConstants.FORMAT_SOAP11.equals(endpointDefinition.getFormat())) { element.addAttribute(fac.createOMAttribute("format", null, "soap11")); } else if (SynapseConstants.FORMAT_SOAP12.equals(endpointDefinition.getFormat())) { element.addAttribute(fac.createOMAttribute("format", null, "soap12")); } else if (SynapseConstants.FORMAT_REST.equals(endpointDefinition.getFormat())) { element.addAttribute(fac.createOMAttribute("format", null, "rest")); // following two kept for backward compatibility } else if (endpointDefinition.isForcePOX()) { element.addAttribute(fac.createOMAttribute("format", null, "pox")); } else if (endpointDefinition.isForceGET()) { element.addAttribute(fac.createOMAttribute("format", null, "get")); } else if (endpointDefinition.isForceSOAP11()) { element.addAttribute(fac.createOMAttribute("format", null, "soap11")); } else if (endpointDefinition.isForceSOAP12()) { element.addAttribute(fac.createOMAttribute("format", null, "soap12")); } else if (endpointDefinition.isForceREST()) { element.addAttribute(fac.createOMAttribute("format", null, "rest")); } }
@Override protected void serializeSpecificEndpointProperties(EndpointDefinition endpointDefinition, OMElement element) { if (SynapseConstants.FORMAT_POX.equals(endpointDefinition.getFormat())) { element.addAttribute(fac.createOMAttribute("format", null, "pox")); } else if (SynapseConstants.FORMAT_GET.equals(endpointDefinition.getFormat())) { element.addAttribute(fac.createOMAttribute("format", null, "get")); } else if (SynapseConstants.FORMAT_SOAP11.equals(endpointDefinition.getFormat())) { element.addAttribute(fac.createOMAttribute("format", null, "soap11")); } else if (SynapseConstants.FORMAT_SOAP12.equals(endpointDefinition.getFormat())) { element.addAttribute(fac.createOMAttribute("format", null, "soap12")); } else if (SynapseConstants.FORMAT_REST.equals(endpointDefinition.getFormat())) { element.addAttribute(fac.createOMAttribute("format", null, "rest")); // following two kept for backward compatibility } else if (endpointDefinition.isForcePOX()) { element.addAttribute(fac.createOMAttribute("format", null, "pox")); } else if (endpointDefinition.isForceGET()) { element.addAttribute(fac.createOMAttribute("format", null, "get")); } else if (endpointDefinition.isForceSOAP11()) { element.addAttribute(fac.createOMAttribute("format", null, "soap11")); } else if (endpointDefinition.isForceSOAP12()) { element.addAttribute(fac.createOMAttribute("format", null, "soap12")); } else if (endpointDefinition.isForceREST()) { element.addAttribute(fac.createOMAttribute("format", null, "rest")); } }
public void init(SynapseEnvironment synapseEnvironment) { ConfigurationContext cc = ((Axis2SynapseEnvironment) synapseEnvironment).getAxis2ConfigurationContext(); if (!initialized) { // The check for clustering environment ClusteringAgent clusteringAgent = cc.getAxisConfiguration().getClusteringAgent(); if (clusteringAgent != null && clusteringAgent.getStateManager() != null) { isClusteringEnabled = Boolean.TRUE; } else { isClusteringEnabled = Boolean.FALSE; } context = new EndpointContext(getName(), getDefinition(), isClusteringEnabled, cc, metricsMBean); } initialized = true; if (children != null) { for (Endpoint e : children) { e.init(synapseEnvironment); } } contentAware = definition != null && ((definition.getFormat() != null && !definition.getFormat().equals(SynapseConstants.FORMAT_REST)) || definition.isSecurityOn() || definition.isAddressingOn()); }
public void init(SynapseEnvironment synapseEnvironment) { ConfigurationContext cc = ((Axis2SynapseEnvironment) synapseEnvironment).getAxis2ConfigurationContext(); if (!initialized) { // The check for clustering environment ClusteringAgent clusteringAgent = cc.getAxisConfiguration().getClusteringAgent(); if (clusteringAgent != null && clusteringAgent.getStateManager() != null) { isClusteringEnabled = Boolean.TRUE; } else { isClusteringEnabled = Boolean.FALSE; } context = new EndpointContext(getName(), getDefinition(), isClusteringEnabled, cc, metricsMBean); } initialized = true; if (children != null) { for (Endpoint e : children) { e.init(synapseEnvironment); } } contentAware = definition != null && ((definition.getFormat() != null && !definition.getFormat().equals(SynapseConstants.FORMAT_REST)) || definition.isSecurityOn() || definition.isReliableMessagingOn() || definition.isAddressingOn() || definition.isUseMTOM()|| definition.isUseSwa()); }
"] [mtom = " + endpoint.isUseMTOM() + "] [swa = " + endpoint.isUseSwa() + "] [format = " + endpoint.getFormat() + "] [force soap11=" + endpoint.isForceSOAP11() + "] [force soap12=" + endpoint.isForceSOAP12() + if (SynapseConstants.FORMAT_POX.equals(endpoint.getFormat())) { axisOutMsgCtx.setDoingREST(true); axisOutMsgCtx.setProperty(org.apache.axis2.Constants.Configuration.MESSAGE_TYPE, } else if (SynapseConstants.FORMAT_GET.equals(endpoint.getFormat())) { axisOutMsgCtx.setDoingREST(true); axisOutMsgCtx.setProperty(Constants.Configuration.HTTP_METHOD, org.apache.axis2.transport.http.HTTPConstants.MEDIA_TYPE_X_WWW_FORM); } else if (SynapseConstants.FORMAT_SOAP11.equals(endpoint.getFormat())) { axisOutMsgCtx.setDoingREST(false); axisOutMsgCtx.removeProperty(org.apache.axis2.Constants.Configuration.MESSAGE_TYPE); } else if (SynapseConstants.FORMAT_SOAP12.equals(endpoint.getFormat())) { axisOutMsgCtx.setDoingREST(false); axisOutMsgCtx.removeProperty(org.apache.axis2.Constants.Configuration.MESSAGE_TYPE); } else if (SynapseConstants.FORMAT_REST.equals(endpoint.getFormat())) { boolean isRest = SynapseConstants.FORMAT_REST.equals(endpoint.getFormat());
"] [mtom = " + endpoint.isUseMTOM() + "] [swa = " + endpoint.isUseSwa() + "] [format = " + endpoint.getFormat() + "] [force soap11=" + endpoint.isForceSOAP11() + "] [force soap12=" + endpoint.isForceSOAP12() + if (SynapseConstants.FORMAT_POX.equals(endpoint.getFormat())) { axisOutMsgCtx.setDoingREST(true); axisOutMsgCtx.setProperty(org.apache.axis2.Constants.Configuration.MESSAGE_TYPE, org.apache.axis2.transport.http.HTTPConstants.MEDIA_TYPE_APPLICATION_XML); } else if (SynapseConstants.FORMAT_GET.equals(endpoint.getFormat())) { axisOutMsgCtx.setDoingREST(true); axisOutMsgCtx.setProperty(Constants.Configuration.HTTP_METHOD, } else if (SynapseConstants.FORMAT_SOAP11.equals(endpoint.getFormat())) { axisOutMsgCtx.setDoingREST(false); axisOutMsgCtx.removeProperty(org.apache.axis2.Constants.Configuration.MESSAGE_TYPE); } else if (SynapseConstants.FORMAT_SOAP12.equals(endpoint.getFormat())) { axisOutMsgCtx.setDoingREST(false); axisOutMsgCtx.removeProperty(org.apache.axis2.Constants.Configuration.MESSAGE_TYPE); } else if (SynapseConstants.FORMAT_REST.equals(endpoint.getFormat())) { boolean isRest = SynapseConstants.FORMAT_REST.equals(endpoint.getFormat());
if (endpoint.getFormat() != null) { String format = endpoint.getFormat(); if (SynapseConstants.FORMAT_POX.equals(format)) { axisOutMsgCtx.setDoingREST(true); boolean isRest = SynapseConstants.FORMAT_REST.equals(endpoint.getFormat()) | axisInMsgCtx.isDoingREST(); if (!isRest && !endpoint.isForceSOAP11() && !endpoint.isForceSOAP12()) { isRest = isRequestRest(axisInMsgCtx);
if (endpoint.getFormat() != null) { String format = endpoint.getFormat(); if (SynapseConstants.FORMAT_POX.equals(format)) { axisOutMsgCtx.setDoingREST(true); boolean isRest = SynapseConstants.FORMAT_REST.equals(endpoint.getFormat()) | axisInMsgCtx.isDoingREST(); if (!isRest && !endpoint.isForceSOAP11() && !endpoint.isForceSOAP12()) {