Free Sample
+ Collection

Drools Developer’s Cookbook

Lucas Amador

Are you a Drools developer seeking self-improvement? If so, this cookbook could quickly enhance and broaden your skills with a host of easy-to-follow recipes on the advanced implementation of this flexible business rules engine.
RRP $26.99
RRP $44.99
Print + eBook

Want this title & more?

$12.99 p/month

Subscribe to PacktLib

Enjoy full and instant access to over 2000 books and videos – you’ll find everything you need to stay ahead of the curve and make sure you can always get the job done.

Book Details

ISBN 139781849511964
Paperback310 pages

About This Book

  • Master the newest Drools Expert, Fusion, Guvnor, Planner and jBPM5 features
  • Integrate Drools by using popular Java Frameworks
  • Part of Packt’s Cookbook series: each recipe is independent and contains practical, step-by-step instructions to help you achieve your goal.

Who This Book Is For

This book is for Drools developers who want to improve their current working methods and discover new features to apply to their projects. Readers are expected to be familiar with the basics of the Drools platform as well as Java.

Table of Contents

Chapter 1: Expert: The Rule Engine
Declaring facts in the engine
Declaring facts using XML
Adding logging to view rules execution behavior
Using timer-based rules
Implementing calendar-based rules
Monitoring query changes in real time
Chapter 2: Expert: Behind the Rules
Marshalling knowledge sessions
Using persistence to store knowledge
How to discard duplicated facts on insertion
Using a custom classloader in a knowledge agent
Verifying the quality of rules with the Drools Verifier
Monitoring knowledge with JMX
Chapter 3: Guvnor: Centralized Knowledge Management
Creating our model definition with the Model Editor
Importing our model definition
Creating data enumerations
Using From Collect patterns in the Guided BRL Editor
Organizing knowledge with Working Sets
Creating rules templates
Creating knowledge snapshots
Chapter 4: Guvnor: Advanced Features and Configuration
Setting and creating a GUI language
Backing up your knowledge
Configuring MySQL as the default rules repository
Configuring the repository files location
Obtaining resources using the REST API
Chapter 5: Fusion: Processing Complex Events
How to declare our facts as events
Testing our application using a pseudo-clock
Entry-points: What they are and how we can use them
Setting up event stream processing mode
Sliding Windows
Event correlations using temporal operators
Chapter 6: Executing Drools Remotely
Knowledge services and multiple endpoints configuration
Deploying the Drools Server in JBoss AS 5.x
Creating commands with XStream marshallers
Using the REST interface to execute commands
Testing the SOAP interface with soapUI
Chapter 7: Integration: How to Connect Drools
Setting up Drools using Spring Framework
Configuring JPA to persist our knowledge with Spring Framework
Integrating Apache Camel in your project
Configuring Apache Camel with Spring Framework
Executing Drools commands from a JMS queue
Chapter 8: Planner: Optimizing Your Automated Planning
Solving a resource assignment problem
Using a Simulated Annealing acceptor
Terminating the Solver
Creating a basic benchmarker
Chapter 9: jBPM5: Managing Business Processes
Creating a business process manually
Testing your business processes
Creating and executing human tasks
Monitoring process a activity and creating reports
Monitoring a business process with Drools Fusion

What You Will Learn

  • Use Drools Guvnor for rules authoring and configuration
  • Configure different ways to store your knowledge using Marshallers, and JPA with Spring
  • Understand how to add complex event processing capabilities to a project
  • Take full advantage of the remote rules execution using the Drools Server.
  • Integrate Drools with the Apache Camel Project using the Spring Framework
  • Monitor Drools knowledge bases and sessions using JMX.
  • Implement automated planning using Drools Planner
  • Migrate and learn new features included in jBPM5.

In Detail

JBoss Drools is an open source business rules engine that provides agility and flexibility to your business logic. Drools 5 has evolved to provide a unified and integrated platform for business rules, business processes, event processing and automated planning. With this book in hand you will be able to use any of these modules and their specific features quickly and with ease.

Drools Developer Cookbook will help you to apply the latest community features to your projects. You will learn about all the Drools modules - Guvnor, Fusion, Expert, and Planner - along with jBPM5 and integration capabilities. The straightforward recipes will help you to implement even more rules in your projects and take you to a new level with the Drools platform.

This book teaches you how to create a more robust business rules implementation, starting with tips on how to write business rules manually, or by using the newest Guvnor rule editors. You will learn how your rules can be integrated with another framework to create a full solution and discover how to use complex features such as event processing. The recipes cover all of the Drools modules and will help you to solve problems with planning, remote execution, and much more.


Read More