use of org.wildfly.clustering.ee.cache.tx.TransactionBatch in project wildfly by wildfly.
the class HotRodSessionManagerFactory method createSessionManager.
@Override
public SessionManager<LC, TransactionBatch> createSessionManager(SessionManagerConfiguration<SC> configuration) {
Registrar<SessionExpirationListener> expirationRegistrar = this.expirationRegistrar;
Batcher<TransactionBatch> batcher = this.batcher;
Duration transactionTimeout = this.transactionTimeout;
HotRodSessionManagerConfiguration<SC> config = new HotRodSessionManagerConfiguration<SC>() {
@Override
public SessionExpirationListener getExpirationListener() {
return configuration.getExpirationListener();
}
@Override
public Registrar<SessionExpirationListener> getExpirationRegistrar() {
return expirationRegistrar;
}
@Override
public Supplier<String> getIdentifierFactory() {
return configuration.getIdentifierFactory();
}
@Override
public SC getServletContext() {
return configuration.getServletContext();
}
@Override
public Batcher<TransactionBatch> getBatcher() {
return batcher;
}
@Override
public Duration getStopTimeout() {
return transactionTimeout;
}
};
return new ConcurrentSessionManager<>(new HotRodSessionManager<>(this.factory, config), ConcurrentManager::new);
}
Aggregations