cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adam Ratcliffe <a...@mrigitech.com>
Subject NotSerializableException when reloading Context
Date Tue, 16 Nov 2004 09:25:44 GMT
Hi,

I've been procrastinating on sorting out a NotSerializableException that comes
up in the server logs whenever I reload the application context:

- Cannot serialize session attribute FOM JavaScript GLOBAL SCOPE for session
52496799933AC84574840800D502E25E
java.io.NotSerializableException:
org.apache.cocoon.components.flow.javascript.fom.CompilingClassLoader

(the full stack trace is shown below)

The problem looks to be related to trying to write a session attribute to disk
that's not serializable. The only 2 objects that I'm conscious of setting on
the Session both implement Serializable, as do the fields of these types.

I'm running Cocoon 2.1.5.1 on Tomcat 5.0.19.

Any advice on tracking down the source of this error would be much appreciated.

Cheers
Adam

INFO: Reloading this Context has started
- Cannot serialize session attribute FOM JavaScript GLOBAL SCOPE for session
52496799933AC84574840800D502E25E
java.io.NotSerializableException:
org.apache.cocoon.components.flow.javascript.fom.CompilingClassLoader
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.writeArray(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.writeArray(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.writeObject(Unknown Source)
	at
org.mozilla.javascript.NativeJavaObject.writeExternal(NativeJavaObject.java:965)
	at
org.mozilla.javascript.NativeJavaClass.writeExternal(NativeJavaClass.java:312)
	at java.io.ObjectOutputStream.writeExternalData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.writeArray(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.defaultWriteFields(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.writeObject(Unknown Source)
	at java.util.HashMap.writeObject(Unknown Source)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeWriteObject(Unknown Source)
	at java.io.ObjectOutputStream.writeSerialData(Unknown Source)
	at java.io.ObjectOutputStream.writeOrdinaryObject(Unknown Source)
	at java.io.ObjectOutputStream.writeObject0(Unknown Source)
	at java.io.ObjectOutputStream.writeObject(Unknown Source)
	at
org.apache.catalina.session.StandardSession.writeObject(StandardSession.java:1446)
	at
org.apache.catalina.session.StandardSession.writeObjectData(StandardSession.java:937)
	at
org.apache.catalina.session.StandardManager.doUnload(StandardManager.java:586)
	at org.apache.catalina.session.StandardManager.unload(StandardManager.java:532)
	at org.apache.catalina.session.StandardManager.stop(StandardManager.java:734)
	at org.apache.catalina.core.StandardContext.stop(StandardContext.java:4436)
	at org.apache.catalina.core.StandardContext.reload(StandardContext.java:2984)
	at
org.apache.catalina.core.StandardContext.backgroundProcess(StandardContext.java:4584)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1662)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1671)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1671)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1651)
	at java.lang.Thread.run(Unknown Source)
- Scheduler Cocoon_$_Tue_Nov_16_18:00:34_NZDT_2004 paused.
- Scheduler Cocoon_$_Tue_Nov_16_18:00:34_NZDT_2004 shutting down.
- Scheduler Cocoon_$_Tue_Nov_16_18:00:34_NZDT_2004 paused.
- Scheduler Cocoon_$_Tue_Nov_16_18:00:34_NZDT_2004 shutdown complete.
- Cache event queue destroyed: listenerId=32, cacheName=main
- Optomizing file keyHash.size()=0
- Closing files, base filename: main
- Called close for main
- QProcessor exiting for listenerId=32, cacheName=groupIdCache
- Cache event queue destroyed: listenerId=32, cacheName=groupIdCache
- Failure updating element, cacheName: main, key: EVENTREGWRAPPER
java.lang.NullPointerException
	at
org.apache.jcs.auxiliary.disk.indexed.IndexedDiskCache.doUpdate(IndexedDiskCache.java:249)
	at
org.apache.jcs.auxiliary.disk.AbstractDiskCache$MyCacheListener.handlePut(AbstractDiskCache.java:417)
	at
org.apache.jcs.engine.CacheEventQueue$PutEvent.doRun(CacheEventQueue.java:440)
	at
org.apache.jcs.engine.CacheEventQueue$AbstractCacheEvent.run(CacheEventQueue.java:358)
	at
org.apache.jcs.engine.CacheEventQueue$QProcessor.run(CacheEventQueue.java:327)
- QProcessor exiting for listenerId=32, cacheName=main
- Optomizing file keyHash.size()=0
- Closing files, base filename: groupIdCache
- Called close for groupIdCache
- Exception loading sessions from persistent storage
java.lang.NullPointerException
	at org.mozilla.javascript.ScriptableObject.get(ScriptableObject.java:161)
	at
org.mozilla.javascript.NativeJavaPackage.getPkgProperty(NativeJavaPackage.java:166)
	at org.mozilla.javascript.NativeJavaPackage.get(NativeJavaPackage.java:156)
	at org.mozilla.javascript.ScriptRuntime.getTopLevelProp(ScriptRuntime.java:735)
	at
org.mozilla.javascript.ScriptableObject.getClassPrototype(ScriptableObject.java:1319)
	at
org.mozilla.javascript.ScriptableObject.getFunctionPrototype(ScriptableObject.java:1297)
	at org.mozilla.javascript.JavaMembers.reflectMethod(JavaMembers.java:317)
	at org.mozilla.javascript.JavaMembers.reflect(JavaMembers.java:331)
	at org.mozilla.javascript.JavaMembers.<init>(JavaMembers.java:58)
	at org.mozilla.javascript.JavaMembers.lookupClass(JavaMembers.java:517)
	at
org.mozilla.javascript.NativeJavaObject.readExternal(NativeJavaObject.java:1027)
	at
org.mozilla.javascript.NativeJavaClass.readExternal(NativeJavaClass.java:319)
	at java.io.ObjectInputStream.readExternalData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.readArray(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.defaultReadObject(Unknown Source)
	at
org.mozilla.javascript.ScriptableObject.readObject(ScriptableObject.java:1829)
	at sun.reflect.GeneratedMethodAccessor71.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.readArray(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.defaultReadObject(Unknown Source)
	at
org.mozilla.javascript.ScriptableObject.readObject(ScriptableObject.java:1829)
	at sun.reflect.GeneratedMethodAccessor71.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.readArray(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.defaultReadObject(Unknown Source)
	at
org.mozilla.javascript.ScriptableObject.readObject(ScriptableObject.java:1829)
	at sun.reflect.GeneratedMethodAccessor71.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.defaultReadObject(Unknown Source)
	at
org.mozilla.javascript.ScriptableObject.readObject(ScriptableObject.java:1829)
	at sun.reflect.GeneratedMethodAccessor71.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.defaultReadObject(Unknown Source)
	at
org.mozilla.javascript.ScriptableObject.readObject(ScriptableObject.java:1829)
	at sun.reflect.GeneratedMethodAccessor71.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.defaultReadObject(Unknown Source)
	at
org.mozilla.javascript.ScriptableObject.readObject(ScriptableObject.java:1829)
	at sun.reflect.GeneratedMethodAccessor71.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.readObject(Unknown Source)
	at
org.mozilla.javascript.NativeJavaObject.readExternal(NativeJavaObject.java:1005)
	at
org.mozilla.javascript.NativeJavaClass.readExternal(NativeJavaClass.java:319)
	at java.io.ObjectInputStream.readExternalData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.readArray(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
	at java.io.ObjectInputStream.defaultReadObject(Unknown Source)
	at
org.mozilla.javascript.ScriptableObject.readObject(ScriptableObject.java:1829)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.readObject(Unknown Source)
	at java.util.HashMap.readObject(Unknown Source)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
	at java.io.ObjectInputStream.readSerialData(Unknown Source)
	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
	at java.io.ObjectInputStream.readObject0(Unknown Source)
	at java.io.ObjectInputStream.readObject(Unknown Source)
	at
org.apache.catalina.session.StandardSession.readObject(StandardSession.java:1376)
	at
org.apache.catalina.session.StandardSession.readObjectData(StandardSession.java:920)
	at org.apache.catalina.session.StandardManager.doLoad(StandardManager.java:463)
	at org.apache.catalina.session.StandardManager.load(StandardManager.java:390)
	at org.apache.catalina.session.StandardManager.start(StandardManager.java:704)
	at org.apache.catalina.core.StandardContext.start(StandardContext.java:4226)
	at org.apache.catalina.core.StandardContext.reload(StandardContext.java:2990)
	at
org.apache.catalina.core.StandardContext.backgroundProcess(StandardContext.java:4584)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1662)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1671)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1671)
	at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1651)
	at java.lang.Thread.run(Unknown Source)
trying to register database
trying to register database
Cannot find CatalogManager.properties
- setting defaults to DC
- setting defaultCompositeCacheAttributes to [ useLateral = true, useRemote =
true, useDisk = true, maxObjs = 100, maxSpoolPerRun = -1 ]
- Could not find value for key jcs.default.elementattributes
- Could not instantiate eAttr named 'jcs.default.elementattributes', using
defaults.
- setting defaultElementAttributes to [ IS_LATERAL = false, IS_SPOOL = false,
IS_REMOTE = false, IS_ETERNAL = true, MaxLifeSeconds = -1, IdleTime = -1,
CreateTime = 1100581482788, LastAccessTime = 1100581482788,
getTimeToLiveSeconds() = -1000, createTime = 1100581482788 ]
- Could not find value for key jcs.system.groupIdCache.elementattributes
- Could not instantiate eAttr named 'jcs.system.groupIdCache.elementattributes',
using defaults.
- initialized LRUMemoryCache for groupIdCache
- Constructed cache with name: groupIdCache
- Cache file root directory:
C:\cygwin\home\adam\dev\smartfind_cocoon\work\cocoon-files\cache-dir
- Could not find value for key jcs.region.main.elementattributes
- Could not instantiate eAttr named 'jcs.region.main.elementattributes', using
defaults.
- initialized LRUMemoryCache for main
- Constructed cache with name: main
- Cache file root directory:
C:\cygwin\home\adam\dev\smartfind_cocoon\work\cocoon-files\cache-dir
- RAMJobStore initialized.
- Quartz scheduler 'Cocoon
- Quartz scheduler version: 1.3.2
- Scheduler Cocoon_$_Tue_Nov_16_18:04:51_NZDT_2004 started.




---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message