[rt-commit] CVS commit: rt

Tobias Brox tobiasb at tobiasb.funcom.com
Wed Mar 22 13:42:10 EST 2000


> > And why do you think it's better to bind users to Templates
> > instead of Scrips?  Well, I can see the reason when the user should be
> > Bcc'ed/Cc'ed ... but except for that, templates must be a lot less
> > flexible than Scrips?
> >
> 
> Right. I actually want to significantly limit what interested parties can 
> set themselves up to recieve.

When thinking, maybe it won't be right to bind a Watcher to a specific
entry in the Scrips table.  But I don't think it makes more sense binding
it to a specific entry in the Template table!  Besides it's a bit
confusing; would it mean that this template always should be sent to the
watcher when something happens, or does it mean that the watcher should
only get emails when the template is invoked?

Maybe we need to rethink the whole concept of Watchers, Scrips, Actions 
and Templates.  At least I think we need to define them better.  I can see
problems to the current approach.


What is an Action?

...some piece of code that can do something whenever a transaction is
done.  The actions shipped with RT sends email.  Eventually site-specific
modules can be dropped in to perform special actions.


What can an Action do?

- decide whether it's applicable or not
- prepare
- commit
- describe itself

...and if it's a subclass of SendEmail, you can also override:

- SetReceipients


What is a Scrip?

...it's an entry in the database that tells that an action is to be
performed with a certain template and argument.  It can be limited by
queue and transaction type.  It has a name and a description.


What is a Watcher?

...it's a request for beeing kept updated on a ticket and/or a queue
and/or whatever.  It is to be used by the Actions.  Watcher items can
easily be enabled/disabled through the `Quiet' attribute.  `Type' might
indicate what emails the watcher wants to get and how to get them.


What is a Template?

...A template is a text template that is to be used for outgoing email -
or for different use for different actions.  One template can be used by
several Scrips.


How do I subscribe to all correspondence of queue A?

...add an entry to the Watchers table.

/* Here we do have a problem.  The Templates doesn't relate to the queues
in any way.  What if we have 5-6 basic templates and all of them are
translated into 5 different languages?  It would be utterly stupid to give
the web user 30 choises, where only some few of them applies to the actual
queue.  We might check up the scrips, and ask them what queues are related
to what templates ... but I think it's sort of the wrong way to do it
anyway.  And what if we use the same template for several Scrips?  I can
agree that there would be something of the same issues if binding watchers
to scrips (or even actions) as the actions contain logic for
deciding who should get mail and who shouldn't.  It seems that whatever we
do here, we will fail.

I suggest a third option; let it be possible to subscribe to specific 
transaction types. */


I'm owning some requests, but I really don't want to get mail about every
transaction - how do I turn it off?

...sorry, you can't.

/* what about moving owner to the watchers table? */


We have the installed the package with all the defaults, and added some
ten queues.  We don't want AutoReply at the last queue we set up, how do
we turn it off?

...by replacing Scrip 1 with one Scrip for each queue except the last one.

/* This is not a good way to do it.  I think we can avoid it with my
idea about priorities */


I'm subscribing to queue 2, but I don't want to receive activity on ticket
#456.  Can I turn it off?

No.

/* What about letting one Quiet Watcher item turn off an active watcher
item? */






More information about the Rt-commit mailing list