I have a fresh install of tcServer 6.0. Based on various docs and threads, I have tried a number of ways to configure my JNDI datasource to no effect. Hoping someone can help.
I have successfully created an instance called 'insight'. Here are my other settings:
$TC_HOME/insight/conf/server.xml:
$TC_HOME/insight/conf/context.xml:Code:... <GlobalNamingResources> <Resource name="jdbc/mydb-dev" auth="Container" type="javax.sql.DataSource" username="username" password="mypass" driverClassname="oracle.jdbc.driver.OracleDriver" url="my-working-jdbc-url" maxActive="20" maxIdle="10" maxWait="-1"/> ...
$TC_HOME/insight/webapps/myapp/WEB-INF/web.xml:Code:... <ResourceLink global="jdbc/mydb-dev" name="jdbc/mydb-dev"/> ...
Spring config:Code:<resource-ref> <description>Oracle Datasource example</description> <res-ref-name>"jdbc/mydb-dev"</res-ref-name> <jndi-name>jdbc/mydb-dev</jndi-name> <res-type>javax.sql.DataSource</res-type> <res-auth>Container</res-auth> </resource-ref>
Error from tc Server on startup:Code:<bean id="jndiDataSource" class="org.springframework.jndi.JndiObjectFactoryBean"> <property name="jndiName"> <value>jdbc/mydb-dev</value> </property> <property name="resourceRef" value="true" /> </bean>
I hope someone can point me in the right direction - this is driving me nutsCode:Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'jndiDataSource' defined in class path resource [applicationContext.xml]: Invocation of init method failed; nested exception is javax.naming.NameNotFoundException: Name jdbc is not bound in this Context
Thanks - Gregg



Reply With Quote
