[request-tracker-maintainers] Bug#594982: Bug#594982: Bug#594982: rt3.8-clients: no way to manage watchers of queues

Tollef Fog Heen tfheen at debian.org
Wed Sep 1 19:02:32 UTC 2010


]] Dominic Hargreaves 

| On Wed, Sep 01, 2010 at 07:47:50AM +0200, Tollef Fog Heen wrote:
| > ]] Dominic Hargreaves 
| 
| > | Either way, I'm fairly sure that this would be considered an enhancement
| > | rather than defect by upstream (the REST interface doesn't really cover
| > | administration, just day to day operation), so setting severity accordingly.
| > 
| > It would be really useful if all functionality in RT is exposed through
| > the REST interface.  I guess that might be a fairly significant effort,
| > though. :-)
| > 
| > Until then, it would be useful if the limitations are documented, and if
| > possible, what workarounds are available.
| 
| Sure. Just for completeness here, then, before I have a chance to write
| some documentation: The RT native perl API is pretty usable once you get
| used to it, but unfortunately isn't that well documented. Have a browse
| through the core code to get a feel for the object model and calling
| API. It's actually on my todo list at work to automate queue creation in
| a similar way :)

I guess I could do it that way.

Another annoying thing is that rt(1) exits 0 even when operations fail,
leading me to have chef recipes that do:

  execute "create queue" do
    command "rt create -t queue set name='#{queue}' set CorrespondAddress=#{queue}@#{node[:domain]} set CommentAddress=#{queue}-comment@#{node[:domain]}"
    environment({ "RTCONFIG" => "/etc/request-tracker3.8/rt_root.conf" })
    not_if "rt show queue/#{queue} | grep -q '^Name: #{queue}$'", :environment => { "RTCONFIG" => "/etc/request-tracker3.8/rt_root.conf" }
  end

  execute "verify queue existence" do
    command "rt show queue/#{queue} | grep -q '^Name: #{queue}$'"
    environment({ "RTCONFIG" => "/etc/request-tracker3.8/rt_root.conf" })
  end

which is a bit silly.

Do you want a separate bug report for that?

| Obviously this only works if you are in a position to run code with the
| same database access as the RT application server itself.

In this case, I'm running stuff as root on the machine where RT is
installed, so that bit is easy enough.

-- 
Tollef Fog Heen
UNIX is user friendly, it's just picky about who its friends are





More information about the pkg-request-tracker-maintainers mailing list