ns_schedule_proc - Schedule a script to run after a certain number of seconds
This command schedules a script to be run after a certain number of seconds. Returns the ID of the newly scheduled script. If -once is specified, then the script is run once and then unscheduled, otherwise it will continue to run every interval seconds. If -thread is specified, then the script will be run in its own thread, otherwise it will run in the scheduler's thread. If the script is long-running, this may interfere with the running of other scheduled scripts, so long-running scripts should be run in their own threads.
ns_unschedule_proc command unschedules a previous scheduled script. NOTE: Current behavior is to silently return without error if the id doesn't represent a currently scheduled ID.
% set id [[ns_schedule_proc -once 60 { ns_log notice "this should run in 60 seconds" }]] 123
% ns_unschedule_proc $id