Chapter 2. Writing and Executing Rules

The best way to learn something new is by trying it out. For this reason, in this chapter, we are going to cut to the chase to write and execute our first rules. We will also cover the most important points about the rule language and how to effectively write rules that mean something to your domain. This chapter will use the eShop model introduced in the previous chapter to demonstrate a set of scenarios where rules can be applied.

Before we start coding, in the first half of this chapter, you will learn how to set up all the standard tools required to work with Drools and the examples provided with this book. We will be creating a project from scratch, therefore, you can use this chapter as a reference to ...

Get Mastering JBoss Drools 6 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.