Author Login
Post Reply
Hi everyone,
I am having a problem with the following scenario:
- A page renders a grid with a number of links
- Clicking one of those links causes the page to re-render, but it breaks with the following exception:
ERROR com.test.CoreModule.SiteRequestExceptionHandler Render queue error in BeforeRenderTemplate[hf/Fund:select]: Failure reading parameter 'encoder' of component hf/Fund:select: It is not permitted to add duplicate elements to a BeanListModel
org.apache.tapestry5.internal.services.RenderQueueException: Render queue error in BeforeRenderTemplate[hf/Fund:select]: Failure reading parameter 'encoder' of component hf/Fund:select: It is not permitted to add duplicate elements to a BeanListModel [at classpath:com/test/pages/hf/Fund.tml, line 186]
at org.apache.tapestry5.internal.services.RenderQueueImpl.run(RenderQueueImpl.java:86)
at org.apache.tapestry5.internal.services.PageRenderQueueImpl.render(PageRenderQueueImpl.java:121)
at $PageRenderQueue_1273cc4eea2.render($PageRenderQueue_1273cc4eea2.java)
at $PageRenderQueue_1273cc4ee99.render($PageRenderQueue_1273cc4ee99.java)
at org.apache.tapestry5.internal.services.MarkupRendererTerminator.renderMarkup(MarkupRendererTerminator.java:37)
at org.apache.tapestry5.services.TapestryModule$27.renderMarkup(TapestryModule.java:1748)
...
- What caused this error was my bean, which threw it when a problem occurred sorting the primary keys, this is all fine so far.
- The trouble is it breaks before re-rendering the page in BeforeRenderTemplate, which means the page never gets a chance to recover / report the exception (i.e.: onException is never invoked)
So my question is what approach can I take to intercept *only these exceptions that don't make it to the page. I rely heavily on onException at the moment, so I don't want to stop using it if possible, the ideal would be to have a new way of intercepting and dealing with these cases, perhaps two distinct mechanisms:
1. For exceptions that don't reach the page / component - taken care of by some new system (sub-system A)
2. Exceptions that do reach the page - remains as is, handled by onException() handler (sub-system B)
Is this possible, any ideas?
Thanks,
Peter
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@(protected)
For additional commands, e-mail: users-help@(protected)