SlideShare uma empresa Scribd logo
1 de 30
jBPM & Drools go Enterprise
     Maciej Swiderski
Build comprehensive BPM
platform on top of jBPM and
     Drools that will truly
  accelerate your business
Sounds nice but what's that?


How easy is to:
•
  Introduce new (version of) process?
•
  Change logic of a process?
•
  Upgrade your environment?
•
  Migrate your active processes?
... the goal is to be able...

• Add new (version) processes without
  affecting already running instances
• Alter business logic invoked by the
  processes independently
• Run different versions of the engine at
  the same time
... the developer goal is to be
              able...
• Do not maintain knowledge sessions on
  application/client side
• Do not worry about version if not
  needed
  – Process version
  – Engine version
• Simplify usability of the engine from
  application/client perspective
JBoss AS7 to the rescue

• JBoss Modules
  – jBPM and Drools configured as JBoss
    Module with all their dependencies
• OSGi
  – Engine factories registered in OSGi service
    registry with version properties
  – Engines registered in OSGi service registry
    with custom properties
  – Client code packaged as OSGi bundles
Platform overview

                                       JBoss AS7
            OSGi Service Registry

    Process bundle            Process bundle


               BPM module v 1.0

jBPM & Drools Module     jBPM & Drools Module
       V 5.2                    V 5.3
Platform components
• BPM module
   – Registers resolver manager
• JBPM & Drools module
   – Registers ExecutionEngineFactory
   – Registers resolvers
• Platform bundle
   – Bootstraps and registers ExecutionEngine
• Client application
   – Uses ExecutionEngine via resolvers
BPM module

• Simple abstraction layer on top of jBPM
  and Drools APIs to make clients
  independent of the version
• Registers ResolverManager in OSGi
  service registry as single point of
  interaction for ExecutionEngine look
  ups
ResolverManager
public interface ExecutionEngineResolverManager {


    void register(String owner, ExecutionEngineResolver resolver);


    void unregister(String owner, UUID resolverUniqueId);


    ExecutionEngineResolver find(RequestContext context);


    ExecutionEngine findAndLookUp(RequestContext context);


    Collection<ExecutionEngineResolver> getResolvers();
}
jBPM & Drools module
• jBPM and Drools components bundled in a
  single JBoss Module together with all
  dependencies
• OSGi enabled
• Registers ExecutionEngineFactory that is
  exposed to process bundles to construct
  ExecutionEngines for given version of jBPM
  and Drools
• Registers resolvers supported by given
  version
ExecutionEngineFactory
public interface ExecutionEngineFactory {
    public ExecutionEngine newExecutionEngine(
                                   ClassLoader bundleClassLoader);
    public ExecutionEngine newExecutionEngine(
                             ClassLoader bundleClassLoader, 
                             ExecutionEngineConfiguration config);
    public ExecutionEngine newExecutionEngine(
                                    ClassLoader bundleClassLoader, 
                              ExecutionEngineConfiguration config, 
                                                 Object callback);
    public ExecutionEngine newExecutionEngine(
                                    ClassLoader bundleClassLoader, 
                              ExecutionEngineConfiguration config, 
                           ExecutionEngineMapperStrategy strategy,
                                                 Object callback);
}
Process bundle
• Main component that makes use of the
  platform and delivers functionality
• Produces ExecutionEngine which is:
   – Wrapper around KnowledgeBase
   – Provides session management based on
     business keys using configurable
     strategies
• Registers ExecutionEngine under various
  properties making it discoverable by resolvers
ExecutionEngine
public interface ExecutionEngine {
    public Object getKnowledgeBase();
    public SessionDelegate getStatelessSession();
    public SessionDelegate getSession(String businessKey);
    public SessionDelegate getSessionById(int id);
    public Object getHumanTaskConnector();
    public UUID getUUID();
    public String buildCompositeId(String id);
    public void disposeSession(SessionDelegate session);
}
Platform interactions
                                   4. Register Exec Engine



Process Bundle                              1. look up        OSGi
                                             EE Factory
                                                             Service
             2. Build EE
                                                             Registry

        ExecEngineFactory

             3. Build EE                        Resolver
                                                Manager
ExecutionEngine


5. Optional – register custom resolvers
Client application

• Ultimate client of the platform
• Makes use of ExecutionEngine and
  ResolverManager to perform work
• Independent of the platform and
  process version
• Communicates only through OSGi
  service registry
Platform interactions

Client app
                        1. Look up                     OSGi
                        Resolver Manager
                                                      Service
                                                      Registry
                        2. find Resolver
                        find ExecEngine
                                           Resolver      3. Look up
 4. perform operation
  on the engine
                                           Manager       exec engine




  ExecutionEngine
Client application code
// get reference to Resolver manager
ServiceReference srf = this.context.getServiceReference(
                  ExecutionEngineResolverManager.class.getName());
ExecutionEngineResolverManager resolverManager =
     (ExecutionEngineResolverManager)this.context.getService(srf);


//find right resolver and directly look up the engine
RequestContext reqContext = new HttpRequestContext(request);
ExecutionEngine engine = 
resolverManager.findAndLookUp(reqContext);


// get session by business key and start process on it    
String compositeProcessInstanceId = engine.getSession("business­
key").startProcess(”process­id”);
Resolvers
• Resolver is responsible for finding the
  right ExecutionEngine based on given
  context
• Default policy - first resolver that
  accepts the context will do the look up
  in OSGi service registry
• Platform delivers some resolvers out of
  the box but process bundles can
  introduce custom resolvers as well
Available default resolvers
• UUID based resolver that accepts context if:
   – Explicitly contains UUID property of the engine
   – Contains composite id property (for instance
     processInstanceId)
• Version based resolver that accepts context if:
   – Explicitly contains version property
• Valid time resolver that will accepts the context if:
   – No version parameter is given
Session management
• In case where more than one session is in
  use there is a need to keep track of the
  identifiers and in some cases even
  relationship between process instance and
  session instance
• By default this need must be secured on
  application side
• On clustered environment things get more
  complicated (avoid concurrent usage of the
  same session)
SessionMappingStrategies
• Platform is equipped with strategies that are
  capable of maintaining sessions identifiers
  based on some business key
• Application refers to the session with custom
  business key like for instance user id or
  department instead of the internal session id
• Strategies are pluggable and every
  ExecutionEngine instance can utilize different
  implementation
Available session mapping
           strategies
• SerializableMap strategy – dedicated
  strategy for standalone installation that
  will simply persist the map of known
  values to the disc
• Clustered strategy – dedicated strategy
  that will employ Inifinispan as
  distributed cache with configured data
  store
Make your engine configurable

• ExecutionEngine will emit notification on
  number of events so the process
  bundle can react on them:
  – Knowledge base creation
  – Knowledge session creation
  – Work item registration
  – Dispose of the session
  – etc
ExecutionEngineCallback
public interface ExecutionEngineCallback {
    public void preKnowledgeBaseCreate(KnowledgeBuilder builder);

    public void postKnowledgeBaseCreate(KnowledgeBase kBase);
    public void preKnowledgeSessionCreate(Environment environment, 

                                        KnowledgeSessionConfiguration config, KnowledgeBase kBase);

    public void postKnowledgeSessionCreate(StatefulKnowledgeSession session, String businessKey);
    public void postKnowledgeSessionCreate(StatelessKnowledgeSession session, String businessKey);

    public void preKnowledgeSessionRestore(Environment environment, 
                                       KnowledgeSessionConfiguration config, KnowledgeBase kBase);

    public void postKnowledgeSessionRestore(StatefulKnowledgeSession session, String businessKey);
    public void preSessionDispose(StatefulKnowledgeSession session, String businessKey);

    public void postSessionDispose(StatefulKnowledgeSession session, String businessKey);

    public void preWorkItemRegister(StatefulKnowledgeSession session, String businessKey,
                                                     KnowledgeBase kBase, WorkItemHandler handler);

    public void postWorkItemRegister(StatefulKnowledgeSession session, String businessKey,
                                                     KnowledgeBase kBase, WorkItemHandler handler);

}
Multi tenancy

• Multi tenancy is achieved by:
  – Separate process bundles registered with
    dedicated properties
  – Additional resolver that will understand
    tenant configuration
  –
• It could be as simple as using tenant id
  property to redirect to the right
  execution engine...
Still in evaluation phase...

• The work is still in evaluation stage so
  everything can change and hopefully if
  it does it's for the good
• Please submit your input, requirements,
  ideas
• There are some limitation currently that
  are being investigated and most of them
  have workarounds :)
Still in evaluation phase...

• The work is still in evaluation stage so
  everything can change and hopefully if
  it does it's for the good
• Please submit your input, requirements,
  ideas
• There are some limitation currently that
  are being investigated and most of them
  have workarounds :)
Thanks for your attention

         Questions? Comments?



     Email: mswiders@redhat.com
     IRC: chat.freenode.net#jbpm
              Test drive:
http://people.redhat.com/mswiders/jbpm-enterprise/
Drools&jBPM

       Drools&jBPM
"All Day Drop in Centre"
     room 105, Hynes

Mais conteúdo relacionado

Mais procurados

Curso de JBPM5
Curso de JBPM5Curso de JBPM5
Curso de JBPM5
Oscar V
 

Mais procurados (10)

Ad106 - XPages Just Keep Getting Better
Ad106 - XPages Just Keep Getting BetterAd106 - XPages Just Keep Getting Better
Ad106 - XPages Just Keep Getting Better
 
Symfony 2 under control
Symfony 2 under controlSymfony 2 under control
Symfony 2 under control
 
Jmeter
JmeterJmeter
Jmeter
 
Jenkins/Jmeter Configuration - Colombo Performance Test Meetup - 2016 April
Jenkins/Jmeter Configuration - Colombo Performance Test Meetup - 2016 AprilJenkins/Jmeter Configuration - Colombo Performance Test Meetup - 2016 April
Jenkins/Jmeter Configuration - Colombo Performance Test Meetup - 2016 April
 
Jbpm online training
Jbpm online trainingJbpm online training
Jbpm online training
 
Maven in Java EE project
Maven in Java EE projectMaven in Java EE project
Maven in Java EE project
 
Curso de JBPM5
Curso de JBPM5Curso de JBPM5
Curso de JBPM5
 
Semantic versioning implementation variations
Semantic versioning implementation variationsSemantic versioning implementation variations
Semantic versioning implementation variations
 
MyFaces CODI and JBoss Seam3 become Apache DeltaSpike
MyFaces CODI and JBoss Seam3 become Apache DeltaSpikeMyFaces CODI and JBoss Seam3 become Apache DeltaSpike
MyFaces CODI and JBoss Seam3 become Apache DeltaSpike
 
Extending ZF & Extending With ZF
Extending ZF & Extending With ZFExtending ZF & Extending With ZF
Extending ZF & Extending With ZF
 

Destaque

Parent spelling workshop
Parent spelling workshopParent spelling workshop
Parent spelling workshop
agaulton
 
Model model pengajaran
Model model pengajaranModel model pengajaran
Model model pengajaran
nik_ruslawati
 

Destaque (18)

Melform Foodservice Catalogue
Melform Foodservice CatalogueMelform Foodservice Catalogue
Melform Foodservice Catalogue
 
Narrant cançons (1)
Narrant cançons (1)Narrant cançons (1)
Narrant cançons (1)
 
Melform Catalogo Vassoi
Melform Catalogo VassoiMelform Catalogo Vassoi
Melform Catalogo Vassoi
 
Descripcions 1r
Descripcions 1rDescripcions 1r
Descripcions 1r
 
Stp1
Stp1Stp1
Stp1
 
Melform Catalogo Foodservice
Melform Catalogo FoodserviceMelform Catalogo Foodservice
Melform Catalogo Foodservice
 
9xm fcc
9xm fcc9xm fcc
9xm fcc
 
Tablas latex
Tablas latexTablas latex
Tablas latex
 
Parent spelling workshop
Parent spelling workshopParent spelling workshop
Parent spelling workshop
 
Esai Novel - Layar Terkembang
Esai Novel - Layar TerkembangEsai Novel - Layar Terkembang
Esai Novel - Layar Terkembang
 
Melform Catalogo Biomedicale
Melform Catalogo BiomedicaleMelform Catalogo Biomedicale
Melform Catalogo Biomedicale
 
gamfic.tv simple presentation
gamfic.tv simple presentationgamfic.tv simple presentation
gamfic.tv simple presentation
 
Cerpen-Hal Tak Terduga
Cerpen-Hal Tak TerdugaCerpen-Hal Tak Terduga
Cerpen-Hal Tak Terduga
 
Reaksi Inti (Makalah Fisika)
Reaksi Inti (Makalah Fisika)Reaksi Inti (Makalah Fisika)
Reaksi Inti (Makalah Fisika)
 
Totdescrivint
TotdescrivintTotdescrivint
Totdescrivint
 
Knowledge drivenmicroservices
Knowledge drivenmicroservicesKnowledge drivenmicroservices
Knowledge drivenmicroservices
 
I si fos cert (textospredictius)
I si fos cert (textospredictius)I si fos cert (textospredictius)
I si fos cert (textospredictius)
 
Model model pengajaran
Model model pengajaranModel model pengajaran
Model model pengajaran
 

Semelhante a jBPM&Drools go Enterprise - JUDCon2012

WSO2 Test Automation Framework : Approach and Adoption
WSO2 Test Automation Framework : Approach and AdoptionWSO2 Test Automation Framework : Approach and Adoption
WSO2 Test Automation Framework : Approach and Adoption
WSO2
 
Jan Egil Ring - Get started with windows power shell desired state configuration
Jan Egil Ring - Get started with windows power shell desired state configurationJan Egil Ring - Get started with windows power shell desired state configuration
Jan Egil Ring - Get started with windows power shell desired state configuration
Nordic Infrastructure Conference
 
Fredrik knalstad 10 ways to trigger orchestrator runbooks in the it jungle
Fredrik knalstad   10 ways to trigger orchestrator runbooks in the it jungleFredrik knalstad   10 ways to trigger orchestrator runbooks in the it jungle
Fredrik knalstad 10 ways to trigger orchestrator runbooks in the it jungle
Per Riis
 
Fredrik Knalstad - 10 ways to trigger orchestrator runbooks in the it jungle
Fredrik Knalstad - 10 ways to trigger orchestrator runbooks in the it jungleFredrik Knalstad - 10 ways to trigger orchestrator runbooks in the it jungle
Fredrik Knalstad - 10 ways to trigger orchestrator runbooks in the it jungle
Nordic Infrastructure Conference
 

Semelhante a jBPM&Drools go Enterprise - JUDCon2012 (20)

Azure Functions - Introduction
Azure Functions - IntroductionAzure Functions - Introduction
Azure Functions - Introduction
 
Automate workflows with leading open-source BPM
Automate workflows with leading open-source BPMAutomate workflows with leading open-source BPM
Automate workflows with leading open-source BPM
 
Windows 2012 R2 Multi Server Management
Windows 2012 R2 Multi Server ManagementWindows 2012 R2 Multi Server Management
Windows 2012 R2 Multi Server Management
 
JBPM5 Community Training Course - Module #1 Introduction
JBPM5 Community Training Course - Module #1 IntroductionJBPM5 Community Training Course - Module #1 Introduction
JBPM5 Community Training Course - Module #1 Introduction
 
WSO2 Test Automation Framework : Approach and Adoption
WSO2 Test Automation Framework : Approach and AdoptionWSO2 Test Automation Framework : Approach and Adoption
WSO2 Test Automation Framework : Approach and Adoption
 
КОСТЯНТИН НАТАЛУХА «Setup and run automated test framework for Android applic...
КОСТЯНТИН НАТАЛУХА «Setup and run automated test framework for Android applic...КОСТЯНТИН НАТАЛУХА «Setup and run automated test framework for Android applic...
КОСТЯНТИН НАТАЛУХА «Setup and run automated test framework for Android applic...
 
Jan Egil Ring - Get started with windows power shell desired state configuration
Jan Egil Ring - Get started with windows power shell desired state configurationJan Egil Ring - Get started with windows power shell desired state configuration
Jan Egil Ring - Get started with windows power shell desired state configuration
 
Automation using ibm rft
Automation using ibm rftAutomation using ibm rft
Automation using ibm rft
 
OSGi Community Event 2010 - OSGi Technical Update
OSGi Community Event 2010 - OSGi Technical UpdateOSGi Community Event 2010 - OSGi Technical Update
OSGi Community Event 2010 - OSGi Technical Update
 
OSGi Community Event 2010 - App Store for the Connected Home Services
OSGi Community Event 2010 - App Store for the Connected Home ServicesOSGi Community Event 2010 - App Store for the Connected Home Services
OSGi Community Event 2010 - App Store for the Connected Home Services
 
JBoss BPM Suite 6 Tech labs
JBoss BPM Suite 6 Tech labsJBoss BPM Suite 6 Tech labs
JBoss BPM Suite 6 Tech labs
 
Practical advice on deployment and management of enterprise workloads
Practical advice on deployment and management of enterprise workloadsPractical advice on deployment and management of enterprise workloads
Practical advice on deployment and management of enterprise workloads
 
Pragmatic Monolith-First, easy to decompose, clean architecture
Pragmatic Monolith-First, easy to decompose, clean architecturePragmatic Monolith-First, easy to decompose, clean architecture
Pragmatic Monolith-First, easy to decompose, clean architecture
 
Fredrik knalstad 10 ways to trigger orchestrator runbooks in the it jungle
Fredrik knalstad   10 ways to trigger orchestrator runbooks in the it jungleFredrik knalstad   10 ways to trigger orchestrator runbooks in the it jungle
Fredrik knalstad 10 ways to trigger orchestrator runbooks in the it jungle
 
10 ways to trigger runbooks from Orchestrator
10 ways to trigger runbooks from Orchestrator10 ways to trigger runbooks from Orchestrator
10 ways to trigger runbooks from Orchestrator
 
Fredrik Knalstad - 10 ways to trigger orchestrator runbooks in the it jungle
Fredrik Knalstad - 10 ways to trigger orchestrator runbooks in the it jungleFredrik Knalstad - 10 ways to trigger orchestrator runbooks in the it jungle
Fredrik Knalstad - 10 ways to trigger orchestrator runbooks in the it jungle
 
Azure functions
Azure functionsAzure functions
Azure functions
 
InterConnect 2016 Java EE 7 Overview (PEJ-5296)
InterConnect 2016 Java EE 7 Overview (PEJ-5296)InterConnect 2016 Java EE 7 Overview (PEJ-5296)
InterConnect 2016 Java EE 7 Overview (PEJ-5296)
 
Deep Dive Azure Functions - Global Azure Bootcamp 2019
Deep Dive Azure Functions - Global Azure Bootcamp 2019Deep Dive Azure Functions - Global Azure Bootcamp 2019
Deep Dive Azure Functions - Global Azure Bootcamp 2019
 
jBPM Connector
jBPM ConnectorjBPM Connector
jBPM Connector
 

Último

Último (20)

Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 

jBPM&Drools go Enterprise - JUDCon2012