WS-ReliableMessaging

Stable • Since 1.5.3

WS-ReliableMessaging (WS-RM) is a protocol ensuring a reliable delivery of messages in a distributed environment even in presence of software, system, or network failures.

This extension provides CXF framework’s WS-ReliableMessaging implementation.

Maven coordinates

Create a new project using quarkus-cxf-rt-ws-rm on code.quarkus.io or add these coordinates to your existing project:

<dependency>
    <groupId>io.quarkiverse.cxf</groupId>
    <artifactId>quarkus-cxf-rt-ws-rm</artifactId>
</dependency>

Check the User guide and especially its Dependency management section for more information about writing applications with Quarkus CXF.

Supported standards

Usage

Once your application depends on quarkus-cxf-rt-ws-rm, WS-RM is enabled for all clients and service endpoints defined in application.properties. This is due to the fact that the quarkus.cxf.client.myClient.rm.enabled and quarkus.cxf.endpoint."/my-endpoint".rm.enabled properties are true by default.

Enabling WS-RM for a client or service endpoints means that WS-RM interceptors will be added to the given client or endpoint.

In addition to that you may want to set some of the options documented below and/or the following WS-Addressing options:

Runnable example

There is an integration test covering WS-RM with a decoupled endpoint in the Quarkus CXF source tree.

It is split into two separate applications that communicate with each other:

To run it, you need to install the server into your local Maven repository first

$ cd test-util-parent/test-ws-rm-server-jvm
$ mvn clean install

And then you can run the test scenario implemented in the client module:

$ cd ../../integration-tests/ws-rm-client
$ mvn clean test

You should see the exchange of SOAP messages between the client, the server and the decoupled endpoint in the console.

Configuration

Configuration property fixed at build time. All other configuration properties are overridable at runtime.

Configuration property Type Default

quarkus.cxf.rm.namespace

string

http://schemas.xmlsoap.org/ws/2005/02/rm

Environment variable: QUARKUS_CXF_RM_NAMESPACE
Since Quarkus CXF: 2.7.0

quarkus.cxf.rm.wsa-namespace

string

http://schemas.xmlsoap.org/ws/2004/08/addressing

WS-Addressing version namespace: http://schemas.xmlsoap.org/ws/2004/08/addressing or http://www.w3.org/2005/08/addressing. Note that this property is ignored unless you are using the http://schemas.xmlsoap.org/ws/2005/02/rm/ RM namespace.

Environment variable: QUARKUS_CXF_RM_WSA_NAMESPACE
Since Quarkus CXF: 2.7.0

quarkus.cxf.rm.inactivity-timeout

long

A time duration in milliseconds after which the associated sequence will be closed if no messages (including acknowledgments and other control messages) were exchanged between the sender and receiver during that period of time. If not set, the associated sequence will never be closed due to inactivity.

Environment variable: QUARKUS_CXF_RM_INACTIVITY_TIMEOUT
Since Quarkus CXF: 2.7.0

quarkus.cxf.rm.retransmission-interval

long

3000

A time duration in milliseconds between successive attempts to resend a message that has not been acknowledged by the receiver.

Environment variable: QUARKUS_CXF_RM_RETRANSMISSION_INTERVAL
Since Quarkus CXF: 2.7.0

quarkus.cxf.rm.exponential-backoff

boolean

false

If true the retransmission interval will be doubled on every transmission attempt; otherwise the retransmission interval stays equal to quarkus.cxf.rm.retransmission-interval for every retransmission attempt.

Environment variable: QUARKUS_CXF_RM_EXPONENTIAL_BACKOFF
Since Quarkus CXF: 2.7.0

quarkus.cxf.rm.acknowledgement-interval

long

A time duration in milliseconds within which an acknowledgement for a received message is expected to be sent by a RM destination. If not specified, the acknowledgements will be sent immediately.

Environment variable: QUARKUS_CXF_RM_ACKNOWLEDGEMENT_INTERVAL
Since Quarkus CXF: 2.7.0

quarkus.cxf.rm.store

string

A reference to a org.apache.cxf.ws.rm.persistence.RMStore bean used to store source and destination sequences and message references.

Environment variable: QUARKUS_CXF_RM_STORE
Since Quarkus CXF: 2.7.0

quarkus.cxf.rm.feature-ref

string

#defaultRmFeature

A reference to a org.apache.cxf.ws.rm.feature.RMFeature bean to set on clients and service endpoint which have quarkus.cxf.[client|service]."name".rm.enabled = true.

If the value is #defaultRmFeature then Quarkus CXF creates and configures the bean for you.

Environment variable: QUARKUS_CXF_RM_FEATURE_REF
Since Quarkus CXF: 2.7.0

quarkus.cxf.client."clients".rm.enabled

boolean

true

If true then the WS-ReliableMessaging interceptors will be added to this client or service endpoint.

Environment variable: QUARKUS_CXF_CLIENT__CLIENTS__RM_ENABLED

quarkus.cxf.endpoint."endpoints".rm.enabled

boolean

true

If true then the WS-ReliableMessaging interceptors will be added to this client or service endpoint.

Environment variable: QUARKUS_CXF_ENDPOINT__ENDPOINTS__RM_ENABLED