7.2. Create a StatefulKnowledgeSession From a KnowledgeBase

Created from the KnowledgeBase, the StatefulKnowledgeSession stores and executes on the runtime data. Below is the code for creating a new StatefulKnowledgeSession from a KnowledgeBase:
StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession();