JSF 托管 bean 在 Tomcat 部署期间导致 java.io.NotSerializedException

发布于 2024-10-14 23:28:17 字数 27906 浏览 4 评论 0原文

在 Tomcat 7 上部署我的 web 应用程序时,我得到下面的控制台输出。重启服务器两三次后,一切正常。

部分的 RMI 连接(这在这里不重要?)

我正在使用 JSF、Tomcat 和与业务逻辑 -java-io-notserializedException">@ViewScoped 托管 bean 中的 @EJB 导致 java.io.NotSerializedException - 在这里我读到了有关序列化的信息。但在这种情况下,客户端状态保存被激活,而我的 webApp 中的情况并非如此(据我的 web.xml 告诉我)。那么我的 viewscoped ManagedBeans 的序列化是否是必要的,或者是否还有其他失败?

这是我的启动控制台输出(对不起其中的德语部分):

28.01.2011 20:25:05 org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Programme\Java\jdk1.6.0_21\jre\bin;.;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:/Programme/Java/jre6/bin/client;C:/Programme/Java/jre6/bin;C:/Programme/Java/jre6/lib/i386;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Programme\Gemeinsame Dateien\Lenovo;C:\Programme\ATI Technologies\ATI.ACE\Core-Static;C:\Programme\Java\jdk1.6.0_20;C:\StudiPortal\TortoiseSVN\bin;C:\StudiPortal\apache-maven-2.0.11\bin;C:\Programme\Intel\WiFi\bin\;C:\Programme\ThinkPad\ConnectUtilities;C:\Programme\GTK2-Runtime\bin;C:\Programme\OpenVPN\bin
28.01.2011 20:25:05 org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNUNG: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:shapeyourbody' did not find a matching property.
28.01.2011 20:25:06 org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8080
28.01.2011 20:25:06 org.apache.coyote.ajp.AjpProtocol init
INFO: Initializing Coyote AJP/1.3 on ajp-8009
28.01.2011 20:25:06 org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 481 ms
28.01.2011 20:25:06 org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
28.01.2011 20:25:06 org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.5
28.01.2011 20:25:09 com.sun.faces.config.ConfigureListener contextInitialized
INFO: Mojarra 2.0.3 (FCS b03) für Kontext '/shapeyourbody' wird initialisiert.
28.01.2011 20:25:10 com.sun.faces.spi.InjectionProviderFactory createInstance
INFO: JSF1048: PostConstruct/PreDestroy-Annotationen vorhanden.  Verwaltete Bean-Methoden, die mit diesen Annotationen markiert sind, lassen die entsprechenden Annotationen verarbeiten.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.aliasbean.AliasBeanTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.aliasbean.AliasBeansScopeTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.calendar.HtmlInputCalendarTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.date.HtmlInputDateTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.schedule.ScheduleTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.tabbedpane.HtmlPanelTabbedPaneTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.tree.taglib.TreeTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processHandlerClass
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse '[handler-class: null]' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processHandlerClass
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse '[handler-class: null]' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processHandlerClass
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse '[handler-class: null]' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processHandlerClass
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse '[handler-class: null]' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 org.apache.catalina.session.StandardManager doLoad
SCHWERWIEGEND: IOException while loading persisted sessions: java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1333)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at org.apache.catalina.session.StandardSession.readObject(StandardSession.java:1576)
    at org.apache.catalina.session.StandardSession.readObjectData(StandardSession.java:1059)
    at org.apache.catalina.session.StandardManager.doLoad(StandardManager.java:284)
    at org.apache.catalina.session.StandardManager.load(StandardManager.java:204)
    at org.apache.catalina.session.StandardManager.startInternal(StandardManager.java:465)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5025)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1035)
    at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:738)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1035)
    at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:289)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardService.startInternal(StandardService.java:442)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:674)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.startup.Catalina.start(Catalina.java:596)
    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 org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:303)
    at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:431)
Caused by: java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1156)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1509)
    at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1474)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1338)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1146)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1338)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1146)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at org.apache.catalina.session.StandardSession.writeObject(StandardSession.java:1652)
    at org.apache.catalina.session.StandardSession.writeObjectData(StandardSession.java:1076)
    at org.apache.catalina.session.StandardManager.doUnload(StandardManager.java:406)
    at org.apache.catalina.session.StandardManager.unload(StandardManager.java:353)
    at org.apache.catalina.session.StandardManager.stopInternal(StandardManager.java:492)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5195)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.core.ContainerBase.stopInternal(ContainerBase.java:1074)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.core.ContainerBase.stopInternal(ContainerBase.java:1074)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.core.StandardService.stopInternal(StandardService.java:498)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.core.StandardServer.stopInternal(StandardServer.java:695)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.startup.Catalina.stop(Catalina.java:663)
    at org.apache.catalina.startup.Catalina.start(Catalina.java:630)
    ... 6 more
28.01.2011 20:25:10 org.apache.catalina.session.StandardManager startInternal
SCHWERWIEGEND: Exception loading sessions from persistent storage
java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1333)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at org.apache.catalina.session.StandardSession.readObject(StandardSession.java:1576)
    at org.apache.catalina.session.StandardSession.readObjectData(StandardSession.java:1059)
    at org.apache.catalina.session.StandardManager.doLoad(StandardManager.java:284)
    at org.apache.catalina.session.StandardManager.load(StandardManager.java:204)
    at org.apache.catalina.session.StandardManager.startInternal(StandardManager.java:465)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5025)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1035)
    at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:738)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1035)
    at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:289)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardService.startInternal(StandardService.java:442)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:674)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.startup.Catalina.start(Catalina.java:596)
    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 org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:303)
    at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:431)
Caused by: java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1156)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1509)
    at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1474)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1338)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1146)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1338)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1146)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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)
    ... 6 more
28.01.2011 20:25:11 org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8080
28.01.2011 20:25:11 org.apache.coyote.ajp.AjpProtocol start
INFO: Starting Coyote AJP/1.3 on ajp-8009
28.01.2011 20:25:11 org.apache.catalina.startup.Catalina start
INFO: Server startup in 4976 ms

谢谢您的帮助

At deployment of my webApplication on Tomcat 7 I am getting the console output below. After restarting the server twice or three times it works without exceptions.

I am using JSF, Tomcat and an RMI connection to businesslogic part (which shouldn't matter here?)

@EJB in @ViewScoped managed bean causes java.io.NotSerializableException - Here I read about Serialization. But in that case client side state saving was activated, which is not the case in my webApp (as far as my web.xml tells me). So is serialization of my viewscoped ManagedBeans necessary or is there another failure?

Here my startup console output (Sry for that german parts in it):

28.01.2011 20:25:05 org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Programme\Java\jdk1.6.0_21\jre\bin;.;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:/Programme/Java/jre6/bin/client;C:/Programme/Java/jre6/bin;C:/Programme/Java/jre6/lib/i386;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Programme\Gemeinsame Dateien\Lenovo;C:\Programme\ATI Technologies\ATI.ACE\Core-Static;C:\Programme\Java\jdk1.6.0_20;C:\StudiPortal\TortoiseSVN\bin;C:\StudiPortal\apache-maven-2.0.11\bin;C:\Programme\Intel\WiFi\bin\;C:\Programme\ThinkPad\ConnectUtilities;C:\Programme\GTK2-Runtime\bin;C:\Programme\OpenVPN\bin
28.01.2011 20:25:05 org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNUNG: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:shapeyourbody' did not find a matching property.
28.01.2011 20:25:06 org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8080
28.01.2011 20:25:06 org.apache.coyote.ajp.AjpProtocol init
INFO: Initializing Coyote AJP/1.3 on ajp-8009
28.01.2011 20:25:06 org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 481 ms
28.01.2011 20:25:06 org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
28.01.2011 20:25:06 org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.5
28.01.2011 20:25:09 com.sun.faces.config.ConfigureListener contextInitialized
INFO: Mojarra 2.0.3 (FCS b03) für Kontext '/shapeyourbody' wird initialisiert.
28.01.2011 20:25:10 com.sun.faces.spi.InjectionProviderFactory createInstance
INFO: JSF1048: PostConstruct/PreDestroy-Annotationen vorhanden.  Verwaltete Bean-Methoden, die mit diesen Annotationen markiert sind, lassen die entsprechenden Annotationen verarbeiten.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.aliasbean.AliasBeanTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.aliasbean.AliasBeansScopeTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.calendar.HtmlInputCalendarTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.date.HtmlInputDateTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.schedule.ScheduleTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.tabbedpane.HtmlPanelTabbedPaneTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processComponent
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse 'org.apache.myfaces.custom.tree.taglib.TreeTagHandler' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processHandlerClass
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse '[handler-class: null]' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processHandlerClass
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse '[handler-class: null]' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processHandlerClass
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse '[handler-class: null]' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 com.sun.faces.config.processor.FaceletTaglibConfigProcessor processHandlerClass
WARNUNG: JSF1029:  Die Anwendung hat Version 2.0 (entweder ausdrücklich durch die Version von /WEB-INF/faces-config.xml oder eine fehlende /WEB-INF/faces-confg.xml), jedoch hängt Klasse '[handler-class: null]' von einer Legacy-Facelet-Klasse ab.  Das von dieser Klasse registrierte Facelet-Artefakt wird nicht registriert.
28.01.2011 20:25:10 org.apache.catalina.session.StandardManager doLoad
SCHWERWIEGEND: IOException while loading persisted sessions: java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1333)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at org.apache.catalina.session.StandardSession.readObject(StandardSession.java:1576)
    at org.apache.catalina.session.StandardSession.readObjectData(StandardSession.java:1059)
    at org.apache.catalina.session.StandardManager.doLoad(StandardManager.java:284)
    at org.apache.catalina.session.StandardManager.load(StandardManager.java:204)
    at org.apache.catalina.session.StandardManager.startInternal(StandardManager.java:465)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5025)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1035)
    at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:738)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1035)
    at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:289)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardService.startInternal(StandardService.java:442)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:674)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.startup.Catalina.start(Catalina.java:596)
    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 org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:303)
    at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:431)
Caused by: java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1156)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1509)
    at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1474)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1338)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1146)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1338)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1146)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at org.apache.catalina.session.StandardSession.writeObject(StandardSession.java:1652)
    at org.apache.catalina.session.StandardSession.writeObjectData(StandardSession.java:1076)
    at org.apache.catalina.session.StandardManager.doUnload(StandardManager.java:406)
    at org.apache.catalina.session.StandardManager.unload(StandardManager.java:353)
    at org.apache.catalina.session.StandardManager.stopInternal(StandardManager.java:492)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5195)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.core.ContainerBase.stopInternal(ContainerBase.java:1074)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.core.ContainerBase.stopInternal(ContainerBase.java:1074)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.core.StandardService.stopInternal(StandardService.java:498)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.core.StandardServer.stopInternal(StandardServer.java:695)
    at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:216)
    at org.apache.catalina.startup.Catalina.stop(Catalina.java:663)
    at org.apache.catalina.startup.Catalina.start(Catalina.java:630)
    ... 6 more
28.01.2011 20:25:10 org.apache.catalina.session.StandardManager startInternal
SCHWERWIEGEND: Exception loading sessions from persistent storage
java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1333)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at java.util.HashMap.readObject(HashMap.java:1030)
    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.invokeReadObject(ObjectStreamClass.java:974)
    at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
    at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
    at org.apache.catalina.session.StandardSession.readObject(StandardSession.java:1576)
    at org.apache.catalina.session.StandardSession.readObjectData(StandardSession.java:1059)
    at org.apache.catalina.session.StandardManager.doLoad(StandardManager.java:284)
    at org.apache.catalina.session.StandardManager.load(StandardManager.java:204)
    at org.apache.catalina.session.StandardManager.startInternal(StandardManager.java:465)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5025)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1035)
    at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:738)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1035)
    at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:289)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardService.startInternal(StandardService.java:442)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:674)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
    at org.apache.catalina.startup.Catalina.start(Catalina.java:596)
    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 org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:303)
    at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:431)
Caused by: java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1156)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1509)
    at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1474)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1338)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1146)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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:1461)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1392)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1150)
    at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1338)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1146)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
    at java.util.HashMap.writeObject(HashMap.java:1001)
    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)
    ... 6 more
28.01.2011 20:25:11 org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8080
28.01.2011 20:25:11 org.apache.coyote.ajp.AjpProtocol start
INFO: Starting Coyote AJP/1.3 on ajp-8009
28.01.2011 20:25:11 org.apache.catalina.startup.Catalina start
INFO: Server startup in 4976 ms

Thank you for your help

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

扛起拖把扫天下 2024-10-21 23:28:17

这是跟踪的相关部分:

SCHWERWIEGEND:从持久存储加载会话时出现异常
java.io.WriteAbortedException:写入中止; java.io.NotSerializedException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
     ...
     在 org.apache.catalina.session.StandardSession.readObject(StandardSession.java:1576)
     在 org.apache.catalina.session.StandardSession.readObjectData(StandardSession.java:1059)
     在 org.apache.catalina.session.StandardManager.doLoad(StandardManager.java:284)
     在 org.apache.catalina.session.StandardManager.load(StandardManager.java:204)
     在 org.apache.catalina.session.StandardManager.startInternal(StandardManager.java:465)
     在 org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
     ...

这个问题涉及与您链接的问题不同的问题。默认情况下,当 Tomcat 关闭时,它会将 HttpSession 序列化到磁盘,然后在启动时从磁盘重新加载,以便最终用户可以继续浏览器会话而不会丢失任何会话数据。

在这种情况下,任何会话属性都应该实现Serialized。 JSF 视图状态默认存储在会话中,包括所有适当的视图作用域 bean。他们还需要实现 Serialized 才能在 Tomcat 关闭/重新启动时继续存在。

从技术上讲,您可以忽略它。当会话/视图作用域 Bean 尚不存在时,JSF 无论如何都会重新创建。但是,最终用户将无法继续使用相同的会话/视图范围数据。当会话不包含任何不可序列化对象时,不会发生这些异常。这就是为什么它“有时”有效。

如果您想完全禁用会话持久性,这样您就不会受到这些异常/警告的困扰,那么您需要添加一个带有 元素相关 web 应用程序的 元素的 Strong>empty pathname 属性。

<Context ... >
    <Manager pathname="" />
</Context>

这基本上指示 Tomcat 根本不使用会话管理器。

另请参阅:

Here's the relevant bit of the trace:

SCHWERWIEGEND: Exception loading sessions from persistent storage
java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: org.dhbw.stg.wwi2008c.mopro.ui.viewscoped.MachineReservationListBean
     ...
     at org.apache.catalina.session.StandardSession.readObject(StandardSession.java:1576)
     at org.apache.catalina.session.StandardSession.readObjectData(StandardSession.java:1059)
     at org.apache.catalina.session.StandardManager.doLoad(StandardManager.java:284)
     at org.apache.catalina.session.StandardManager.load(StandardManager.java:204)
     at org.apache.catalina.session.StandardManager.startInternal(StandardManager.java:465)
     at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:140)
     ...

This one concerns a different problem than the question which you linked. By default, when Tomcat shutdowns, it will serialize the HttpSession to disk which will then be reloaded from disk on startup so that the endusers can just continue with the browser session without losing any session data.

In such case, any session attribute is supposed to implement Serializable. The JSF view state is by default stored in the session, including all appropriate view scoped beans. They needs to implement Serializable as well in order to survive a Tomcat shutdown/restart.

Technically, you can just ignore it. JSF will recreate the session/view scoped beans anyway when not present yet. However, the enduser won't be able to continue with the same session/view scoped data. Those exceptions won't occur when the session doesn't contain any non-serializable objects. That's why it "sometimes" works.

If you want to disable session persistence altogether so that you won't be bothered with those exceptions/warnings, then you need to add a <Manager> element with an empty pathname attribute to the <Context> element of the webapp in question.

<Context ... >
    <Manager pathname="" />
</Context>

This basically instructs Tomcat to use no session manager at all.

See also:

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文