[interchange-cvs] interchange - heins modified 2 files
interchange-cvs at icdevgroup.org
interchange-cvs at icdevgroup.org
Sat Jun 5 14:21:07 EDT 2004
User: heins
Date: 2004-06-05 18:21:06 GMT
Modified: lib/Vend Config.pm
Modified: lib/Vend/Table DBI.pm
Log:
* Add directive DatabaseAutoIgnore which prevents DatabaseAuto
bringing in tables matching its regex.
DatabaseAutoIgnore ^sql_
DatabaseAuto dbi:Pg:dbname=foo someuser
This prevents trying to bring in the new tables that get auto-added
to ever PostgreSQL 7.4 schema; they were causing errors.
Must be set before DatabaseAuto.
Revision Changes Path
2.141 +4 -3 interchange/lib/Vend/Config.pm
rev 2.141, prev_rev 2.140
Index: Config.pm
===================================================================
RCS file: /var/cvs/interchange/lib/Vend/Config.pm,v
retrieving revision 2.140
retrieving revision 2.141
diff -u -r2.140 -r2.141
--- Config.pm 30 Apr 2004 20:09:38 -0000 2.140
+++ Config.pm 5 Jun 2004 18:21:06 -0000 2.141
@@ -1,6 +1,6 @@
# Vend::Config - Configure Interchange
#
-# $Id: Config.pm,v 2.140 2004/04/30 20:09:38 mheins Exp $
+# $Id: Config.pm,v 2.141 2004/06/05 18:21:06 mheins Exp $
#
# Copyright (C) 2002-2003 Interchange Development Group
# Copyright (C) 1996-2002 Red Hat, Inc.
@@ -48,7 +48,7 @@
use Vend::File;
use Vend::Data;
-$VERSION = substr(q$Revision: 2.140 $, 10);
+$VERSION = substr(q$Revision: 2.141 $, 10);
my %CDname;
my %CPname;
@@ -392,7 +392,7 @@
['Message', 'message', ''],
['Variable', 'variable', ''],
['VarName', 'varname', ''],
- ['Limit', 'hash', 'option_list 5000 chained_cost_levels 32'],
+ ['Limit', 'hash', 'option_list 5000 chained_cost_levels 32 robot_expire 1'],
['ScratchDefault', 'hash', ''],
['Profile', 'locale', ''],
['ValuesDefault', 'hash', ''],
@@ -424,6 +424,7 @@
['SessionLockFile', undef, 'etc/session.lock'],
['DatabaseDefault', 'hash', ''],
['DatabaseAuto', 'dbauto', ''],
+ ['DatabaseAutoIgnore', 'regex', ''],
['Database', 'database', ''],
['Autoload', undef, ''],
['AutoEnd', undef, ''],
2.60 +13 -2 interchange/lib/Vend/Table/DBI.pm
rev 2.60, prev_rev 2.59
Index: DBI.pm
===================================================================
RCS file: /var/cvs/interchange/lib/Vend/Table/DBI.pm,v
retrieving revision 2.59
retrieving revision 2.60
diff -u -r2.59 -r2.60
--- DBI.pm 11 Apr 2004 18:18:43 -0000 2.59
+++ DBI.pm 5 Jun 2004 18:21:06 -0000 2.60
@@ -1,6 +1,6 @@
# Vend::Table::DBI - Access a table stored in an DBI/DBD database
#
-# $Id: DBI.pm,v 2.59 2004/04/11 18:18:43 mheins Exp $
+# $Id: DBI.pm,v 2.60 2004/06/05 18:21:06 mheins Exp $
#
# Copyright (C) 2002-2004 Interchange Development Group
# Copyright (C) 1996-2002 Red Hat, Inc.
@@ -21,7 +21,7 @@
# MA 02111-1307 USA.
package Vend::Table::DBI;
-$VERSION = substr(q$Revision: 2.59 $, 10);
+$VERSION = substr(q$Revision: 2.60 $, 10);
use strict;
@@ -2140,9 +2140,20 @@
}
};
+ my $re;
+ if(exists $Vend::Cfg->{DatabaseAutoIgnore}) {
+ $re = $Vend::Cfg->{DatabaseAutoIgnore};
+ }
+ elsif(exists $Vend::Config::C->{DatabaseAutoIgnore}) {
+ $re = $Vend::Config::C->{DatabaseAutoIgnore};
+ }
+ $re and $re = qr/$re/;
+#::logDebug("ignore re=$re");
+
my %found;
return undef unless @tabs;
for my $t (@tabs) {
+ next if $re and $t =~ $re;
$found{$t} = 1;
push @out, [$t, "$t.txt $dsn"];
push @out, [$t, "USER $user"] if $user;
More information about the interchange-cvs
mailing list