[jboss-user] [JBoss Cache: Core Edition] - Re: Sample *-jboss-beans.xml for JBoss AS 5.0.GA

amit.bhayani@jboss.com do-not-reply at jboss.com
Wed Jan 14 06:27:43 EST 2009


Initially I got an error Class not found for org.jboss.cache.CacheImpl, so I replaced CacheImpl by Cache realizing that CacheImpl is not there any more.

After above change I am now getting 

Caused by: java.lang.IllegalArgumentException: Constructor needs a factoryMethod attribute when there is a factoryClass attribute or factory element.


Was looking at http://www.jboss.org/file-access/default/members/jbossmc/freezone/docs/2.0.x/userGuide/ch10s03.html
and I think I need to declare  factoryMethod="newInstance"

so I declared  factoryMethod="createCache"

so now it looks like

  | 	<bean name="DefaultCacheFactory" class="org.jboss.cache.DefaultCacheFactory">      
  | 		
  | 		<constructor factoryClass="org.jboss.cache.DefaultCacheFactory"  factoryMethod="createCache">
  | 		</constructor>
  | 		
  | 	</bean>

but again I got 

17:02:12,107 ERROR [AbstractKernelController] Error installing to Instantiated: name=DefaultCacheFactory state=Described
org.jboss.joinpoint.spi.JoinpointException: Method not found createCache[] for class org.jboss.cache.DefaultCacheFactory
        at org.jboss.joinpoint.plugins.Config.findMethodInfo(Config.java:400)
        at org.jboss.joinpoint.plugins.Config.findMethodInfo(Config.java:366)
        at org.jboss.kernel.plugins.config.Configurator.findMethod(Configurator.java:550)


Any clue?

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4201701#4201701

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4201701



More information about the jboss-user mailing list