/** * Create a custom SOAP fault. * @param soapFaultType the soap fault type. * @param subcode The fault subcode. * @param reason The fault reason. * @param detailElement The fault detailElement. */ public SoapFault11(final SoapFaultType soapFaultType, final QName subcode, final String reason, final Element detailElement) { super(soapFaultType, subcode, reason, getDetailString(detailElement)) ; this.detailElement = detailElement; }
@Override public ServiceRegistry run() { return ServiceRegistry.getRegistry(); }
/** * Get the service URI. * @param serviceName The service name. * @param isSecure true if the secure service URL is required false if the normal service URL is required * @return The service URI or null if not registered. */ public String getServiceURI(final String serviceName, boolean isSecure) { if (isSecure) { return getSecureServiceURI(serviceName); } else { return getServiceURI(serviceName); } } }
final W3CEndpointReference getParticipant(final String id, final boolean isSecure) { final QName serviceName = AtomicTransactionConstants.PARTICIPANT_SERVICE_QNAME; final QName endpointName = AtomicTransactionConstants.PARTICIPANT_PORT_QNAME; final String address = ServiceRegistry.getRegistry().getServiceURI(AtomicTransactionConstants.PARTICIPANT_SERVICE_NAME, isSecure); W3CEndpointReferenceBuilder builder = new W3CEndpointReferenceBuilder(); builder.serviceName(serviceName); builder.endpointName(endpointName); builder.address(address); InstanceIdentifier.setEndpointInstanceIdentifier(builder, id); return builder.build(); }
public static SoapFault11 fromFault(Fault fault) { try { QName subcode = fault.getFaultcode(); String reason = fault.getFaultstring(); return new SoapFault11(SoapFaultType.FAULT_SENDER, subcode, reason); } catch (Throwable th) { return new SoapFault11(th); } }
public Fault toFault() { Fault fault = factory.createFault(); QName faultcode = subcode; String faultstring = getReason(); fault.setFaultcode(faultcode); fault.setFaultstring(faultstring); return fault; }
private W3CEndpointReference getCompletionCoordinator(final InstanceIdentifier instanceIdentifier, final boolean isSecure) { W3CEndpointReferenceBuilder builder = new W3CEndpointReferenceBuilder(); String address = ServiceRegistry.getRegistry().getServiceURI(AtomicTransactionConstants.COMPLETION_COORDINATOR_SERVICE_NAME, isSecure); builder.serviceName(AtomicTransactionConstants.COMPLETION_COORDINATOR_SERVICE_QNAME); builder.endpointName(AtomicTransactionConstants.COMPLETION_COORDINATOR_PORT_QNAME); builder.address(address); InstanceIdentifier.setEndpointInstanceIdentifier(builder, instanceIdentifier); return builder.build(); }
/** * Get the service URI. * @param serviceName The service name. * @param isSecure true if the secure service URL is required false if the normal service URL is required * @return The service URI or null if not registered. */ public String getServiceURI(final String serviceName, boolean isSecure) { if (isSecure) { return getSecureServiceURI(serviceName); } else { return getServiceURI(serviceName); } } }
public static SoapFault11 fromFault(Fault fault) { try { QName subcode = fault.getFaultcode(); String reason = fault.getFaultstring(); return new SoapFault11(SoapFaultType.FAULT_SENDER, subcode, reason); } catch (Throwable th) { return new SoapFault11(th); } }
/** * Create a custom SOAP fault. * @param soapFaultType the soap fault type. * @param subcode The fault subcode. * @param reason The fault reason. * @param detailElement The fault detailElement. */ public SoapFault11(final SoapFaultType soapFaultType, final QName subcode, final String reason, final Element detailElement) { super(soapFaultType, subcode, reason, getDetailString(detailElement)) ; this.detailElement = detailElement; }
private W3CEndpointReference getCoordinator(final String participantId, final boolean isSecure) { W3CEndpointReferenceBuilder builder = new W3CEndpointReferenceBuilder(); String address = ServiceRegistry.getRegistry().getServiceURI(AtomicTransactionConstants.COORDINATOR_SERVICE_NAME, isSecure); builder.serviceName(AtomicTransactionConstants.COORDINATOR_SERVICE_QNAME); builder.endpointName(AtomicTransactionConstants.COORDINATOR_PORT_QNAME); builder.address(address); InstanceIdentifier.setEndpointInstanceIdentifier(builder, participantId); return builder.build(); }
/** * Get the service URI. * @param serviceName The service name. * @param isSecure true if the secure service URL is required false if the normal service URL is required * @return The service URI or null if not registered. */ public String getServiceURI(final String serviceName, boolean isSecure) { if (isSecure) { return getSecureServiceURI(serviceName); } else { return getServiceURI(serviceName); } } }
public static SoapFault11 fromFault(Fault fault) { try { QName subcode = fault.getFaultcode(); String reason = fault.getFaultstring(); return new SoapFault11(SoapFaultType.FAULT_SENDER, subcode, reason); } catch (Throwable th) { return new SoapFault11(th); } }
/** * Create a custom SOAP fault. * @param soapFaultType the soap fault type. * @param subcode The fault subcode. * @param reason The fault reason. * @param detailElement The fault detailElement. */ public SoapFault11(final SoapFaultType soapFaultType, final QName subcode, final String reason, final Element detailElement) { super(soapFaultType, subcode, reason, getDetailString(detailElement)) ; this.detailElement = detailElement; }
private W3CEndpointReference getCompletionCoordinator(final InstanceIdentifier instanceIdentifier, final boolean isSecure) { W3CEndpointReferenceBuilder builder = new W3CEndpointReferenceBuilder(); String address = ServiceRegistry.getRegistry().getServiceURI(AtomicTransactionConstants.COMPLETION_COORDINATOR_SERVICE_NAME, isSecure); builder.serviceName(AtomicTransactionConstants.COMPLETION_COORDINATOR_SERVICE_QNAME); builder.endpointName(AtomicTransactionConstants.COMPLETION_COORDINATOR_PORT_QNAME); builder.address(address); InstanceIdentifier.setEndpointInstanceIdentifier(builder, instanceIdentifier); return builder.build(); }
/** * Get the service URI. * @param serviceName The service name. * @param isSecure true if the secure service URL is required false if the normal service URL is required * @return The service URI or null if not registered. */ public String getServiceURI(final String serviceName, boolean isSecure) { if (isSecure) { return getSecureServiceURI(serviceName); } else { return getServiceURI(serviceName); } } }
public static SoapFault11 fromFault(Fault fault) { try { QName subcode = fault.getFaultcode(); String reason = fault.getFaultstring(); return new SoapFault11(SoapFaultType.FAULT_SENDER, subcode, reason); } catch (Throwable th) { return new SoapFault11(th); } }
/** * Create a custom SOAP fault. * @param soapFaultType the soap fault type. * @param subcode The fault subcode. * @param reason The fault reason. * @param detailElement The fault detailElement. */ public SoapFault11(final SoapFaultType soapFaultType, final QName subcode, final String reason, final Element detailElement) { super(soapFaultType, subcode, reason, getDetailString(detailElement)) ; this.detailElement = detailElement; }
private W3CEndpointReference getCoordinator(final String participantId, final boolean isSecure) { W3CEndpointReferenceBuilder builder = new W3CEndpointReferenceBuilder(); String address = ServiceRegistry.getRegistry().getServiceURI(AtomicTransactionConstants.COORDINATOR_SERVICE_NAME, isSecure); builder.serviceName(AtomicTransactionConstants.COORDINATOR_SERVICE_QNAME); builder.endpointName(AtomicTransactionConstants.COORDINATOR_PORT_QNAME); builder.address(address); InstanceIdentifier.setEndpointInstanceIdentifier(builder, participantId); return builder.build(); }
private W3CEndpointReference getParticipant(final String id, final boolean isSecure) { final QName serviceName = AtomicTransactionConstants.PARTICIPANT_SERVICE_QNAME; final QName endpointName = AtomicTransactionConstants.PARTICIPANT_PORT_QNAME; final String address = ServiceRegistry.getRegistry().getServiceURI(AtomicTransactionConstants.PARTICIPANT_SERVICE_NAME, isSecure); W3CEndpointReferenceBuilder builder = new W3CEndpointReferenceBuilder(); builder.serviceName(serviceName); builder.endpointName(endpointName); builder.address(address); InstanceIdentifier.setEndpointInstanceIdentifier(builder, id); return builder.build(); }