[jbossseam-issues] [JBoss JIRA] Commented: (JBSEAM-3294) Exception Handling not working under certain conditions
Pete Muir (JIRA)
jira-events at lists.jboss.org
Sun Aug 24 13:58:38 EDT 2008
[ https://jira.jboss.org/jira/browse/JBSEAM-3294?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12426349#action_12426349 ]
Pete Muir commented on JBSEAM-3294:
-----------------------------------
Hi Maximiliano,
I really need an example so I can debug the problem myself (not that I don't trust your debugging, but without a way to reproduce, it's very hard to tell if the bug is fixed).
> Exception Handling not working under certain conditions
> -------------------------------------------------------
>
> Key: JBSEAM-3294
> URL: https://jira.jboss.org/jira/browse/JBSEAM-3294
> Project: Seam
> Issue Type: Bug
> Affects Versions: 2.0.3.CR1
> Environment: Kubuntu, Tomcat 6.0.14, Eclipse Europa 3.3.2
> Reporter: Maximiliano Carrizo
> Priority: Minor
> Original Estimate: 1 day
> Remaining Estimate: 1 day
>
> I have the following action method:
> public String confirm() {
> log.info("---------> Saving Selected Role");
> securityServices.confirmRole(roleOperationType, selectedRole);
> events.raiseTransactionSuccessEvent(Constant.REFRESH_ROLE_LIST);
> return Constant.SUCCESS;
> }
> This pages config ( exception trapping only ):
> <!-- Exceptions Trapping -->
> <exception class="javax.persistence.OptimisticLockException">
> <end-conversation />
> <redirect view-id="/pages/publicArea/errors/genericError.xhtml">
> <message>#{messages['dirty_data_error']}</message>
> </redirect>
> </exception>
> <exception class="org.jboss.seam.security.AuthorizationException">
> <end-conversation />
> <redirect view-id="/pages/publicArea/errors/genericError.xhtml">
> <message>#{messages['no_permission_granted']}</message>
> </redirect>
> </exception>
>
> <exception class="org.hibernate.StaleObjectStateException">
> <end-conversation />
> <redirect view-id="/pages/publicArea/errors/genericError.xhtml">
> <message>#{messages['record_locked']}</message>
> </redirect>
> </exception>
> <exception class="java.lang.Throwable">
> <end-conversation />
> <redirect view-id="/pages/publicArea/errors/genericError.xhtml">
> <message>#{messages['unknown_error']} #{org.jboss.seam.handledException.getMessage()}</message>
> </redirect>
> </exception>
> Im testing exception handling functionality of my app. When the service of my action:
> securityServices.confirmRole(roleOperationType, selectedRole);
> throws this exception:
> javax.faces.el.EvaluationException: javax.persistence.PersistenceException: org.hibernate.PropertyValueException: not-null property references a null or transient value: com.teracode.seamapp.security.model.Role.home
> at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:91)
> In some cases app works fine ( closes current long-running conversation, opens error page and shows error message ) and in other cases leaves conversation open and dont show error message. I do always the same testing steps over and over .... and sometimes fails and sometimes not. I couldnt find an error criteria, but, when I change parameter concurrent-request-timeout on components.xml, setting a big value, something funny happens.
> Imagine I set concurrent-request-timeout on ten seconds. If I execute action and app answers me instantly, app works fine. If action lasts for ten seconds, app fails.
> I thought on sending you an example, but I've tested app at my partners machines, and ...... had the same behavior.
> Best regards
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the seam-issues
mailing list