Stall Until

I am now happily running RT 2.0.15 (was 1.0.6 only last week), and now I am
ready to embark on making a few changes.

At my last shop, using Remedy, we were able to add a state called "blocked"
and a field called “Freeze until”. One would block a ticket when one was
waiting for something external – a call back, a package to arrive – and
set the date. It would then automatically re-open on that date so it
would appear in your list again. (Did he ever call back? Did the package
arrive?)

I want to add this to RT. status=stalled is already there. All I need is
"stall until". I can probably figure out the external cron job that does a
query and moves things back to open (though I’d like to have this trigger a
Scrip if possible).

Can one of y’all give me the easy-'n-obvious (to you) edits I need to make?

(A further refinement would be to stall until a dependency is satisfied,
i.e. a ticket in “Depends on” moves to a defined state, such as closed, or
something else happens to it. Today’s example: change out this router
[ticket A] during the next downtime [ticket B]. Or can I already do this
with Scrips? I have yet to dive into Scrips.)

Jim Hickstein wrote:

I want to add this to RT. status=stalled is already there. All I need is
“stall until”. I can probably figure out the external cron job that does a
query and moves things back to open (though I’d like to have this trigger a
Scrip if possible).

“escalator” from http://www.fsck.com/pub/rt/contrib/2.0/rt-addons/
is an example of how to get a cron job to fire off a scrip.
The EscalatePriority scrip that it uses shows you how to pull
the Due Date from the ticket; use either that or the “Starts”
field ($ticket->StartsObj) to designate the time to open.
Put that together with a check for "stalled’ and a SetStatus
call and you’re done. :slight_smile:

(A further refinement would be to stall until a dependency is satisfied,
i.e. a ticket in “Depends on” moves to a defined state, such as closed, or
something else happens to it. Today’s example: change out this router
[ticket A] during the next downtime [ticket B]. Or can I already do this
with Scrips? I have yet to dive into Scrips.)

You can do that with Scrips. Look at OpenDependent, it’s part of
the standard RT distribution. CloseDependent is an easy tweak;
SetDependentStatus wouldn’t be hard using $self->Argument either,
if you wanted to genericise.

Have fun!
Phil Homewood, Systems Janitor, www.SnapGear.com
pdh@snapgear.com Ph: +61 7 3435 2810 Fx: +61 7 3891 3630
SnapGear - Custom Embedded Solutions and Security Appliances

“escalator” from http://www.fsck.com/pub/rt/contrib/2.0/rt-addons/
is an example of how to get a cron job to fire off a scrip.
The EscalatePriority scrip that it uses shows you how to pull
the Due Date from the ticket; use either that or the “Starts”
field ($ticket->StartsObj) to designate the time to open.

Oh! I hadn’t thought about “Starts”. That may well do. Thanks!

“escalator” from http://www.fsck.com/pub/rt/contrib/2.0/rt-addons/
is an example of how to get a cron job to fire off a scrip.
The EscalatePriority scrip that it uses shows you how to pull
the Due Date from the ticket; use either that or the “Starts”
field ($ticket->StartsObj) to designate the time to open.

Oh! I hadn’t thought about “Starts”. That may well do. Thanks!

I implemented this a while ago; I can’t remember if I got round to
posting my solution or not, so it’s attached. This is a script that’s
cronned every so often.

(feel free to add to contrib section or whatever)

One caveat though; it depends on the Starts field being correct. If you
set it to the past, or do anything else on the ticket, then it may not
work. I recently found one ticket that had the year 2002 by accident,
and it had not unstalled.

Robie.
Robie Basak robie@principle.co.uk
Northern Principle Limited

rt-autostart (2.49 KB)