Package org.kie.api.runtime
Interface KieContainerSessionsPool
-
- All Superinterfaces:
KieSessionsPool
public interface KieContainerSessionsPool extends KieSessionsPool
A pool of session created from a KieContainer
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description KieSession
newKieSession(java.lang.String kSessionName)
Obtain aKieSession
with the given name from this pool.KieSession
newKieSession(java.lang.String kSessionName, KieSessionConfiguration conf)
Obtain aKieSession
with the given name and configuration from this pool.StatelessKieSession
newStatelessKieSession(java.lang.String kSessionName)
Obtain aStatelessKieSession
with the given name from this pool.StatelessKieSession
newStatelessKieSession(java.lang.String kSessionName, KieSessionConfiguration conf)
Obtain aStatelessKieSession
with the given name and configuration from this pool.-
Methods inherited from interface org.kie.api.runtime.KieSessionsPool
newKieSession, newKieSession, newStatelessKieSession, newStatelessKieSession, shutdown
-
-
-
-
Method Detail
-
newKieSession
KieSession newKieSession(java.lang.String kSessionName)
Obtain aKieSession
with the given name from this pool. CallingKieSession.dispose()
on this session when you are done will push it back into the pool.- Returns:
- created
KieSession
- Throws:
java.lang.RuntimeException
- if the KieContainer doesn't have any KieSession with the given name
-
newKieSession
KieSession newKieSession(java.lang.String kSessionName, KieSessionConfiguration conf)
Obtain aKieSession
with the given name and configuration from this pool. CallingKieSession.dispose()
on this session when you are done will push it back into the pool.- Returns:
- created
KieSession
- Throws:
java.lang.RuntimeException
- if the KieContainer doesn't have any KieSession with the given name
-
newStatelessKieSession
StatelessKieSession newStatelessKieSession(java.lang.String kSessionName)
Obtain aStatelessKieSession
with the given name from this pool. Note that, what is pooled here is notStatelessKieSession
but theKieSession
that it internally wraps, so calling multiple timesCommandExecutor.execute(Command)
()} (or one of its overload) will make thisStatelessKieSession
to get aKieSession
from the pool instead of creating a new one.- Returns:
- created
StatelessKieSession
- Throws:
java.lang.RuntimeException
- if this KieContainer doesn't have any StatelessKieSession with the given name
-
newStatelessKieSession
StatelessKieSession newStatelessKieSession(java.lang.String kSessionName, KieSessionConfiguration conf)
Obtain aStatelessKieSession
with the given name and configuration from this pool. Note that, what is pooled here is notStatelessKieSession
but theKieSession
that it internally wraps, so calling multiple timesCommandExecutor.execute(Command)
()} (or one of its overload) will make thisStatelessKieSession
to get aKieSession
from the pool instead of creating a new one.- Returns:
- created
StatelessKieSession
- Throws:
java.lang.RuntimeException
- if this KieContainer doesn't have any StatelessKieSession with the given name
-
-