this.trackedConnectionAssociator = trackedConnectionAssociator;
}
public void before(Object[] context, ServletRequest httpRequest, ServletResponse httpResponse, int dispatch) {
try {
SharedConnectorInstanceContext newConnectorInstanceContext = new SharedConnectorInstanceContext(unshareableResources, applicationManagedSecurityResources, false);
ConnectorInstanceContext oldContext = trackedConnectionAssociator.enter(newConnectorInstanceContext);
if (oldContext != null) {
newConnectorInstanceContext.share(oldContext);
}
context[oldIndex] = oldContext;
context[newIndex] = newConnectorInstanceContext;
} catch (ResourceException e) {
throw new RuntimeException(e);