[Logo] Terracotta Discussion Forums
  [Search] Search   [Recent Topics] Recent Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
[Expert]
Terracotta + EHCache throws Exception  XML
Forum Index -> Terracotta Platform
Author Message
sunil_kulkarni

journeyman

Joined: 07/15/2009 02:10:46
Messages: 31
Offline

Hi,

I am using the Terracotta 3.0.0 FX trail version and EHCache(version 1.5).

I am using following setup
3 machines - 1 TC Server and 2 TC Client

I am running the following program SubscriberCreator.java as TC Client.

I did the following steps :-
1) Start the TC Server
2) Ran the TC Client program on one machine.(machine1)
3) Ran the TC Client program on another machine.(machine2)

TC Client on machine1 started correctly at step1.
But while starting the TC client on machine2 , it is showing following message :-
Jul 28, 2009 8:15:27 PM net.sf.ehcache.CacheManager detectAndFixDiskStorePathConflict
WARNING: Creating a new instance of CacheManager using the diskStorePath "/tmp" which is already used by an existing CacheManager.
The source of the configuration was file located at /home/hadoop/Terracotta/alljars/ehcache-1.5.0/ehcache.xml.
The diskStore path for this CacheManager will be set to /tmp/ehcache_auto_created_1248792327394.
To avoid this warning consider using the CacheManager factory methods to create a singleton CacheManager or specifying a separate ehcache configuration (ehcache.xml) for each CacheManager instance.
Current cache size is : 0


and started program executions.

After that when I see the at TC Client program on machine1 , It is showing me following exception:-

2009-07-28 20:13:36,024 ERROR - OnLoad execute script failed for: class net.sf.ehcache.Cache error: self .onloadCache ( ) line: 1; Sourced file: inline evaluation of: ``self.onloadCache();'' : Method Invocation self.onloadCache
java.lang.NullPointerException
at net.sf.ehcache.Cache.onloadCache(CacheTC.java:502)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at bsh.Reflect.invokeMethod(Unknown Source)
at bsh.Reflect.invokeObjectMethod(Unknown Source)
at bsh.Name.invokeMethod(Unknown Source)
at bsh.BSHMethodInvocation.eval(Unknown Source)
at bsh.BSHPrimaryExpression.eval(Unknown Source)
at bsh.BSHPrimaryExpression.eval(Unknown Source)
at bsh.Interpreter.eval(Unknown Source)
at bsh.Interpreter.eval(Unknown Source)
at bsh.Interpreter.eval(Unknown Source)
at com.tc.object.TCObjectImpl.performOnLoadActionIfNecessary(TCObjectImpl.java:161)
at com.tc.object.TCObjectImpl.hydrate(TCObjectImpl.java:119)
at com.tc.object.ClientObjectManagerImpl.lookup(ClientObjectManagerImpl.java:538)
at com.tc.object.ClientObjectManagerImpl.lookupObject(ClientObjectManagerImpl.java:432)
at com.tc.object.ClientObjectManagerImpl.lookupObject(ClientObjectManagerImpl.java:420)
at com.tc.object.TCObjectPhysical.resolveReference(TCObjectPhysical.java:129)
at com.tc.object.TCObjectPhysical.resolveAllReferences(TCObjectPhysical.java:55)
at com.tc.object.TCObjectImpl.performOnLoadActionIfNecessary(TCObjectImpl.java:145)
at com.tc.object.TCObjectImpl.hydrate(TCObjectImpl.java:119)
at com.tc.object.ClientObjectManagerImpl.lookup(ClientObjectManagerImpl.java:538)
at com.tc.object.ClientObjectManagerImpl.lookupObject(ClientObjectManagerImpl.java:432)
at com.tc.object.ClientObjectManagerImpl.lookupObject(ClientObjectManagerImpl.java:420)
at com.tc.object.applicator.ListApplicator.hydrate(ListApplicator.java:55)
at com.tc.object.TCClassImpl.hydrate(TCClassImpl.java:170)
at com.tc.object.TCObjectImpl.hydrate(TCObjectImpl.java:118)
at com.tc.object.tx.ClientTransactionManagerImpl.basicApply(ClientTransactionManagerImpl.java:568)
at com.tc.object.tx.ClientTransactionManagerImpl.apply(ClientTransactionManagerImpl.java:595)
at com.tc.object.handler.ReceiveTransactionHandler.handleEvent(ReceiveTransactionHandler.java:88)
at com.tc.async.impl.StageImpl$WorkerThread.run(StageImpl.java:142)
java.lang.NullPointerException
at net.sf.ehcache.config.ConfigurationHelperTC.loadCache(ConfigurationHelperTC.java:78)
at net.sf.ehcache.config.ConfigurationHelperTC.initializeCachesIfRequired(ConfigurationHelperTC.java:72)
at net.sf.ehcache.CacheManager.loadCaches(CacheManager.java)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at bsh.Reflect.invokeMethod(Unknown Source)
at bsh.Reflect.invokeObjectMethod(Unknown Source)
at bsh.Name.invokeMethod(Unknown Source)
at bsh.BSHMethodInvocation.eval(Unknown Source)
at bsh.BSHPrimaryExpression.eval(Unknown Source)
at bsh.BSHPrimaryExpression.eval(Unknown Source)
at bsh.Interpreter.eval(Unknown Source)
at bsh.Interpreter.eval(Unknown Source)
at bsh.Interpreter.eval(Unknown Source)
at com.tc.object.TCObjectImpl.performOnLoadActionIfNecessary(TCObjectImpl.java:161)
at com.tc.object.TCObjectImpl.hydrate(TCObjectImpl.java:119)
at com.tc.object.ClientObjectManagerImpl.lookup(ClientObjectManagerImpl.java:538)
at com.tc.object.ClientObjectManagerImpl.lookupObject(ClientObjectManagerImpl.java:432)
at com.tc.object.ClientObjectManagerImpl.lookupObject(ClientObjectManagerImpl.java:420)
at com.tc.object.applicator.ListApplicator.hydrate(ListApplicator.java:55)
at com.tc.object.TCClassImpl.hydrate(TCClassImpl.java:170)
at com.tc.object.TCObjectImpl.hydrate(TCObjectImpl.java:118)
at com.tc.object.tx.ClientTransactionManagerImpl.basicApply(ClientTransactionManagerImpl.java:568)
at com.tc.object.tx.ClientTransactionManagerImpl.apply(ClientTransactionManagerImpl.java:595)
at com.tc.object.handler.ReceiveTransactionHandler.handleEvent(ReceiveTransactionHandler.java:88)
at com.tc.async.impl.StageImpl$WorkerThread.run(StageImpl.java:142)
2009-07-28 20:13:36,293 ERROR - OnLoad execute script failed for: class net.sf.ehcache.CacheManager error: self .loadCaches ( ) line: 1; Sourced file: inline evaluation of: ``self.loadCaches();'' : Method Invocation self.loadCaches
java.lang.NullPointerException
at net.sf.ehcache.config.ConfigurationHelperTC.loadCache(ConfigurationHelperTC.java:78)
at net.sf.ehcache.config.ConfigurationHelperTC.initializeCachesIfRequired(ConfigurationHelperTC.java:72)
at net.sf.ehcache.CacheManager.loadCaches(CacheManager.java)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at bsh.Reflect.invokeMethod(Unknown Source)
at bsh.Reflect.invokeObjectMethod(Unknown Source)
at bsh.Name.invokeMethod(Unknown Source)
at bsh.BSHMethodInvocation.eval(Unknown Source)
at bsh.BSHPrimaryExpression.eval(Unknown Source)
at bsh.BSHPrimaryExpression.eval(Unknown Source)
at bsh.Interpreter.eval(Unknown Source)
at bsh.Interpreter.eval(Unknown Source)
at bsh.Interpreter.eval(Unknown Source)
at com.tc.object.TCObjectImpl.performOnLoadActionIfNecessary(TCObjectImpl.java:161)
at com.tc.object.TCObjectImpl.hydrate(TCObjectImpl.java:119)
at com.tc.object.ClientObjectManagerImpl.lookup(ClientObjectManagerImpl.java:538)
at com.tc.object.ClientObjectManagerImpl.lookupObject(ClientObjectManagerImpl.java:432)
at com.tc.object.ClientObjectManagerImpl.lookupObject(ClientObjectManagerImpl.java:420)
at com.tc.object.applicator.ListApplicator.hydrate(ListApplicator.java:55)
at com.tc.object.TCClassImpl.hydrate(TCClassImpl.java:170)
at com.tc.object.TCObjectImpl.hydrate(TCObjectImpl.java:118)
at com.tc.object.tx.ClientTransactionManagerImpl.basicApply(ClientTransactionManagerImpl.java:568)
at com.tc.object.tx.ClientTransactionManagerImpl.apply(ClientTransactionManagerImpl.java:595)
at com.tc.object.handler.ReceiveTransactionHandler.handleEvent(ReceiveTransactionHandler.java:88)
at com.tc.async.impl.StageImpl$WorkerThread.run(StageImpl.java:142)


I have attched the program that I am using as TC client , TC config file and ehcache.sml file.

--------
Thanks in advance.
 Filename ehcache.xml [Disk] Download
 Description EHCache Configuration file
 Filesize 23 Kbytes
 Downloaded:  189 time(s)

 Filename tc-config.xml [Disk] Download
 Description TC Configuration File
 Filesize 2 Kbytes
 Downloaded:  164 time(s)

 Filename SubscriberCreator.java [Disk] Download
 Description TC Client Program
 Filesize 3 Kbytes
 Downloaded:  168 time(s)

amiller

ophanim

Joined: 08/29/2007 09:05:48
Messages: 722
Location: St. Louis, MO
Offline

Ehcache 1.5 is not supported with Terracotta 3.0. Can you try with Ehcache 1.4.1?

Alex Miller (Terracotta Engineer) - Want to post to the forums? Sign up here
[WWW]
sunil_kulkarni

journeyman

Joined: 07/15/2009 02:10:46
Messages: 31
Offline

I have checked the above code with following :-
Terracotta FX trial version and EHCache 1.4.1 .

But still it is throwing an exception.

sunil_kulkarni

journeyman

Joined: 07/15/2009 02:10:46
Messages: 31
Offline

I have checked all configuration files and modified the java code.
Not it is working ...

Thanks.
sunil_kulkarni

journeyman

Joined: 07/15/2009 02:10:46
Messages: 31
Offline

Sorry.... Now it is working.... spelling mistake in above comments.

 
Forum Index -> Terracotta Platform
Go to:   
Powered by JForum 2.1.7 © JForum Team