Excepting certain queues from global scrips (my solution)

So, after searching for ways to accomplish this, and seeing it is a common feature request (sometimes termed “disable notifications for specific queues”), with some existing solutions that accomplish it but weren’t quite what I was looking for, I decided to write my own. It is implemented as custom condition Perl modules (installed under $RTHOME/local/lib/RT/Condition).

After installation you get new conditions to use in your scrips like “On Correspond (w/queue exceptions)”. The queue exception list is set in your RT_SiteConfig. You can have a mixture of “truly global” and “global with exceptions” scrips by changing which condition they use.

I don’t claim to be a Perl hacker so I’m sure there are some things that could be done better, but this works for me, at least with RT 4.0.1. Perhaps someone with better knowledge could explain why in my StatusChangeQueueExcept module I had to instantiate the other checks field-by-field instead of just passing $self.

Attached is my README and the tarball, which I hope makes it through to the list. It is not yet packaged as an extension or plugin; I might do so if there is demand and I receive guidance as to which, if either, is appropriate.

Andrew Daugherity
Systems Analyst
Division of Research, Texas A&M University
adaugherity@tamu.edu

ATT00001.txt (2 Bytes)

README (4.71 KB)

RT-Queue-Exceptions.tar.gz (2.93 KB)

Hi all,

I can only support this feature request. All other methods seem
unsatisfactory to me atm. The proposed changes from Andrew make sense to
me, altough I had not time to review and test the code.

I can only encourage the coding team to interate such a feature.

Have a nice weekend,
LROn 08.08.2011 23:27, Daugherity, Andrew W wrote:

So, after searching for ways to accomplish this, and seeing it is a common feature request (sometimes termed “disable notifications for specific queues”), with some existing solutions that accomplish it but weren’t quite what I was looking for, I decided to write my own. It is implemented as custom condition Perl modules (installed under $RTHOME/local/lib/RT/Condition).

After installation you get new conditions to use in your scrips like “On Correspond (w/queue exceptions)”. The queue exception list is set in your RT_SiteConfig. You can have a mixture of “truly global” and “global with exceptions” scrips by changing which condition they use.

I don’t claim to be a Perl hacker so I’m sure there are some things that could be done better, but this works for me, at least with RT 4.0.1. Perhaps someone with better knowledge could explain why in my StatusChangeQueueExcept module I had to instantiate the other checks field-by-field instead of just passing $self.

Attached is my README and the tarball, which I hope makes it through to the list. It is not yet packaged as an extension or plugin; I might do so if there is demand and I receive guidance as to which, if either, is appropriate.

Andrew Daugherity
Systems Analyst
Division of Research, Texas A&M University
adaugherity@tamu.edu


2011 Training: http://bestpractical.com/services/training.html