Package org.kie.internal.runtime.manager
Interface SessionFactory
public interface SessionFactory
Factory that produces
KieSession instances.-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Closes the factory and releases all resourcesorg.kie.api.runtime.KieSessionfindKieSessionById(Long sessionId) LoadsKieSessionform data store (such as db) based on given id.org.kie.api.runtime.KieSessionProduces new instance ofKieSessionvoidInvoked when runtime engine is about to be disposed
-
Method Details
-
newKieSession
org.kie.api.runtime.KieSession newKieSession()Produces new instance ofKieSession- Returns:
- new instance of
KieSession
-
findKieSessionById
LoadsKieSessionform data store (such as db) based on given id.- Parameters:
sessionId- identifier of ksession- Returns:
- loaded instance of
KieSession - Throws:
RuntimeException- in case session cannot be loaded
-
close
void close()Closes the factory and releases all resources -
onDispose
Invoked when runtime engine is about to be disposed- Parameters:
sessionId- ksession id that is disposed.
-