[JBoss Seam] - Benelux JBoss User Group: Rotterdam, 2nd of November : Seam
by pepite
Hi,
I am not sure this is the right place to mention it.
We will hold our second JBoss Benelux User Group meeting:
Date: Friday, 2nd November 2007
Time: Arrive 1700-1800, presentations start 1800, finish 2000-2100.
Location: Lunatech Research, Heemraadssingel 70,
3021 DD Rotterdam
The Netherlands
http://www.lunatech-research.com/contact/
The programme will begin with a presentation on Open Source SOA by Bruno Georges, Technical Development Manager, Enterprise Frameworks at JBoss. This will include an ESB Presentation and a demo based on jBPM for process flow orchestration.
In the second presentation, Peter Hilton and Nicolas Leroux, will describe
Lunatech's practical experience with JBoss Seam. We will talk about strengths and limitations of JBoss Seam 1.2.1.
Please reply by e-mail (nicolas at lunatech dot com) to let me know whether you will attend, and feel free
to forward the invitation to anyone you know who might like to attend.
Nicolas Leroux
Lunatech Research
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4097428#4097428
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4097428
18Â years, 8Â months
[JBoss Seam] - Re: RuntimeException using @Pattern
by vlaugier
Hello,
my experience
I have also meet the invalidStateException with a non required email field
The field is an email field with a @Email annotation in the entityBean and a s:validateAll in the form
If I submit the form with an invalid email pattern I receive a nice jsf error message as expected
if I submit the form without completing the email field, I receive the debug page and the invalidStateException.
| Caused by: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state
| at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1394)
| at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:135)
| at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:87)
| at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:175)
| ... 84 more
| Caused by: javax.persistence.PersistenceException: org.hibernate.validator.InvalidStateException: validation failed for: fr.helmet.portal.entity.Account
| at org.hibernate.ejb.AbstractEntityManagerImpl$1.beforeCompletion(AbstractEntityManagerImpl.java:527)
| at com.arjuna.ats.internal.jta.resources.arjunacore.SynchronizationImple.beforeCompletion(SynchronizationImple.java:114)
| at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.beforeCompletion(TwoPhaseCoordinator.java:247)
| at com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator.end(TwoPhaseCoordinator.java:86)
| at com.arjuna.ats.arjuna.AtomicAction.commit(AtomicAction.java:177)
| at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1382)
| ... 87 more
| Caused by: org.hibernate.validator.InvalidStateException: validation failed for: fr.helmet.portal.entity.Account
| at org.hibernate.validator.event.ValidateEventListener.validate(ValidateEventListener.java:143)
| at org.hibernate.validator.event.ValidateEventListener.onPreInsert(ValidateEventListener.java:167)
| at org.hibernate.action.EntityInsertAction.preInsert(EntityInsertAction.java:156)
| at org.hibernate.action.EntityInsertAction.execute(EntityInsertAction.java:49)
| at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:250)
| at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:234)
| at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:141)
| at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:298)
| at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:27)
| at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1000)
| at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:338)
| at org.hibernate.ejb.AbstractEntityManagerImpl$1.beforeCompletion(AbstractEntityManagerImpl.java:515)
| ... 92 more
| 11:17:58,324 ERROR [ExceptionFilter] exception root cause
| javax.faces.FacesException: #{accountManager.registerClient}: java.lang.RuntimeException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Can't commit because the transaction is in aborted state
| at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:107)
| at javax.faces.component.UICommand.broadcast(UICommand.java:383)
| at org.ajax4jsf.component.AjaxViewRoot.processEvents(AjaxViewRoot.java:186)
| at org.ajax4jsf.component.AjaxViewRoot.broadcastEvents(AjaxViewRoot.java:164)
| at org.ajax4jsf.component.AjaxViewRoot.processApplication(AjaxViewRoot.java:352)
| at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:97)
| at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)
| at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)
| at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChai
|
What I have done is tansform the attribute in a null attribute if it has been set to an empty string in the form. This is done before persisting :
| if (this.getAccount().getEmail().equalsIgnoreCase("")) this.getAccount().setEmail(null);
|
I still do not quite undertsand what is going on but at least it works
Cheers
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4097425#4097425
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4097425
18Â years, 8Â months