run-at is 2.4 spec and I think Tomcat 4 _IS_NOT_ Servlet 2.4 spec
My guess it will work in Tomcat 5.0.X and above.
Comments?
Mark.
--- Dwayne Ghant [EMAIL PROTECTED] wrote:
Have fun I hope this helps!!! It should.
web-app id='/'
servlet servlet-name='hello'
run-at - is not part of the servlet spec. It will not appear in tomcat.
-Tim
Mark wrote:
run-at is 2.4 spec and I think Tomcat 4 _IS_NOT_ Servlet 2.4 spec
My guess it will work in Tomcat 5.0.X and above.
Comments?
-
To
On Tue, 21 Dec 2004 20:24:25 -0800, Dwayne Ghant [EMAIL PROTECTED] wrote:
The alarm is configured as any other servlet, with the addition of the
run-at tag. The following configuration runs the servlet every 15
minutes. If the hour is missing, e.g. :15 the service is run at the
specified
run-at is resin specific (non servlet compliant extension)
-Tim
Thomas Chille wrote:
On Tue, 21 Dec 2004 20:24:25 -0800, Dwayne Ghant [EMAIL PROTECTED] wrote:
The alarm is configured as any other servlet, with the addition of the
run-at tag. The following configuration runs the servlet every 15
Will be the the RUN-AT-paramter evaluated by Tomcat 5.0x or by anybody else?
Use an external scheduler like Quartz or Flux.
Andrzej Jan Taramina
Chaeron Corporation: Enterprise System Solutions
http://www.chaeron.com
-
To
If you are running Linux or Unix check the syntax for the 'nice'
command.
[EMAIL PROTECTED] 12-27-2004 18:55
Frank W. Zammetti wrote:
It's interesting, Craig and I had an exchange about threads in
servlet
containers last week... I can't find a link to the thread
unfortunately.
Anyway, the
Dennis Payne wrote:
If you are running Linux or Unix check the syntax for the 'nice'
command.
[EMAIL PROTECTED] 12-27-2004 18:55
Frank W. Zammetti wrote:
It's interesting, Craig and I had an exchange about threads in
servlet
containers last week... I can't find a link to
Dennis Payne wrote:
Frank,
I'm using threads and didn't know I was vulnerable.
I'm not sure vulnerable is really the right word, but I'll go with it :)
Here's how I've
done it. I created a class that implements runnable and call its
initialize method from a servlet init method at application
The minimum thread priority is 1, maximum is 10 and medium or normal is 5. See:
http://java.sun.com/j2se/1.4.2/docs/api/constant-values.html#java.lang.Thread.NORM_PRIORITY
You can set a good neighbor poilicy with MIN_PRIORITY. Hunter on
Servlets covers this with a daemon servlet.
Jack
On
Frank W. Zammetti wrote:
Dennis Payne wrote:
Frank,
I'm using threads and didn't know I was vulnerable.
I'm not sure vulnerable is really the right word, but I'll go with
it :)
Here's how I've done it. I created a class that implements runnable
and call its initialize method from a servlet
I think what you describe is probably more properly implemented as some
sort of queueing system. Something along the lines of setting up a
queue on each data collection server that lazily updates the central
server (there's other ways to structure it of course).
Otherwise, I myself would tend
Frank W. Zammetti wrote:
I think what you describe is probably more properly implemented as
some sort of queueing system. Something along the lines of setting up
a queue on each data collection server that lazily updates the
central server (there's other ways to structure it of course).
Jukka Uusisalo wrote:
Jorge Sopena wrote:
Why is bad using own threads inside web application?
Aren't all the servlet request actually a thread in Tomcat?
I can't find a reason why it's so bad solution.
I think that comes from J2EE specs. I do not remember is threads just
forbidden but if you
Frank W. Zammetti wrote:
It's interesting, Craig and I had an exchange about threads in servlet
containers last week... I can't find a link to the thread unfortunately.
Anyway, the basic idea behind that don't spawn your own threads
inside a servlet container admonishment is based more on the
Use java.util.Timer and java.util.TimerTask. Create a Timer object.
Timer timer = new Timer(). Then create a TimerTask object. SomeTask
task = new SomeTasK().
private class SomeTask
extends TimerTask {
public void run() {
// do stuff
}
}
Schedule the task:
Hi,
I am using Tomcat4.1.30 version.
I have to develop a client application which looks in the database every 30
minutes,
to retrieve the status of an order and send the status to the remote client.
Again waits for the
The client's response and insert the repsonse back to the database.
I wanted
Shilpa Nalgonda wrote:
Hi,
I am using Tomcat4.1.30 version.
I have to develop a client application which looks in the database every 30
minutes,
to retrieve the status of an order and send the status to the remote client.
Again waits for the
The client's response and insert the repsonse back to
Hi,
you can use something like HTTPUnit which just calls the web page with your
servlet.
Can can easiliy schedule the HTTPUnit Job, so it runs every 30mins.
Cheers
Bernhard
-Ursprüngliche Nachricht-
Von: Shilpa Nalgonda [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 21. Dezember 2004
+1. you aren't being clear the only reason I can think you have an
application wishing to talk to a servlet is that you are then going on to
request info from the servlet from a remote machine across the net?? .. in that
case and most others you should have your application polling the
Hello, Shilpa,
With Wade, I wonder what you want. Apparently you have a client
making and order and being informed about the status of the order.
You say you have to develop a client application which looks to the
database. Since this is a Tomcat list, that would seem to be a
server
Thanks for the reply...
The application which i am trying to write is a standalone utility.. Client
does not hit this servlet.
Instead my application which is a servlet, will make some database calls--
and if the required data is present in the database, then that data is sent
to the client via
no, and I believe doing so it bad practice. use some OS controlled timer like
cron to issue a HTTP call to your servlet. I once wrote a shell script that
calls a http address on the local machine but cannot remember how ;) if you are
using oracle then you can setup this timer thread inside the
Why are you writing a servlet for this? If the application does not
use any of the services confined to the Servlet API and Tomcat, just
write a stand-alone application and setup up a cron job to run it.
Seems like overkill to me.
On Tue, 21 Dec 2004 16:28:49 -, Allistair Crossley
[EMAIL
On Tue, 2004-12-21 at 11:28, Allistair Crossley wrote:
no, and I believe doing so it bad practice. use some OS controlled timer like
cron to issue a HTTP call to your servlet. I once wrote a shell script that
calls a http address on the local machine but cannot remember how ;) if you
are
I agree. Also You could write a standalone java class which does nothing but
makes a http call to your Servlet. This class can be scheduled to run as a
task every 30 minutes or so.
pandu
From: Allistair Crossley [EMAIL PROTECTED]
Reply-To: Tomcat Users List [EMAIL PROTECTED]
To: Tomcat Users
Laba diena.
Dkojame, kad mums parate.
Js atsista inut isaugota ms duomen bazje.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
My application has to use the connection pooling of Tomcat to talk to the
database...
and all my Database access classes are deployed om Tomcat...so if i just
write a java standalone command line program,
can i access those connection pooling classes...
-Original Message-
From: Billy
of course you can ... look up http://jakarta.apache.org/commons/dbcp/ and
commons-pool or your database's driver may even have an implementation that
supports pooling that you can instantiate directly with the javax.sql or
java.sql api.
cron(30s) --
socket call --
your app
Hi,
I'm having a similar problem in my application.
I've got several servlets called by the users. Every requets save some
information in DB, that has to be sent to another server later and in a
compress format.
So I need sth similar toShilpa is asking, a process which runs every X
minutes to
myself and ben have suggested the most appropriate methods for doing this. Ben
mentions WGET http://www.gnu.org/software/wget/wget.html which can be added to
a *basic* script hooked up to a cron with an interval of whatever you like.
you really ought to get rid of threads and thread sleeps
Use cron in Unix/Linux or task scheduler in Windows.
[EMAIL PROTECTED] 12-21-2004 08:44
Hi,
I am using Tomcat4.1.30 version.
I have to develop a client application which looks in the database
every 30
minutes,
to retrieve the status of an order and send the status to the remote
client.
Again
External scripts really are the best answer for this. It is not
possible to 'PUSH' information like this without a dedicated client!
[EMAIL PROTECTED] 12-21-2004 10:14
Hi,
I'm having a similar problem in my application.
I've got several servlets called by the users. Every requets save some
Why is bad using own threads inside web application?
Aren't all the servlet request actually a thread in Tomcat?
I can't find a reason why it's so bad solution.
In that way, you manage to have a single and independent application.
Maybe I don't know some thread behaviour in Tomcat...
Jorge.
I would say it should be avoided at all if possible using threads. Since as
we know in case of threads, there is not much management you can do. Also in
my experience i have seen it is very easy for them to get out of control .
So if there are any other alternatives, They should be explored
Check out QuartzScheduler from Open Symphony it's easy to configure within
Tomcat.
Fredrik
-Original Message-
From: pandu yelamanchili [mailto:[EMAIL PROTECTED]
Sent: Tuesday, December 21, 2004 9:58 AM
To: [EMAIL PROTECTED]
Subject: Re: How to run servlet for every 30 minutes in
You may user a scheduler to schedule your tasks to run every 30 minutes.
http://www.theserverside.com/blogs/printfriendly.tss?id=QuartzSchedulerInJ2E
E
http://www.quartzscheduler.org/quartz/.
Peiyun
-Original Message-
From: Wade Chandler [mailto:[EMAIL PROTECTED]
Sent: December 21,
You may use a scheduler to schedule your tasks to run every 30 minutes.
http://www.theserverside.com/blogs/printfriendly.tss?id=QuartzSchedulerInJ2E
E
http://www.quartzscheduler.org/quartz/.
Peiyun
-Original Message-
From: Shilpa Nalgonda [mailto:[EMAIL PROTECTED]
Sent: December 21,
You may use a scheduler to schedule your tasks to run every 30 minutes.
http://www.theserverside.com/blogs/printfriendly.tss?id=QuartzSchedulerInJ2E
E
http://www.quartzscheduler.org/quartz/.
Peiyun
-Original Message-
From: Allistair Crossley [mailto:[EMAIL PROTECTED]
Sent: December
Jorge Sopena wrote:
Why is bad using own threads inside web application?
Aren't all the servlet request actually a thread in Tomcat?
I can't find a reason why it's so bad solution.
I think that comes from J2EE specs. I do not remember is threads just
forbidden but if you follow specs, you do not
It is possible to create a servlet thread in the init() method. That
thread sould stay alive and run something every thirty minutes. The
issue of pushing information out to the user remins the same. The
servlet and the thread cannot do that. On the other hand, it is
possible to setup java
I think I saw something like this, but not sure if it works:
servlet
servlet-nameServlet/servlet-name
servlet-classServlet/servlet-class
run-atcron expression?/run-at
load-on-startup1/load-on-startup
/servlet
Peiyun
-Original Message-
At 05:37 PM 12/21/2004, you wrote:
It is possible to create a servlet thread in the init() method. That
thread sould stay alive and run something every thirty minutes. The
issue of pushing information out to the user remins the same. The
servlet and the thread cannot do that. On the other
It's interesting, Craig and I had an exchange about threads in servlet
containers last week... I can't find a link to the thread unfortunately.
Anyway, the basic idea behind that don't spawn your own threads inside
a servlet container admonishment is based more on the fact that it's
quite easy
On Tue, Dec 21, 2004 at 03:37:26PM -0700, Dennis Payne wrote:
: It is possible to create a servlet thread in the init() method. That
: thread sould stay alive and run something every thirty minutes.
Yes and no. ;)
It's possible to use a servlet's init() method for this; but per the
spec,
Your just lending weight to what I said... Don't play with threads in a
servlet contain unless your really sure you have to and are really sure
you can do it safely :)
(I'm not sure I knew init() could be called more than once, certainly I
didn't remember when I wrote that, so excellent point)
Have fun I hope this helps!!! It should.
web-app id='/'
servlet servlet-name='hello'
servlet-class='test.HelloWorld'
load-on-startup/
/servlet
/web-app
The value is a list of 24-hour times when the servlet should be
automatically executed. To run the servlet every 6 hours, you could use:
The alarm is configured as any other servlet, with the addition of the
run-at tag. The following configuration runs the servlet every 15
minutes. If the hour is missing, e.g. :15 the service is run at the
specified minute.
15 minute configuration
servlet name='alarm'
Wow! After reading all of that long thread I got the SDN Editorial Team
newsletter in my inbox. It talks about REVISITING TIMERS WITH ENTERPRISE
BEANS. The link they give is
https://bpcatalog.dev.java.net/nonav/enterprise/timerservice/. This should
at least give some idea of how to do it
Hi,
create a task in your scheduler that calls an URL with your servlet. That's
how we do background processes like sending newsletters etc.
Maarteb
-Oorspronkelijk bericht-
Van: Dennis Payne [mailto:[EMAIL PROTECTED]
Verzonden: Tuesday, December 21, 2004 11:37 PM
Aan: [EMAIL
You can just use the messaging classes in COS.
Jack
On Tue, 21 Dec 2004 16:28:49 -, Allistair Crossley
[EMAIL PROTECTED] wrote:
no, and I believe doing so it bad practice. use some OS controlled timer like
cron to issue a HTTP call to your servlet. I once wrote a shell script that
+1
Jack
On Tue, 21 Dec 2004 10:40:59 -0600, Billy Talton [EMAIL PROTECTED] wrote:
Why are you writing a servlet for this? If the application does not
use any of the services confined to the Servlet API and Tomcat, just
write a stand-alone application and setup up a cron job to run it.
Why don't you guys use something like Lea's multithreading queues?
Jack
On Tue, 21 Dec 2004 18:14:30 +0100, Jorge Sopena [EMAIL PROTECTED] wrote:
Hi,
I'm having a similar problem in my application.
I've got several servlets called by the users. Every requets save some
information in DB,
[OT]Threads and Servlets Question on the struts-user list.
Jack
On Tue, 21 Dec 2004 18:17:40 -0500, Frank W. Zammetti
[EMAIL PROTECTED] wrote:
It's interesting, Craig and I had an exchange about threads in servlet
containers last week... I can't find a link to the thread unfortunately.
53 matches
Mail list logo