From: Matt Sergeant [EMAIL PROTECTED]
On Thu, 15 Feb 2001, Perrin Harkins wrote:
Maybe we should add process scheduling into Apache, and a file system, and
a window manager, and...
Perhaps its the difference between people who've had to write shrink-wrap
apps? The question for me is
On Wed, 14 Feb 2001, Perrin Harkins wrote:
On Wed, 14 Feb 2001, Pierre Phaneuf wrote:
I guess two persons "simpler" aren't always the same: I find it easier
laying out a table and querying it than hacking something to fiddle with
my crontab safely.
As far as I know, crontab -e is
On Thu, 15 Feb 2001, Ask Bjoern Hansen wrote:
On Wed, 14 Feb 2001, Perrin Harkins wrote:
On Wed, 14 Feb 2001, Pierre Phaneuf wrote:
I guess two persons "simpler" aren't always the same: I find it easier
laying out a table and querying it than hacking something to fiddle with
my
Ask Bjoern Hansen wrote:
So: What is the task at hand (more than "run something at certain
intervals" (which is what cron(8) is for)).
I am building a web something-something (I don't know what's the current
buzzword for that, you know, the big integrated things) similar to the
ArsDigita
Ask Bjoern Hansen wrote:
I guess two persons "simpler" aren't always the same: I find it easier
laying out a table and querying it than hacking something to fiddle with
my crontab safely.
As far as I know, crontab -e is perfectly safe.
"crontab -l | foo" and "foo | crontab -" are
Matt Sergeant wrote:
as for putting cron into Apache: I don't understand why that's wanted
in the first place. When connecting to the database outside the httpd
it doesn't matter if it goes a little slow. And having separate
programs to do the maintenance would easily be much simpler
On Thu, 15 Feb 2001, Pierre Phaneuf wrote:
Ask Bjoern Hansen wrote:
I guess two persons "simpler" aren't always the same: I find it easier
laying out a table and querying it than hacking something to fiddle with
my crontab safely.
As far as I know, crontab -e is perfectly
On Thu, Feb 15, 2001 at 09:04:43AM -0500, Pierre Phaneuf wrote:
Apache::Schedule let you register callbacks (per Apache child process)
that will be called after a given amount of time has passed, either once
or repeatedly. Callbacks will be called at the next request after the
required
Stas Bekman wrote:
I might be barking at the wrong tree, but why cron? Why don't you use
at(1). you don't need to parse crontab for that, and you can spawn
processes with whatever intervals on demand. basically you can call
at(1) itself at the end of at() so you can do the same as crontab.
Tim Bunce wrote:
Apache::Schedule let you register callbacks (per Apache child process)
that will be called after a given amount of time has passed, either once
or repeatedly. Callbacks will be called at the next request after the
required time, or at child exit time.
Would it work
"PP" == Pierre Phaneuf [EMAIL PROTECTED] writes:
As far as I know, crontab -e is perfectly safe.
"crontab -l | foo" and "foo | crontab -" are your friends.
PP Ah yes. The problem with this is between the "crontab -l" and the
PP "crontab -". You have to parse the crontab, find your own
On Thu, 15 Feb 2001, Stas Bekman wrote:
I might be barking at the wrong tree, but why cron? Why don't you use
at(1).
And there's a CPAN module for it: Schedule::At. It claims to be
cross-platform, and I believe NT has a version of at(1).
- Perrin
Vivek Khera wrote:
PP Ah yes. The problem with this is between the "crontab -l" and the
PP "crontab -". You have to parse the crontab, find your own entry without
Very limited thinking going on here. The crontab program honors the
EDITOR environment variable. Now... setenv
On Thu, 15 Feb 2001, Matt Sergeant wrote:
Its just a convenience thing. I've wanted to be able to do this too, for
example to have emails go off at a particular interval. So yes, it can be
done as cron + URI, but I'm just jealous of AOLServer's ability to do it
all in one. This is especially
"PP" == Pierre Phaneuf [EMAIL PROTECTED] writes:
With appropriate Perl modules for the cron files, this should be
trivial. But then, you probably aren't doing this from mod_perl...
PP Well, yes, why? :-)
You really want to have your web server writing files that execute
arbitrary programs
On Thu, 15 Feb 2001, Perrin Harkins wrote:
Maybe we should add process scheduling into Apache, and a file system, and
a window manager, and...
:-)
Okay, I'm being silly, and there are times when duplication is necessary,
but cron is such a well-established way of solving this problem that
be simply an Apache::Cron module or something like that, to
ease the task of add/modifying/removing cron jobs from mod_perl, I
agree.
--
"As usual, this being a 1.3.x release, I haven't even compiled this
kernel yet. So if it works, you should be doubly impressed."
-- Linus Torvalds
Vivek Khera wrote:
With appropriate Perl modules for the cron files, this should be
trivial. But then, you probably aren't doing this from mod_perl...
PP Well, yes, why? :-)
You really want to have your web server writing files that execute
arbitrary programs at arbitrary times?
Perrin Harkins wrote:
Well, if I call the "check for things to do" URI every minute, then I'll
be just fine. Many times, I'll just check and find nothing to do
Huh? Why would you call it if there's nothing to do? Are you thinking
you'll write a cron-ish task/timing spec for your Perl
Huh? Why would you call it if there's nothing to do? Are you thinking
you'll write a cron-ish task/timing spec for your Perl app and just use
the cron triggers as a constant clock?
Yes, exactly. My plan is to have a table with the tasks in my database,
and check expired tasks in a
Perrin Harkins wrote:
Yes, exactly. My plan is to have a table with the tasks in my database,
and check expired tasks in a cleanup handler. I'll have to lock the
table, so that only one process does that. I'll also query the database
only every so often, not at every request cleanup.
Perrin Harkins wrote:
Sure, but why waste resources?
Because it's easy? :-)
As for the simplicity, having multiple individual custom cron jobs is
simpler than one single generic cron job?
Yes, much simpler, at least for the scheduling and dispatching part.
Instead of designing
On Wed, 14 Feb 2001, Pierre Phaneuf wrote:
I guess two persons "simpler" aren't always the same: I find it easier
laying out a table and querying it than hacking something to fiddle with
my crontab safely.
As far as I know, crontab -e is perfectly safe.
- Perrin
Perhaps I've missed something, but in all this discussion no one has
asked what it is you're trying to do. All I know is that you want to
schedule something in a database and then check that database every
minute (or so) and process the scheduled somethings.
Generally speaking, 'at' is the
Is there a way to have a Perl function called at some point in time,
like I think AOLserver can do in Tcl (but I don't want to do either
AOLserver or Tcl!)?
I thought about checking the time in a PerlCleanupHandler, but this
would be in each Apache subprocess and I want this to get called only
On Tue, 13 Feb 2001, Pierre Phaneuf wrote:
Is there a way to have a Perl function called at some point in time,
like I think AOLserver can do in Tcl (but I don't want to do either
AOLserver or Tcl!)?
I thought about checking the time in a PerlCleanupHandler, but this
would be in each
"PP" == Pierre Phaneuf [EMAIL PROTECTED] writes:
PP Is there a way to have a Perl function called at some point in time,
PP like I think AOLserver can do in Tcl (but I don't want to do either
PP AOLserver or Tcl!)?
Set up a handler and have a cron job "GET" the URL for it.
You already have
Is there a way to have a Perl function called at some point in time,
like I think AOLserver can do in Tcl (but I don't want to do either
AOLserver or Tcl!)?
I thought about checking the time in a PerlCleanupHandler, but this
would be in each Apache subprocess and I want this to get
On Tue, 13 Feb 2001, Pierre Phaneuf wrote:
Matt Sergeant wrote:
Pretty much what you've already found out - Apache has no "cron" like
daemon. One way you can do it is fork off a sub-process and run some sort
of Cron perl module (I think there's a Cron module on CPAN, or you can run
Matt Sergeant wrote:
Isn't forking off from Apache rather nasty? I saw something to that
effect somewhere in the eagle book and on some web pages, but I think
there are ways to do that without causing problems.
Yes, its a pain. I suggest using the ways detailed below. My only problem
On Tue, 13 Feb 2001, Pierre Phaneuf wrote:
Well, if I call the "check for things to do" URI every minute, then I'll
be just fine. Many times, I'll just check and find nothing to do
Huh? Why would you call it if there's nothing to do? Are you thinking
you'll write a cron-ish task/timing spec
31 matches
Mail list logo