O'Reilly logo

Drools JBoss Rules 5.0 Developer's Guide by Michal Bali, Bogdan Brinzarea

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Validation using stateful session

Our implementation of validation service from Chapter 3, Validation, is working seamlessly, but it is doing more work than needed. The state of the session isn't kept, and so, all of the rules have to be processed every time. Imagine a web application where a user logs into his/her bank account and wants to do a couple of changes. Every change needs to leave the system in a consistent state. The validation must run as a part of every request. However, with the validation implementation that we have, all of the objects will have to be inserted into a new stateless knowledge session over and over again which is unnecessary. With a stateful session, we just need to insert all of the objects once and then simply update ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required