Uploaded image for project: 'Seam Persistence'
  1. Seam Persistence
  2. SEAMPERSIST-49

Seam Persistence Fails in clustered environment

    Details

    • Type: Bug
    • Status: Open (View Workflow)
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 3.0.0.Final
    • Fix Version/s: Future
    • Labels:
    • Environment:

      Tomcat 7.0.14 with memchached session manager, Myfaces 2.0.5, Weld 1.1.2-SNAPSHOT, Persistence 3.0.0.Final, Faces 3.0.1.Final, XML Config 3.0.0.Final, Hibernate 3.6.4

    • Workaround:
      Workaround Exists
    • Workaround Description:
      Hide
      diff --git a/impl/src/main/java/org/jboss/seam/transaction/TransactionExtension.java b/impl/src/main/java/org/jboss/seam/transaction/TransactionExtension.java
      index 688b674..67a72f1 100644
      --- a/impl/src/main/java/org/jboss/seam/transaction/TransactionExtension.java
      +++ b/impl/src/main/java/org/jboss/seam/transaction/TransactionExtension.java
      @@ -49,7 +49,7 @@ import org.jboss.seam.solder.reflection.annotated.AnnotatedTypeBuilder;
        *
        * @author Stuart Douglas
        */
      -public class TransactionExtension implements Extension {
      +public class TransactionExtension implements Extension, java.io.Serializable {
           private static final Logger log = Logger.getLogger(TransactionExtension.class);
       
           private final Set<Throwable> exceptions = new HashSet<Throwable>();
      
      Show
      diff --git a/impl/src/main/java/org/jboss/seam/transaction/TransactionExtension.java b/impl/src/main/java/org/jboss/seam/transaction/TransactionExtension.java index 688b674..67a72f1 100644 --- a/impl/src/main/java/org/jboss/seam/transaction/TransactionExtension.java +++ b/impl/src/main/java/org/jboss/seam/transaction/TransactionExtension.java @@ -49,7 +49,7 @@ import org.jboss.seam.solder.reflection.annotated.AnnotatedTypeBuilder; * * @author Stuart Douglas */ - public class TransactionExtension implements Extension { + public class TransactionExtension implements Extension, java.io.Serializable { private static final Logger log = Logger.getLogger(TransactionExtension.class); private final Set<Throwable> exceptions = new HashSet<Throwable>();

      Description

      Session replication fails when using Seam Persistence.
      Following exceptions occurs:

      WARNING: Cannot serialize session attribute org.jboss.weld.context.http.HttpSessionContext#org.jboss.weld.bean-flat-ManagedBean-TestController[@javax.enterprise.context.SessionScoped()@javax.inject.Named(value=)]

      {TestController.userDao[@javax.inject.Inject()];TestController.newUser[@org.jboss.seam.transaction.Transactional(value=REQUIRED)@org.jboss.seam.transaction.TransactionalInterceptorBinding()]();TestController.post[@javax.annotation.PostConstruct()]();}

      for session 488BDFEE2194D758C7B76C6E60E6BD5E-n2
      java.io.NotSerializableException: org.jboss.seam.transaction.TransactionExtension
      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1164)
      at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1518)
      at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1483)
      at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400)
      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158)
      at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1518)
      at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1483)
      at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400)
      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158)
      at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:330)
      at java.util.ArrayList.writeObject(ArrayList.java:570)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:945)
      at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1469)
      at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400)
      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158)
      at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1518)
      at java.io.ObjectOutputStream.defaultWriteObject(ObjectOutputStream.java:422)
      at java.util.Collections$SynchronizedCollection.writeObject(Collections.java:1602)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:945)
      at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1469)
      at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400)
      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158)
      at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1518)
      at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1483)
      at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400)
      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158)
      at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1518)
      at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1483)
      at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1400)
      at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1158)
      at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:330)
      at de.javakaffee.web.msm.JavaSerializationTranscoder.writeAttributes(JavaSerializationTranscoder.java:143)
      at de.javakaffee.web.msm.JavaSerializationTranscoder.serializeAttributes(JavaSerializationTranscoder.java:106)
      at de.javakaffee.web.msm.TranscoderService.serializeAttributes(TranscoderService.java:138)
      at de.javakaffee.web.msm.BackupSessionTask.serializeAttributes(BackupSessionTask.java:177)
      at de.javakaffee.web.msm.BackupSessionTask.call(BackupSessionTask.java:111)
      at de.javakaffee.web.msm.BackupSessionTask.call(BackupSessionTask.java:48)
      at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
      at java.util.concurrent.FutureTask.run(FutureTask.java:138)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      at java.lang.Thread.run(Thread.java:662)

      Why is it stored in the session? Can it be made serializable?

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  Unassigned
                  Reporter:
                  tandraschko Thomas Andraschko
                • Votes:
                  1 Vote for this issue
                  Watchers:
                  4 Start watching this issue

                  Dates

                  • Created:
                    Updated: