This is the forth and final part in the series started around possible Red Hat JBoss Business Rules Management System (BRMS) deployment architectures.
Previously we covered in three separate articles the various deployment architectures and rule authoring tasks you have to deploy a rules and/or events project in your enterprise.
In this article we move forward to the various aspects around rule deployments with a focus on the choices available to a rule administrator in delivering the rules to her enterprise applications.
|Rule artifacts found in artifact repository.|
Deploying With KieScanner
After the rule administrator builds a project it is available in the Artifact repository. Select Open to get the contents of a pom.xml file. The project is also downloadable as a jar file that can be included in your deployable artifact (e.g. EAR, WAR).
Once the project JAR is available in the Artifact repository the KieScanner will pick it up on the configured interval and load the new version into the KieContainer.
Any new KieSessions created in the application will be created against the latest version.
If you would rather not use the KieScanner or your rules do not change often enough to require a KieScanner then you can still embedded the rule project within your application.
|Embedding rules artifact into application.|
Once the project is built its available for download from the Artifact repository page in JBoss BRMS Business Central workbench.
This can be downloaded manually and included into another version control repository or can be accessed through an URL and included in your application:
As an example based on our figures included in this article, our project artifact could be found here:
|Rule administrator defines a realtime decision server
by putting a rule project into a container.
In this situation the rule project JAR is included in your application deployable (e.g. WAR/EAR) as any other JAR file would.
Deploying Realtime Decision Server
The final option available to a rule administrator has been included in JBoss BRMS 6.1, an out-of-the-box rule decision server.
This realtime decision server is deployed by default with JBoss BRMS, but can be deployed to any other web container since it’s a WAR.
|Realtime decision server deployments.|
Rules can then be instantiated and executed through REST, JMS, or Java interfaces. The realtime decision server manages containers that can run independently of each other. A rule administrator can create a container and select a rule project that will run in that container.
Once the container is started applications can access them through the container endpoint, for example:
The container then exposes all the functionality needed by an application through its REST interface as detailed in the documentation.
If you want to head back and catch up on the previous articles in this series:
|Looking to Automate your business?|
This concludes this series where we examined Red Hat JBoss BRMS design time architectures for rules and events, with thanks to John Hurlocker.
(Article guest authored together with John Hurlocker, Senior Middleware Consultant at Red Hat in North America)