|
From: Christian B. <chr...@gm...> - 2008-08-14 12:51:26
|
I'm trying to integrate exception handling with Seam, a few issues: Resteasy doesn't implement the JAX RS exception handling nearest-type search: https://jira.jboss.org/jira/browse/RESTEASY-69 - so I can't write a generic ExceptionMapper<Exception> and delegate all of that to Seam. The second issue is that Resteasy swallows exceptions (and worse, it writes ugly logs): https://jira.jboss.org/jira/browse/RESTEASY-105 Seam has an ExceptionFilter, we need it to destroy contexts, end transactions, and so on. That filter will not run if dispatcher.invoke() does not throw an exception. I'm not sure how to best solve both issues. It's hard to implement a cleanup routine in Seam as a generic ExceptionMapper<Exception>, so I'd really like the regular ExceptionFilter to run. But that means that ExceptionMapper invocation has to occur outside of dispatcher.invoke(). Probably the best solution would be to implement ExceptionMapper handling in Resteasy as some kind of filter I could enable/disable/ extend. |