Package: debbugs
Severity: wishlist
Tags: patch

Please find in attachment a patch that implements a basic infrastructure
to add SOAP support to the BTS.

I need that to get usertag data, so I implemented this first function but
it's really easy to add new functions available over SOAP.

You'll have to install libsoap-lite-perl.

I would really appreciate that you put this patch live on the real BTS since
the summer of code project of my student needs that...

Strictly speaking parts of the patch can be dropped, I simply modified the
various CGI to be able to find the Debbugs module somewhere else than
/usr/share/perl5 ... I think it's a useful addition so I left that in the
patch.

The patch is against the mainline bzr branch of the BTS.
If I must update the patch so that it applies on another branch, please
tell me.

Here's the script that I used to test the SOAP interface.
You'll have to update the URL of course.

#!/usr/bin/perl

use lib '/home/rhertzog-deb/partages/debian/bzr/debbugs/';

use SOAP::Lite;
use Data::Dumper;

my $soap = SOAP::Lite
    -> uri('/Usertag')
    -> proxy('http://debbugs:8080/cgi-bin/soap.cgi');

my $result = $soap->get_usertag("[EMAIL PROTECTED]", "policy");

unless ($result->fault) {
    print Data::Dumper->Dump([$result->result()]);
} else {
    print join ', ',
      $result->faultcode,
      $result->faultstring;
}


Cheers,

-- System Information:
Debian Release: testing/unstable
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'unstable')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.15-1-686
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)

Attachment: soap.patch
Description: application/awk

Attachment: test.pl
Description: Perl program

Reply via email to