@Provider @Priority(value=4920) public class ImportWildflyClientGlobalTransactionFilter extends Object implements javax.ws.rs.container.ContainerRequestFilter, javax.ws.rs.container.ContainerResponseFilter
Request and response filter which is expected to be called
for the request side after the InboundBridgeFilter is processed
while on the response side before the InboundBridgeFilter is processed.
Purpose of this filter is an integration of WFTC with Narayana REST-AT Inbound Bridge. Inbound Bridge uses Narayana transactions while WFLY utilizes WFTC transactions (wrapping the underlaying Narayana) ones. For that on request side the Inbound bridge first creates the Narayana transaction and then the request filter makes the WFTC to wrap and to know about this transaction. On the response side the WFTC needs to suspend its wrapping transaction and then Narayana suspend its own transaction (which was already suspended by WFTC callback and thus is ignored on the Narayana side).
The InboundBridgeFilter defines its Priority
as . This WildFly filter has to be processed after the Narayana
one and it needs to define higher priority.
Priorities#USER-100
| Constructor and Description |
|---|
ImportWildflyClientGlobalTransactionFilter() |
| Modifier and Type | Method and Description |
|---|---|
void |
filter(javax.ws.rs.container.ContainerRequestContext requestContext) |
void |
filter(javax.ws.rs.container.ContainerRequestContext requestContext,
javax.ws.rs.container.ContainerResponseContext responseContext) |
public ImportWildflyClientGlobalTransactionFilter()
public void filter(javax.ws.rs.container.ContainerRequestContext requestContext)
throws IOException
filter in interface javax.ws.rs.container.ContainerRequestFilterIOExceptionpublic void filter(javax.ws.rs.container.ContainerRequestContext requestContext,
javax.ws.rs.container.ContainerResponseContext responseContext)
throws IOException
filter in interface javax.ws.rs.container.ContainerResponseFilterIOExceptionCopyright © 2021 JBoss by Red Hat. All rights reserved.