[MOBY-guts] biomoby commit

Mark Wilkinson mwilkinson at pub.open-bio.org
Tue Jun 15 01:00:26 UTC 2004


mwilkinson
Mon Jun 14 21:00:26 EDT 2004
Update of /home/repository/moby/moby-live/Perl/MOBY
In directory pub.open-bio.org:/tmp/cvs-serv12372/MOBY

Modified Files:
	Central.pm OntologyServer.pm central_db_connection.pm 
Log Message:
a few bugfixes for undeclared variables etc

moby-live/Perl/MOBY Central.pm,1.128,1.129 OntologyServer.pm,1.42,1.43 central_db_connection.pm,1.3,1.4
===================================================================
RCS file: /home/repository/moby/moby-live/Perl/MOBY/Central.pm,v
retrieving revision 1.128
retrieving revision 1.129
diff -u -r1.128 -r1.129
--- /home/repository/moby/moby-live/Perl/MOBY/Central.pm	2004/06/15 00:09:36	1.128
+++ /home/repository/moby/moby-live/Perl/MOBY/Central.pm	2004/06/15 01:00:26	1.129
@@ -182,11 +182,11 @@
 
     my $conf = MOBY::Config->new;
 
-    $username = $conf->{mobycentral}->{username};
-    $password = $conf->{mobycentral}->{password};
-    $port = $conf->{mobycentral}->{port};
-    $dbname = $conf->{mobycentral}->{dbname};
-    $url = $conf->{mobycentral}->{url};
+    my $username = $conf->{mobycentral}->{username};
+    my $password = $conf->{mobycentral}->{password};
+    my $port = $conf->{mobycentral}->{port};
+    my $dbname = $conf->{mobycentral}->{dbname};
+    my $url = $conf->{mobycentral}->{url};
     
 	#my $url = $ENV{MOBY_CENTRAL_URL}; chomp $url;
 	#my $dbname = $ENV{MOBY_CENTRAL_DBNAME}; chomp $dbname;

===================================================================
RCS file: /home/repository/moby/moby-live/Perl/MOBY/OntologyServer.pm,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -r1.42 -r1.43
--- /home/repository/moby/moby-live/Perl/MOBY/OntologyServer.pm	2004/06/15 00:22:05	1.42
+++ /home/repository/moby/moby-live/Perl/MOBY/OntologyServer.pm	2004/06/15 01:00:26	1.43
@@ -142,11 +142,10 @@
 
 	
 	my $conf = MOBY::Config->new;
-	$self->username = $conf->{$self->database}->{username} unless $self->username;
-    $self->password = $conf->{$self->database}->{password} unless $self->password;
-    $self->port = $conf->{$self->database}->{port} unless $self->port;
-    $self->dbname = $self->database unless $self->dbname;
-    $self->host = $conf->{$self->database}->{url} unless $self->host;
+	$self->username($conf->{$self->database}->{username}) unless $self->username;
+    $self->password($conf->{$self->database}->{password}) unless $self->password;
+    $self->port($conf->{$self->database}->{port}) unless $self->port;
+    $self->host($conf->{$self->database}->{url}) unless $self->host;
  
 	my $host = $self->host?$self->host:$ENV{MOBY_CENTRAL_URL}; chomp $host;
 	my $username = $self->username?$self->username:$ENV{MOBY_CENTRAL_DBUSER}; chomp $username;

===================================================================
RCS file: /home/repository/moby/moby-live/Perl/MOBY/central_db_connection.pm,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- /home/repository/moby/moby-live/Perl/MOBY/central_db_connection.pm	2004/06/15 00:37:55	1.3
+++ /home/repository/moby/moby-live/Perl/MOBY/central_db_connection.pm	2004/06/15 01:00:26	1.4
@@ -119,40 +119,17 @@
 
     my $conf = MOBY::Config->new;
 
-    $username = $conf->{mobycentral}->{username};
-    $password = $conf->{mobycentral}->{password};
-    $port = $conf->{mobycentral}->{port};
-    $dbname = $conf->{mobycentral}->{dbname};
-    $url = $conf->{mobycentral}->{url};
-    
-	#my $url = $ENV{MOBY_CENTRAL_URL}; chomp $url;
-	#my $dbname = $ENV{MOBY_CENTRAL_DBNAME}; chomp $dbname;
-	#my $username = $ENV{MOBY_CENTRAL_DBUSER}; chomp $username;
-	#my $password = $ENV{MOBY_CENTRAL_DBPASS}; chomp $password;
-	#my $port = $ENV{MOBY_CENTRAL_DBPORT}; chomp $port;
-	
+    my $username = $conf->{mobycentral}->{username};
+    my $password = $conf->{mobycentral}->{password};
+    my $port = $conf->{mobycentral}->{port};
+    my $dbname = $conf->{mobycentral}->{dbname};
+    my $url = $conf->{mobycentral}->{url};
+    	
 	my ($dsn) = "DBI:mysql:$dbname:$url:$port";
 	my $dbh = DBI->connect($dsn, $username, $password, {RaiseError => 1}) or die "can't connect to database";
 	
-	return ($dbh);
-
-	my $host = $ENV{MOBY_CENTRAL_URL}; chomp $host;
-	my $dbname = $ENV{MOBY_CENTRAL_DBNAME}; chomp $dbname;
-	my $username = $ENV{MOBY_CENTRAL_DBUSER}; chomp $username;
-	my $password = $ENV{MOBY_CENTRAL_DBPASS}; chomp $password;
-    my $port = $ENV{MOBY_CENTRAL_DBPORT}; chomp $port;
-    
-    #my $dbname = $self->dbname;
-    #my $host = $self->host;
-    #my $port = $self->port;
-    #my $username = $self->username;
-    #my $password = $self->password;
-    my ($dsn) = "DBI:mysql:$dbname:$host:$port";
-
-    my $dbh = DBI->connect($dsn, $username, $password, {RaiseError => 1}) or die "can't connect to database";
-
     $self->dbh($dbh);
-    return $self;
+	return $self;
 
 }
 




More information about the MOBY-guts mailing list