PDA

View Full Version : Deploy the sample app JPetStore to Macromedia JRun4 Problem



sunfmin
Aug 23rd, 2004, 03:04 AM
When I deploy the sample app JPetStore to Macromedia JRun4 , I got the following error. but work fine in Jakarta Tomcat 4.1.30
can anyone tell me what's wrong with it. and How can I solve it? thanks.




08/23 14:52:49 info [axis] Initializing servlet 'remoting'
08/23 14:52:49 info [axis] Framework servlet 'remoting' init
08/23 14:52:49 user Initializing WebApplicationContext for servlet 'remoting'
08/23 14:52:49 error [axis] Context initialization failed
org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'sqlMap' defined in resource [/WEB-INF/dataAccessContext-local.xml] of ServletContext: Initialization of bean failed; nested exception is java.lang.VerifyError: (class: com/ibatis/db/sqlmap/XmlSqlMapBuilder, method: buildFragmentList signature: (Lorg/jdom/Element;)Ljava/util/List;) Incompatible object argument for function call
java.lang.VerifyError: (class: com/ibatis/db/sqlmap/XmlSqlMapBuilder, method: buildFragmentList signature: (Lorg/jdom/Element;)Ljava/util/List;) Incompatible object argument for function call
at org.springframework.orm.ibatis.SqlMapFactoryBean.a fterPropertiesSet(SqlMapFactoryBean.java:75)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.invokeInitMethods(Abstr actAutowireCapableBeanFactory.java:987)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.createBean(AbstractAuto wireCapableBeanFactory.java:284)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.createBean(AbstractAuto wireCapableBeanFactory.java:204)
at org.springframework.beans.factory.support.Abstract BeanFactory.getBean(AbstractBeanFactory.java:198)
at org.springframework.beans.factory.support.Abstract BeanFactory.getBean(AbstractBeanFactory.java:135)
at org.springframework.beans.factory.support.DefaultL istableBeanFactory.preInstantiateSingletons(Defaul tListableBeanFactory.java:217)
at org.springframework.context.support.AbstractApplic ationContext.refresh(AbstractApplicationContext.ja va:284)
at org.springframework.web.context.support.XmlWebAppl icationContext.refresh(XmlWebApplicationContext.ja va:131)
at org.springframework.web.context.ContextLoader.crea teWebApplicationContext(ContextLoader.java:156)
at org.springframework.web.context.ContextLoader.init WebApplicationContext(ContextLoader.java:97)
at org.springframework.web.context.ContextLoaderServl et.init(ContextLoaderServlet.java:80)
at javax.servlet.GenericServlet.init(GenericServlet.j ava:258)
at jrun.servlet.WebApplicationService.loadServlet(Web ApplicationService.java:1204)
at jrun.servlet.WebApplicationService.preloadServlets (WebApplicationService.java:762)
at jrun.servlet.WebApplicationService.postStart(WebAp plicationService.java:257)
at jrun.deployment.DeployerService.initModules(Deploy erService.java:711)
at jrun.deployment.DeployerService.createWatchedDeplo yment(DeployerService.java:242)
at jrun.deployment.DeployerService.deploy(DeployerSer vice.java:430)
at jrun.deployment.DeployerService.checkWatchedDirect ories(DeployerService.java:179)
at jrun.deployment.DeployerService.run(DeployerServic e.java:891)
at jrunx.scheduler.SchedulerService.invokeRunnable(Sc hedulerService.java:223)
at jrunx.scheduler.ThreadPool$DownstreamMetrics.invok eRunnable(ThreadPool.java:348)
at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRu nnable(ThreadPool.java:451)
at jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeR unnable(ThreadPool.java:294)
at jrunx.scheduler.WorkerThread.run(WorkerThread.java :66)

mraible
Aug 23rd, 2004, 11:15 AM
It looks to me like JRun has a version of JDOM that conflicts with Spring. Maybe you can replace it with the one that Spring uses?

sunfmin
Aug 23rd, 2004, 08:30 PM
It is located in jrun.jar,It is so funny that JRun4 include jdom in it's jar.
then how can I separate it? thanks.



jrun.jar
├─allaire
├─com
├─images
├─javax
├─jrun
├─jrunx
├─META-INF
├─net
└─org
├─apache
├─jdom
├─mozilla
├─omg
├─w3c
└─xml

Colin Sampaleanu
Aug 23rd, 2004, 08:43 PM
That's a pretty nasty thing for them to do.

Assuming JRun does have the ability to load classes it needs from something like a lib dir, what's stopping you from just editing the jar file (with a zip archive maniulator) and removing the files, then dropping in an up to date JDOM?

Regards,

sunfmin
Aug 23rd, 2004, 09:28 PM
Looks like it is the only way I can do that.
ok. thanks.

Juergen Hoeller
Aug 24th, 2004, 12:48 AM
It looks to me like JRun has a version of JDOM that conflicts with Spring. Maybe you can replace it with the one that Spring uses?

Actually, it's iBATIS SQL Maps 1.3.1 that requires JDOM, not Spring itself. Note that SQL Maps 2.0 doesn't require JDOM anymore.

Velocity depends on JDOM too, if I recall correctly. In any case, JRun really shouldn't bundle JDOM in its server jar...

Juergen

Colin Sampaleanu
Aug 24th, 2004, 09:15 AM
FWIW, the upgrade form iBatis SQL Maps 1.0 to 2.0, which would also get rid of this issue, is very simple and mechanical, although relatively tedious if you have a lot of mapping files and code, since most maps and code will be touched unless you run in the compatibility mode. But the process is straightforward, and not-error prone since since everything in 1.0 has an equivalent in 2.0.

Regards,