aspose file tools*
The moose likes Tomcat and the fly likes configuring Quartz scheduler in tomcat 6 using JNDI Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "configuring Quartz scheduler in tomcat 6 using JNDI " Watch "configuring Quartz scheduler in tomcat 6 using JNDI " New topic
Author

configuring Quartz scheduler in tomcat 6 using JNDI

Shantanu Puranik
Ranch Hand

Joined: Jun 10, 2004
Posts: 67
Hello,

I'm working on project that involves porting legacy app. from old version of JBoss and java to tomcat 6.x and jdk 1.6.
Quartz 1.6 is configured as JNDI resource using mbean in old app.
For new app. Quartz version remains the same.

What I 've done till now:
1. Created myWebApp_quartz.properties file and placed under /webapps/myWebApp/WEB-INF/classes

2. Added following entry in web.xml

I get an exception saying, javax.naming.NameNotFoundException: Name myWebAppQuartz is not bound in this Context
It means that quartz instance isn't registered with JNDI.
I want to know how to configure Quartz scheduler in tomcat 6 using JNDI.
Thank you.


--- Shantanu
Shantanu Puranik
Ranch Hand

Joined: Jun 10, 2004
Posts: 67
Just figured out with help of tomcat help resource
Scroll down the page to section Adding Custom Resource Factories

1. Implement interface javax.naming.spi.ObjectFactory

2. create quartz.properties file as shown in the above post (consider specifying additional properties as required by your app.)

3. In web.xml add resource ref
4. create context.xml in the project structure at location /webapps/META-INF.
When deployed tomcat will automatically create <myWebApp>.xml in dir. \tomcat\conf\Catalina\localhost and the contents of context.xml will be copied into it.
Finally, perform lookup as
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: configuring Quartz scheduler in tomcat 6 using JNDI
 
Similar Threads
JSF 1.1 and Tomcat 6
wsdd urgent help Web Services
wsdd urgent help
Struts 1.1 - Tomcat 4.1.30 deployment problem
Hot deploy