File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes General Computing and the fly likes Rule Engine and Work Flow Engine Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » General Computing
Bookmark "Rule Engine and Work Flow Engine" Watch "Rule Engine and Work Flow Engine" New topic
Author

Rule Engine and Work Flow Engine

JavaBala Subramanian
Greenhorn

Joined: Sep 13, 2005
Posts: 1
Hi All,

Can anybody tell me "What is the difference between Rule Engine and Work Flow Engine".

My project is implementing JESS Rule engine. Now it has been found certain performance issues with it.

(Its sorta.. JESS related files are instantiated whenever one Shipment is created. If I create 10 shipments in a single shot then 10 times the same instantiation will take place which Eats up the memory)

Can anybody suggest rule engine better in performance than JESS; both under Open source and commercial Rule engines category. If this problem can be rectified without the replacement of rule engine thats also fine.

Please Guide me!

Thanks
Bala.
Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24184
    
  34

Originally posted by JavaBala Subramanian:

Can anybody tell me "What is the difference between Rule Engine and Work Flow Engine".


A workflow engine tracks business processes (often the routing of documents) via a flowchart. It sends email or otherwise notifies people about the status of the process.

A rule engine applies rules to data, and performs programmed responses to patterns in the data. A rule engine is more general than a workflow engine; a workflow engine is one of the many kinds of systems you can build with a rule engine.


My project is implementing JESS Rule engine. Now it has been found certain performance issues with it.

(Its sorta.. JESS related files are instantiated whenever one Shipment is created. If I create 10 shipments in a single shot then 10 times the same instantiation will take place which Eats up the memory)


Jess is actually one of the fastest rule engines available. Most of the time, performance problems in a Jess program are caused by writing inefficient rules. If you write a slow bubble sort in Java, you could say Java is slow, or you could instead change it into a fast Quicksort. Jess is the same way -- you can write very slow programs, and very fast ones.

Other times, it's not bad rules, but a bad application architecture. All rules engines depend on "temporal redundancy" for speed -- in other words, they're fastest if the rules and most of the data are constant over time. Don't clear the engine, reload the rules, and reload all the data for each Shipment you process. Try to take advantage of temporal redundancy by retaining the things that don't change over time. To use another analogy: a database wouldn't be very fast if before every query, you had to reload all the data from scratch.

You can tell us about your current system and I'll see what I can do to help you speed it up.


[Jess in Action][AskingGoodQuestions]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Rule Engine and Work Flow Engine