[MOBY-guts] biomoby commit
Mark Wilkinson
mwilkinson at pub.open-bio.org
Fri Jul 30 00:40:09 UTC 2004
mwilkinson
Thu Jul 29 20:40:09 EDT 2004
Update of /home/repository/moby/moby-live/Perl/MOBY
In directory pub.open-bio.org:/tmp/cvs-serv21862/MOBY
Modified Files:
Central.pm service_instance.pm
Log Message:
deprecating the deregisterService routine... kinda... it still works, but only if the service was registered without a signatureURL
moby-live/Perl/MOBY Central.pm,1.136,1.137 service_instance.pm,1.7,1.8
===================================================================
RCS file: /home/repository/moby/moby-live/Perl/MOBY/Central.pm,v
retrieving revision 1.136
retrieving revision 1.137
diff -u -r1.136 -r1.137
--- /home/repository/moby/moby-live/Perl/MOBY/Central.pm 2004/07/30 00:07:18 1.136
+++ /home/repository/moby/moby-live/Perl/MOBY/Central.pm 2004/07/30 00:40:09 1.137
@@ -1087,7 +1087,7 @@
my $error;
$error .="missing serviceName \n" unless defined $serviceName;
$error .="missing serviceType \n" unless defined $serviceType;
- $error .="missing signatureURL \n" unless defined $signatureURL;
+# $error .="missing signatureURL \n" unless defined $signatureURL;
$error .="missing authURI \n" unless defined $AuthURI;
$error .="missing contactEmail \n" unless defined $contactEmail;
return &_error("Malformed authURI - must not have an http:// prefix","") if $AuthURI =~ '[/:]';
@@ -1431,9 +1431,12 @@
return &_error("The service specified by authority=$authURI servicename=$serviceName does not exist in the registry", "") unless (MOBY::service_instance->new(servicename => $serviceName, authority_uri => $authURI, test => 1));
my $SERVICE = MOBY::service_instance->new(servicename => $serviceName, authority_uri => $authURI);
- my $result = $SERVICE->DELETE_THYSELF;
-
- if ($result){
+ if ($SERVICE->signatureURL){
+ return &_error("it is illegal to register a service that has a signatureURL. Such services must be deregistered by deleting the RDF at the location identified by the signatureURL","");
+ }
+
+ my $result = $SERVICE->DELETE_THYSELF;
+ if ($result){
return &_success("Service Deregistered Successfully","");
} else {
return &_error("Service deletion failed for unknown reasons","");
===================================================================
RCS file: /home/repository/moby/moby-live/Perl/MOBY/service_instance.pm,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- /home/repository/moby/moby-live/Perl/MOBY/service_instance.pm 2004/07/30 00:07:18 1.7
+++ /home/repository/moby/moby-live/Perl/MOBY/service_instance.pm 2004/07/30 00:40:09 1.8
@@ -231,6 +231,8 @@
$self->contact_email($existing_service->{'email'});
$self->description($existing_service->{'desc'});
$self->authority($existing_service->{'authURI'});
+ $self->signatureURL($existing_service->{'signatureURL'});
+
$self->{__exists__} = 1; # this service already existed
} elsif (!($existing_service) # if it doesn't exist
&& (defined $self->category) # and you have given me things I need to create it
More information about the MOBY-guts
mailing list