public <T> StatefulEJBLocator<T> openSession(final StatelessEJBLocator<T> statelessLocator, final ConnectionPeerIdentity identity, EJBSessionCreationInvocationContext clientInvocationContext) throws Exception { SessionOpenInvocation<T> invocation = invocationTracker.addInvocation(id -> new SessionOpenInvocation<>(id, statelessLocator, clientInvocationContext)); try (MessageOutputStream out = invocationTracker.allocateMessage()) { out.write(Protocol.OPEN_SESSION_REQUEST); out.writeShort(invocation.getIndex()); writeRawIdentifier(statelessLocator, out); if (version >= 3) { out.writeInt(identity.getId()); invocation.setOutflowHandle(writeTransaction(clientInvocationContext.getTransaction(), out)); } } catch (IOException e) { CreateException createException = new CreateException(e.getMessage()); createException.initCause(e); throw createException; } // await the response return invocation.getResult(); }
invocation.setOutflowHandle(writeTransaction(invocationContext.getTransaction(), marshaller));
public <T> StatefulEJBLocator<T> openSession(final StatelessEJBLocator<T> statelessLocator, final ConnectionPeerIdentity identity, EJBSessionCreationInvocationContext clientInvocationContext) throws Exception { SessionOpenInvocation<T> invocation = invocationTracker.addInvocation(id -> new SessionOpenInvocation<>(id, statelessLocator, clientInvocationContext)); try (MessageOutputStream out = invocationTracker.allocateMessage()) { out.write(Protocol.OPEN_SESSION_REQUEST); out.writeShort(invocation.getIndex()); writeRawIdentifier(statelessLocator, out); if (version >= 3) { out.writeInt(identity.getId()); invocation.setOutflowHandle(writeTransaction(clientInvocationContext.getTransaction(), out)); } } catch (IOException e) { CreateException createException = new CreateException(e.getMessage()); createException.initCause(e); throw createException; } // await the response return invocation.getResult(); }
public <T> StatefulEJBLocator<T> openSession(final StatelessEJBLocator<T> statelessLocator, final ConnectionPeerIdentity identity, EJBSessionCreationInvocationContext clientInvocationContext) throws Exception { SessionOpenInvocation<T> invocation = invocationTracker.addInvocation(id -> new SessionOpenInvocation<>(id, statelessLocator, clientInvocationContext)); try (MessageOutputStream out = invocationTracker.allocateMessage()) { out.write(Protocol.OPEN_SESSION_REQUEST); out.writeShort(invocation.getIndex()); writeRawIdentifier(statelessLocator, out); if (version >= 3) { out.writeInt(identity.getId()); invocation.setOutflowHandle(writeTransaction(clientInvocationContext.getTransaction(), out)); } } catch (IOException e) { CreateException createException = new CreateException(e.getMessage()); createException.initCause(e); throw createException; } // await the response return invocation.getResult(); }
invocation.setOutflowHandle(writeTransaction(invocationContext.getTransaction(), marshaller));
invocation.setOutflowHandle(writeTransaction(invocationContext.getTransaction(), marshaller));