-
Bug
-
Resolution: Done
-
Major
-
4.3.0.GA_CP02_FP01
-
None
-
Release Notes
I am testing with Seam 2.0.2.FP and EAP 4.3_CP03 (Due to a clustering bug) mod_jk 1.2.27 and JDK 1.5_15. The clustering bug causes a "NoSuchEJBException: Could not find stateful bean: 4sv1g5o-jqzric-fhyhsk09-1-fhyhunhd-9" as seen in https://jira.jboss.org/jira/browse/JBSEAM-3172 but is worked around via the jvm argument:
-Djboss.web.clustered.session.notification.policy=org.jboss.web.tomcat.service.session.notification.IgnoreUndeployLegacyClusteredSessionNotificationPolicy
which is available in EAP 4.3_CP03.
So with the booking example, I create a user, book a hotel, proceed, but before I click 'Confirm' I kill the one node, wait for it to stop, the click 'Confirm' and I get:
+++++++++++++++++++++++++++++++++++++++++++
14:32:19,133 INFO [HotelBookingAction] Attempting to book hotel: Hotel(Marriot Downtown,55 Fourth Street,San Francisco,94103) from user: User(asdf)
...
14:32:19,179 ERROR [application] javax.ejb.EJBTransactionRolledbackException: org.hibernate.PropertyValueException: not-null property references a null or transient value: org.jboss.seam.example.booking.Booking.user
javax.faces.el.EvaluationException: javax.ejb.EJBTransactionRolledbackException: org.hibernate.PropertyValueException: not-null property references a null or transient value: org.jboss.seam.example.booking.Booking.user
...
Caused by: javax.persistence.PersistenceException: org.hibernate.PropertyValueException: not-null property references a null or transient value: org.jboss.seam.example.booking.Booking.user
at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:629)
at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:218)
at org.jboss.ejb3.entity.ExtendedEntityManager.persist(ExtendedEntityManager.java:101)
at org.jboss.seam.persistence.EntityManagerProxy.persist(EntityManagerProxy.java:135)
at org.jboss.seam.example.booking.HotelBookingAction.confirm(HotelBookingAction.java:100)
+++++++++++++++++++++++++++++++++++++++++++
What is not clear is why the null property exception is thrown when both the user and hotel objects have values as shown from the added logging statements.
Also seen intermittendly is:
+++++++++++++++++++++++++++++++++++++++++++
11:22:43,059 ERROR [JBossCacheService] externalizeSession(): exception occurred externalizing session SessionBasedClusteredSession[id: 6C114286CFF2CBD46D5526518BF76257.node2 lastAccessedTime: 1228753362864 version: 35 lastOutdated: 0]
java.io.NotSerializableException: java.util.ArrayList$SubList
at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1173)
at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:343)
at org.jboss.seam.jsf.ListDataModel.writeObject(ListDataModel.java:23)
at sun.reflect.GeneratedMethodAccessor173.invoke(Unknown Source)
+++++++++++++++++++++++++++++++++++++++++++
Which is easily fixed by wrapping the subList in a new ArrayList as indicated in https://jira.jboss.org/jira/browse/JBSEAM-3176