
|
If you were logged in you would be able to see more operations.
|
|
|
|
File Attachments:
|
|
|
Environment:
|
ALL
|
|
| Resolution Date: |
27/Jan/06 12:37 PM
|
|
There are 4 methods on the org.apache.beehive.controls.spi.svc.Interceptorinterface.
For a control operation, preInvoke/postInvoke are called before and after the operation, respectively. The postInvoke callback contains the exception that the operation threw. For preEvent/postEvent, which is called before and after control event dispatching, however, there is no exception information passed to the postEvent callback. This looks inconsistent to me.
Imagine that you need to enforce J2EE transaction behaviors using these interceptors (i.e. rollback a transaction in case of a system exception), you will need to know what exception has been generated as the result of invoking the operation or event callback. You could do this for your control operations, but not event callbacks, since the exception caught during event callback isn't passsed to the interceptor.
In my humble opinion, I think we should make preInvoke/postinvoke and preEvent/postEvent API's symmetric.
|
|
Description
|
There are 4 methods on the org.apache.beehive.controls.spi.svc.Interceptorinterface.
For a control operation, preInvoke/postInvoke are called before and after the operation, respectively. The postInvoke callback contains the exception that the operation threw. For preEvent/postEvent, which is called before and after control event dispatching, however, there is no exception information passed to the postEvent callback. This looks inconsistent to me.
Imagine that you need to enforce J2EE transaction behaviors using these interceptors (i.e. rollback a transaction in case of a system exception), you will need to know what exception has been generated as the result of invoking the operation or event callback. You could do this for your control operations, but not event callbacks, since the exception caught during event callback isn't passsed to the interceptor.
In my humble opinion, I think we should make preInvoke/postinvoke and preEvent/postEvent API's symmetric. |
Show » |
|
org.apache.beehive.controls.spi.svc.Interceptor