[rt-devel] More SOAP

Jesse jesse at fsck.com
Fri Mar 16 18:04:03 EST 2001


have you required RT::Ticket and done all the RTInit stuff, that, for example, the 
CLI or web ui or mail gateway do?


On Fri, Mar 16, 2001 at 05:55:17PM -0500, David Sarno wrote:
> Hi.  I'm using RT 1.3.49.01 and attempting to build a SOAP system to wrap
> around some of the RT commands.  The first thing I'm trying to do is to
> create a ticket.  I'm using SOAP to directly call the Ticket->Create()
> method, and passing it the required hash of arguments.  The following
> client code faults with an error saying that it can't find the Method
> 'Load' in RT::User.  Does this strike anyone as an obvious misuse of the
> object/method syntax?  The modules are all in /home/rt/lib/RT, but I don't
> think I'm telling the compiler where to find them correctly. Sorry for
> asking about such a little problem
> 
> ****
> #!/usr/bin/perl -w
> 
> use SOAP::Lite;
> use lib '/home/rt/lib';
> use diagnostics;
> 
> my %args = (id => 1,
>                 Queue => "testqueue",
>                 Requestor => undef,
>                 RequestorEmail => undef,
>                 Type => 'ticket',
>                 Owner => RT::User->Load('das56'),  # ***Problem Line***
>                 Subject => '[no subject]',
>                 InitialPriority => "0",
>                 FinalPriority => "0",
>                 Status => 'new',
>                 TimeWorked => "0",
>                 Due => "0",
>             MIMEObj => undef);
> 
> my $s = SOAP::Lite
>    ->uri('RT/Ticket')
>    ->proxy('http://irref.mine.nu/user/das56/soap/serv.cgi')
>    ->on_debug(sub{print STDERR @_})
>    ->Create(%args);
> 
> print $s->result();
> ***
> 
> Secondarily, I'm an undergrad compsci major and part of my senior project
> (building an update mechanism for a library database) is figuring out how to
> interface a database and RT using SOAP.  I'm trying to figure out the
> cleanest possible way of creating a SOAP wrapper around a few of the key RT
> functions.  If the bare-bones way that I've tried above strikes anyone as
> right or wrong, I'd really like to hear your ideas.  I'm not an expert
> hacker, so I'm trying to figure out a fairly simple yet functional way to
> build this stuff.  Someone suggested simply creating a soap client that made
> system calls to the CLI, but I'm concerned about security issues that might
> go along with it.
> 
> Thanks very much.
> 
> --dave
> 
> 
> _______________________________________________
> Rt-devel mailing list
> Rt-devel at lists.fsck.com
> http://lists.fsck.com/mailman/listinfo/rt-devel
> 

-- 
jesse reed vincent -- root at eruditorum.org -- jesse at fsck.com 
70EBAC90: 2A07 FC22 7DB4 42C1 9D71 0108 41A3 3FB3 70EB AC90

And I'm told we do share some common rituals. Our "flame war" is apparently 
held in person in their land and called "project meeting".
					-Alan Cox [on "Suits"]




More information about the Rt-devel mailing list