php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #2217 Internal Task Scheduler
Submitted: 1999-09-02 09:44 UTC Modified: 1999-09-02 09:56 UTC
From: nikolail at viny dot com Assigned:
Status: Closed Package: Feature/Change Request
PHP Version: 3.0.12 OS: ALL
Private report: No CVE-ID: None
 [1999-09-02 09:44 UTC] nikolail at viny dot com
Some nice feature to add,

I think alot folks would like internal PHP task scheduler,
and abbility to submit tasks from within php code, 
i know you can use cron for that , but to make
it os independent something like that should exists inside of PHP.
It has to be ran as daemon i think 
and php should have set of functions to control it like:

task_id     = 
task_create(PHP script,period,start_datetime,end_datetime);

array tasks = 
tasks_list();
              
task_remove(task_id);

where period could be "WEEKLY"/"DAYLY"/"HOURLY"/"MONTHLY"/"YEARLY"
And could be also some other stuff,
so just using:

task_create("http://www.test.com/tasks/report.php","WEEKLY",time(),NULL);

will submit task to scheduler asking it to execute report.php 
each week("WEEKLY") starting from right now (time()) until cancel (NULL)

Thanks 

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1999-09-02 09:56 UTC] zeev at cvs dot php dot net
This is really way beyond the scope of a web oriented scripting
language (and in my opinion, of any computer language at all).
Cron has been used for years on UNIX systems, Win32 systems have
their own way of scheduling tasks, and any other operating system
out there worth mentioning probably has one as well.

Writing a complete platform-independent task scheduler might be
a worthy project (seems rather hopeless to me) - but it
definitely has nothing to do with PHP.  If&when someone actually
does this, it definitely shouldn't be related to PHP and should
be able to run any executable the operating system supports.

Zeev

 [2004-06-08 21:43 UTC] Johnfontana2003 at yahoo dot com
Why not? Cold Fusion has its own scheduler, it works brilliantly. Why should it need to be able to execute any file, when of course any shared hosting situation would just disable that functionality? I think it's a great idea.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Nov 14 10:01:30 2024 UTC