Announcement Announcement Module
Collapse
No announcement yet.
Spring MDP running in Tomcat Unable to connect to Remote Queue in Weblogic 10.0 Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Spring MDP running in Tomcat Unable to connect to Remote Queue in Weblogic 10.0

    Dear All,

    I have a Spring MDP which is listening to a remote Weblogic Queue.
    When I run this application in tomcat, I get the below error.

    Code:
    2011/07/14 09:52:40 ERROR  initWebApplicationContext(ContextLoader.java:214) - Context initialization failed  
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'ConnectionFactory11' defined in ServletContext resource [/WEB-INF/config/jms-consumer-config.xml]: Invocation of init method failed; nested exception is javax.naming.NamingException: Unhandled exception in lookup [Root exception is org.omg.CORBA.NO_PERMISSION:   vmcid: 0x0  minor code: 0  completed: No]
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1337)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:476)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:412)
    	at java.security.AccessController.doPrivileged(AccessController.java:219)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:383)
    	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:276)
    	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
    	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:273)
    	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:175)
    	at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:479)
    	at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:716)
    	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:377)
    	at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:254)
    	at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:198)
    	at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:47)
    	at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3934)
    	at org.apache.catalina.core.StandardContext.start(StandardContext.java:4429)
    	at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
    	at org.apache.catalina.core.StandardHost.start(StandardHost.java:722)
    	at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
    	at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
    	at org.apache.catalina.core.StandardService.start(StandardService.java:516)
    	at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
    	at org.apache.catalina.startup.Catalina.start(Catalina.java:583)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    	at java.lang.reflect.Method.invoke(Method.java:618)
    	at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
    	at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
    Caused by: 
    javax.naming.NamingException: Unhandled exception in lookup [Root exception is org.omg.CORBA.NO_PERMISSION:   vmcid: 0x0  minor code: 0  completed: No]
    	at weblogic.corba.j2ee.naming.Utils.wrapNamingException(Utils.java:83)
    	at weblogic.corba.j2ee.naming.ContextImpl.lookup(ContextImpl.java:232)
    	at weblogic.corba.j2ee.naming.ContextImpl.lookup(ContextImpl.java:168)
    	at javax.naming.InitialContext.lookup(InitialContext.java:363)
    	at org.springframework.jndi.JndiTemplate$1.doInContext(JndiTemplate.java:154)
    	at org.springframework.jndi.JndiTemplate.execute(JndiTemplate.java:87)
    	at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:152)
    	at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:178)
    	at org.springframework.jndi.JndiLocatorSupport.lookup(JndiLocatorSupport.java:95)
    	at org.springframework.jndi.JndiObjectLocator.lookup(JndiObjectLocator.java:105)
    	at org.springframework.jndi.JndiObjectFactoryBean.lookupWithFallback(JndiObjectFactoryBean.java:201)
    	at org.springframework.jndi.JndiObjectFactoryBean.afterPropertiesSet(JndiObjectFactoryBean.java:187)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1368)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1334)
    	... 29 more

    My WebLogic 10.0 with IBM java 5
    Tomcat 6.0 with IBM Java 5
    My Weblogic Administration/console is running in HTTPS


    My template looks like

    Code:
    <bean id="jndiTemplate11" class="org.springframework.jndi.JndiTemplate">
    		<property name="environment">
    			<props>
    				<prop key="java.naming.factory.initial">${InitialContext.factory}</prop>
    				<prop key="java.naming.provider.url">${InitialContext.url11}</prop>
    				<prop key="java.naming.security.principal">${contextUserName}</prop>
    				<prop key="java.naming.security.credentials">${contextPassword}</prop>
    			</props>
    		</property>
    	</bean>
    In my property file I Have
    Code:
    InitialContext.factory=weblogic.jndi.WLInitialContextFactory
    jms.connectionFactory=jms/cf
    jms.DMSQueue=jms/DMSQueue
    InitialContext.url11=t3://10.54.115.171:80
    contextUserName=system
    contextPassword=system123
    Any help is appreciated..
Working...
X