Skip to content
UdemyTeaching & AcademicsPaid courseBeginner levelCertificate

Master Drools Programming - Learn How to Write Drools Rules (Udemy.com)

Learn how to run and write rules for Apache Drools Rule Engine and how to work with spredsheet decision tables

Created by: Juhan Aasaru

Last updated March 2025

icon
What you will learn

  • Program rules in Drools 7 domain specific language
  • Learn Drools language constructs like insert, modify, exists, forall, insertLogical, salience, agenda-group etc
  • Create spreadsheet decision tables and spreadsheet templates
  • What is Complex Event Processing and how Drools handles it
  • How to use rule templates (DRT or Freemarker) and run dynamically defined DRL
  • Understand different Drools running modes (active/passive, cloud/stream, sequential)
  • How Drools works internally and what to keep in mind for writing faster performing rules

How it compares

Against the other 503 rated Udemy courses in Teaching & Academics on CourseDuck:

  • Rating4.5 out of 5higher than 42% of them
  • Reviews2,075#82 of 504 by number of reviews
  • Length7.9 hourslonger than 79% of them
  • Last updatedMarch 2025more recently than 64% of them

icon
Course Description

We learn Apache Drools DSL (Drools programming language) and go over the most common DSL constructs. We move in small steps and gradually introduce new concepts, so it is easier to follow even for a beginner.

This way we cover the most common Drools topics like:

  • what is a rule engine

  • what is the difference between a method and a rule

  • why one would use a rule engine instead of writing regular Java code

  • understanding of the when/then clauses

  • understanding in which order the rules fire and when the order is not known

  • how to control the execution using activation groups, agenda groups and salience

  • declaring variables in DRL

  • difference between stateless and stateful sessions

  • inserting facts and modifying existing objects in the session

  • cross products (similar to SQL join)

  • exists, forall and collect

  • using spreadsheet decision tables to create Drools rules

  • using templates for creating rules and feeding data into them from spreadsheets and other tabular data sources

  • complex event processing (CEP) in Drools

    • difference between fact and event

    • declaring facts and events in Java and inside DRL code

    • different rule execution modes (active/passive, cloud/stream, sequential)

    • time and length-based sliding windows

    • entry-points

    • global variables

    • timers

  • how Apache Drools' internal algorithm Phreak works

This course comes with two Java projects containing all the code we worked with during the course. The first project includes all the code examples in traditional Drools syntax and a second copy of all the rules in the new Drools OOPath syntax (introduced by Drools 8). The first project has been upgraded to run using Drools 10.

You are encouraged to check out and run the code yourself to better understand and experiment with changes.

There are instructions on running the code in IntelliJ, Eclipse, and VS Code.

After completing this course, you will better understand which kinds of problems could be solved with Drools and how to write the most common business rules in Drools DSL.


icon
Udemy Discount

The discount is applied through our link. Open the course from here and Udemy's current promotional price is applied at checkout on most courses, no code to type.

Some courses are excluded from Udemy's promotions. If the price does not drop, clear your browser cookies and use the button again.

icon
Instructor Details

Juhan Aasaru

Since 2005, I have been working as a Java developer, solution architect, and CTO. I have created several in-class courses and two courses on Udemy. I'm passionate about teaching new technologies and explaining them clearly and understandably.

I have helped many junior developers secure their first job, and recently, I have focused on equipping beginners with the skills necessary to be hired as junior Java developers.

icon
More Teaching & Academics courses

$11.99

$12.99

$10.99

$10.99

$69.99

$89.99

icon
Reviews

4.5

2,075 ratings on Udemy

Select a bar to show only those reviews.Select the bar again to show every rating.

By Jose Pablo Guerra Betancourt on 7/2/2026

This course provides a clear and practical explanation of how Drools works behind the scenes. I especially enjoyed the sections about the Rete Network, Phreak algorithm, Working Memory, Agenda, and rule execution flow. The examples based on passports and visa applications made complex concepts easy to understand. The performance tips and best practices for writing efficient rules were particularly valuable. I would recommend this course to anyone who wants to move beyond basic Drools usage and understand how the rule engine really works.

By CLAUDIU EDUARD RADU on 2/22/2025

A good course, hands on focused. Very good for experienced people in other technologies, a little bit difficult if you are a beginner in general. I appreciated the concrete examples, easy to understand the applicability. What it would be nice to be improved: - The projects are already built and you can start working with them. On the other side it would be nice if it would be a section when to show how to setup a project from scratch (like what dependencies to add in the project, the recommended versions, the proper setting of the project and so on) - Including the projects used could be maybe presented first as "business requests" to be fullfiled (not big thing in the end, you figure out during the lessons) - Maybe for some practical examples (the ones more complex) would be nice to be an introductory part to explain first the concept. - The course looks like a combination of old different courses mixed together and for me the order was strange. First it had the practical things and at the end the presentation of the generic mechanisms. Maybe a refactorization of this could help. In the end, for me looked like a good course with a lot of valuable informations.

By Anup Jani on 1/21/2025

simple explanation. humble gestures. illustrative presentation. Have prepared well. Notes are systematic but way bit more complicated approach to explaining things. Audience gets tired half way, & gets impatient. It is 8 hours but I am full time constantly on it for 3 days & still am half way only. Quite complex examples. Explained well, organized well but example chose was pretty complex for a beginner. I understand DROOLS is complex. Great teacher. Thank you.

By Pranamshankar Nagasrikantan on 10/13/2024

As a Java programmer that's completely new to Drools, this course (that actually combines beginner + intermediate Drools) was a great introduction to learning about Drools. Juhan walks through various concepts in a very easy to use manner. I loved the way the code is segmented into different steps that gradually increase complexity / talk about different concepts. You can see how much of effort he has put into making this simple and easy to learn. Deep appreciation to Juhan for putting out this course to learn Drools technology in a short time!

By Anonymized User on 8/20/2023

Thank you for the course. I has learnt logs of different and new. I am newer to use the drools using the Business Central Workbench and I never programing to create the drools. So I need to learn how to use the drools in the kie server that created by the Java as your course for our service to call the REST web service to get the rule info from the created Url in the kie server. Hopefully, you understood my question. when I created the drool decision with the data object from the business central workbench. built and deploy the drl to kie server for the Rest API to calling. Thank you very much again. This is Paul Maeng paul.maeng@ingramcontent.com

By Bhaskar Vakkalanka on 11/4/2021

Material is good and tutor is also good in knowledge & explanation but it was already built package. If it could be explained with a small initial example on how to do it by explaining one by creating drl, java and repository, updates to xmls, including required libraries on drools like a project in Java, I mean building an example from scratch would have helped much. then this material helps on concepts and experimentation purposes on top of example. Anyway, thank you.

By Anonymized User on 7/16/2021

In summary: Clarifies the separation of the Java application and Drools Rules; Shows how to use Drools in a Java application (initiate a session, fireAllRules, dispose session); Show how to get the results back in the Java app (ksession.getObjects()) Shows the importance and advantage of preparing a dataset of tests (scenarios) with expected results; Clarifies Stateless vs Stateful; Clarifies the usage of activation-group and agenda-group, with resilience; Demonstrate how to debug Drools with EventListeners (DebugAgendaEventListener, RuleRuntimeEventListener); Clarifies the usage of insert vs insertLogical; Importance of defining the object equality (equals and hash); Usage of $ and this; modify vs new fact; Usage of the 'not' keyword; How to reduce the number of rules considering only the positive matches and insertLogical; Show usage of Exists and ForAll; My critics: Best available video training (some other good tutorials exists, but not as video). Really gives a good idea of the usage of Drools with a Java application. No stress put on the design and authoring of the rules ahead of time. It's a try&error training, showing the progression of the authoring using Java and MVEL coding (vs diagrams). Some concern with the logic : Issue Visa and then Invalidate Visa Did not cover passive mode vs active mode From section 7, and the usage of 'not' keyword, the logic is harder to follow. Hard to understand the right meaning of Exists and Forall. Refer to Rules Language Reference.

By Nathan Zugsay on 11/22/2020

I enjoyed this course. I didn't have any experience with Drools but now have a better understanding.

By Sree Panchajanyam D on 11/19/2020

Content is good. Instructor is knowledgable.
Course could be more engaging and enthusiastic.
Listened at 1.75x speed so as to stay engaged.

By Ajit Gadade on 11/10/2020

Learning with real time example gives transparent learning.

By Meera Thacker on 11/1/2020

great learning

By Armand Welsh on 10/27/2020

I wouldn't rate it poorly, but the way to expressing the concepts of the drools engine are more complicated than the actual technical knowledge tree description given in the docs.

Showing 12 of 108 reviews

icon
Quality Score

No CourseDuck member has rated this course yet. Taken it? Give each part a thumbs up or down.

Content Quality
/
Video Quality
/
Qualified Instructor
/
Course Pace
/
Course Depth & Coverage
/

Overall Score : 90 / 100