Select to view content in your preferred language

[Resolved] Development : Geoportal and Eclipse IDE issue

2643
1
03-06-2012 01:17 PM
MichalGasparovic
Occasional Contributor
Hi,

colleague of mine has successfully "installed" the latest geoportal on one of our servers, with all the db being in Oracle, using LDAP and all other settings... all good. up and running.

I'm supposed to do a bit of a customisation on this product, so I've followed this link Eclipse Project from Source Code.
I'm using the Tomcat 6.0 and JDK6, Eclipse Indigo.

I've followed the steps in the link, but cannot successfully run the application. Well, the application starts up, but have a stack of error messages in the console. I've noticed, that the changes I make in the gpt.config -> gpt.xml are not picked up ! So obviously, there is some other file(s) I need to modify to get the proper settings in place. e.g. luceneIndexPath is always empty despite the fact it has a value in the gpt.xml.

any ideas where shall I make a changes to the configuration?

Also, in the stack trace, I get the following error
[HTML]
SEVERE: Connection test failed.
org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot load JDBC driver class 'oracle.jdbc.driver.OracleDriver'
at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createConnectionFactory(BasicDataSource.java:1429)
at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1371)
at org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:1044)
at com.esri.gpt.framework.sql.DatabaseReference.openJndiConnection(DatabaseReference.java:279)
at com.esri.gpt.framework.sql.DatabaseReference.openConnection(DatabaseReference.java:233)
at com.esri.gpt.framework.sql.DatabaseReference.testConnection(DatabaseReference.java:313)
at com.esri.gpt.framework.sql.DatabaseReferences.add(DatabaseReferences.java:89)
at com.esri.gpt.framework.context.ApplicationConfigurationLoader.loadDatabase(ApplicationConfigurationLoader.java:450)
at com.esri.gpt.framework.context.ApplicationConfigurationLoader.load(ApplicationConfigurationLoader.java:130)
at com.esri.gpt.framework.context.ApplicationContext.loadConfiguration(ApplicationContext.java:84)
at com.esri.gpt.framework.context.ApplicationContext.getInstance(ApplicationContext.java:70)
at com.esri.gpt.framework.context.InitializationServlet.init(InitializationServlet.java:64)
at javax.servlet.GenericServlet.init(GenericServlet.java:160)
at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1266)
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1185)
at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1080)
at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5001)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5289)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.StandardContext.reload(StandardContext.java:3894)
at org.apache.catalina.loader.WebappLoader.backgroundProcess(WebappLoader.java:424)
at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1310)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1496)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1506)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1506)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1485)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1688)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1533)
at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createConnectionFactory(BasicDataSource.java:1420)
... 26 more
[/HTML]

I've added the context.xml in the meta-inf folder with the setting from our 'live' server (on where it all works), and also got the ojdbc6.jar from there and put it in the location the link above suggests.
Any ideas on how to fix this one please?

Thanks for all your help.

[ UPDATE ]
Started from scratch again. the changes in gpt.xml are now being picked up, but the jdbc connection errors persist "Cannot load JDBC driver class 'oracle.jdbc.driver.OracleDriver'"

[ UPDATE ]
All good now. I've went through this from scratch, got the ojdbc6.jar file from the oracle website (interesting the one that works on our server doesn't work on my machine, java kept complaining) and put that file under tomcat/lib folder.
0 Kudos
1 Reply
CliveReece
Esri Contributor
Good to hear you were able to resolve your issue.  I've found Tomcat sometimes likes to hang on to webapp files when doing an update.  When in doubt, I manually tell Tomcat to undeploy the geoportal and then also go into the Tomcat cache (work/Catalina/localhost) and delete the geoportal folder there too before re-deploying geoportal.
0 Kudos