tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Karthik Nanjangude <karthik.nanjang...@xius-bcgi.com>
Subject RE: Scheduling tasks in Tomcat
Date Tue, 28 Apr 2009 04:24:24 GMT
Hi

I would suggest u to use the Listener tag instead of Load on startup

<listener>
<listener-class>
  org.quartz.ee.servlet.QuartzInitializerListener
</listener-class>
</listener>

As per "Quartz Enterprise Job Scheduler API (1.6.2)"

org.quartz.ee.servlet.QuartzInitializerServlet  is deprecated




with regards
Karthik


-----Original Message-----
From: Aden Jones [mailto:adenjones@gmail.com]
Sent: Tuesday, April 28, 2009 9:35 AM
To: users@tomcat.apache.org
Subject: RE: Scheduling tasks in Tomcat




mgainty wrote:
>
>
> javac .\org\quartz\ee\servlet\QuartzInitializerServlet.java
> place .\org\quartz\ee\servlet\QuartzInitializerServlet.class to
> WEB-INF/classes
>
> Okay so QuatzInitializerServlet.java is the class that I create for
> scheduling the events.
>
> your web.xml will need to associate the Servlet class with url-pattern as
> in this configuration:
>  <servlet>
>  <servlet-name>Servlet</servlet-name>
>
> <servlet-class>org.quartz.ee.servlet.QuartzInitializerServlet</servlet-class>
>
>  It would be okay I suppose if I use my existing structure and reference
> <servlet-class>com.timekeeper.util.QuartzInitializerServlet</servlet-class>
> ?
>
>
>   <load-on-startup>1</load-on-startup>
>  </servlet>
>  <servlet-mapping>
>   <servlet-name>Servlet</servlet-name>
>   <url-pattern>*</url-pattern>
>
> Why would I need to add a url pattern if it only needs to be run on
> startup?
>  </servlet-mapping>
>
> you will also need an startup display page index.jsp and configure
> index.jsp as welcome-file e.g.
>
>   <welcome-file-list>
>     <welcome-file>index.jsp</welcome-file>
>   </welcome-file-list>
>
> HTH
> Martin
> ______________________________________________
> Disclaimer and Confidentiality/Verzicht und Vertraulichkeitanmerkung /
> Note de déni et de confidentialité
> This message is confidential. If you should not be the intended receiver,
> then we ask politely to report. Each unauthorized forwarding or
> manufacturing of a copy is inadmissible. This message serves only for the
> exchange of information and has no legal binding effect. Due to the easy
> manipulation of emails we cannot take responsibility over the the
> contents.
> Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene
> Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte
> Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht
> dient lediglich dem Austausch von Informationen und entfaltet keine
> rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von
> E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen.
> Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le
> destinataire prévu, nous te demandons avec bonté que pour satisfaire
> informez l'expéditeur. N'importe quelle diffusion non autorisée ou la
> copie de ceci est interdite. Ce message sert à l'information seulement et
> n'aura pas n'importe quel effet légalement obligatoire. Étant donné que
> les email peuvent facilement être sujets à la manipulation, nous ne
> pouvons accepter aucune responsabilité pour le contenu fourni.
>
>
>
>
>
>
>> Date: Mon, 27 Apr 2009 17:52:16 -0700
>> From: adenjones@gmail.com
>> To: users@tomcat.apache.org
>> Subject: Re: Scheduling tasks in Tomcat
>>
>>
>> I will probably use quartz to schedule the actual task and add it to my
>> webapp as my teacher would prefer that the servlet contains everything.
>>
>> What I don't understand is how or if (after I create my class that
>> contains
>> the scheduling code) Tomcat actually runs the code. Do I need to add
>> something to web.xml to tell Tomcat to run it. Does Tomcat run every
>> class
>> in the servlet automatically.
>>
>>
>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Scheduling-tasks-in-Tomcat-tp23251939p23268143.html
>> Sent from the Tomcat - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>
> _________________________________________________________________
> Rediscover Hotmail®: Now available on your iPhone or BlackBerry
> http://windowslive.com/RediscoverHotmail?ocid=TXT_TAGLM_WL_HM_Rediscover_Mobile2_042009
>

--
View this message in context: http://www.nabble.com/Scheduling-tasks-in-Tomcat-tp23251939p23269777.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message