Hello guys,
Im trying to build a client that can connect to the services deployed on a Jboss-4.0.2 AS. The deployed application is a project wich a generated using andromda-3.1-RC1-SNAPSHOT. The client application wich im trying to build is a project I generated using mevenide on eclipse-3.1. I added the following jars as dependencies for my client application, in both project.xml (maven POM) and as libraries on eclipse (This is needed in order to work with eclipse without getting compilation errors everywhere). Here is a list of the jars I bounded as dependencies (for them to be in my client application classpath): 1.- cashFlow-core-1.0.jar (Part of my andromda project) 2.- cashFlow-common-1.0.jar (Part of my andromda project) 3.- cashFlow-workflow-1.0.jar (Part of my andromda project) 4.- jbossall-client.jar 5.- spring-1.2.2.jar 6.- hibernate-3.0.5.jar 7.- commons-logging-1.0.4.jar 8.- commons-collections-3.1.jar 9.- odmg-3.0.jar (This is needen when working directly with hibernate pojos). Bejore running the client app I deployed the ear file of my andromda project to a jboss AS. I modified the content of the beanRefFactory.xml as pointed by Chad Brandon When running the client applicacation im getting this error (Long): Quote: 24/07/2005 12:05:24 PM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions INFO: Loading XML bean definitions from URL [file:/W:/cashFlow/target/classes/beanRefFactory.xml] 24/07/2005 12:05:24 PM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions INFO: Loading XML bean definitions from URL [jar:file:/W:/cashFlow/core/target/cashFlow-core-1.0.jar!/beanRefFactory.xml] 24/07/2005 12:05:24 PM org.springframework.beans.factory.support.DefaultListableBeanFactory registerBeanDefinition INFO: Overriding bean definition for bean 'beanRefFactory': replacing [Root bean with class [org.springframework.context.support.ClassPathXmlApplicationContext] defined in URL [file:/W:/cashFlow/target/classes/beanRefFactory.xml]] with [Root bean with class [org.springframework.context.support.ClassPathXmlApplicationContext] defined in URL [jar:file:/W:/cashFlow/core/target/cashFlow-core-1.0.jar!/beanRefFactory.xml]] 24/07/2005 12:05:24 PM org.springframework.beans.factory.support.DefaultListableBeanFactory registerBeanDefinition INFO: Overriding bean definition for bean 'beanRefFactoryEjb': replacing [Root bean with class [org.springframework.context.support.ClassPathXmlApplicationContext] defined in URL [file:/W:/cashFlow/target/classes/beanRefFactory.xml]] with [Root bean with class [org.springframework.context.support.ClassPathXmlApplicationContext] defined in URL [jar:file:/W:/cashFlow/core/target/cashFlow-core-1.0.jar!/beanRefFactory.xml]] 24/07/2005 12:05:24 PM org.springframework.context.support.AbstractRefreshableApplicationContext refreshBeanFactory INFO: Bean factory for application context [org.springframework.context.support.ClassPathXmlApplicationContext;hashCode=33219526]: org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans [beanRefFactory,beanRefFactoryEjb]; root of BeanFactory hierarchy 24/07/2005 12:05:24 PM org.springframework.context.support.AbstractApplicationContext refresh INFO: 2 beans defined in application context [org.springframework.context.support.ClassPathXmlApplicationContext;hashCode=33219526] 24/07/2005 12:05:24 PM org.springframework.core.CollectionFactory <clinit> INFO: JDK 1.4+ collections available 24/07/2005 12:05:24 PM org.springframework.core.CollectionFactory <clinit> INFO: Commons Collections 3.x available 24/07/2005 12:05:24 PM org.springframework.context.support.AbstractApplicationContext initMessageSource INFO: Unable to locate MessageSource with name 'messageSource': using default [EMAIL PROTECTED] 24/07/2005 12:05:24 PM org.springframework.context.support.AbstractApplicationContext initApplicationEventMulticaster INFO: Unable to locate ApplicationEventMulticaster with name 'applicationEventMulticaster': using default [EMAIL PROTECTED] 24/07/2005 12:05:24 PM org.springframework.beans.factory.support.DefaultListableBeanFactory preInstantiateSingletons INFO: Pre-instantiating singletons in factory [org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans [beanRefFactory,beanRefFactoryEjb]; root of BeanFactory hierarchy] 24/07/2005 12:05:24 PM org.springframework.beans.factory.support.AbstractBeanFactory getBean INFO: Creating shared instance of singleton bean 'beanRefFactory' 24/07/2005 12:05:24 PM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions INFO: Loading XML bean definitions from class path resource [applicationContext.xml] 24/07/2005 12:05:24 PM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions INFO: Loading XML bean definitions from class path resource [applicationContext-dataSource.xml] 24/07/2005 12:05:24 PM org.springframework.context.support.AbstractRefreshableApplicationContext refreshBeanFactory INFO: Bean factory for application context [org.springframework.context.support.ClassPathXmlApplicationContext;hashCode=28637909]: org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans [messageSource,sessionFactory,hibernateInterceptor,ingresoDao,ingresoDaoTarget,contibuyenteDao,contibuyenteDaoTarget,serviceTransactionInterceptor,ingresoSBTarget,ingresoSB,jbpmSBTarget,jbpmSB,dataSource,transactionManager]; root of BeanFactory hierarchy 24/07/2005 12:05:24 PM org.springframework.context.support.AbstractApplicationContext refresh INFO: 14 beans defined in application context [org.springframework.context.support.ClassPathXmlApplicationContext;hashCode=28637909] 24/07/2005 12:05:24 PM org.springframework.beans.factory.support.AbstractBeanFactory getBean INFO: Creating shared instance of singleton bean 'messageSource' 24/07/2005 12:05:24 PM org.springframework.context.support.AbstractApplicationContext initMessageSource INFO: Using MessageSource [org.springframework.context.support.ResourceBundleMessageSource: basenames=[messages]] 24/07/2005 12:05:24 PM org.springframework.context.support.AbstractApplicationContext initApplicationEventMulticaster INFO: Unable to locate ApplicationEventMulticaster with name 'applicationEventMulticaster': using default [EMAIL PROTECTED] 24/07/2005 12:05:24 PM org.springframework.beans.factory.support.DefaultListableBeanFactory preInstantiateSingletons INFO: Pre-instantiating singletons in factory [org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans [messageSource,sessionFactory,hibernateInterceptor,ingresoDao,ingresoDaoTarget,contibuyenteDao,contibuyenteDaoTarget,serviceTransactionInterceptor,ingresoSBTarget,ingresoSB,jbpmSBTarget,jbpmSB,dataSource,transactionManager]; root of BeanFactory hierarchy] 24/07/2005 12:05:24 PM org.springframework.beans.factory.support.AbstractBeanFactory getBean INFO: Creating shared instance of singleton bean 'sessionFactory' 24/07/2005 12:05:24 PM org.springframework.beans.factory.support.AbstractBeanFactory getBean INFO: Creating shared instance of singleton bean 'dataSource' 24/07/2005 12:05:24 PM org.springframework.beans.factory.support.AbstractBeanFactory destroySingletons INFO: Destroying singletons in factory {org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans [messageSource,sessionFactory,hibernateInterceptor,ingresoDao,ingresoDaoTarget,contibuyenteDao,contibuyenteDaoTarget,serviceTransactionInterceptor,ingresoSBTarget,ingresoSB,jbpmSBTarget,jbpmSB,dataSource,transactionManager]; root of BeanFactory hierarchy} 24/07/2005 12:05:24 PM org.springframework.beans.factory.support.AbstractBeanFactory destroySingletons INFO: Destroying singletons in factory {org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans [beanRefFactory,beanRefFactoryEjb]; root of BeanFactory hierarchy} org.springframework.beans.factory.access.BootstrapException: Unable to initialize group definition. Group resource name [classpath*:beanRefFactory.xml], factory key [beanRefFactoryEjb]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'beanRefFactory' defined in URL [jar:file:/W:/cashFlow/core/target/cashFlow-core-1.0.jar!/beanRefFactory.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.FatalBeanException: Could not instantiate class [org.springframework.context.support.ClassPathXmlApplicationContext]; constructor threw exception; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in class path resource [applicationContext.xml]: Can't resolve reference to bean 'dataSource' while setting property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean wit h name 'dataSource' defined in class path resource [applicationContext-dataSource.xml]: Initialization of bean failed; nested exception is javax.naming.NoInitialContextException: Cannot instantiate class: org.jnp.interfaces.NamingContextFactory org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'beanRefFactory' defined in URL [jar:file:/W:/cashFlow/core/target/cashFlow-core-1.0.jar!/beanRefFactory.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.FatalBeanException: Could not instantiate class [org.springframework.context.support.ClassPathXmlApplicationContext]; constructor threw exception; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in class path resource [applicationContext.xml]: Can't resolve reference to bean 'dataSource' while setting property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [applicationContext-dataSource.xml]: Initialization of bean failed; nested exception is javax.naming.NoInitialContextException: Cannot instantiate class: o rg.jnp.interfaces.NamingContextFactory org.springframework.beans.FatalBeanException: Could not instantiate class [org.springframework.context.support.ClassPathXmlApplicationContext]; constructor threw exception; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in class path resource [applicationContext.xml]: Can't resolve reference to bean 'dataSource' while setting property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [applicationContext-dataSource.xml]: Initialization of bean failed; nested exception is javax.naming.NoInitialContextException: Cannot instantiate class: org.jnp.interfaces.NamingContextFactory org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in class path resource [applicationContext.xml]: Can't resolve reference to bean 'dataSource' while setting property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [applicationContext-dataSource.xml]: Initialization of bean failed; nested exception is javax.naming.NoInitialContextException: Cannot instantiate class: org.jnp.interfaces.NamingContextFactory org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [applicationContext-dataSource.xml]: Initialization of bean failed; nested exception is javax.naming.NoInitialContextException: Cannot instantiate class: org.jnp.interfaces.NamingContextFactory javax.naming.NoInitialContextException: Cannot instantiate class: org.jnp.interfaces.NamingContextFactory [Root exception is java.lang.ClassNotFoundException: org/jnp/interfaces/NamingContextFactory ] at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:652) at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243) at javax.naming.InitialContext.init(InitialContext.java:219) at javax.naming.InitialContext.<init>(InitialContext.java:195) at org.springframework.jndi.JndiTemplate.createInitialContext(JndiTemplate.java:105) at org.springframework.jndi.JndiTemplate.execute(JndiTemplate.java:83) at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:121) at org.springframework.jndi.JndiLocatorSupport.lookup(JndiLocatorSupport.java:71) at org.springframework.jndi.JndiObjectLocator.lookup(JndiObjectLocator.java:106) at org.springframework.jndi.JndiObjectFactoryBean.afterPropertiesSet(JndiObjectFactoryBean.java:125) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:966) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:358) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:226) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:147) at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:176) at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:105) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:920) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:731) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:340) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:226) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:147) at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:270) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:312) at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:80) at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:65) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:274) at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:100) at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:75) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:579) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:322) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:226) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:147) at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:276) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:312) at org.springframework.context.access.ContextSingletonBeanFactoryLocator.initializeDefinition(ContextSingletonBeanFactoryLocator.java:136) at org.springframework.beans.factory.access.SingletonBeanFactoryLocator.useBeanFactory(SingletonBeanFactoryLocator.java:386) at abcware.cashflow.ServiceLocator.getContext(ServiceLocator.java:106) at abcware.cashflow.ServiceLocator.getJbpmSB(ServiceLocator.java:170) at abcware.cashFlow.CFC.main(CFC.java:21) Caused by: java.lang.ClassNotFoundException: org/jnp/interfaces/NamingContextFactory at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:219) at com.sun.naming.internal.VersionHelper12.loadClass(VersionHelper12.java:42) at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:649) ... 41 more Exception in thread "main" (end of quote) The org.jnp.interfaces.NamingContextFactory class is in the jbossall-client.jar wich is in my classpath. Does anyone have any clues of what am I missing? [Rolling Eyes] -- Diego Bendlin _________________________________________________________ Reply to the post : http://galaxy.andromda.org/forum/viewtopic.php?p=3064#3064 Posting to http://forum.andromda.org/ is preferred over posting to the mailing list! ------------------------------------------------------- SF.Net email is sponsored by: Discover Easy Linux Migration Strategies from IBM. Find simple to follow Roadmaps, straightforward articles, informative Webcasts and more! Get everything you need to get up to speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click _______________________________________________ Andromda-user mailing list Andromda-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/andromda-user