[MOBY-guts] biomoby commit
Eddie Kawas
kawas at dev.open-bio.org
Tue Oct 17 14:00:53 UTC 2006
kawas
Tue Oct 17 10:00:53 EDT 2006
Update of /home/repository/moby/moby-live/Perl/MOBY
In directory dev.open-bio.org:/tmp/cvs-serv19977
Modified Files:
Central.pm
Log Message:
added code that removes the hard coded URL from this module and replaces it with a property that is obtained from mobycentral.config.
The property and value are:
rdf_generator = http://mobycentral.icapture.ubc.ca/authority/RDFGenerator
However, if you have a custom registry and you have installed the 'registry servlets', then use your own url as per the configuration documentation for the servlets.
moby-live/Perl/MOBY Central.pm,1.261,1.262
===================================================================
RCS file: /home/repository/moby/moby-live/Perl/MOBY/Central.pm,v
retrieving revision 1.261
retrieving revision 1.262
diff -u -r1.261 -r1.262
--- /home/repository/moby/moby-live/Perl/MOBY/Central.pm 2006/10/12 14:01:14 1.261
+++ /home/repository/moby/moby-live/Perl/MOBY/Central.pm 2006/10/17 14:00:53 1.262
@@ -1439,7 +1439,9 @@
sub _getServiceInstanceRDF {
my ( %args ) = @_;
my $browser = LWP::UserAgent->new;
- my $url = URI->new( 'http://mobycentral.icapture.ubc.ca/authority/RDFGenerator' );
+ my $conf = MOBY::Config->new();
+ return "" unless $conf->{mobycentral}->{rdf_generator};
+ my $url = URI->new( $conf->{mobycentral}->{rdf_generator} );
# makes an object representing the URL
$url->query_form( # And here the form data pairs:
'name' => $args{name},
@@ -1447,7 +1449,6 @@
'url' => $args{url},
'uri' => $args{uri}
);
-
my $response = $browser->get($url);
if ($response) {
my $rdfXML = $response->content;
More information about the MOBY-guts
mailing list