aspose file tools*
The moose likes Other Application Frameworks and the fly likes aop rules engine Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Frameworks » Other Application Frameworks
Bookmark "aop rules engine" Watch "aop rules engine" New topic
Author

aop rules engine

Joe Robles
Greenhorn

Joined: Jan 13, 2009
Posts: 11
Hi all,

I am new to rules engine world. I am exploring ways to implement exception handling in my application - when to throw an exception and what to do with different types of exceptions.

I want to explore if Spring aop can be used in creating a simple rules engine or is there a need to use third party rules engines like groovy/drools with spring aop?

I am sure many of you must have already used some of the approaches for this same purpose. Thus any pointers are highly appreciated.

Thanks in advance for your valuable time and input.
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14688
    
  16

I am exploring ways to implement exception handling in my application - when to throw an exception and what to do with different types of exceptions.

And you need aop for this ? What about basic try/catch blocks ?


[My Blog]
All roads lead to JavaRanch
Joe Robles
Greenhorn

Joined: Jan 13, 2009
Posts: 11
The application already has non-aop based exception handling framework in place. Now there is a need to refactor it and thus exploring the usage of aop including its usage in try/catch blocks and the other two needs mentioned in my original post.

Hope to know your input.

Thanks.
Joe Robles
Greenhorn

Joined: Jan 13, 2009
Posts: 11
Also is there a way to implement Spring aop based rules (instead of using third party rules engine) to decide at the facade layer as what to do with different types of exceptions thrown by the different layers of the system - whether to log them/rethrow etc.

Thanks.
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17257
    
    6

Christophe Verré wrote:
I am exploring ways to implement exception handling in my application - when to throw an exception and what to do with different types of exceptions.

And you need aop for this ? What about basic try/catch blocks ?


Actually using AOP as an exception handler/manager is a great solution. Usually there is a big debate on propogation of exceptions and how to handle them at different levels to the point of what does the user see displayed. An Exception handler at the AOP level can do all this in one place, with a simple method, and then all that tangled code that would have been in your app code is now removed, to make it even more maintainable, and dramatically decreasing your costs.

Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
Joe Robles
Greenhorn

Joined: Jan 13, 2009
Posts: 11
Hi

Thanks for the prompt reply.

Could you give pointers to the examples/articles/books for the following using Spring aop:

1) Avoiding try catch blocks
2) Spring aop based exception handlers
3) how to implement xml conifguration of rules as what to do with different types of exceptions - log/rethrow certain exceptions based on business requirements.

Thanks in advance.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: aop rules engine