[Bast-commits] r8755 - in DBIx-Class/0.08/branches/storage-interbase: . lib/DBIx lib/DBIx/Class lib/DBIx/Class/Admin lib/DBIx/Class/CDBICompat lib/DBIx/Class/InflateColumn lib/DBIx/Class/Manual lib/DBIx/Class/Optional lib/DBIx/Class/Relationship lib/DBIx/Class/ResultSource lib/DBIx/Class/SQLAHacks lib/DBIx/Class/Schema lib/DBIx/Class/Storage lib/DBIx/Class/Storage/DBI lib/DBIx/Class/Storage/DBI/ODBC lib/DBIx/Class/Storage/DBI/Oracle lib/DBIx/Class/Storage/DBI/Replicated lib/DBIx/Class/Storage/DBI/Replicated/Balancer lib/DBIx/Class/Storage/DBI/Role lib/DBIx/Class/Storage/DBI/Sybase lib/DBIx/Class/Storage/DBI/Sybase/ASE script t t/admin t/count t/inflate t/lib/DBICTest t/lib/DBICTest/Schema t/resultset t/search t/storage

caelum at dev.catalyst.perl.org caelum at dev.catalyst.perl.org
Fri Feb 19 11:17:58 GMT 2010


Author: caelum
Date: 2010-02-19 11:17:57 +0000 (Fri, 19 Feb 2010)
New Revision: 8755

Added:
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Admin.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Admin/
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Admin/Types.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Optional/
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Optional/Dependencies.pm
   DBIx-Class/0.08/branches/storage-interbase/t/10optional_deps.t
   DBIx-Class/0.08/branches/storage-interbase/t/admin/
   DBIx-Class/0.08/branches/storage-interbase/t/admin/01load.t
   DBIx-Class/0.08/branches/storage-interbase/t/admin/02ddl.t
   DBIx-Class/0.08/branches/storage-interbase/t/admin/03data.t
   DBIx-Class/0.08/branches/storage-interbase/t/admin/10script.t
   DBIx-Class/0.08/branches/storage-interbase/t/count/group_by_func.t
   DBIx-Class/0.08/branches/storage-interbase/t/resultset/is_ordered.t
   DBIx-Class/0.08/branches/storage-interbase/t/search/select_chains.t
   DBIx-Class/0.08/branches/storage-interbase/t/storage/replicated.t
Removed:
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/AmbiguousGlob.pm
   DBIx-Class/0.08/branches/storage-interbase/t/89dbicadmin.t
   DBIx-Class/0.08/branches/storage-interbase/t/storage/replication.t
Modified:
   DBIx-Class/0.08/branches/storage-interbase/
   DBIx-Class/0.08/branches/storage-interbase/Changes
   DBIx-Class/0.08/branches/storage-interbase/Makefile.PL
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/AbstractSearch.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/ColumnsAsHash.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/Copy.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/Iterator.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/InflateColumn.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/InflateColumn/File.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Component.pod
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Cookbook.pod
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Example.pod
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/FAQ.pod
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Intro.pod
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Joining.pod
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Reading.pod
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Troubleshooting.pod
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Ordered.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/PK.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/Base.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/BelongsTo.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/HasMany.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/HasOne.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSet.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSetColumn.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSource.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSource/Table.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSourceHandle.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSourceProxy.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Row.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/SQLAHacks/OracleJoins.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Schema.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Schema/Versioned.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/StartupCheck.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/AutoCast.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/MSSQL.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/MultiColumnIn.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/ODBC/ACCESS.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Oracle/WhereJoins.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Balancer.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Balancer/First.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Introduction.pod
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Pool.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Replicant.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Role/QueryCounter.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/SQLAnywhere.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Sybase/ASE.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Sybase/ASE/NoBindVars.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/mysql.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBIHacks.pm
   DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/TxnScopeGuard.pm
   DBIx-Class/0.08/branches/storage-interbase/script/dbicadmin
   DBIx-Class/0.08/branches/storage-interbase/t/03podcoverage.t
   DBIx-Class/0.08/branches/storage-interbase/t/749sybase_asa.t
   DBIx-Class/0.08/branches/storage-interbase/t/76select.t
   DBIx-Class/0.08/branches/storage-interbase/t/86sqlt.t
   DBIx-Class/0.08/branches/storage-interbase/t/94versioning.t
   DBIx-Class/0.08/branches/storage-interbase/t/99dbic_sqlt_parser.t
   DBIx-Class/0.08/branches/storage-interbase/t/count/distinct.t
   DBIx-Class/0.08/branches/storage-interbase/t/inflate/datetime_sybase_asa.t
   DBIx-Class/0.08/branches/storage-interbase/t/inflate/hri.t
   DBIx-Class/0.08/branches/storage-interbase/t/lib/DBICTest/AuthorCheck.pm
   DBIx-Class/0.08/branches/storage-interbase/t/lib/DBICTest/Schema/ForceForeign.pm
Log:
 r23119 at hlagh (orig r8601):  caelum | 2010-02-10 15:29:51 -0500
 workaround for Moose bug affecting Replicated storage
 r23120 at hlagh (orig r8602):  caelum | 2010-02-10 15:40:07 -0500
 revert Moose bug workaround, bump Moose dep for Replicated to 0.98
 r23121 at hlagh (orig r8603):  caelum | 2010-02-10 16:48:34 -0500
 add a couple proxy methods to Replicated so it can run
 r23133 at hlagh (orig r8615):  caelum | 2010-02-11 05:35:01 -0500
  r21090 at hlagh (orig r7836):  caelum | 2009-11-02 06:40:52 -0500
  new branch to fix unhandled methods in Storage::DBI::Replicated
  r21091 at hlagh (orig r7837):  caelum | 2009-11-02 06:42:00 -0500
  add test to display unhandled methods
  r21092 at hlagh (orig r7838):  caelum | 2009-11-02 06:55:34 -0500
  minor fix to last committed test
  r21093 at hlagh (orig r7839):  caelum | 2009-11-02 09:26:00 -0500
  minor test code cleanup
  r23125 at hlagh (orig r8607):  caelum | 2010-02-10 19:25:51 -0500
  add unimplemented Storage::DBI methods to ::DBI::Replicated
  r23130 at hlagh (orig r8612):  ribasushi | 2010-02-11 05:12:48 -0500
  Podtesting exclusion
 
 r23135 at hlagh (orig r8617):  frew | 2010-02-11 05:45:54 -0500
 Changes (from a while ago)
 r23136 at hlagh (orig r8618):  caelum | 2010-02-11 05:46:58 -0500
 savepoints for SQLAnywhere
 r23145 at hlagh (orig r8627):  ribasushi | 2010-02-11 06:33:19 -0500
  r8424 at Thesaurus (orig r8411):  ribasushi | 2010-01-22 11:19:40 +0100
  Chaining POC test
 
 r23146 at hlagh (orig r8628):  ribasushi | 2010-02-11 06:34:19 -0500
  r8426 at Thesaurus (orig r8413):  ribasushi | 2010-01-22 11:35:15 +0100
  Moev failing regression test away from trunk
 
 r23147 at hlagh (orig r8629):  ribasushi | 2010-02-11 06:34:56 -0500
 
 r23148 at hlagh (orig r8630):  ribasushi | 2010-02-11 06:35:03 -0500
  r8507 at Thesaurus (orig r8494):  frew | 2010-02-01 04:33:08 +0100
  small refactor to put select/as/+select/+as etc merging in it's own function
 
 r23149 at hlagh (orig r8631):  ribasushi | 2010-02-11 06:35:11 -0500
  r8514 at Thesaurus (orig r8501):  frew | 2010-02-02 05:12:29 +0100
  revert actual changes from yesterday as per ribasushis advice
 
 r23150 at hlagh (orig r8632):  ribasushi | 2010-02-11 06:35:16 -0500
  r8522 at Thesaurus (orig r8509):  frew | 2010-02-02 19:39:33 +0100
  delete +stuff if stuff exists
 
 r23151 at hlagh (orig r8633):  ribasushi | 2010-02-11 06:35:23 -0500
  r8534 at Thesaurus (orig r8521):  frew | 2010-02-03 06:14:44 +0100
  change deletion/overriding to fix t/76
 
 r23152 at hlagh (orig r8634):  ribasushi | 2010-02-11 06:35:30 -0500
  r8535 at Thesaurus (orig r8522):  frew | 2010-02-03 06:57:15 +0100
  some basic readability factorings (aka, fewer nested ternaries and long maps)
 
 r23153 at hlagh (orig r8635):  ribasushi | 2010-02-11 06:36:01 -0500
  r8558 at Thesaurus (orig r8545):  frew | 2010-02-04 20:32:54 +0100
  fix incorrect test in t/76select.t and posit an incorrect solution
 
 r23154 at hlagh (orig r8636):  ribasushi | 2010-02-11 06:38:47 -0500
 
 r23155 at hlagh (orig r8637):  ribasushi | 2010-02-11 06:38:57 -0500
  r8578 at Thesaurus (orig r8565):  ribasushi | 2010-02-05 19:11:09 +0100
  Should not be needed
 
 r23156 at hlagh (orig r8638):  ribasushi | 2010-02-11 06:39:03 -0500
  r8579 at Thesaurus (orig r8566):  ribasushi | 2010-02-05 19:13:24 +0100
  SQLA now fixed
 
 r23157 at hlagh (orig r8639):  ribasushi | 2010-02-11 06:39:10 -0500
  r8624 at Thesaurus (orig r8611):  ribasushi | 2010-02-11 10:31:08 +0100
  MOAR testing
 
 r23158 at hlagh (orig r8640):  ribasushi | 2010-02-11 06:39:17 -0500
  r8626 at Thesaurus (orig r8613):  frew | 2010-02-11 11:16:30 +0100
  fix bad test
 
 r23159 at hlagh (orig r8641):  ribasushi | 2010-02-11 06:39:23 -0500
  r8627 at Thesaurus (orig r8614):  frew | 2010-02-11 11:21:52 +0100
  fix t/76, break rsc tests
 
 r23160 at hlagh (orig r8642):  ribasushi | 2010-02-11 06:39:30 -0500
  r8632 at Thesaurus (orig r8619):  frew | 2010-02-11 11:53:50 +0100
  fix incorrect test
 
 r23161 at hlagh (orig r8643):  ribasushi | 2010-02-11 06:39:35 -0500
  r8633 at Thesaurus (orig r8620):  frew | 2010-02-11 11:54:49 +0100
  make t/76s and t/88 pass by deleting from the correct attr hash
 
 r23162 at hlagh (orig r8644):  ribasushi | 2010-02-11 06:39:40 -0500
  r8634 at Thesaurus (orig r8621):  frew | 2010-02-11 11:55:41 +0100
  fix a test due to ordering issues
 
 r23163 at hlagh (orig r8645):  ribasushi | 2010-02-11 06:39:45 -0500
  r8635 at Thesaurus (orig r8622):  frew | 2010-02-11 11:58:23 +0100
  this is why you run tests before you commit them.
 
 r23164 at hlagh (orig r8646):  ribasushi | 2010-02-11 06:39:51 -0500
  r8636 at Thesaurus (orig r8623):  frew | 2010-02-11 12:00:59 +0100
  fix another ordering issue
 
 r23165 at hlagh (orig r8647):  ribasushi | 2010-02-11 06:39:57 -0500
  r8637 at Thesaurus (orig r8624):  frew | 2010-02-11 12:11:31 +0100
  fix for search/select_chains
 
 r23166 at hlagh (orig r8648):  ribasushi | 2010-02-11 06:40:03 -0500
 
 r23167 at hlagh (orig r8649):  caelum | 2010-02-11 06:40:07 -0500
 test nanosecond precision for SQLAnywhere
 r23168 at hlagh (orig r8650):  ribasushi | 2010-02-11 06:40:09 -0500
  r8639 at Thesaurus (orig r8626):  ribasushi | 2010-02-11 12:33:03 +0100
  Changes and small ommission
 
 r23171 at hlagh (orig r8653):  ribasushi | 2010-02-11 12:16:45 -0500
 Changes
 r23179 at hlagh (orig r8661):  ribasushi | 2010-02-12 03:12:45 -0500
 Fix moose dep
 r23185 at hlagh (orig r8667):  dew | 2010-02-12 12:05:11 -0500
 Add is_ordered to DBIC::ResultSet
 r23193 at hlagh (orig r8675):  ribasushi | 2010-02-13 03:36:29 -0500
  r8667 at Thesaurus (orig r8654):  ribasushi | 2010-02-11 18:17:35 +0100
  Try a dep-handling idea
  r8675 at Thesaurus (orig r8662):  ribasushi | 2010-02-12 12:46:11 +0100
  Move optional deps out of the Makefile
  r8676 at Thesaurus (orig r8663):  ribasushi | 2010-02-12 13:40:53 +0100
  Support methods to verify group dependencies
  r8677 at Thesaurus (orig r8664):  ribasushi | 2010-02-12 13:45:18 +0100
  Move sqlt dephandling to Optional::Deps
  r8679 at Thesaurus (orig r8666):  ribasushi | 2010-02-12 14:03:17 +0100
  Move replicated to Opt::Deps
  r8684 at Thesaurus (orig r8671):  ribasushi | 2010-02-13 02:47:52 +0100
  Auto-POD for Optional Deps
  r8685 at Thesaurus (orig r8672):  ribasushi | 2010-02-13 02:53:20 +0100
  Privatize the full list method
  r8686 at Thesaurus (orig r8673):  ribasushi | 2010-02-13 02:59:51 +0100
  Scary warning
  r8687 at Thesaurus (orig r8674):  ribasushi | 2010-02-13 09:35:01 +0100
  Changes
 
 r23196 at hlagh (orig r8678):  ribasushi | 2010-02-13 04:07:15 -0500
 Autogen comment for Dependencies.pod
 r23197 at hlagh (orig r8679):  ribasushi | 2010-02-13 04:11:24 -0500
 Ask for newer M::I
 r23203 at hlagh (orig r8685):  ribasushi | 2010-02-13 05:11:10 -0500
 Add author/license to pod
 r23204 at hlagh (orig r8686):  arcanez | 2010-02-13 07:43:22 -0500
 fix typo per nuba on irc
 r23210 at hlagh (orig r8692):  ribasushi | 2010-02-13 09:15:33 -0500
  r8001 at Thesaurus (orig r7989):  goraxe | 2009-11-30 01:14:47 +0100
  Branch for dbicadmin script refactor
  
  r8003 at Thesaurus (orig r7991):  goraxe | 2009-11-30 01:26:39 +0100
  add DBIx::Class::Admin
  r8024 at Thesaurus (orig r8012):  goraxe | 2009-12-02 22:49:27 +0100
  get deployment tests to pass
  r8025 at Thesaurus (orig r8013):  goraxe | 2009-12-02 22:50:42 +0100
  get deployment tests to pass
  r8026 at Thesaurus (orig r8014):  goraxe | 2009-12-02 23:52:40 +0100
  all ddl tests now pass
  r8083 at Thesaurus (orig r8071):  goraxe | 2009-12-12 17:01:11 +0100
  add quite attribute to DBIx::Class admin
  r8086 at Thesaurus (orig r8074):  goraxe | 2009-12-12 17:36:58 +0100
  add tests for data manipulation ported from 89dbicadmin.t
  r8088 at Thesaurus (orig r8076):  goraxe | 2009-12-12 17:38:07 +0100
  add sleep 1 to t/admin/02ddl.t so insert into upgrade table does not happen too quickly
  r8089 at Thesaurus (orig r8077):  goraxe | 2009-12-12 17:40:33 +0100
  update DBIx::Class::Admin data manip functions to pass the test
  r8095 at Thesaurus (orig r8083):  goraxe | 2009-12-12 19:36:22 +0100
  change passing of preversion to be a parameter
  r8096 at Thesaurus (orig r8084):  goraxe | 2009-12-12 19:38:26 +0100
  add some pod to DBIx::Class::Admin
  r8103 at Thesaurus (orig r8091):  goraxe | 2009-12-12 22:08:55 +0100
  some changes to make DBIx::Class::Admin more compatible with dbicadmin interface
  r8104 at Thesaurus (orig r8092):  goraxe | 2009-12-12 22:09:39 +0100
  commit refactored dbicadmin script and very minor changes to its existing test suite
  r8107 at Thesaurus (orig r8095):  goraxe | 2009-12-12 22:34:35 +0100
  add compatability for --op for dbicadmin, revert test suite
  r8127 at Thesaurus (orig r8115):  goraxe | 2009-12-15 22:14:20 +0100
  dep check to end of module
  r8128 at Thesaurus (orig r8116):  goraxe | 2009-12-15 23:15:25 +0100
  add namespace::autoclean to DBIx::Class::Admin
  r8129 at Thesaurus (orig r8117):  goraxe | 2009-12-15 23:16:00 +0100
  update test suite to skip if cannot load DBIx::Class::Admin
  r8130 at Thesaurus (orig r8118):  goraxe | 2009-12-15 23:18:35 +0100
  add deps check for 89dbicadmin.t
  r8131 at Thesaurus (orig r8119):  goraxe | 2009-12-15 23:19:01 +0100
  include deps for dbicadmin DBIx::Class::Admin to Makefile.PL
  r8149 at Thesaurus (orig r8137):  goraxe | 2009-12-17 23:21:50 +0100
  use DBICTest::_database over creating a schema object to steal conn info
  r8338 at Thesaurus (orig r8326):  goraxe | 2010-01-15 19:00:17 +0100
  change white space to not be tabs
  r8339 at Thesaurus (orig r8327):  goraxe | 2010-01-15 19:10:42 +0100
  remove Module::Load from test suite
  r8358 at Thesaurus (orig r8346):  ribasushi | 2010-01-17 17:52:10 +0100
  Real detabify
  r8359 at Thesaurus (orig r8347):  ribasushi | 2010-01-17 18:01:53 +0100
  Fix POD (spacing matters)
  r8360 at Thesaurus (orig r8348):  ribasushi | 2010-01-17 21:57:53 +0100
  More detabification
  r8361 at Thesaurus (orig r8349):  ribasushi | 2010-01-17 22:33:12 +0100
  Test cleanup
  r8362 at Thesaurus (orig r8350):  ribasushi | 2010-01-17 22:41:11 +0100
  More tets cleanup
  r8363 at Thesaurus (orig r8351):  ribasushi | 2010-01-17 22:43:57 +0100
  And more cleanup
  r8364 at Thesaurus (orig r8352):  ribasushi | 2010-01-17 22:51:21 +0100
  Disallow mucking with INC
  r8365 at Thesaurus (orig r8353):  ribasushi | 2010-01-17 23:23:15 +0100
  More cleanup
  r8366 at Thesaurus (orig r8354):  ribasushi | 2010-01-17 23:27:49 +0100
  Add lib path to ENV so that $^X can see it
  r8367 at Thesaurus (orig r8355):  ribasushi | 2010-01-17 23:33:10 +0100
  Move script-test
  r8368 at Thesaurus (orig r8356):  goraxe | 2010-01-17 23:35:03 +0100
  change warns/dies -> carp/throw_exception
  r8369 at Thesaurus (orig r8357):  goraxe | 2010-01-17 23:53:54 +0100
  add goraxe to contributors
  r8370 at Thesaurus (orig r8358):  goraxe | 2010-01-17 23:54:15 +0100
  remove comment headers 
  r8404 at Thesaurus (orig r8391):  caelum | 2010-01-20 20:54:29 +0100
  minor fixups
  r8405 at Thesaurus (orig r8392):  goraxe | 2010-01-20 21:13:24 +0100
  add private types to coerce
  r8406 at Thesaurus (orig r8393):  goraxe | 2010-01-20 21:17:19 +0100
  remove un-needed coerce from schema_class of type Str
  r8411 at Thesaurus (orig r8398):  caelum | 2010-01-21 23:36:25 +0100
  minor documentation updates
  r8436 at Thesaurus (orig r8423):  caelum | 2010-01-25 02:56:30 +0100
  this code never runs anyway
  r8440 at Thesaurus (orig r8427):  caelum | 2010-01-26 14:05:53 +0100
  prefer JSON::DWIW for barekey support
  r8693 at Thesaurus (orig r8680):  ribasushi | 2010-02-13 10:27:18 +0100
  dbicadmin dependencies
  r8694 at Thesaurus (orig r8681):  ribasushi | 2010-02-13 10:28:04 +0100
  Some cleaup, make use of Text::CSV
  r8695 at Thesaurus (orig r8682):  ribasushi | 2010-02-13 10:34:19 +0100
  We use Try::Tiny in a single spot, not grounds for inlusion in deps
  r8696 at Thesaurus (orig r8683):  ribasushi | 2010-02-13 10:37:30 +0100
  POD section
  r8697 at Thesaurus (orig r8684):  ribasushi | 2010-02-13 11:05:17 +0100
  Switch tests to Optional::Deps
  r8700 at Thesaurus (orig r8687):  ribasushi | 2010-02-13 14:32:50 +0100
  Switch Admin/dbicadmin to Opt::Deps
  r8702 at Thesaurus (orig r8689):  ribasushi | 2010-02-13 14:39:24 +0100
  JSON dep is needed for Admin.pm itself
  r8703 at Thesaurus (orig r8690):  ribasushi | 2010-02-13 15:06:28 +0100
  Test fixes
  r8704 at Thesaurus (orig r8691):  ribasushi | 2010-02-13 15:13:31 +0100
  Changes
 
 r23212 at hlagh (orig r8694):  ribasushi | 2010-02-13 10:37:57 -0500
 Test for optional deps manager
 r23215 at hlagh (orig r8697):  caelum | 2010-02-13 23:22:03 -0500
 add doc on maximum cursors for SQLAnywhere
 r23216 at hlagh (orig r8698):  ribasushi | 2010-02-14 03:23:09 -0500
 Cleanup dependencies / Admin inheritance
 r23217 at hlagh (orig r8699):  ribasushi | 2010-02-14 03:28:29 -0500
 Some formatting
 r23220 at hlagh (orig r8702):  ribasushi | 2010-02-14 04:46:51 -0500
 This is Moose, so use CMOP
 r23225 at hlagh (orig r8707):  ribasushi | 2010-02-15 04:28:22 -0500
 Final POD touches
 r23226 at hlagh (orig r8708):  ribasushi | 2010-02-15 04:31:38 -0500
 Spellcheck (jawnsy++)
 r23227 at hlagh (orig r8709):  ribasushi | 2010-02-15 04:32:24 -0500
 One more
 r23228 at hlagh (orig r8710):  ribasushi | 2010-02-15 08:49:26 -0500
 Release 0.08119
 r23230 at hlagh (orig r8712):  ribasushi | 2010-02-15 08:50:56 -0500
 Bump trunl version
 r23231 at hlagh (orig r8713):  rafl | 2010-02-15 09:49:55 -0500
 Make sure we actually run all tests, given we're using done_testing.
 r23232 at hlagh (orig r8714):  rafl | 2010-02-15 09:50:01 -0500
 Make sure overriding deployment_statements is possible from within schemas.
 r23233 at hlagh (orig r8715):  rafl | 2010-02-15 09:56:06 -0500
 Changelogging.
 r23234 at hlagh (orig r8716):  rafl | 2010-02-15 09:58:09 -0500
 Make some cookbook code compile.
 r23235 at hlagh (orig r8717):  nuba | 2010-02-15 10:11:52 -0500
 spelling fixes in the documaentation, sholud be gud now ;)
 r23237 at hlagh (orig r8719):  caelum | 2010-02-16 05:09:58 -0500
 use OO interface of Hash::Merge for ::DBI::Replicated
 r23239 at hlagh (orig r8721):  ribasushi | 2010-02-16 05:41:06 -0500
 Augment did-author-run-makefile check to include OptDeps
 r23240 at hlagh (orig r8722):  ribasushi | 2010-02-16 06:16:06 -0500
 Reorg support section, add live-chat link
 r23244 at hlagh (orig r8726):  caelum | 2010-02-16 08:51:58 -0500
 set behavior for Hash::Merge in ::DBI::Replicated, otherwise it uses the global setting
 r23245 at hlagh (orig r8727):  caelum | 2010-02-16 09:43:25 -0500
 POD touchups
 r23346 at hlagh (orig r8746):  ribasushi | 2010-02-18 18:30:37 -0500
 Fix bogus test
 r23347 at hlagh (orig r8747):  ribasushi | 2010-02-18 18:34:22 -0500
 Retire useless abstraction (all rdbms need this anyway)
 r23348 at hlagh (orig r8748):  ribasushi | 2010-02-18 18:35:01 -0500
 Fix count of group_by over aliased function
 r23352 at hlagh (orig r8752):  ribasushi | 2010-02-19 04:11:20 -0500
  r8497 at Thesaurus (orig r8484):  ribasushi | 2010-01-31 10:06:29 +0100
  Branch to unify mandatory PK handling
  r8498 at Thesaurus (orig r8485):  ribasushi | 2010-01-31 10:20:36 +0100
  This is not really used for anything (same code in DBI)
  r8499 at Thesaurus (orig r8486):  ribasushi | 2010-01-31 10:25:55 +0100
  Helper primary_columns wrapper to throw if a PK is not defined
  r8500 at Thesaurus (orig r8487):  ribasushi | 2010-01-31 11:07:25 +0100
  Stupid errors
  r8501 at Thesaurus (orig r8488):  ribasushi | 2010-01-31 12:18:57 +0100
  Saner handling of nonexistent/partial conditions
  r8762 at Thesaurus (orig r8749):  ribasushi | 2010-02-19 10:07:40 +0100
  trap unresolvable conditions due to incomplete relationship specification
  r8764 at Thesaurus (orig r8751):  ribasushi | 2010-02-19 10:11:09 +0100
  Changes
 
 r23354 at hlagh (orig r8754):  ribasushi | 2010-02-19 05:14:30 -0500
 Fix for RT54697



Property changes on: DBIx-Class/0.08/branches/storage-interbase
___________________________________________________________________
Name: svk:merge
   - 168d5346-440b-0410-b799-f706be625ff1:/DBIx-Class-current:2207
462d4d0c-b505-0410-bf8e-ce8f877b3390:/local/bast/DBIx-Class:3159
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/cookbook_fixes:7657
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/prefetch_bug-unqualified_column_in_search_related_cond:7959
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/resultsetcolumn_custom_columns:5160
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/sqla_1.50_compat:5414
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/void_populate_resultset_cond:7935
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/trunk:7982
9c88509d-e914-0410-b01c-b9530614cbfe:/local/DBIx-Class:32260
9c88509d-e914-0410-b01c-b9530614cbfe:/local/DBIx-Class-CDBICompat:54993
9c88509d-e914-0410-b01c-b9530614cbfe:/vendor/DBIx-Class:31122
ab17426e-7cd3-4704-a2a2-80b7c0a611bb:/local/dbic_column_attr:10946
ab17426e-7cd3-4704-a2a2-80b7c0a611bb:/local/dbic_trunk:11788
bd5ac9a7-f185-4d95-9186-dbb8b392a572:/local/os/bast/DBIx-Class/0.08/trunk:2798
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/_abandoned_but_possibly_useful/table_name_ref:7266
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/ado_mssql:7886
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/autocast:7418
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/belongs_to_null_col_fix:5244
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/cdbicompat_integration:4160
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/column_attr:5074
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/complex_join_rels:4589
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/connect_info_hash:7435
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/connected_schema_leak:8264
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/cookbook_fixes:7479
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/count_distinct:6218
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/count_rs:6741
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/create_scalarref_rt51559:8027
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/diamond_relationships:6310
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/discard_changes_replication_fix:7252
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/file_column:3920
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/fix-update-and-delete-as_query:6162
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/get_inflated_columns_rt46953:7964
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/grouped_has_many_join:7382
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/grouped_prefetch:6885
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/ic_dt_post_inflate:8517
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/informix:8434
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/is_resultset_paginated:7769
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/joined_count:6323
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mc_fixes:6645
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_limit_regression:8278
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_money_type:7096
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_rno_pagination:8054
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_storage_minor_refactor:7210
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_top_fixes:6971
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/multi_stuff:5565
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/multicreate_fixes:7275
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/multiple_version_upgrade:8429
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mysql_ansi:7175
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mystery_join:6589
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/new_replication_transaction_fixup:7058
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/no_duplicate_indexes_for_pk_cols:8373
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/normalize_connect_info:8274
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/null_column_regression:8314
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/on_connect_call:6854
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/on_disconnect_do:3694
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle-tweaks:6222
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle_sequence:4173
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle_shorten_aliases:8234
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/order_by_refactor:6475
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/parser_fk_index:4485
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/pg_unqualified_schema:7842
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch:5699
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch-group_by:7917
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_bug-unqualified_column_in_search_related_cond:7900
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_limit:6724
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_pager:8431
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_redux:7206
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/reduce_pings:7261
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/replication_dedux:4600
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/rsrc_in_storage:6577
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/rt_bug_41083:5437
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/savepoints:4223
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/search_related_prefetch:6818
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sqla_1.50_compat:5321
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sqlt_parser_view:8145
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/storage-ms-access:4142
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/storage-tweaks:6262
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/subclassed_rsset:5930
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/subquery:5617
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/syb_connected:6919
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase:7682
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_asa:8513
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_bulk_insert:7679
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_bulkinsert_support:7796
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_computed_columns:8496
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_mssql:6125
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_refactor:7940
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_support:7797
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/table_name_ref:7132
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/top_limit_altfix:6429
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/type_aware_update:6619
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/unresolvable_prefetch:6949
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/versioned_enhancements:4125
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/versioning:4578
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/view_rels:7908
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/views:5585
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/void_populate_resultset_cond:7944
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/tags/0.08108_prerelease_please_do_not_pull_into_it:7008
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/tags/pre_0.08109_please_do_not_merge:7336
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/trunk:8596
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-C3:318
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-current:2222
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-joins:173
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-resultset:570
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/datetime:1716
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/find_compat:1855
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/find_unique_query_fixes:2142
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/inflate:1988
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/many_to_many:2025
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/re_refactor_bugfix:1944
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/reorganize_tests:1827
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset-new-refactor:1766
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset_2_electric_boogaloo:2175
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset_cleanup:2102
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/sqlt_tests_refactor:2043
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/trunk/DBIx-Class:3606
fe160bb6-dc1c-0410-9f2b-d64a711b54a5:/local/DBIC-trunk-0.08:10510
   + 168d5346-440b-0410-b799-f706be625ff1:/DBIx-Class-current:2207
462d4d0c-b505-0410-bf8e-ce8f877b3390:/local/bast/DBIx-Class:3159
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/cookbook_fixes:7657
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/prefetch_bug-unqualified_column_in_search_related_cond:7959
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/resultsetcolumn_custom_columns:5160
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/sqla_1.50_compat:5414
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/branches/void_populate_resultset_cond:7935
4d5fae46-8e6a-4e08-abee-817e9fb894a2:/local/bast/DBIx-Class/0.08/trunk:7982
9c88509d-e914-0410-b01c-b9530614cbfe:/local/DBIx-Class:32260
9c88509d-e914-0410-b01c-b9530614cbfe:/local/DBIx-Class-CDBICompat:54993
9c88509d-e914-0410-b01c-b9530614cbfe:/vendor/DBIx-Class:31122
ab17426e-7cd3-4704-a2a2-80b7c0a611bb:/local/dbic_column_attr:10946
ab17426e-7cd3-4704-a2a2-80b7c0a611bb:/local/dbic_trunk:11788
bd5ac9a7-f185-4d95-9186-dbb8b392a572:/local/os/bast/DBIx-Class/0.08/trunk:2798
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/_abandoned_but_possibly_useful/table_name_ref:7266
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/ado_mssql:7886
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/autocast:7418
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/belongs_to_null_col_fix:5244
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/cdbicompat_integration:4160
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/chaining_fixes:8626
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/column_attr:5074
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/complex_join_rels:4589
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/connect_info_hash:7435
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/connected_schema_leak:8264
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/cookbook_fixes:7479
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/count_distinct:6218
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/count_rs:6741
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/create_scalarref_rt51559:8027
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/dbicadmin_refactor:8691
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/dephandling:8674
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/diamond_relationships:6310
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/discard_changes_replication_fix:7252
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/file_column:3920
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/fix-update-and-delete-as_query:6162
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/get_inflated_columns_rt46953:7964
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/grouped_has_many_join:7382
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/grouped_prefetch:6885
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/handle_all_storage_methods_in_replicated:8612
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/ic_dt_post_inflate:8517
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/informix:8434
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/is_resultset_paginated:7769
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/joined_count:6323
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mc_fixes:6645
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_limit_regression:8278
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_money_type:7096
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_rno_pagination:8054
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_storage_minor_refactor:7210
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mssql_top_fixes:6971
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/multi_stuff:5565
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/multicreate_fixes:7275
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/multiple_version_upgrade:8429
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mysql_ansi:7175
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/mystery_join:6589
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/new_replication_transaction_fixup:7058
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/no_duplicate_indexes_for_pk_cols:8373
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/normalize_connect_info:8274
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/null_column_regression:8314
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/on_connect_call:6854
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/on_disconnect_do:3694
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle-tweaks:6222
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle_sequence:4173
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/oracle_shorten_aliases:8234
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/order_by_refactor:6475
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/parser_fk_index:4485
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/pg_unqualified_schema:7842
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch:5699
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch-group_by:7917
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_bug-unqualified_column_in_search_related_cond:7900
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_limit:6724
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_pager:8431
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/prefetch_redux:7206
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/pri_key_refactor:8751
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/reduce_pings:7261
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/replication_dedux:4600
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/rsrc_in_storage:6577
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/rt_bug_41083:5437
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/savepoints:4223
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/search_related_prefetch:6818
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sqla_1.50_compat:5321
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sqlt_parser_view:8145
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/storage-ms-access:4142
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/storage-tweaks:6262
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/subclassed_rsset:5930
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/subquery:5617
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/syb_connected:6919
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase:7682
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_asa:8513
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_bulk_insert:7679
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_bulkinsert_support:7796
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_computed_columns:8496
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_mssql:6125
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_refactor:7940
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/sybase_support:7797
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/table_name_ref:7132
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/top_limit_altfix:6429
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/type_aware_update:6619
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/unresolvable_prefetch:6949
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/versioned_enhancements:4125
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/versioning:4578
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/view_rels:7908
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/views:5585
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/branches/void_populate_resultset_cond:7944
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/tags/0.08108_prerelease_please_do_not_pull_into_it:7008
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/tags/pre_0.08109_please_do_not_merge:7336
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/DBIx-Class/0.08/trunk:8754
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-C3:318
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-current:2222
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-joins:173
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class-resultset:570
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/datetime:1716
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/find_compat:1855
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/find_unique_query_fixes:2142
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/inflate:1988
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/many_to_many:2025
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/re_refactor_bugfix:1944
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/reorganize_tests:1827
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset-new-refactor:1766
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset_2_electric_boogaloo:2175
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/resultset_cleanup:2102
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/branches/DBIx-Class/sqlt_tests_refactor:2043
bd8105ee-0ff8-0310-8827-fb3f25b6796d:/trunk/DBIx-Class:3606
fe160bb6-dc1c-0410-9f2b-d64a711b54a5:/local/DBIC-trunk-0.08:10510

Modified: DBIx-Class/0.08/branches/storage-interbase/Changes
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/Changes	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/Changes	2010-02-19 11:17:57 UTC (rev 8755)
@@ -1,5 +1,22 @@
 Revision history for DBIx::Class
 
+        - Make sure possibly overwritten deployment_statements methods in
+          schemas get called on $schema->deploy
+        - Fix count() with group_by aliased-function resultsets
+        - Massive refactor and cleanup of primary key handling
+        - Fixed regression losing custom result_class (really this time)
+
+0.08119 2010-02-15 09:36:00 (UTC)
+        - Add $rs->is_ordered to test for existing order_by on a resultset
+        - Add as_subselect_rs to DBIC::ResultSet from
+          DBIC::Helper::ResultSet::VirtualView::as_virtual_view
+        - Refactor dbicadmin adding DDL manipulation capabilities
+        - New optional dependency manager to aid extension writers
+        - Depend on newest bugfixed Moose
+        - Make resultset chaining consistent wrt selection specification
+        - Storage::DBI::Replicated cleanup
+        - Fix autoinc PKs without an autoinc flag on Sybase ASA
+
 0.08118 2010-02-08 11:53:00 (UTC)
         - Fix a bug causing UTF8 columns not to be decoded (RT#54395)
         - Fix bug in One->Many->One prefetch-collapse handling (RT#54039)

Modified: DBIx-Class/0.08/branches/storage-interbase/Makefile.PL
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/Makefile.PL	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/Makefile.PL	2010-02-19 11:17:57 UTC (rev 8755)
@@ -1,146 +1,124 @@
-use inc::Module::Install 0.89;
+use inc::Module::Install 0.93;
 use strict;
 use warnings;
 use POSIX ();
 
 use 5.008001;
 
-# ****** DO NOT ADD OPTIONAL DEPENDENCIES. EVER. --mst ******
+use FindBin;
+use lib "$FindBin::Bin/lib";
 
+###
+### DO NOT ADD OPTIONAL DEPENDENCIES HERE, EVEN AS recommends()
+### All of them should go to DBIx::Class::Optional::Dependencies
+###
+
+
 name     'DBIx-Class';
 perl_version '5.008001';
 all_from 'lib/DBIx/Class.pm';
 
+my $build_requires = {
+  'DBD::SQLite'              => '1.25',
+};
 
-test_requires 'Test::Builder'       => '0.33';
-test_requires 'Test::Deep'          => '0';
-test_requires 'Test::Exception'     => '0';
-test_requires 'Test::More'          => '0.92';
-test_requires 'Test::Warn'          => '0.21';
+my $test_requires = {
+  'File::Temp'               => '0.22',
+  'Test::Builder'            => '0.33',
+  'Test::Deep'               => '0',
+  'Test::Exception'          => '0',
+  'Test::More'               => '0.92',
+  'Test::Warn'               => '0.21',
+};
 
-test_requires 'File::Temp'          => '0.22';
+my $runtime_requires = {
+  # Core
+  'List::Util'               => '0',
+  'Scalar::Util'             => '0',
+  'Storable'                 => '0',
 
+  # Dependencies
+  'Carp::Clan'               => '6.0',
+  'Class::Accessor::Grouped' => '0.09002',
+  'Class::C3::Componentised' => '1.0005',
+  'Class::Inspector'         => '1.24',
+  'Data::Page'               => '2.00',
+  'DBI'                      => '1.609',
+  'MRO::Compat'              => '0.09',
+  'Module::Find'             => '0.06',
+  'Path::Class'              => '0.18',
+  'Scope::Guard'             => '0.03',
+  'SQL::Abstract'            => '1.61',
+  'SQL::Abstract::Limit'     => '0.13',
+  'Sub::Name'                => '0.04',
+  'Data::Dumper::Concise'    => '1.000',
+};
 
-# Core
-requires 'List::Util'               => '0';
-requires 'Scalar::Util'             => '0';
-requires 'Storable'                 => '0';
+# this is so we can order requires alphabetically
+# copies are needed for author requires injection
+my $reqs = {
+  build_requires => { %$build_requires },
+  requires => { %$runtime_requires },
+  test_requires => { %$test_requires },
+};
 
-# Dependencies (keep in alphabetical order)
-requires 'Carp::Clan'               => '6.0';
-requires 'Class::Accessor::Grouped' => '0.09002';
-requires 'Class::C3::Componentised' => '1.0005';
-requires 'Class::Inspector'         => '1.24';
-requires 'Data::Page'               => '2.00';
-requires 'DBD::SQLite'              => '1.25';
-requires 'DBI'                      => '1.609';
-requires 'JSON::Any'                => '1.18';
-requires 'MRO::Compat'              => '0.09';
-requires 'Module::Find'             => '0.06';
-requires 'Path::Class'              => '0.16';
-requires 'Scope::Guard'             => '0.03';
-requires 'SQL::Abstract'            => '1.61';
-requires 'SQL::Abstract::Limit'     => '0.13';
-requires 'Sub::Name'                => '0.04';
-requires 'Data::Dumper::Concise'    => '1.000';
+# re-build README and require extra modules for testing if we're in a checkout
+if ($Module::Install::AUTHOR) {
 
-my %replication_requires = (
-  'Moose',                    => '0.90',
-  'MooseX::Types',            => '0.21',
-  'namespace::clean'          => '0.11',
-  'Hash::Merge',              => '0.11',
-);
+  print "Regenerating README\n";
+  system('pod2text lib/DBIx/Class.pm > README');
 
-#************************************************************************#
-# Make *ABSOLUTELY SURE* that nothing on this list is a real require,    #
-# since every module listed in %force_requires_if_author is deleted      #
-# from the final META.yml (thus will never make it as a CPAN dependency) #
-#************************************************************************#
-my %force_requires_if_author = (
-  %replication_requires,
+  if (-f 'MANIFEST') {
+    print "Removing MANIFEST\n";
+    unlink 'MANIFEST';
+  }
 
-  # when changing also adjust $DBIx::Class::Storage::DBI::minimum_sqlt_version
-  'SQL::Translator'           => '0.11002',
+  print "Regenerating Optional/Dependencies.pod\n";
+  require DBIx::Class::Optional::Dependencies;
+  DBIx::Class::Optional::Dependencies->_gen_pod;
 
-#  'Module::Install::Pod::Inherit' => '0.01',
+# FIXME Disabled due to unsolved issues, ask theorbtwo
+#  require Module::Install::Pod::Inherit;
+#  PodInherit();
 
-  # when changing also adjust version in t/02pod.t
-  'Test::Pod'                 => '1.26',
+  warn <<'EOW';
+******************************************************************************
+******************************************************************************
+***                                                                        ***
+*** AUTHOR MODE: all optional test dependencies converted to hard requires ***
+***                                                                        ***
+******************************************************************************
+******************************************************************************
 
-  # when changing also adjust version in t/06notabs.t
-#  'Test::NoTabs'              => '0.9',
+EOW
 
-  # when changing also adjust version in t/07eol.t
-#  'Test::EOL'                 => '0.6',
+  $reqs->{test_requires} = {
+    %{$reqs->{test_requires}},
+    %{DBIx::Class::Optional::Dependencies->_all_optional_requirements},
+  };
+}
 
-  # when changing also adjust version in t/03podcoverage.t
-  'Test::Pod::Coverage'       => '1.08',
-  'Pod::Coverage'             => '0.20',
+# compose final req list, for alphabetical ordering
+my %final_req;
+for my $rtype (keys %$reqs) {
+  for my $mod (keys %{$reqs->{$rtype}} ) {
 
-  # CDBI-compat related
-  'DBIx::ContextualFetch'     => '0',
-  'Class::DBI::Plugin::DeepAbstractSearch' => '0',
-  'Class::Trigger'            => '0',
-  'Time::Piece::MySQL'        => '0',
-  'Clone'                     => '0',
-  'Date::Simple'              => '3.03',
+    # sanity check req duplications
+    if ($final_req{$mod}) {
+      die "$mod specified as both a '$rtype' and a '$final_req{$mod}[0]'\n";
+    }
 
-  # t/52cycle.t
-  'Test::Memory::Cycle'       => '0',
-  'Devel::Cycle'              => '1.10',
+    $final_req{$mod} = [ $rtype, $reqs->{$rtype}{$mod}||0 ],
+  }
+}
 
-  # t/36datetime.t
-  # t/60core.t
-  'DateTime::Format::SQLite'  => '0',
+# actual require
+for my $mod (sort keys %final_req) {
+  my ($rtype, $ver) = @{$final_req{$mod}};
+  no strict 'refs';
+  $rtype->($mod, $ver);
+}
 
-  # t/96_is_deteministic_value.t
-  'DateTime::Format::Strptime'=> '0',
-
-  # database-dependent reqs
-  #
-  $ENV{DBICTEST_PG_DSN}
-    ? (
-      'Sys::SigAction' => '0',
-      'DBD::Pg' => '2.009002',
-      'DateTime::Format::Pg' => '0',
-    ) : ()
-  ,
-
-  $ENV{DBICTEST_MYSQL_DSN}
-    ? (
-      'DateTime::Format::MySQL' => '0',
-    ) : ()
-  ,
-
-  $ENV{DBICTEST_ORA_DSN}
-    ? (
-      'DateTime::Format::Oracle' => '0',
-    ) : ()
-  ,
-
-  $ENV{DBICTEST_SYBASE_DSN}
-    ? (
-      'DateTime::Format::Sybase' => 0,
-    ) : ()
-  ,
-  grep $_, @ENV{qw/DBICTEST_SYBASE_ASA_DSN DBICTEST_SYBASE_ASA_ODBC_DSN/}
-    ? (
-      'DateTime::Format::Strptime' => 0,
-    ) : ()
-  ,
-  grep $_, @ENV{qw/DBICTEST_FIREBIRD_DSN DBICTEST_FIREBIRD_ODBC_DSN/}
-    ? (
-      'DateTime::Format::Strptime' => 0,
-    ) : ()
-  ,
-);
-#************************************************************************#
-# Make ABSOLUTELY SURE that nothing on the list above is a real require, #
-# since every module listed in %force_requires_if_author is deleted      #
-# from the final META.yml (thus will never make it as a CPAN dependency) #
-#************************************************************************#
-
-
 install_script (qw|
     script/dbicadmin
 |);
@@ -160,50 +138,25 @@
   lib/DBIx/Class/PK/Auto
 |);
 no_index package => $_ for (qw/
-  DBIx::Class::Storage::DBI::AmbiguousGlob
   DBIx::Class::SQLAHacks DBIx::Class::Storage::DBIHacks
 /);
 
-# re-build README and require extra modules for testing if we're in a checkout
 
-if ($Module::Install::AUTHOR) {
-  warn <<'EOW';
-******************************************************************************
-******************************************************************************
-***                                                                        ***
-*** AUTHOR MODE: all optional test dependencies converted to hard requires ***
-***                                                                        ***
-******************************************************************************
-******************************************************************************
-
-EOW
-
-  foreach my $module (sort keys %force_requires_if_author) {
-    build_requires ($module => $force_requires_if_author{$module});
-  }
-
-  print "Regenerating README\n";
-  system('pod2text lib/DBIx/Class.pm > README');
-
-  if (-f 'MANIFEST') {
-    print "Removing MANIFEST\n";
-    unlink 'MANIFEST';
-  }
-
-#  require Module::Install::Pod::Inherit;
-#  PodInherit();
-}
-
 auto_install();
 
 WriteAll();
 
+
 # Re-write META.yml to _exclude_ all forced requires (we do not want to ship this)
 if ($Module::Install::AUTHOR) {
 
+  # FIXME test_requires is not yet part of META
+  my %original_build_requires = ( %$build_requires, %$test_requires );
+
+  print "Regenerating META with author requires excluded\n";
   Meta->{values}{build_requires} = [ grep
-    { not exists $force_requires_if_author{$_->[0]} }
-    ( @{Meta->{values}{build_requires}} )
+    { exists $original_build_requires{$_->[0]} }
+   ( @{Meta->{values}{build_requires}} )
   ];
 
   Meta->write;

Added: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Admin/Types.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Admin/Types.pm	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Admin/Types.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,48 @@
+package # hide from PAUSE
+    DBIx::Class::Admin::Types;
+
+use MooseX::Types -declare => [qw(
+    DBICConnectInfo
+    DBICArrayRef
+    DBICHashRef
+)];
+use MooseX::Types::Moose qw/Int HashRef ArrayRef Str Any Bool/;
+use MooseX::Types::JSON qw(JSON);
+
+subtype DBICArrayRef,
+    as ArrayRef;
+
+subtype DBICHashRef,
+    as HashRef;
+
+coerce DBICArrayRef,
+  from JSON,
+  via { _json_to_data ($_) };
+
+coerce DBICHashRef,
+  from JSON,
+  via { _json_to_data($_) };
+
+subtype DBICConnectInfo,
+  as ArrayRef;
+
+coerce DBICConnectInfo,
+  from JSON,
+   via { return _json_to_data($_) } ;
+
+coerce DBICConnectInfo,
+  from Str,
+    via { return _json_to_data($_) };
+
+coerce DBICConnectInfo,
+  from HashRef,
+   via { [ $_ ] };
+
+sub _json_to_data {
+  my ($json_str) = @_;
+  my $json = JSON::Any->new(allow_barekey => 1, allow_singlequote => 1, relaxed=>1);
+  my $ret = $json->jsonToObj($json_str);
+  return $ret;
+}
+
+1;

Added: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Admin.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Admin.pm	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Admin.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,568 @@
+package DBIx::Class::Admin;
+
+# check deps
+BEGIN {
+  use Carp::Clan qw/^DBIx::Class/;
+  use DBIx::Class;
+  croak('The following modules are required for DBIx::Class::Admin ' . DBIx::Class::Optional::Dependencies->req_missing_for ('admin') )
+    unless DBIx::Class::Optional::Dependencies->req_ok_for ('admin');
+}
+
+use Moose;
+use MooseX::Types::Moose qw/Int Str Any Bool/;
+use DBIx::Class::Admin::Types qw/DBICConnectInfo DBICHashRef/;
+use MooseX::Types::JSON qw(JSON);
+use MooseX::Types::Path::Class qw(Dir File);
+use Try::Tiny;
+use JSON::Any qw(DWIW XS JSON);
+use namespace::autoclean;
+
+=head1 NAME
+
+DBIx::Class::Admin - Administration object for schemas
+
+=head1 SYNOPSIS
+
+  $ dbicadmin --help
+
+  $ dbicadmin --schema=MyApp::Schema \
+    --connect='["dbi:SQLite:my.db", "", ""]' \
+    --deploy
+
+  $ dbicadmin --schema=MyApp::Schema --class=Employee \
+    --connect='["dbi:SQLite:my.db", "", ""]' \
+    --op=update --set='{ "name": "New_Employee" }'
+
+  use DBIx::Class::Admin;
+
+  # ddl manipulation
+  my $admin = DBIx::Class::Admin->new(
+    schema_class=> 'MY::Schema',
+    sql_dir=> $sql_dir,
+    connect_info => { dsn => $dsn, user => $user, password => $pass },
+  );
+
+  # create SQLite sql
+  $admin->create('SQLite');
+
+  # create SQL diff for an upgrade
+  $admin->create('SQLite', {} , "1.0");
+
+  # upgrade a database
+  $admin->upgrade();
+
+  # install a version for an unversioned schema
+  $admin->install("3.0");
+
+=head1 REQUIREMENTS
+
+The Admin interface has additional requirements not currently part of
+L<DBIx::Class>. See L<DBIx::Class::Optional::Dependencies> for more details.
+
+=head1 ATTRIBUTES
+
+=head2 schema_class
+
+the class of the schema to load
+
+=cut
+
+has 'schema_class' => (
+  is  => 'ro',
+  isa => Str,
+);
+
+
+=head2 schema
+
+A pre-connected schema object can be provided for manipulation
+
+=cut
+
+has 'schema' => (
+  is          => 'ro',
+  isa         => 'DBIx::Class::Schema',
+  lazy_build  => 1,
+);
+
+sub _build_schema {
+  my ($self)  = @_;
+  require Class::MOP;
+  Class::MOP::load_class($self->schema_class);
+
+  $self->connect_info->[3]->{ignore_version} =1;
+  return $self->schema_class->connect(@{$self->connect_info()} ); # ,  $self->connect_info->[3], { ignore_version => 1} );
+}
+
+
+=head2 resultset
+
+a resultset from the schema to operate on
+
+=cut
+
+has 'resultset' => (
+  is  => 'rw',
+  isa => Str,
+);
+
+
+=head2 where
+
+a hash ref or json string to be used for identifying data to manipulate
+
+=cut
+
+has 'where' => (
+  is      => 'rw',
+  isa     => DBICHashRef,
+  coerce  => 1,
+);
+
+
+=head2 set
+
+a hash ref or json string to be used for inserting or updating data
+
+=cut
+
+has 'set' => (
+  is      => 'rw',
+  isa     => DBICHashRef,
+  coerce  => 1,
+);
+
+
+=head2 attrs
+
+a hash ref or json string to be used for passing additonal info to the ->search call
+
+=cut
+
+has 'attrs' => (
+  is      => 'rw',
+  isa     => DBICHashRef,
+  coerce  => 1,
+);
+
+
+=head2 connect_info
+
+connect_info the arguments to provide to the connect call of the schema_class
+
+=cut
+
+has 'connect_info' => (
+  is          => 'ro',
+  isa         => DBICConnectInfo,
+  lazy_build  => 1,
+  coerce      => 1,
+);
+
+sub _build_connect_info {
+  my ($self) = @_;
+  return $self->_find_stanza($self->config, $self->config_stanza);
+}
+
+
+=head2 config_file
+
+config_file provide a config_file to read connect_info from, if this is provided
+config_stanze should also be provided to locate where the connect_info is in the config
+The config file should be in a format readable by Config::General
+
+=cut
+
+has config_file => (
+  is      => 'ro',
+  isa     => File,
+  coerce  => 1,
+);
+
+
+=head2 config_stanza
+
+config_stanza for use with config_file should be a '::' deliminated 'path' to the connection information
+designed for use with catalyst config files
+
+=cut
+
+has 'config_stanza' => (
+  is  => 'ro',
+  isa => Str,
+);
+
+
+=head2 config
+
+Instead of loading from a file the configuration can be provided directly as a hash ref.  Please note 
+config_stanza will still be required.
+
+=cut
+
+has config => (
+  is          => 'ro',
+  isa         => DBICHashRef,
+  lazy_build  => 1,
+);
+
+sub _build_config {
+  my ($self) = @_;
+
+  eval { require Config::Any }
+    or die ("Config::Any is required to parse the config file.\n");
+
+  my $cfg = Config::Any->load_files ( {files => [$self->config_file], use_ext =>1, flatten_to_hash=>1});
+
+  # just grab the config from the config file
+  $cfg = $cfg->{$self->config_file};
+  return $cfg;
+}
+
+
+=head2 sql_dir
+
+The location where sql ddl files should be created or found for an upgrade.
+
+=cut
+
+has 'sql_dir' => (
+  is      => 'ro',
+  isa     => Dir,
+  coerce  => 1,
+);
+
+
+=head2 version
+
+Used for install, the version which will be 'installed' in the schema
+
+=cut
+
+has version => (
+  is  => 'rw',
+  isa => Str,
+);
+
+
+=head2 preversion
+
+Previouse version of the schema to create an upgrade diff for, the full sql for that version of the sql must be in the sql_dir
+
+=cut
+
+has preversion => (
+  is  => 'rw',
+  isa => Str,
+);
+
+
+=head2 force
+
+Try and force certain operations.
+
+=cut
+
+has force => (
+  is  => 'rw',
+  isa => Bool,
+);
+
+
+=head2 quiet
+
+Be less verbose about actions
+
+=cut
+
+has quiet => (
+  is  => 'rw',
+  isa => Bool,
+);
+
+has '_confirm' => (
+  is  => 'bare',
+  isa => Bool,
+);
+
+
+=head1 METHODS
+
+=head2 create
+
+=over 4
+
+=item Arguments: $sqlt_type, \%sqlt_args, $preversion
+
+=back
+
+L<create> will generate sql for the supplied schema_class in sql_dir.  The flavour of sql to 
+generate can be controlled by suppling a sqlt_type which should be a L<SQL::Translator> name.  
+
+Arguments for L<SQL::Translator> can be supplied in the sqlt_args hashref.
+
+Optional preversion can be supplied to generate a diff to be used by upgrade.
+
+=cut
+
+sub create {
+  my ($self, $sqlt_type, $sqlt_args, $preversion) = @_;
+
+  $preversion ||= $self->preversion();
+
+  my $schema = $self->schema();
+  # create the dir if does not exist
+  $self->sql_dir->mkpath() if ( ! -d $self->sql_dir);
+
+  $schema->create_ddl_dir( $sqlt_type, (defined $schema->schema_version ? $schema->schema_version : ""), $self->sql_dir->stringify, $preversion, $sqlt_args );
+}
+
+
+=head2 upgrade
+
+=over 4
+
+=item Arguments: <none>
+
+=back
+
+upgrade will attempt to upgrade the connected database to the same version as the schema_class.
+B<MAKE SURE YOU BACKUP YOUR DB FIRST>
+
+=cut
+
+sub upgrade {
+  my ($self) = @_;
+  my $schema = $self->schema();
+  if (!$schema->get_db_version()) {
+    # schema is unversioned
+    $schema->throw_exception ("Could not determin current schema version, please either install() or deploy().\n");
+  } else {
+    my $ret = $schema->upgrade();
+    return $ret;
+  }
+}
+
+
+=head2 install
+
+=over 4
+
+=item Arguments: $version
+
+=back
+
+install is here to help when you want to move to L<DBIx::Class::Schema::Versioned> and have an existing 
+database.  install will take a version and add the version tracking tables and 'install' the version.  No 
+further ddl modification takes place.  Setting the force attribute to a true value will allow overriding of 
+already versioned databases.
+
+=cut
+
+sub install {
+  my ($self, $version) = @_;
+
+  my $schema = $self->schema();
+  $version ||= $self->version();
+  if (!$schema->get_db_version() ) {
+    # schema is unversioned
+    print "Going to install schema version\n";
+    my $ret = $schema->install($version);
+    print "retun is $ret\n";
+  }
+  elsif ($schema->get_db_version() and $self->force ) {
+    carp "Forcing install may not be a good idea";
+    if($self->_confirm() ) {
+      $self->schema->_set_db_version({ version => $version});
+    }
+  }
+  else {
+    $schema->throw_exception ("Schema already has a version. Try upgrade instead.\n");
+  }
+
+}
+
+
+=head2 deploy
+
+=over 4
+
+=item Arguments: $args
+
+=back
+
+deploy will create the schema at the connected database.  C<$args> are passed straight to 
+L<DBIx::Class::Schema/deploy>.
+
+=cut
+
+sub deploy {
+  my ($self, $args) = @_;
+  my $schema = $self->schema();
+  if (!$schema->get_db_version() ) {
+    # schema is unversioned
+    $schema->deploy( $args, $self->sql_dir)
+      or $schema->throw_exception ("Could not deploy schema.\n"); # FIXME deploy() does not return 1/0 on success/fail
+  } else {
+    $schema->throw_exception("A versioned schema has already been deployed, try upgrade instead.\n");
+  }
+}
+
+=head2 insert
+
+=over 4
+
+=item Arguments: $rs, $set
+
+=back
+
+insert takes the name of a resultset from the schema_class and a hashref of data to insert
+into that resultset
+
+=cut
+
+sub insert {
+  my ($self, $rs, $set) = @_;
+
+  $rs ||= $self->resultset();
+  $set ||= $self->set();
+  my $resultset = $self->schema->resultset($rs);
+  my $obj = $resultset->create( $set );
+  print ''.ref($resultset).' ID: '.join(',',$obj->id())."\n" if (!$self->quiet);
+}
+
+
+=head2 update
+
+=over 4
+
+=item Arguments: $rs, $set, $where
+
+=back
+
+update takes the name of a resultset from the schema_class, a hashref of data to update and
+a where hash used to form the search for the rows to update.
+
+=cut
+
+sub update {
+  my ($self, $rs, $set, $where) = @_;
+
+  $rs ||= $self->resultset();
+  $where ||= $self->where();
+  $set ||= $self->set();
+  my $resultset = $self->schema->resultset($rs);
+  $resultset = $resultset->search( ($where||{}) );
+
+  my $count = $resultset->count();
+  print "This action will modify $count ".ref($resultset)." records.\n" if (!$self->quiet);
+
+  if ( $self->force || $self->_confirm() ) {
+    $resultset->update_all( $set );
+  }
+}
+
+
+=head2 delete
+
+=over 4
+
+=item Arguments: $rs, $where, $attrs
+
+=back
+
+delete takes the name of a resultset from the schema_class, a where hashref and a attrs to pass to ->search.
+The found data is deleted and cannot be recovered.
+
+=cut
+
+sub delete {
+  my ($self, $rs, $where, $attrs) = @_;
+
+  $rs ||= $self->resultset();
+  $where ||= $self->where();
+  $attrs ||= $self->attrs();
+  my $resultset = $self->schema->resultset($rs);
+  $resultset = $resultset->search( ($where||{}), ($attrs||()) );
+
+  my $count = $resultset->count();
+  print "This action will delete $count ".ref($resultset)." records.\n" if (!$self->quiet);
+
+  if ( $self->force || $self->_confirm() ) {
+    $resultset->delete_all();
+  }
+}
+
+
+=head2 select
+
+=over 4
+
+=item Arguments: $rs, $where, $attrs
+
+=back
+
+select takes the name of a resultset from the schema_class, a where hashref and a attrs to pass to ->search. 
+The found data is returned in a array ref where the first row will be the columns list.
+
+=cut
+
+sub select {
+  my ($self, $rs, $where, $attrs) = @_;
+
+  $rs ||= $self->resultset();
+  $where ||= $self->where();
+  $attrs ||= $self->attrs();
+  my $resultset = $self->schema->resultset($rs);
+  $resultset = $resultset->search( ($where||{}), ($attrs||()) );
+
+  my @data;
+  my @columns = $resultset->result_source->columns();
+  push @data, [@columns];# 
+
+  while (my $row = $resultset->next()) {
+    my @fields;
+    foreach my $column (@columns) {
+      push( @fields, $row->get_column($column) );
+    }
+    push @data, [@fields];
+  }
+
+  return \@data;
+}
+
+sub _confirm {
+  my ($self) = @_;
+  print "Are you sure you want to do this? (type YES to confirm) \n";
+  # mainly here for testing
+  return 1 if ($self->meta->get_attribute('_confirm')->get_value($self));
+  my $response = <STDIN>;
+  return 1 if ($response=~/^YES/);
+  return;
+}
+
+sub _find_stanza {
+  my ($self, $cfg, $stanza) = @_;
+  my @path = split /::/, $stanza;
+  while (my $path = shift @path) {
+    if (exists $cfg->{$path}) {
+      $cfg = $cfg->{$path};
+    }
+    else {
+      die ("Could not find $stanza in config, $path does not seem to exist.\n");
+    }
+  }
+  return $cfg;
+}
+
+=head1 AUTHOR
+
+See L<DBIx::Class/CONTRIBUTORS>.
+
+=head1 LICENSE
+
+You may distribute this code under the same terms as Perl itself
+
+=cut
+
+1;

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/AbstractSearch.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/AbstractSearch.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/AbstractSearch.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -10,7 +10,7 @@
 
 =head1 SYNOPSIS
 
-See DBIx::Class::CDBICompat for directions for use.
+See DBIx::Class::CDBICompat for usage directions.
 
 =head1 DESCRIPTION
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/ColumnsAsHash.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/ColumnsAsHash.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/ColumnsAsHash.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -11,7 +11,7 @@
 
 =head1 SYNOPSIS
 
-See DBIx::Class::CDBICompat for directions for use.
+See DBIx::Class::CDBICompat for usage directions.
 
 =head1 DESCRIPTION
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/Copy.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/Copy.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/Copy.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -12,7 +12,7 @@
 
 =head1 SYNOPSIS
 
-See DBIx::Class::CDBICompat for directions for use.
+See DBIx::Class::CDBICompat for usage directions.
 
 =head1 DESCRIPTION
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/Iterator.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/Iterator.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat/Iterator.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -10,7 +10,7 @@
 
 =head1 SYNOPSIS
 
-See DBIx::Class::CDBICompat for directions for use.
+See DBIx::Class::CDBICompat for usage directions.
 
 =head1 DESCRIPTION
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/CDBICompat.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -91,7 +91,7 @@
 
 =head2 Choosing Features
 
-In fact, this class is just a receipe containing all the features emulated.
+In fact, this class is just a recipe containing all the features emulated.
 If you like, you can choose which features to emulate by building your 
 own class and loading it like this:
 
@@ -145,7 +145,7 @@
 
 =item Relationships
 
-Relationships between tables (has_a, has_many...) must be delcared after all tables in the relationship have been declared.  Thus the usual CDBI idiom of declaring columns and relationships for each class together will not work.  They must instead be done like so:
+Relationships between tables (has_a, has_many...) must be declared after all tables in the relationship have been declared.  Thus the usual CDBI idiom of declaring columns and relationships for each class together will not work.  They must instead be done like so:
 
     package Foo;
     use base qw(Class::DBI);

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/InflateColumn/File.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/InflateColumn/File.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/InflateColumn/File.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -176,7 +176,7 @@
 
 =head2 _file_column_callback ($file,$ret,$target)
 
-method made to be overridden for callback purposes.
+Method made to be overridden for callback purposes.
 
 =cut
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/InflateColumn.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/InflateColumn.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/InflateColumn.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -26,7 +26,7 @@
 
 It can be used, for example, to automatically convert to and from
 L<DateTime> objects for your date and time fields. There's a
-conveniece component to actually do that though, try
+convenience component to actually do that though, try
 L<DBIx::Class::InflateColumn::DateTime>.
 
 It will handle all types of references except scalar references. It
@@ -114,7 +114,7 @@
 
 Fetch a column value in its inflated state.  This is directly
 analogous to L<DBIx::Class::Row/get_column> in that it only fetches a
-column already retreived from the database, and then inflates it.
+column already retrieved from the database, and then inflates it.
 Throws an exception if the column requested is not an inflated column.
 
 =cut

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Component.pod
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Component.pod	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Component.pod	2010-02-19 11:17:57 UTC (rev 8755)
@@ -106,7 +106,7 @@
 
 =head2 Experimental
 
-These components are under development, there interfaces may
+These components are under development, their interfaces may
 change, they may not work, etc.  So, use them if you want, but
 be warned.
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Cookbook.pod
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Cookbook.pod	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Cookbook.pod	2010-02-19 11:17:57 UTC (rev 8755)
@@ -141,7 +141,7 @@
   );
 
 ... and you'll get back a perfect L<DBIx::Class::ResultSet> (except, of course,
-that you cannot modify the rows it contains, ie. cannot call L</update>,
+that you cannot modify the rows it contains, e.g. cannot call L</update>,
 L</delete>, ...  on it).
 
 Note that you cannot have bind parameters unless is_virtual is set to true.
@@ -201,7 +201,7 @@
   # SELECT name name, LENGTH( name )
   # FROM artist
 
-Note that the C<as> attribute B<has absolutely nothing to do> with the sql
+Note that the C<as> attribute B<has absolutely nothing to do> with the SQL
 syntax C< SELECT foo AS bar > (see the documentation in 
 L<DBIx::Class::ResultSet/ATTRIBUTES>). You can control the C<AS> part of the
 generated SQL via the C<-as> field attribute as follows:
@@ -329,7 +329,7 @@
     artist_id => { 'IN' => $inside_rs->get_column('id')->as_query },
   });
 
-The usual operators ( =, !=, IN, NOT IN, etc) are supported.
+The usual operators ( =, !=, IN, NOT IN, etc.) are supported.
 
 B<NOTE>: You have to explicitly use '=' when doing an equality comparison.
 The following will B<not> work:
@@ -411,7 +411,7 @@
 
 Using SQL functions on the left hand side of a comparison is generally not a
 good idea since it requires a scan of the entire table. (Unless your RDBMS
-supports indexes on expressions - including return values of functions -, and
+supports indexes on expressions - including return values of functions - and
 you create an index on the return value of the function in question.) However,
 it can be accomplished with C<DBIx::Class> when necessary.
 
@@ -771,7 +771,7 @@
 
     package My::App::Schema;
 
-    use base DBIx::Class::Schema;
+    use base 'DBIx::Class::Schema';
 
     # load subclassed classes from My::App::Schema::Result/ResultSet
     __PACKAGE__->load_namespaces;
@@ -791,7 +791,7 @@
 
     use strict;
     use warnings;
-    use base My::Shared::Model::Result::Baz;
+    use base 'My::Shared::Model::Result::Baz';
 
     # WARNING: Make sure you call table() again in your subclass,
     # otherwise DBIx::Class::ResultSourceProxy::Table will not be called
@@ -814,7 +814,7 @@
 for admin.  We would like like to give the admin users
 objects (L<DBIx::Class::Row>) the same methods as a regular user but
 also special admin only methods.  It doesn't make sense to create two
-seperate proxy-class files for this.  We would be copying all the user
+separate proxy-class files for this.  We would be copying all the user
 methods into the Admin class.  There is a cleaner way to accomplish
 this.
 
@@ -1268,7 +1268,7 @@
   my $schema = MySchema->connect("dbi:Pg:dbname=my_db");
 
   # Start a transaction. Every database change from here on will only be 
-  # commited into the database if the eval block succeeds.
+  # committed into the database if the eval block succeeds.
   eval {
     $schema->txn_do(sub {
       # SQL: BEGIN WORK;
@@ -1321,7 +1321,7 @@
   };
   if ($@) {
     # There was an error while handling the $job. Rollback all changes
-    # since the transaction started, including the already commited
+    # since the transaction started, including the already committed
     # ('released') savepoints. There will be neither a new $job nor any
     # $thing entry in the database.
 
@@ -1621,10 +1621,10 @@
 Add the L<DBIx::Class::Schema::Versioned> schema component to your
 Schema class. This will add a new table to your database called
 C<dbix_class_schema_vesion> which will keep track of which version is installed
-and warn if the user trys to run a newer schema version than the
+and warn if the user tries to run a newer schema version than the
 database thinks it has.
 
-Alternatively, you can send the conversion sql scripts to your
+Alternatively, you can send the conversion SQL scripts to your
 customers as above.
 
 =head2 Setting quoting for the generated SQL
@@ -1706,7 +1706,7 @@
     }
   );
 
-In conditions (eg. C<\%cond> in the L<DBIx::Class::ResultSet/search> family of
+In conditions (e.g. C<\%cond> in the L<DBIx::Class::ResultSet/search> family of
 methods) you cannot directly use array references (since this is interpreted as
 a list of values to be C<OR>ed), but you can use the following syntax to force
 passing them as bind values:

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Example.pod
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Example.pod	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Example.pod	2010-02-19 11:17:57 UTC (rev 8755)
@@ -58,7 +58,7 @@
     title TEXT NOT NULL
   );
 
-and create the sqlite database file:
+and create the SQLite database file:
 
   sqlite3 example.db < example.sql
 
@@ -198,7 +198,7 @@
   use strict;
 
   my $schema = MyDatabase::Main->connect('dbi:SQLite:db/example.db');
-  # for other DSNs, e.g. MySql, see the perldoc for the relevant dbd
+  # for other DSNs, e.g. MySQL, see the perldoc for the relevant dbd
   # driver, e.g perldoc L<DBD::mysql>.
 
   get_tracks_by_cd('Bad');
@@ -345,7 +345,7 @@
 
 =head1 Notes
 
-A reference implentation of the database and scripts in this example
+A reference implementation of the database and scripts in this example
 are available in the main distribution for DBIx::Class under the
 directory F<t/examples/Schema>.
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/FAQ.pod
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/FAQ.pod	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/FAQ.pod	2010-02-19 11:17:57 UTC (rev 8755)
@@ -641,7 +641,7 @@
 second one will use a default port of 5433, while L<DBD::Pg> is compiled with a
 default port of 5432.
 
-You can chance the port setting in C<postgresql.conf>.
+You can change the port setting in C<postgresql.conf>.
 
 =item I've lost or forgotten my mysql password
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Intro.pod
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Intro.pod	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Intro.pod	2010-02-19 11:17:57 UTC (rev 8755)
@@ -225,7 +225,7 @@
 Note that L<DBIx::Class::Schema> does not cache connections for you. If you use
 multiple connections, you need to do this manually.
 
-To execute some sql statements on every connect you can add them as an option in
+To execute some SQL statements on every connect you can add them as an option in
 a special fifth argument to connect:
 
   my $another_schema = My::Schema->connect(

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Joining.pod
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Joining.pod	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Joining.pod	2010-02-19 11:17:57 UTC (rev 8755)
@@ -113,7 +113,7 @@
 
 =head2 Whole related objects
 
-To fetch entire related objects, eg CDs and all Track data, use the
+To fetch entire related objects, e.g. CDs and all Track data, use the
 'prefetch' attribute:
 
   $schema->resultset('CD')->search(
@@ -129,7 +129,7 @@
   SELECT cd.ID, cd.Title, cd.Year, tracks.id, tracks.Name, tracks.Artist FROM CD JOIN Tracks ON CD.ID = tracks.CDID WHERE cd.Title = 'Funky CD' ORDER BY 'tracks.id';
 
 The syntax of 'prefetch' is the same as 'join' and implies the
-joining, so no need to use both together.
+joining, so there is no need to use both together.
 
 =head2 Subset of related fields
 
@@ -232,7 +232,7 @@
 
 To perform joins using relations of the tables you are joining to, use
 a hashref to indicate the join depth. This can theoretically go as
-deep as you like (warning, contrived examples!): 
+deep as you like (warning: contrived examples!): 
 
   join => { room => { table => 'leg' } }
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Reading.pod
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Reading.pod	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Reading.pod	2010-02-19 11:17:57 UTC (rev 8755)
@@ -17,14 +17,14 @@
 Methods should be documented in the files which also contain the code
 for the method, or that file should be hidden from PAUSE completely,
 in which case the methods are documented in the file which loads
-it. Methods may also be documented and refered to in files
+it. Methods may also be documented and referred to in files
 representing the major objects or components on which they can be
 called.
 
 For example, L<DBIx::Class::Relationship> documents the methods
 actually coded in the helper relationship classes like
 DBIx::Class::Relationship::BelongsTo. The BelongsTo file itself is
-hidden from pause as it has no documentation. The accessors created by
+hidden from PAUSE as it has no documentation. The accessors created by
 relationships should be mentioned in L<DBIx::Class::Row>, the major
 object that they will be called on.
 
@@ -46,7 +46,7 @@
 what the method returns.
 
 The first item provides a list of all possible values for the
-arguments of the method in order, separated by C<, >, preceeded by the
+arguments of the method in order, separated by C<, >, preceded by the
 text "Arguments: "
 
 Example (for the belongs_to relationship):
@@ -145,10 +145,10 @@
 =item *
 
 The argument list is followed by some examples of how to use the
-method, using it's various types of arguments.
+method, using its various types of arguments.
 
 The examples can also include ways to use the results if
-applicable. For instance if the documentation is for a relationship
+applicable. For instance, if the documentation is for a relationship
 type, the examples can include how to call the resulting relation
 accessor, how to use the relation name in a search and so on.
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Troubleshooting.pod
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Troubleshooting.pod	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Manual/Troubleshooting.pod	2010-02-19 11:17:57 UTC (rev 8755)
@@ -23,7 +23,7 @@
 
   $schema->storage->debugfh(IO::File->new('/tmp/trace.out', 'w');
 
-Alternatively you can do this with the environment variable too:-
+Alternatively you can do this with the environment variable, too:-
 
   export DBIC_TRACE="1=/tmp/trace.out"
 
@@ -51,9 +51,8 @@
 
 There's likely a syntax error in the table class referred to elsewhere
 in this error message.  In particular make sure that the package
-declaration is correct, so for a schema C< MySchema > you need to
-specify a fully qualified namespace: C< package MySchema::MyTable; >
-for example.
+declaration is correct. For example, for a schema C< MySchema > 
+you need to specify a fully qualified namespace: C< package MySchema::MyTable; >.
 
 =head2 syntax error at or near "<something>" ...
 
@@ -103,7 +102,7 @@
 =head2 column "foo DESC" does not exist ...
 
 This can happen if you are still using the obsolete order hack, and also
-happen to turn on sql-quoting.
+happen to turn on SQL-quoting.
 
   $rs->search( {}, { order_by => [ 'name DESC' ] } );
 
@@ -133,15 +132,15 @@
   Fedora 8     - perl-5.8.8-41.fc8
   RHEL5        - perl-5.8.8-15.el5_2.1
 
-The issue is due to perl doing an exhaustive search of blessed objects
+This issue is due to perl doing an exhaustive search of blessed objects
 under certain circumstances.  The problem shows up as performance
-degredation exponential to the number of L<DBIx::Class> row objects in
-memory, so can be unoticeable with certain data sets, but with huge
+degradation exponential to the number of L<DBIx::Class> row objects in
+memory, so can be unnoticeable with certain data sets, but with huge
 performance impacts on other datasets.
 
-A pair of tests for susceptability to the issue, and performance effects
+A pair of tests for susceptibility to the issue and performance effects
 of the bless/overload problem can be found in the L<DBIx::Class> test
-suite in the file C<t/99rh_perl_perf_bug.t>
+suite, in the C<t/99rh_perl_perf_bug.t> file.
 
 Further information on this issue can be found in
 L<https://bugzilla.redhat.com/show_bug.cgi?id=379791>,
@@ -150,7 +149,7 @@
 
 =head2 Excessive Memory Allocation with TEXT/BLOB/etc. Columns and Large LongReadLen
 
-It has been observed, using L<DBD::ODBC>, that a creating a L<DBIx::Class::Row> 
+It has been observed, using L<DBD::ODBC>, that creating a L<DBIx::Class::Row> 
 object which includes a column of data type TEXT/BLOB/etc. will allocate 
 LongReadLen bytes.  This allocation does not leak, but if LongReadLen 
 is large in size, and many such row objects are created, e.g. as the 


Property changes on: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Optional
___________________________________________________________________
Name: svn:ignore
   + Dependencies.pod


Added: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Optional/Dependencies.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Optional/Dependencies.pm	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Optional/Dependencies.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,396 @@
+package DBIx::Class::Optional::Dependencies;
+
+use warnings;
+use strict;
+
+use Carp;
+
+# NO EXTERNAL NON-5.8.1 CORE DEPENDENCIES EVER (e.g. C::A::G)
+# This module is to be loaded by Makefile.PM on a pristine system
+
+# POD is generated automatically by calling _gen_pod from the
+# Makefile.PL in $AUTHOR mode
+
+my $moose_basic = {
+  'Moose'                      => '0.98',
+  'MooseX::Types'              => '0.21',
+};
+
+my $admin_basic = {
+  %$moose_basic,
+  'MooseX::Types::Path::Class' => '0.05',
+  'MooseX::Types::JSON'        => '0.02',
+  'JSON::Any'                  => '1.22',
+  'namespace::autoclean'       => '0.09',
+};
+
+my $reqs = {
+  dist => {
+    #'Module::Install::Pod::Inherit' => '0.01',
+  },
+
+  replicated => {
+    req => {
+      %$moose_basic,
+      'namespace::clean'          => '0.11',
+      'Hash::Merge'               => '0.12',
+    },
+    pod => {
+      title => 'Storage::Replicated',
+      desc => 'Modules required for L<DBIx::Class::Storage::DBI::Replicated>',
+    },
+  },
+
+  admin => {
+    req => {
+      %$admin_basic,
+    },
+    pod => {
+      title => 'DBIx::Class::Admin',
+      desc => 'Modules required for the DBIx::Class administrative library',
+    },
+  },
+
+  admin_script => {
+    req => {
+      %$moose_basic,
+      %$admin_basic,
+      'Getopt::Long::Descriptive' => '0.081',
+      'Text::CSV'                 => '1.16',
+    },
+    pod => {
+      title => 'dbicadmin',
+      desc => 'Modules required for the CLI DBIx::Class interface dbicadmin',
+    },
+  },
+
+  deploy => {
+    req => {
+      'SQL::Translator'           => '0.11002',
+    },
+    pod => {
+      title => 'Storage::DBI::deploy()',
+      desc => 'Modules required for L<DBIx::Class::Storage::DBI/deploy> and L<DBIx::Class::Storage::DBI/deploymen_statements>',
+    },
+  },
+
+  author => {
+    req => {
+      'Test::Pod'                 => '1.26',
+      'Test::Pod::Coverage'       => '1.08',
+      'Pod::Coverage'             => '0.20',
+      #'Test::NoTabs'              => '0.9',
+      #'Test::EOL'                 => '0.6',
+    },
+  },
+
+  core => {
+    req => {
+      # t/52cycle.t
+      'Test::Memory::Cycle'       => '0',
+      'Devel::Cycle'              => '1.10',
+
+      # t/36datetime.t
+      # t/60core.t
+      'DateTime::Format::SQLite'  => '0',
+
+      # t/96_is_deteministic_value.t
+      'DateTime::Format::Strptime'=> '0',
+    },
+  },
+
+  cdbicompat => {
+    req => {
+      'DBIx::ContextualFetch'     => '0',
+      'Class::DBI::Plugin::DeepAbstractSearch' => '0',
+      'Class::Trigger'            => '0',
+      'Time::Piece::MySQL'        => '0',
+      'Clone'                     => '0',
+      'Date::Simple'              => '3.03',
+    },
+  },
+
+  rdbms_pg => {
+    req => {
+      $ENV{DBICTEST_PG_DSN}
+        ? (
+          'Sys::SigAction'        => '0',
+          'DBD::Pg'               => '2.009002',
+          'DateTime::Format::Pg'  => '0',
+        ) : ()
+    },
+  },
+
+  rdbms_mysql => {
+    req => {
+      $ENV{DBICTEST_MYSQL_DSN}
+        ? (
+          'DateTime::Format::MySQL' => '0',
+          'DBD::mysql'              => '0',
+        ) : ()
+    },
+  },
+
+  rdbms_oracle => {
+    req => {
+      $ENV{DBICTEST_ORA_DSN}
+        ? (
+          'DateTime::Format::Oracle' => '0',
+        ) : ()
+    },
+  },
+
+  rdbms_ase => {
+    req => {
+      $ENV{DBICTEST_SYBASE_DSN}
+        ? (
+          'DateTime::Format::Sybase' => 0,
+        ) : ()
+    },
+  },
+
+  rdbms_asa => {
+    req => {
+      (scalar grep $_, @ENV{qw/DBICTEST_SYBASE_ASA_DSN DBICTEST_SYBASE_ASA_ODBC_DSN/})
+        ? (
+          'DateTime::Format::Strptime' => 0,
+        ) : ()
+    },
+  },
+};
+
+
+sub _all_optional_requirements {
+  return { map { %{ $reqs->{$_}{req} || {} } } (keys %$reqs) };
+}
+
+sub req_list_for {
+  my ($class, $group) = @_;
+
+  croak "req_list_for() expects a requirement group name"
+    unless $group;
+
+  my $deps = $reqs->{$group}{req}
+    or croak "Requirement group '$group' does not exist";
+
+  return { %$deps };
+}
+
+
+our %req_availability_cache;
+sub req_ok_for {
+  my ($class, $group) = @_;
+
+  croak "req_ok_for() expects a requirement group name"
+    unless $group;
+
+  $class->_check_deps ($group) unless $req_availability_cache{$group};
+
+  return $req_availability_cache{$group}{status};
+}
+
+sub req_missing_for {
+  my ($class, $group) = @_;
+
+  croak "req_missing_for() expects a requirement group name"
+    unless $group;
+
+  $class->_check_deps ($group) unless $req_availability_cache{$group};
+
+  return $req_availability_cache{$group}{missing};
+}
+
+sub req_errorlist_for {
+  my ($class, $group) = @_;
+
+  croak "req_errorlist_for() expects a requirement group name"
+    unless $group;
+
+  $class->_check_deps ($group) unless $req_availability_cache{$group};
+
+  return $req_availability_cache{$group}{errorlist};
+}
+
+sub _check_deps {
+  my ($class, $group) = @_;
+
+  my $deps = $class->req_list_for ($group);
+
+  my %errors;
+  for my $mod (keys %$deps) {
+    if (my $ver = $deps->{$mod}) {
+      eval "use $mod $ver ()";
+    }
+    else {
+      eval "require $mod";
+    }
+
+    $errors{$mod} = $@ if $@;
+  }
+
+  if (keys %errors) {
+    my $missing = join (', ', map { $deps->{$_} ? "$_ >= $deps->{$_}" : $_ } (sort keys %errors) );
+    $missing .= " (see $class for details)" if $reqs->{$group}{pod};
+    $req_availability_cache{$group} = {
+      status => 0,
+      errorlist => { %errors },
+      missing => $missing,
+    };
+  }
+  else {
+    $req_availability_cache{$group} = {
+      status => 1,
+      errorlist => {},
+      missing => '',
+    };
+  }
+}
+
+# This is to be called by the author onbly (automatically in Makefile.PL)
+sub _gen_pod {
+  my $class = shift;
+  my $modfn = __PACKAGE__ . '.pm';
+  $modfn =~ s/\:\:/\//g;
+
+  require DBIx::Class;
+  my $distver = DBIx::Class->VERSION;
+
+  my @chunks = (
+    <<"EOC",
+#########################################################################
+#####################  A U T O G E N E R A T E D ########################
+#########################################################################
+#
+# The contents of this POD file are auto-generated.  Any changes you make
+# will be lost. If you need to change the generated text edit _gen_pod()
+# at the end of $modfn
+#
+EOC
+    '=head1 NAME',
+    "$class - Optional module dependency specifications (for module authors)",
+    '=head1 SYNOPSIS (EXPERIMENTAL)',
+    <<EOS,
+B<THE USAGE SHOWN HERE IS EXPERIMENTAL>
+
+Somewhere in your build-file (e.g. L<Module::Install>'s Makefile.PL):
+
+  ...
+
+  configure_requires 'DBIx::Class' => '$distver';
+
+  require $class;
+
+  my \$deploy_deps = $class->req_list_for ('deploy');
+
+  for (keys %\$deploy_deps) {
+    requires \$_ => \$deploy_deps->{\$_};
+  }
+
+  ...
+
+Note that there are some caveats regarding C<configure_requires()>, more info
+can be found at L<Module::Install/configure_requires>
+EOS
+    '=head1 DESCRIPTION',
+    <<'EOD',
+Some of the less-frequently used features of L<DBIx::Class> have external
+module dependencies on their own. In order not to burden the average user
+with modules he will never use, these optional dependencies are not included
+in the base Makefile.PL. Instead an exception with a descriptive message is
+thrown when a specific feature is missing one or several modules required for
+its operation. This module is the central holding place for  the current list
+of such dependencies, for DBIx::Class core authors, and DBIx::Class extension
+authors alike.
+EOD
+    '=head1 CURRENT REQUIREMENT GROUPS',
+    <<'EOD',
+Dependencies are organized in C<groups> and each group can list one or more
+required modules, with an optional minimum version (or 0 for any version).
+The group name can be used in the 
+EOD
+  );
+
+  for my $group (sort keys %$reqs) {
+    my $p = $reqs->{$group}{pod}
+      or next;
+
+    my $modlist = $reqs->{$group}{req}
+      or next;
+
+    next unless keys %$modlist;
+
+    push @chunks, (
+      "=head2 $p->{title}",
+      "$p->{desc}",
+      '=over',
+      ( map { "=item * $_" . ($modlist->{$_} ? " >= $modlist->{$_}" : '') } (sort keys %$modlist) ),
+      '=back',
+      "Requirement group: B<$group>",
+    );
+  }
+
+  push @chunks, (
+    '=head1 METHODS',
+    '=head2 req_list_for',
+    '=over',
+    '=item Arguments: $group_name',
+    '=item Returns: \%list_of_module_version_pairs',
+    '=back',
+    <<EOD,
+This method should be used by DBIx::Class extension authors, to determine the
+version of modules a specific feature requires in the B<current> version of
+DBIx::Class. See the L<SYNOPSIS|/SYNOPSIS (EXPERIMENTAL)> for a real-world
+example.
+EOD
+
+    '=head2 req_ok_for',
+    '=over',
+    '=item Arguments: $group_name',
+    '=item Returns: 1|0',
+    '=back',
+    'Returns true or false depending on whether all modules required by C<$group_name> are present on the system and loadable',
+
+    '=head2 req_missing_for',
+    '=over',
+    '=item Arguments: $group_name',
+    '=item Returns: $error_message_string',
+    '=back',
+    <<EOD,
+Returns a single line string suitable for inclusion in larger error messages.
+This method would normally be used by DBIx::Class core-module author, to
+indicate to the user that he needs to install specific modules before he will
+be able to use a specific feature.
+
+For example if the requirements for C<replicated> are not available, the
+returned string would look like:
+
+ Moose >= 0.98, MooseX::Types >= 0.21, namespace::clean (see $class for details)
+
+The author is expected to prepend the necessary text to this message before
+returning the actual error seen by the user.
+EOD
+
+    '=head2 req_errorlist_for',
+    '=over',
+    '=item Arguments: $group_name',
+    '=item Returns: \%list_of_loaderrors_per_module',
+    '=back',
+    <<'EOD',
+Returns a hashref containing the actual errors that occured while attempting
+to load each module in the requirement group.
+EOD
+    '=head1 AUTHOR',
+    'See L<DBIx::Class/CONTRIBUTORS>.',
+    '=head1 LICENSE',
+    'You may distribute this code under the same terms as Perl itself',
+  );
+
+  my $fn = __FILE__;
+  $fn =~ s/\.pm$/\.pod/;
+
+  open (my $fh, '>', $fn) or croak "Unable to write to $fn: $!";
+  print $fh join ("\n\n", @chunks);
+  close ($fh);
+}
+
+1;

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Ordered.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Ordered.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Ordered.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -127,7 +127,7 @@
 This method specifies a value of L</position_column> which B<would
 never be assigned to a row> during normal operation. When
 a row is moved, its position is set to this value temporarily, so
-that any unique constrainst can not be violated. This value defaults
+that any unique constraints can not be violated. This value defaults
 to 0, which should work for all cases except when your positions do
 indeed start from 0.
 
@@ -797,15 +797,15 @@
 
     if (grep { $_ eq $position_column } ( map { @$_ } (values %{{ $rsrc->unique_constraints }} ) ) ) {
 
-        my @pcols = $rsrc->primary_columns;
+        my @pcols = $rsrc->_pri_cols;
         my $cursor = $shift_rs->search ({}, { order_by => { "-$ord", $position_column }, columns => \@pcols } )->cursor;
         my $rs = $self->result_source->resultset;
 
-        while (my @pks = $cursor->next ) {
-
+        my @all_pks = $cursor->all;
+        while (my $pks = shift @all_pks) {
           my $cond;
           for my $i (0.. $#pcols) {
-            $cond->{$pcols[$i]} = $pks[$i];
+            $cond->{$pcols[$i]} = $pks->[$i];
           }
 
           $rs->search($cond)->update ({ $position_column => \ "$position_column $op 1" } );
@@ -921,7 +921,7 @@
 triggering any of the positioning integrity code).
 
 Some day you might get confronted by datasets that have ambiguous
-positioning data (i.e. duplicate position values within the same group,
+positioning data (e.g. duplicate position values within the same group,
 in a table without unique constraints). When manually fixing such data
 keep in mind that you can not invoke L<DBIx::Class::Row/update> like
 you normally would, as it will get confused by the wrong data before
@@ -956,14 +956,14 @@
 
 =head2 Multiple Moves
 
-Be careful when issueing move_* methods to multiple objects.  If 
+Be careful when issuing move_* methods to multiple objects.  If 
 you've pre-loaded the objects then when you move one of the objects 
 the position of the other object will not reflect their new value 
 until you reload them from the database - see
 L<DBIx::Class::Row/discard_changes>.
 
 There are times when you will want to move objects as groups, such 
-as changeing the parent of several objects at once - this directly 
+as changing the parent of several objects at once - this directly 
 conflicts with this problem.  One solution is for us to write a 
 ResultSet class that supports a parent() method, for example.  Another 
 solution is to somehow automagically modify the objects that exist 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/PK.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/PK.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/PK.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -31,13 +31,27 @@
   my ($self) = @_;
   $self->throw_exception( "Can't call id() as a class method" )
     unless ref $self;
-  my @pk = $self->_ident_values;
-  return (wantarray ? @pk : $pk[0]);
+  my @id_vals = $self->_ident_values;
+  return (wantarray ? @id_vals : $id_vals[0]);
 }
 
 sub _ident_values {
   my ($self) = @_;
-  return (map { $self->{_column_data}{$_} } $self->primary_columns);
+  my (@ids, @missing);
+
+  for ($self->_pri_cols) {
+    push @ids, $self->get_column($_);
+    push @missing, $_ if (! defined $ids[-1] and ! $self->has_column_loaded ($_) );
+  }
+
+  if (@missing && $self->in_storage) {
+    $self->throw_exception (
+      'Unable to uniquely identify row object with missing PK columns: '
+      . join (', ', @missing )
+    );
+  }
+
+  return @ids;
 }
 
 =head2 ID
@@ -64,12 +78,11 @@
   $self->throw_exception( "Can't call ID() as a class method" )
     unless ref $self;
   return undef unless $self->in_storage;
-  return $self->_create_ID(map { $_ => $self->{_column_data}{$_} }
-                             $self->primary_columns);
+  return $self->_create_ID(%{$self->ident_condition});
 }
 
 sub _create_ID {
-  my ($self,%vals) = @_;
+  my ($self, %vals) = @_;
   return undef unless 0 == grep { !defined } values %vals;
   return join '|', ref $self || $self, $self->result_source->name,
     map { $_ . '=' . $vals{$_} } sort keys %vals;
@@ -87,9 +100,25 @@
 
 sub ident_condition {
   my ($self, $alias) = @_;
-  my %cond;
+
+  my @pks = $self->_pri_cols;
+  my @vals = $self->_ident_values;
+
+  my (%cond, @undef);
   my $prefix = defined $alias ? $alias.'.' : '';
-  $cond{$prefix.$_} = $self->get_column($_) for $self->primary_columns;
+  for my $col (@pks) {
+    if (! defined ($cond{$prefix.$col} = shift @vals) ) {
+      push @undef, $col;
+    }
+  }
+
+  if (@undef && $self->in_storage) {
+    $self->throw_exception (
+      'Unable to construct row object identity condition due to NULL PK columns: '
+      . join (', ', @undef)
+    );
+  }
+
   return \%cond;
 }
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/Base.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/Base.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/Base.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -200,9 +200,15 @@
     my $query = ((@_ > 1) ? {@_} : shift);
 
     my $source = $self->result_source;
-    my $cond = $source->_resolve_condition(
-      $rel_info->{cond}, $rel, $self
-    );
+
+    # condition resolution may fail if an incomplete master-object prefetch
+    # is encountered
+    my $cond =
+      eval { $source->_resolve_condition( $rel_info->{cond}, $rel, $self ) }
+        ||
+      $DBIx::Class::ResultSource::UNRESOLVABLE_CONDITION
+    ;
+
     if ($cond eq $DBIx::Class::ResultSource::UNRESOLVABLE_CONDITION) {
       my $reverse = $source->reverse_relationship_info($rel);
       foreach my $rev_rel (keys %$reverse) {
@@ -260,7 +266,7 @@
   ( $objects_rs ) = $rs->search_related_rs('relname', $cond, $attrs);
 
 This method works exactly the same as search_related, except that 
-it guarantees a restultset, even in list context.
+it guarantees a resultset, even in list context.
 
 =cut
 
@@ -392,7 +398,7 @@
 call set_from_related on the book.
 
 This is called internally when you pass existing objects as values to
-L<DBIx::Class::ResultSet/create>, or pass an object to a belongs_to acessor.
+L<DBIx::Class::ResultSet/create>, or pass an object to a belongs_to accessor.
 
 The columns are only set in the local copy of the object, call L</update> to
 set them in the storage.

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/BelongsTo.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/BelongsTo.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/BelongsTo.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -24,19 +24,14 @@
   # no join condition or just a column name
   if (!ref $cond) {
     $class->ensure_class_loaded($f_class);
-    my %f_primaries = map { $_ => 1 } eval { $f_class->primary_columns };
+    my %f_primaries = map { $_ => 1 } eval { $f_class->_pri_cols };
     $class->throw_exception(
-      "Can't infer join condition for ${rel} on ${class}; ".
-      "unable to load ${f_class}: $@"
+      "Can't infer join condition for ${rel} on ${class}: $@"
     ) if $@;
 
     my ($pri, $too_many) = keys %f_primaries;
     $class->throw_exception(
       "Can't infer join condition for ${rel} on ${class}; ".
-      "${f_class} has no primary keys"
-    ) unless defined $pri;
-    $class->throw_exception(
-      "Can't infer join condition for ${rel} on ${class}; ".
       "${f_class} has multiple primary keys"
     ) if $too_many;
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/HasMany.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/HasMany.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/HasMany.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -14,7 +14,10 @@
 
   unless (ref $cond) {
     $class->ensure_class_loaded($f_class);
-    my ($pri, $too_many) = $class->primary_columns;
+    my ($pri, $too_many) = eval { $class->_pri_cols };
+    $class->throw_exception(
+      "Can't infer join condition for ${rel} on ${class}: $@"
+    ) if $@;
 
     $class->throw_exception(
       "has_many can only infer join for a single primary key; ".

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/HasOne.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/HasOne.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship/HasOne.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -24,7 +24,7 @@
     $class->ensure_class_loaded($f_class);
 
     my $pri = $class->_get_primary_key;
-  
+
     $class->throw_exception(
       "might_have/has_one needs a primary key  to infer a join; ".
       "${class} has none"
@@ -60,8 +60,12 @@
 sub _get_primary_key {
   my ( $class, $target_class ) = @_;
   $target_class ||= $class;
-  my ($pri, $too_many) = $target_class->primary_columns;
+  my ($pri, $too_many) = eval { $target_class->_pri_cols };
   $class->throw_exception(
+    "Can't infer join condition on ${target_class}: $@"
+  ) if $@;
+
+  $class->throw_exception(
     "might_have/has_one can only infer join for a single primary key; ".
     "${class} has more"
   ) if $too_many;

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Relationship.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -111,7 +111,7 @@
 you want to use the default value for it, but still want to set C<\%attrs>.
 
 See L<DBIx::Class::Relationship::Base> for documentation on the
-attrubutes that are allowed in the C<\%attrs> argument.
+attributes that are allowed in the C<\%attrs> argument.
 
 
 =head2 belongs_to
@@ -234,7 +234,7 @@
 
 Creates a one-to-many relationship where the foreign class refers to
 this class's primary key. This relationship refers to zero or more
-records in the foreign table (ie, a C<LEFT JOIN>). This relationship 
+records in the foreign table (e.g. a C<LEFT JOIN>). This relationship 
 defaults to using the end of this classes namespace as the foreign key
 in C<$related_class> to resolve the join, unless C<$their_fk_column>
 specifies the foreign key column in C<$related_class> or C<cond>

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSet.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSet.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSet.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -141,7 +141,7 @@
 =head1 OVERLOADING
 
 If a resultset is used in a numeric context it returns the L</count>.
-However, if it is used in a booleand context it is always true.  So if
+However, if it is used in a boolean context it is always true.  So if
 you want to check if a resultset has any results use C<if $rs != 0>.
 C<if $rs> will always be true.
 
@@ -291,10 +291,15 @@
     $rows = $self->get_cache;
   }
 
+  # reset the selector list
+  if (List::Util::first { exists $attrs->{$_} } qw{columns select as}) {
+     delete @{$our_attrs}{qw{select as columns +select +as +columns include_columns}};
+  }
+
   my $new_attrs = { %{$our_attrs}, %{$attrs} };
 
   # merge new attrs into inherited
-  foreach my $key (qw/join prefetch +select +as bind/) {
+  foreach my $key (qw/join prefetch +select +as +columns include_columns bind/) {
     next unless exists $attrs->{$key};
     $new_attrs->{$key} = $self->_merge_attr($our_attrs->{$key}, $attrs->{$key});
   }
@@ -519,7 +524,7 @@
     # in ::Relationship::Base::search_related (the row method), and furthermore
     # the relationship is of the 'single' type. This means that the condition
     # provided by the relationship (already attached to $self) is sufficient,
-    # as there can be only one row in the databse that would satisfy the
+    # as there can be only one row in the database that would satisfy the
     # relationship
   }
   else {
@@ -530,7 +535,7 @@
   }
 
   # Run the query
-  my $rs = $self->search ($query, {result_class => $self->result_class, %$attrs});
+  my $rs = $self->search ($query, $attrs);
   if (keys %{$rs->_resolved_attrs->{collapse}}) {
     my $row = $rs->next;
     carp "Query returned more than one row" if $rs->next;
@@ -634,7 +639,7 @@
 =head2 search_related_rs
 
 This method works exactly the same as search_related, except that
-it guarantees a restultset, even in list context.
+it guarantees a resultset, even in list context.
 
 =cut
 
@@ -692,7 +697,7 @@
 
 =item B<Note>
 
-As of 0.08100, this method enforces the assumption that the preceeding
+As of 0.08100, this method enforces the assumption that the preceding
 query returns only one row. If more than one row is returned, you will receive
 a warning:
 
@@ -1131,6 +1136,7 @@
   if ($result_class) {
     $self->ensure_class_loaded($result_class);
     $self->_result_class($result_class);
+    $self->{attrs}{result_class} = $result_class if ref $self;
   }
   $self->_result_class;
 }
@@ -1256,10 +1262,10 @@
   # if we multi-prefetch we group_by primary keys only as this is what we would
   # get out of the rs via ->next/->all. We *DO WANT* to clobber old group_by regardless
   if ( keys %{$attrs->{collapse}}  ) {
-    $sub_attrs->{group_by} = [ map { "$attrs->{alias}.$_" } ($rsrc->primary_columns) ]
+    $sub_attrs->{group_by} = [ map { "$attrs->{alias}.$_" } ($rsrc->_pri_cols) ]
   }
 
-  $sub_attrs->{select} = $rsrc->storage->_subq_count_select ($rsrc, $sub_attrs);
+  $sub_attrs->{select} = $rsrc->storage->_subq_count_select ($rsrc, $attrs);
 
   # this is so that the query can be simplified e.g.
   # * ordering can be thrown away in things like Top limit
@@ -1415,7 +1421,7 @@
     my $attrs = $self->_resolved_attrs_copy;
 
     delete $attrs->{$_} for qw/collapse select as/;
-    $attrs->{columns} = [ map { "$attrs->{alias}.$_" } ($self->result_source->primary_columns) ];
+    $attrs->{columns} = [ map { "$attrs->{alias}.$_" } ($self->result_source->_pri_cols) ];
 
     if ($needs_group_by_subq) {
       # make sure no group_by was supplied, or if there is one - make sure it matches
@@ -1592,7 +1598,7 @@
       ],
      },
      { artistid => 5, name => 'Angsty-Whiny Girl', cds => [
-        { title => 'My parents sold me to a record company' ,year => 2005 },
+        { title => 'My parents sold me to a record company', year => 2005 },
         { title => 'Why Am I So Ugly?', year => 2006 },
         { title => 'I Got Surgery and am now Popular', year => 2007 }
       ],
@@ -1620,7 +1626,7 @@
     [qw/artistid name/],
     [100, 'A Formally Unknown Singer'],
     [101, 'A singer that jumped the shark two albums ago'],
-    [102, 'An actually cool singer.'],
+    [102, 'An actually cool singer'],
   ]);
 
 Please note an important effect on your data when choosing between void and
@@ -2127,7 +2133,7 @@
 B<keyed on the relationship name>. If the relationship is of type C<multi>
 (L<DBIx::Class::Relationship/has_many>) - pass an arrayref of hashrefs.
 The process will correctly identify columns holding foreign keys, and will
-transparrently populate them from the keys of the corresponding relation.
+transparently populate them from the keys of the corresponding relation.
 This can be applied recursively, and will work correctly for a structure
 with an arbitrary depth and width, as long as the relationships actually
 exists and the correct column data has been supplied.
@@ -2465,6 +2471,23 @@
   return !!$self->{attrs}{page};
 }
 
+=head2 is_ordered
+
+=over 4
+
+=item Arguments: none
+
+=item Return Value: true, if the resultset has been ordered with C<order_by>.
+
+=back
+
+=cut
+
+sub is_ordered {
+  my ($self) = @_;
+  return scalar $self->result_source->storage->_parse_order_by($self->{attrs}{order_by});
+}
+
 =head2 related_resultset
 
 =over 4
@@ -2777,41 +2800,46 @@
   # build columns (as long as select isn't set) into a set of as/select hashes
   unless ( $attrs->{select} ) {
 
-    my @cols = ( ref($attrs->{columns}) eq 'ARRAY' )
-      ? @{ delete $attrs->{columns}}
-      : (
-          ( delete $attrs->{columns} )
-            ||
-          $source->columns
-        )
-    ;
+    my @cols;
+    if ( ref $attrs->{columns} eq 'ARRAY' ) {
+      @cols = @{ delete $attrs->{columns}}
+    } elsif ( defined $attrs->{columns} ) {
+      @cols = delete $attrs->{columns}
+    } else {
+      @cols = $source->columns
+    }
 
-    @colbits = map {
-      ( ref($_) eq 'HASH' )
-      ? $_
-      : {
-          (
-            /^\Q${alias}.\E(.+)$/
-              ? "$1"
-              : "$_"
-          )
-            =>
-          (
-            /\./
-              ? "$_"
-              : "${alias}.$_"
-          )
-        }
-    } @cols;
+    for (@cols) {
+      if ( ref $_ eq 'HASH' ) {
+        push @colbits, $_
+      } else {
+        my $key = /^\Q${alias}.\E(.+)$/
+          ? "$1"
+          : "$_";
+        my $value = /\./
+          ? "$_"
+          : "${alias}.$_";
+        push @colbits, { $key => $value };
+      }
+    }
   }
 
   # add the additional columns on
-  foreach ( 'include_columns', '+columns' ) {
-      push @colbits, map {
-          ( ref($_) eq 'HASH' )
-            ? $_
-            : { ( split( /\./, $_ ) )[-1] => ( /\./ ? $_ : "${alias}.$_" ) }
-      } ( ref($attrs->{$_}) eq 'ARRAY' ) ? @{ delete $attrs->{$_} } : delete $attrs->{$_} if ( $attrs->{$_} );
+  foreach (qw{include_columns +columns}) {
+    if ( $attrs->{$_} ) {
+      my @list = ( ref($attrs->{$_}) eq 'ARRAY' )
+        ? @{ delete $attrs->{$_} }
+        : delete $attrs->{$_};
+      for (@list) {
+        if ( ref($_) eq 'HASH' ) {
+          push @colbits, $_
+        } else {
+          my $key = ( split /\./, $_ )[-1];
+          my $value = ( /\./ ? $_ : "$alias.$_" );
+          push @colbits, { $key => $value };
+        }
+      }
+    }
   }
 
   # start with initial select items
@@ -2820,15 +2848,22 @@
         ( ref $attrs->{select} eq 'ARRAY' )
       ? [ @{ $attrs->{select} } ]
       : [ $attrs->{select} ];
-    $attrs->{as} = (
-      $attrs->{as}
-      ? (
-        ref $attrs->{as} eq 'ARRAY'
-        ? [ @{ $attrs->{as} } ]
-        : [ $attrs->{as} ]
+
+    if ( $attrs->{as} ) {
+      $attrs->{as} =
+        (
+          ref $attrs->{as} eq 'ARRAY'
+            ? [ @{ $attrs->{as} } ]
+            : [ $attrs->{as} ]
         )
-      : [ map { m/^\Q${alias}.\E(.+)$/ ? $1 : $_ } @{ $attrs->{select} } ]
-    );
+    } else {
+      $attrs->{as} = [ map {
+         m/^\Q${alias}.\E(.+)$/
+           ? $1
+           : $_
+         } @{ $attrs->{select} }
+      ]
+    }
   }
   else {
 
@@ -2838,27 +2873,24 @@
   }
 
   # now add colbits to select/as
-  push( @{ $attrs->{select} }, map { values( %{$_} ) } @colbits );
-  push( @{ $attrs->{as} },     map { keys( %{$_} ) } @colbits );
+  push @{ $attrs->{select} }, map values %{$_}, @colbits;
+  push @{ $attrs->{as}     }, map keys   %{$_}, @colbits;
 
-  my $adds;
-  if ( $adds = delete $attrs->{'+select'} ) {
+  if ( my $adds = delete $attrs->{'+select'} ) {
     $adds = [$adds] unless ref $adds eq 'ARRAY';
-    push(
-      @{ $attrs->{select} },
-      map { /\./ || ref $_ ? $_ : "${alias}.$_" } @$adds
-    );
+    push @{ $attrs->{select} },
+      map { /\./ || ref $_ ? $_ : "$alias.$_" } @$adds;
   }
-  if ( $adds = delete $attrs->{'+as'} ) {
+  if ( my $adds = delete $attrs->{'+as'} ) {
     $adds = [$adds] unless ref $adds eq 'ARRAY';
-    push( @{ $attrs->{as} }, @$adds );
+    push @{ $attrs->{as} }, @$adds;
   }
 
-  $attrs->{from} ||= [ {
+  $attrs->{from} ||= [{
     -source_handle => $source->handle,
     -alias => $self->{attrs}{alias},
     $self->{attrs}{alias} => $source->from,
-  } ];
+  }];
 
   if ( $attrs->{join} || $attrs->{prefetch} ) {
 
@@ -2878,7 +2910,7 @@
           $join,
           $alias,
           { %{ $attrs->{seen_join} || {} } },
-          ($attrs->{seen_join} && keys %{$attrs->{seen_join}})
+          ( $attrs->{seen_join} && keys %{$attrs->{seen_join}})
             ? $attrs->{from}[-1][0]{-join_path}
             : []
           ,
@@ -3298,7 +3330,7 @@
 will fail miserably.
 
 To get around this limitation, you can supply literal SQL to your
-C<select> attibute that contains the C<AS alias> text, eg:
+C<select> attribute that contains the C<AS alias> text, e.g.
 
   select => [\'myfield AS alias']
 
@@ -3409,7 +3441,7 @@
 C<prefetch> can be used with the following relationship types: C<belongs_to>,
 C<has_one> (or if you're using C<add_relationship>, any relationship declared
 with an accessor type of 'single' or 'filter'). A more complex example that
-prefetches an artists cds, the tracks on those cds, and the tags associted
+prefetches an artists cds, the tracks on those cds, and the tags associated
 with that artist is given below (assuming many-to-many from artists to tags):
 
  my $rs = $schema->resultset('Artist')->search(
@@ -3488,7 +3520,7 @@
 
 =back
 
-Specifes the maximum number of rows for direct retrieval or the number of
+Specifies the maximum number of rows for direct retrieval or the number of
 rows per page if the page attribute or method is used.
 
 =head2 offset

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSetColumn.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSetColumn.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSetColumn.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -83,11 +83,6 @@
   $new_parent_rs ||= $rs->search_rs;
   my $new_attrs = $new_parent_rs->{attrs} ||= {};
 
-  # FIXME - this should go away when the chaining branch is merged
-  # since what we do is actually chain to the original resultset, we need to throw
-  # away all selectors (otherwise they'll chain)
-  delete $new_attrs->{$_} for (qw/columns +columns select +select as +as cols include_columns/);
-
   # prefetch causes additional columns to be fetched, but we can not just make a new
   # rs via the _resolved_attrs trick - we need to retain the separation between
   # +select/+as and select/as. At the same time we want to preserve any joins that the

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSource/Table.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSource/Table.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSource/Table.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -16,7 +16,7 @@
 
 =head1 DESCRIPTION
 
-Table object that inherits from L<DBIx::Class::ResultSource>
+Table object that inherits from L<DBIx::Class::ResultSource>.
 
 =head1 METHODS
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSource.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSource.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSource.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -503,6 +503,16 @@
   return @{shift->_primaries||[]};
 }
 
+sub _pri_cols {
+  my $self = shift;
+  my @pcols = $self->primary_columns
+    or $self->throw_exception (sprintf(
+      'Operation requires a primary key to be declared on %s via set_primary_key',
+      ref $self,
+    ));
+  return @pcols;
+}
+
 =head2 add_unique_constraint
 
 =over 4
@@ -1565,7 +1575,7 @@
   __PACKAGE__->column_info_from_storage(1);
 
 Enables the on-demand automatic loading of the above column
-metadata from storage as neccesary.  This is *deprecated*, and
+metadata from storage as necessary.  This is *deprecated*, and
 should not be used.  It will be removed before 1.0.
 
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSourceHandle.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSourceHandle.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSourceHandle.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -87,7 +87,7 @@
 =head2 STORABLE_thaw
 
 Thaws frozen handle. Resets the internal schema reference to the package
-variable C<$thaw_schema>. The recomened way of setting this is to use 
+variable C<$thaw_schema>. The recommended way of setting this is to use 
 C<< $schema->thaw($ice) >> which handles this for you.
 
 =cut

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSourceProxy.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSourceProxy.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/ResultSourceProxy.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -75,6 +75,10 @@
   shift->result_source_instance->primary_columns(@_);
 }
 
+sub _pri_cols {
+  shift->result_source_instance->_pri_cols(@_);
+}
+
 sub add_unique_constraint {
   shift->result_source_instance->add_unique_constraint(@_);
 }

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Row.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Row.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Row.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -470,7 +470,7 @@
 to C<update>, e.g. ( { %{ $href } } )
 
 If the values passed or any of the column values set on the object
-contain scalar references, eg:
+contain scalar references, e.g.:
 
   $row->last_modified(\'NOW()');
   # OR
@@ -918,7 +918,7 @@
 L<DBIx::Class::Relationship/has_many> key, and create the related
 objects if necessary.
 
-Be aware that the input hashref might be edited in place, so dont rely
+Be aware that the input hashref might be edited in place, so don't rely
 on it being the same after a call to C<set_inflated_columns>. If you
 need to preserve the hashref, it is sufficient to pass a shallow copy
 to C<set_inflated_columns>, e.g. ( { %{ $href } } )
@@ -972,7 +972,7 @@
 the new object.
 
 Relationships will be followed by the copy procedure B<only> if the
-relationship specifes a true value for its
+relationship specifies a true value for its
 L<cascade_copy|DBIx::Class::Relationship::Base> attribute. C<cascade_copy>
 is set by default on C<has_many> relationships and unset on all others.
 
@@ -995,7 +995,7 @@
   $new->insert;
 
   # Its possible we'll have 2 relations to the same Source. We need to make
-  # sure we don't try to insert the same row twice esle we'll violate unique
+  # sure we don't try to insert the same row twice else we'll violate unique
   # constraints
   my $rels_copied = {};
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/SQLAHacks/OracleJoins.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/SQLAHacks/OracleJoins.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/SQLAHacks/OracleJoins.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -96,8 +96,7 @@
 
 This module was originally written to support Oracle < 9i where ANSI joins
 weren't supported at all, but became the module for Oracle >= 8 because
-Oracle's optimising of ANSI joins is horrible.  (See:
-http://scsys.co.uk:8001/7495)
+Oracle's optimising of ANSI joins is horrible.
 
 =head1 SYNOPSIS
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Schema/Versioned.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Schema/Versioned.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Schema/Versioned.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -258,7 +258,7 @@
 
 =back
 
-Virtual method that should be overriden to create an upgrade file.
+Virtual method that should be overridden to create an upgrade file.
 This is useful in the case of upgrading across multiple versions
 to concatenate several files to create one upgrade file.
 
@@ -279,7 +279,7 @@
 
 =back
 
-Virtual method that should be overriden to return an ordered list
+Virtual method that should be overridden to return an ordered list
 of schema versions. This is then used to produce a set of steps to
 upgrade through to achieve the required schema version.
 
@@ -303,7 +303,7 @@
 then it is assumed you can do the upgrade as a single step). It
 then iterates through the list of versions between the current db
 version and the schema version applying one update at a time until
-all relvant updates are applied.
+all relevant updates are applied.
 
 The individual update steps are performed by using
 L</upgrade_single_step>, which will apply the update and also
@@ -544,7 +544,7 @@
 compatibility between the old versions table (SchemaVersions) and the new one
 (dbix_class_schema_versions).
 
-To avoid the checks on connect, set the env var DBIC_NO_VERSION_CHECK or alternatively you can set the ignore_version attr in the forth argument like so:
+To avoid the checks on connect, set the environment var DBIC_NO_VERSION_CHECK or alternatively you can set the ignore_version attr in the forth argument like so:
 
   my $schema = MyApp::Schema->connect(
     $dsn,
@@ -617,8 +617,9 @@
     return;
   }
 
-  $self->throw_exception($self->storage->_sqlt_version_error)
-    if (not $self->storage->_sqlt_version_ok);
+  unless (DBIx::Class::Optional::Dependencies->req_ok_for ('deploy')) {
+    $self->throw_exception("Unable to proceed without " . DBIx::Class::Optional::Dependencies->req_missing_for ('deploy') );
+  }
 
   my $db_tr = SQL::Translator->new({
                                     add_drop_table => 1,

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Schema.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Schema.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Schema.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -82,7 +82,7 @@
 
 With no arguments, this method uses L<Module::Find> to load all your
 Result classes from a sub-namespace F<Result> under your Schema class'
-namespace. Eg. With a Schema of I<MyDB::Schema> all files in
+namespace, i.e. with a Schema of I<MyDB::Schema> all files in
 I<MyDB::Schema::Result> are assumed to be Result classes.
 
 It also finds all ResultSet classes in the namespace F<ResultSet> and
@@ -748,7 +748,7 @@
 L<DBIx::Class::ResultSet/create>, and a arrayref of the resulting row
 objects is returned.
 
-i.e.,
+e.g.
 
   $schema->populate('Artist', [
     [ qw/artistid name/ ],
@@ -851,7 +851,7 @@
 
 It also attaches a corresponding L<DBIx::Class::ResultSource> object to the
 new $schema object. If C<$additional_base_class> is given, the new composed
-classes will inherit from first the corresponding classe from the current
+classes will inherit from first the corresponding class from the current
 schema then the base class.
 
 For example, for a schema with My::Schema::CD and My::Schema::Artist classes,
@@ -1155,7 +1155,7 @@
 
 Provided as the recommended way of thawing schema objects. You can call 
 C<Storable::thaw> directly if you wish, but the thawed objects will not have a
-reference to any schema, so are rather useless
+reference to any schema, so are rather useless.
 
 =cut
 
@@ -1167,8 +1167,8 @@
 
 =head2 freeze
 
-This doesn't actualy do anything more than call L<Storable/freeze>, it is just
-provided here for symetry.
+This doesn't actually do anything more than call L<Storable/freeze>, it is just
+provided here for symmetry.
 
 =cut
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/StartupCheck.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/StartupCheck.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/StartupCheck.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -17,7 +17,7 @@
 triggers, incorrectly flagging those versions of perl to be buggy. A
 more comprehensive check has been moved into the test suite in
 C<t/99rh_perl_perf_bug.t> and further information about the bug has been
-put in L<DBIx::Class::Manual::Troubleshooting>
+put in L<DBIx::Class::Manual::Troubleshooting>.
 
 Other checks may be added from time to time.
 

Deleted: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/AmbiguousGlob.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/AmbiguousGlob.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/AmbiguousGlob.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -1,47 +0,0 @@
-package DBIx::Class::Storage::DBI::AmbiguousGlob;
-
-use strict;
-use warnings;
-
-use base 'DBIx::Class::Storage::DBI';
-use mro 'c3';
-
-=head1 NAME
-
-DBIx::Class::Storage::DBI::AmbiguousGlob - Storage component for RDBMS choking on count(*)
-
-=head1 DESCRIPTION
-
-Some servers choke on things like:
-
-  COUNT(*) FROM (SELECT tab1.col, tab2.col FROM tab1 JOIN tab2 ... )
-
-claiming that col is a duplicate column (it loses the table specifiers by
-the time it gets to the *). Thus for any subquery count we select only the
-primary keys of the main table in the inner query. This hopefully still
-hits the indexes and keeps the server happy.
-
-At this point the only overriden method is C<_subq_count_select()>
-
-=cut
-
-sub _subq_count_select {
-  my ($self, $source, $rs_attrs) = @_;
-
-  return $rs_attrs->{group_by} if $rs_attrs->{group_by};
-
-  my @pcols = map { join '.', $rs_attrs->{alias}, $_ } ($source->primary_columns);
-  return @pcols ? \@pcols : [ 1 ];
-}
-
-=head1 AUTHORS
-
-See L<DBIx::Class/CONTRIBUTORS>
-
-=head1 LICENSE
-
-You may distribute this code under the same terms as Perl itself.
-
-=cut
-
-1;

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/AutoCast.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/AutoCast.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/AutoCast.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -23,7 +23,7 @@
 throw implicit type conversion errors.
 
 As long as a column L<data_type|DBIx::Class::ResultSource/add_columns> is
-defined, and it resolves to a base RDBMS native type via L</_native_data_type> as
+defined and resolves to a base RDBMS native type via L</_native_data_type> as
 defined in your Storage driver, the placeholder for this column will be
 converted to:
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/MSSQL.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/MSSQL.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/MSSQL.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -3,7 +3,7 @@
 use strict;
 use warnings;
 
-use base qw/DBIx::Class::Storage::DBI::AmbiguousGlob DBIx::Class::Storage::DBI/;
+use base qw/DBIx::Class::Storage::DBI/;
 use mro 'c3';
 
 use List::Util();
@@ -341,7 +341,7 @@
 Thus compromise between usability and perfection is the MSSQL-specific
 L<resultset attribute|DBIx::Class::ResultSet/ATTRIBUTES> C<unsafe_subselect_ok>.
 It is deliberately not possible to set this on the Storage level, as the user
-should inspect (and preferrably regression-test) the return of every such
+should inspect (and preferably regression-test) the return of every such
 ResultSet individually. The example above would work if written like:
 
  $rs->search ({}, {
@@ -354,7 +354,7 @@
 If it is possible to rewrite the search() in a way that will avoid the need
 for this flag - you are urged to do so. If DBIC internals insist that an
 ordered subselect is necessary for an operation, and you believe there is a
-differnt/better way to get the same result - please file a bugreport.
+different/better way to get the same result - please file a bugreport.
 
 =head1 AUTHOR
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/MultiColumnIn.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/MultiColumnIn.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/MultiColumnIn.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -17,7 +17,7 @@
 The storage class for any such RDBMS should inherit from this class, in order
 to dramatically speed up update/delete operations on joined multipk resultsets.
 
-At this point the only overriden method is C<_multipk_update_delete()>
+At this point the only overridden method is C<_multipk_update_delete()>
 
 =cut
 
@@ -26,7 +26,7 @@
   my ($rs, $op, $values) = @_;
 
   my $rsrc = $rs->result_source;
-  my @pcols = $rsrc->primary_columns;
+  my @pcols = $rsrc->_pri_cols;
   my $attrs = $rs->_resolved_attrs;
 
   # naive check - this is an internal method after all, we should know what we are doing 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/ODBC/ACCESS.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/ODBC/ACCESS.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/ODBC/ACCESS.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -79,7 +79,7 @@
 
 =head1 IMPLEMENTATION NOTES
 
-MS Access supports the @@IDENTITY function for retriving the id of the latest inserted row.
+MS Access supports the @@IDENTITY function for retrieving the id of the latest inserted row.
 @@IDENTITY is global to the connection, so to support the possibility of getting the last inserted
 id for different tables, the insert() function stores the inserted id on a per table basis.
 last_insert_id() then just returns the stored value.

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Oracle/WhereJoins.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Oracle/WhereJoins.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Oracle/WhereJoins.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -23,8 +23,7 @@
 
 This module was originally written to support Oracle < 9i where ANSI joins
 weren't supported at all, but became the module for Oracle >= 8 because
-Oracle's optimising of ANSI joins is horrible.  (See:
-http://scsys.co.uk:8001/7495)
+Oracle's optimising of ANSI joins is horrible.
 
 =head1 SYNOPSIS
 
@@ -44,7 +43,7 @@
 It should properly support left joins, and right joins.  Full outer joins are
 not possible due to the fact that Oracle requires the entire query be written
 to union the results of a left and right join, and by the time this module is
-called to create the where query and table definition part of the sql query,
+called to create the where query and table definition part of the SQL query,
 it's already too late.
 
 =head1 METHODS

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Balancer/First.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Balancer/First.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Balancer/First.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -19,7 +19,7 @@
 database's (L<DBIx::Class::Storage::DBI::Replicated::Replicant>), defines a
 method by which query load can be spread out across each replicant in the pool.
 
-This Balancer just get's whatever is the first replicant in the pool
+This Balancer just gets whichever is the first replicant in the pool.
 
 =head1 ATTRIBUTES
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Balancer.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Balancer.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Balancer.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -110,7 +110,7 @@
 This method should be defined in the class which consumes this role.
 
 Given a pool object, return the next replicant that will serve queries.  The
-default behavior is to grap the first replicant it finds but you can write 
+default behavior is to grab the first replicant it finds but you can write 
 your own subclasses of L<DBIx::Class::Storage::DBI::Replicated::Balancer> to 
 support other balance systems.
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Introduction.pod
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Introduction.pod	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Introduction.pod	2010-02-19 11:17:57 UTC (rev 8755)
@@ -9,8 +9,8 @@
 This is an introductory document for L<DBIx::Class::Storage::Replication>.
 
 This document is not an overview of what replication is or why you should be
-using it.  It is not a document explaing how to setup MySQL native replication
-either.  Copious external resources are avialable for both.  This document
+using it.  It is not a document explaining how to setup MySQL native replication
+either.  Copious external resources are available for both.  This document
 presumes you have the basics down.
   
 =head1 DESCRIPTION
@@ -33,7 +33,7 @@
 For an easy way to start playing with MySQL native replication, see:
 L<MySQL::Sandbox>.
 
-If you are using this with a L<Catalyst> based appplication, you may also wish
+If you are using this with a L<Catalyst> based application, you may also want
 to see more recent updates to L<Catalyst::Model::DBIC::Schema>, which has 
 support for replication configuration options as well.
 
@@ -41,15 +41,15 @@
 
 By default, when you start L<DBIx::Class>, your Schema (L<DBIx::Class::Schema>)
 is assigned a storage_type, which when fully connected will reflect your
-underlying storage engine as defined by your choosen database driver.  For
+underlying storage engine as defined by your chosen database driver.  For
 example, if you connect to a MySQL database, your storage_type will be
 L<DBIx::Class::Storage::DBI::mysql>  Your storage type class will contain 
 database specific code to help smooth over the differences between databases
 and let L<DBIx::Class> do its thing.
 
 If you want to use replication, you will override this setting so that the
-replicated storage engine will 'wrap' your underlying storages and present to
-the end programmer a unified interface.  This wrapper storage class will
+replicated storage engine will 'wrap' your underlying storages and present 
+a unified interface to the end programmer.  This wrapper storage class will
 delegate method calls to either a master database or one or more replicated
 databases based on if they are read only (by default sent to the replicants)
 or write (reserved for the master).  Additionally, the Replicated storage 
@@ -72,8 +72,8 @@
 storage itself (L<DBIx::Class::Storage::DBI::Replicated>).  A replicated storage
 takes a pool of replicants (L<DBIx::Class::Storage::DBI::Replicated::Pool>)
 and a software balancer (L<DBIx::Class::Storage::DBI::Replicated::Pool>).  The
-balancer does the job of splitting up all the read traffic amongst each
-replicant in the Pool. Currently there are two types of balancers, a Random one
+balancer does the job of splitting up all the read traffic amongst the
+replicants in the Pool. Currently there are two types of balancers, a Random one
 which chooses a Replicant in the Pool using a naive randomizer algorithm, and a
 First replicant, which just uses the first one in the Pool (and obviously is
 only of value when you have a single replicant).
@@ -132,7 +132,7 @@
 balancers have the 'auto_validate_every' option.  This is the number of seconds
 we allow to pass between validation checks on a load balanced replicant. So
 the higher the number, the more possibility that your reads to the replicant 
-may be inconsistant with what's on the master.  Setting this number too low
+may be inconsistent with what's on the master.  Setting this number too low
 will result in increased database loads, so choose a number with care.  Our
 experience is that setting the number around 5 seconds results in a good
 performance / integrity balance.
@@ -145,14 +145,14 @@
 This object (L<DBIx::Class::Storage::DBI::Replicated::Pool>) manages all the
 declared replicants.  'maximum_lag' is the number of seconds a replicant is
 allowed to lag behind the master before being temporarily removed from the pool.
-Keep in mind that the Balancer option 'auto_validate_every' determins how often
+Keep in mind that the Balancer option 'auto_validate_every' determines how often
 a replicant is tested against this condition, so the true possible lag can be
 higher than the number you set.  The default is zero.
 
 No matter how low you set the maximum_lag or the auto_validate_every settings,
 there is always the chance that your replicants will lag a bit behind the
 master for the supported replication system built into MySQL.  You can ensure
-reliabily reads by using a transaction, which will force both read and write
+reliable reads by using a transaction, which will force both read and write
 activity to the master, however this will increase the load on your master
 database.
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Pool.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Pool.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Pool.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -7,6 +7,7 @@
 use DBI ();
 use Carp::Clan qw/^DBIx::Class/;
 use MooseX::Types::Moose qw/Num Int ClassName HashRef/;
+use DBIx::Class::Storage::DBI::Replicated::Types 'DBICStorageDBI';
 
 use namespace::clean -except => 'meta';
 
@@ -22,7 +23,7 @@
 =head1 DESCRIPTION
 
 In a replicated storage type, there is at least one replicant to handle the
-read only traffic.  The Pool class manages this replicant, or list of 
+read-only traffic.  The Pool class manages this replicant, or list of 
 replicants, and gives some methods for querying information about their status.
 
 =head1 ATTRIBUTES
@@ -52,7 +53,7 @@
 
 This is an integer representing a time since the last time the replicants were
 validated. It's nothing fancy, just an integer provided via the perl L<time|perlfunc/time>
-builtin.
+built-in.
 
 =cut
 
@@ -86,7 +87,7 @@
 =head2 replicants
 
 A hashref of replicant, with the key being the dsn and the value returning the
-actual replicant storage.  For example if the $dsn element is something like:
+actual replicant storage.  For example, if the $dsn element is something like:
 
   "dbi:SQLite:dbname=dbfile"
 
@@ -116,7 +117,7 @@
 
 =item delete_replicant ($key)
 
-removes the replicant under $key from the pool
+Removes the replicant under $key from the pool
 
 =back
 
@@ -152,6 +153,14 @@
   },
 );
 
+=head2 master
+
+Reference to the master Storage.
+
+=cut
+
+has master => (is => 'rw', isa => DBICStorageDBI, weak_ref => 1);
+
 =head1 METHODS
 
 This class defines the following methods.
@@ -243,7 +252,13 @@
     $replicant->_determine_driver
   });
 
-  DBIx::Class::Storage::DBI::Replicated::Replicant->meta->apply($replicant);  
+  Moose::Meta::Class->initialize(ref $replicant);
+
+  DBIx::Class::Storage::DBI::Replicated::Replicant->meta->apply($replicant);
+
+  # link back to master
+  $replicant->master($self->master);
+
   return $replicant;
 }
 
@@ -253,7 +268,7 @@
 connect.  For the master database this is desirable, but since replicants are
 allowed to fail, this behavior is not desirable.  This method wraps the call
 to ensure_connected in an eval in order to catch any generated errors.  That
-way a slave can go completely offline (ie, the box itself can die) without
+way a slave can go completely offline (e.g. the box itself can die) without
 bringing down your entire pool of databases.
 
 =cut
@@ -350,7 +365,7 @@
 inactive, and thus removed from the replication pool.
 
 This tests L<all_replicants>, since a replicant that has been previous marked
-as inactive can be reactived should it start to pass the validation tests again.
+as inactive can be reactivated should it start to pass the validation tests again.
 
 See L<DBIx::Class::Storage::DBI> for more about checking if a replicating
 connection is not following a master or is lagging.

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Replicant.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Replicant.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated/Replicant.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -4,6 +4,7 @@
 requires qw/_query_start/;
 with 'DBIx::Class::Storage::DBI::Replicated::WithDSN';
 use MooseX::Types::Moose qw/Bool Str/;
+use DBIx::Class::Storage::DBI::Replicated::Types 'DBICStorageDBI';
 
 use namespace::clean -except => 'meta';
 
@@ -32,14 +33,14 @@
 =head2 active
 
 This is a boolean which allows you to programmatically activate or deactivate a
-replicant from the pool.  This way to you do stuff like disallow a replicant
-when it get's too far behind the master, if it stops replicating, etc.
+replicant from the pool.  This way you can do stuff like disallow a replicant
+when it gets too far behind the master, if it stops replicating, etc.
 
 This attribute DOES NOT reflect a replicant's internal status, i.e. if it is
 properly replicating from a master and has not fallen too many seconds behind a
 reliability threshold.  For that, use L</is_replicating>  and L</lag_behind_master>.
 Since the implementation of those functions database specific (and not all DBIC
-supported DB's support replication) you should refer your database specific
+supported DBs support replication) you should refer your database-specific
 storage driver for more information.
 
 =cut
@@ -55,6 +56,14 @@
 has dsn => (is => 'rw', isa => Str);
 has id  => (is => 'rw', isa => Str);
 
+=head2 master
+
+Reference to the master Storage.
+
+=cut
+
+has master => (is => 'rw', isa => DBICStorageDBI, weak_ref => 1);
+
 =head1 METHODS
 
 This class defines the following methods.
@@ -66,7 +75,9 @@
 =cut
 
 sub debugobj {
-    return shift->schema->storage->debugobj;
+  my $self = shift;
+
+  return $self->master->debugobj;
 }
 
 =head1 ALSO SEE

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Replicated.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -2,27 +2,9 @@
 
 BEGIN {
   use Carp::Clan qw/^DBIx::Class/;
-
-  ## Modules required for Replication support not required for general DBIC
-  ## use, so we explicitly test for these.
-
-  my %replication_required = (
-    'Moose' => '0.90',
-    'MooseX::Types' => '0.21',
-    'namespace::clean' => '0.11',
-    'Hash::Merge' => '0.11'
-  );
-
-  my @didnt_load;
-
-  for my $module (keys %replication_required) {
-    eval "use $module $replication_required{$module}";
-    push @didnt_load, "$module $replication_required{$module}"
-      if $@;
-  }
-
-  croak("@{[ join ', ', @didnt_load ]} are missing and are required for Replication")
-    if @didnt_load;
+  use DBIx::Class;
+  croak('The following modules are required for Replication ' . DBIx::Class::Optional::Dependencies->req_missing_for ('replicated') )
+    unless DBIx::Class::Optional::Dependencies->req_ok_for ('replicated');
 }
 
 use Moose;
@@ -32,7 +14,8 @@
 use DBIx::Class::Storage::DBI::Replicated::Types qw/BalancerClassNamePart DBICSchema DBICStorageDBI/;
 use MooseX::Types::Moose qw/ClassName HashRef Object/;
 use Scalar::Util 'reftype';
-use Hash::Merge 'merge';
+use Hash::Merge;
+use List::Util qw/min max/;
 
 use namespace::clean -except => 'meta';
 
@@ -43,7 +26,7 @@
 =head1 SYNOPSIS
 
 The Following example shows how to change an existing $schema to a replicated
-storage type, add some replicated (readonly) databases, and perform reporting
+storage type, add some replicated (read-only) databases, and perform reporting
 tasks.
 
 You should set the 'storage_type attribute to a replicated type.  You should
@@ -92,7 +75,7 @@
 Warning: This class is marked BETA.  This has been running a production
 website using MySQL native replication as its backend and we have some decent
 test coverage but the code hasn't yet been stressed by a variety of databases.
-Individual DB's may have quirks we are not aware of.  Please use this in first
+Individual DBs may have quirks we are not aware of.  Please use this in first
 development and pass along your experiences/bug fixes.
 
 This class implements replicated data store for DBI. Currently you can define
@@ -106,28 +89,21 @@
 to all existing storages.  This way our storage class is a drop in replacement
 for L<DBIx::Class::Storage::DBI>.
 
-Read traffic is spread across the replicants (slaves) occuring to a user
+Read traffic is spread across the replicants (slaves) occurring to a user
 selected algorithm.  The default algorithm is random weighted.
 
 =head1 NOTES
 
-The consistancy betweeen master and replicants is database specific.  The Pool
+The consistency between master and replicants is database specific.  The Pool
 gives you a method to validate its replicants, removing and replacing them
 when they fail/pass predefined criteria.  Please make careful use of the ways
 to force a query to run against Master when needed.
 
 =head1 REQUIREMENTS
 
-Replicated Storage has additional requirements not currently part of L<DBIx::Class>
+Replicated Storage has additional requirements not currently part of
+L<DBIx::Class>. See L<DBIx::Class::Optional::Dependencies> for more details.
 
-  Moose => '0.90',
-  MooseX::Types => '0.21',
-  namespace::clean => '0.11',
-  Hash::Merge => '0.11'
-
-You will need to install these modules manually via CPAN or make them part of the
-Makefile for your distribution.
-
 =head1 ATTRIBUTES
 
 This class defines the following attributes.
@@ -276,12 +252,17 @@
     select
     select_single
     columns_info_for
+    _dbh_columns_info_for 
+    _select
   /],
 );
 
 =head2 write_handler
 
-Defines an object that implements the write side of L<BIx::Class::Storage::DBI>.
+Defines an object that implements the write side of L<BIx::Class::Storage::DBI>,
+as well as methods that don't write or read that can be called on only one
+storage, methods that return a C<$dbh>, and any methods that don't make sense to
+run on a replicant.
 
 =cut
 
@@ -292,7 +273,10 @@
   handles=>[qw/
     on_connect_do
     on_disconnect_do
+    on_connect_call
+    on_disconnect_call
     connect_info
+    _connect_info
     throw_exception
     sql_maker
     sqlt_type
@@ -328,6 +312,59 @@
     svp_rollback
     svp_begin
     svp_release
+    relname_to_table_alias
+    _straight_join_to_node
+    _dbh_last_insert_id
+    _fix_bind_params
+    _default_dbi_connect_attributes
+    _dbi_connect_info
+    auto_savepoint
+    _sqlt_version_ok
+    _query_end
+    bind_attribute_by_data_type
+    transaction_depth
+    _dbh
+    _select_args
+    _dbh_execute_array
+    _sql_maker_args
+    _sql_maker
+    _query_start
+    _sqlt_version_error
+    _per_row_update_delete
+    _dbh_begin_work
+    _dbh_execute_inserts_with_no_binds
+    _select_args_to_query
+    _svp_generate_name
+    _multipk_update_delete
+    source_bind_attributes
+    _normalize_connect_info
+    _parse_connect_do
+    _dbh_commit
+    _execute_array
+    _placeholders_supported
+    _verify_pid
+    savepoints
+    _sqlt_minimum_version
+    _sql_maker_opts
+    _conn_pid
+    _typeless_placeholders_supported
+    _conn_tid
+    _dbh_autocommit
+    _native_data_type
+    _get_dbh
+    sql_maker_class
+    _dbh_rollback
+    _adjust_select_args_for_complex_prefetch
+    _resolve_ident_sources
+    _resolve_column_info
+    _prune_unused_joins
+    _strip_cond_qualifiers
+    _parse_order_by
+    _resolve_aliastypes_from_select_args
+    _execute
+    _do_query
+    _dbh_sth
+    _dbh_execute
   /],
 );
 
@@ -336,8 +373,8 @@
 
 =head2 around: connect_info
 
-Preserve master's C<connect_info> options (for merging with replicants.)
-Also set any Replicated related options from connect_info, such as
+Preserves master's C<connect_info> options (for merging with replicants.)
+Also sets any Replicated-related options from connect_info, such as
 C<pool_type>, C<pool_args>, C<balancer_type> and C<balancer_args>.
 
 =cut
@@ -347,10 +384,12 @@
 
   my $wantarray = wantarray;
 
+  my $merge = Hash::Merge->new('LEFT_PRECEDENT');
+
   my %opts;
   for my $arg (@$info) {
     next unless (reftype($arg)||'') eq 'HASH';
-    %opts = %{ merge($arg, \%opts) };
+    %opts = %{ $merge->merge($arg, \%opts) };
   }
   delete $opts{dsn};
 
@@ -359,7 +398,7 @@
       if $opts{pool_type};
 
     $self->pool_args(
-      merge((delete $opts{pool_args} || {}), $self->pool_args)
+      $merge->merge((delete $opts{pool_args} || {}), $self->pool_args)
     );
 
     $self->pool($self->_build_pool)
@@ -371,7 +410,7 @@
       if $opts{balancer_type};
 
     $self->balancer_args(
-      merge((delete $opts{balancer_args} || {}), $self->balancer_args)
+      $merge->merge((delete $opts{balancer_args} || {}), $self->balancer_args)
     );
 
     $self->balancer($self->_build_balancer)
@@ -391,8 +430,12 @@
   my $master = $self->master;
   $master->_determine_driver;
   Moose::Meta::Class->initialize(ref $master);
+
   DBIx::Class::Storage::DBI::Replicated::WithDSN->meta->apply($master);
 
+  # link pool back to master
+  $self->pool->master($master);
+
   $wantarray ? @res : $res;
 };
 
@@ -512,7 +555,8 @@
     $self->throw_exception('too many hashrefs in connect_info')
       if @hashes > 2;
 
-    my %opts = %{ merge(reverse @hashes) };
+    my $merge = Hash::Merge->new('LEFT_PRECEDENT');
+    my %opts = %{ $merge->merge(reverse @hashes) };
 
 # delete them
     splice @$r, $i+1, ($#{$r} - $i), ();
@@ -525,7 +569,7 @@
     delete $master_opts{dbh_maker};
 
 # merge with master
-    %opts = %{ merge(\%opts, \%master_opts) };
+    %opts = %{ $merge->merge(\%opts, \%master_opts) };
 
 # update
     $r->[$i] = \%opts;
@@ -553,7 +597,7 @@
 =head2 execute_reliably ($coderef, ?@args)
 
 Given a coderef, saves the current state of the L</read_handler>, forces it to
-use reliable storage (ie sets it to the master), executes a coderef and then
+use reliable storage (e.g. sets it to the master), executes a coderef and then
 restores the original state.
 
 Example:
@@ -633,7 +677,7 @@
 =head2 set_balanced_storage
 
 Sets the current $schema to be use the </balancer> for all reads, while all
-writea are sent to the master only
+writes are sent to the master only
 
 =cut
 
@@ -744,50 +788,35 @@
 
 =head2 debugobj
 
-set a debug object across all storages
+set a debug object
 
 =cut
 
 sub debugobj {
   my $self = shift @_;
-  if(@_) {
-    foreach my $source ($self->all_storages) {
-      $source->debugobj(@_);
-    }
-  }
-  return $self->master->debugobj;
+  return $self->master->debugobj(@_);
 }
 
 =head2 debugfh
 
-set a debugfh object across all storages
+set a debugfh object
 
 =cut
 
 sub debugfh {
   my $self = shift @_;
-  if(@_) {
-    foreach my $source ($self->all_storages) {
-      $source->debugfh(@_);
-    }
-  }
-  return $self->master->debugfh;
+  return $self->master->debugfh(@_);
 }
 
 =head2 debugcb
 
-set a debug callback across all storages
+set a debug callback
 
 =cut
 
 sub debugcb {
   my $self = shift @_;
-  if(@_) {
-    foreach my $source ($self->all_storages) {
-      $source->debugcb(@_);
-    }
-  }
-  return $self->master->debugcb;
+  return $self->master->debugcb(@_);
 }
 
 =head2 disconnect
@@ -818,6 +847,165 @@
   $self->master->cursor_class;
 }
 
+=head2 cursor
+
+set cursor class on all storages, or return master's, alias for L</cursor_class>
+above.
+
+=cut
+
+sub cursor {
+  my ($self, $cursor_class) = @_;
+
+  if ($cursor_class) {
+    $_->cursor($cursor_class) for $self->all_storages;
+  }
+  $self->master->cursor;
+}
+
+=head2 unsafe
+
+sets the L<DBIx::Class::Storage::DBI/unsafe> option on all storages or returns
+master's current setting
+
+=cut
+
+sub unsafe {
+  my $self = shift;
+
+  if (@_) {
+    $_->unsafe(@_) for $self->all_storages;
+  }
+
+  return $self->master->unsafe;
+}
+
+=head2 disable_sth_caching
+
+sets the L<DBIx::Class::Storage::DBI/disable_sth_caching> option on all storages
+or returns master's current setting
+
+=cut
+
+sub disable_sth_caching {
+  my $self = shift;
+
+  if (@_) {
+    $_->disable_sth_caching(@_) for $self->all_storages;
+  }
+
+  return $self->master->disable_sth_caching;
+}
+
+=head2 lag_behind_master
+
+returns the highest Replicant L<DBIx::Class::Storage::DBI/lag_behind_master>
+setting
+
+=cut
+
+sub lag_behind_master {
+  my $self = shift;
+
+  return max map $_->lag_behind_master, $self->replicants;
+} 
+
+=head2 is_replicating
+
+returns true if all replicants return true for
+L<DBIx::Class::Storage::DBI/is_replicating>
+
+=cut
+
+sub is_replicating {
+  my $self = shift;
+
+  return (grep $_->is_replicating, $self->replicants) == ($self->replicants);
+}
+
+=head2 connect_call_datetime_setup
+
+calls L<DBIx::Class::Storage::DBI/connect_call_datetime_setup> for all storages
+
+=cut
+
+sub connect_call_datetime_setup {
+  my $self = shift;
+  $_->connect_call_datetime_setup for $self->all_storages;
+}
+
+sub _populate_dbh {
+  my $self = shift;
+  $_->_populate_dbh for $self->all_storages;
+}
+
+sub _connect {
+  my $self = shift;
+  $_->_connect for $self->all_storages;
+}
+
+sub _rebless {
+  my $self = shift;
+  $_->_rebless for $self->all_storages;
+}
+
+sub _determine_driver {
+  my $self = shift;
+  $_->_determine_driver for $self->all_storages;
+}
+
+sub _driver_determined {
+  my $self = shift;
+  
+  if (@_) {
+    $_->_driver_determined(@_) for $self->all_storages;
+  }
+
+  return $self->master->_driver_determined;
+}
+
+sub _init {
+  my $self = shift;
+  
+  $_->_init for $self->all_storages;
+}
+
+sub _run_connection_actions {
+  my $self = shift;
+  
+  $_->_run_connection_actions for $self->all_storages;
+}
+
+sub _do_connection_actions {
+  my $self = shift;
+  
+  if (@_) {
+    $_->_do_connection_actions(@_) for $self->all_storages;
+  }
+}
+
+sub connect_call_do_sql {
+  my $self = shift;
+  $_->connect_call_do_sql(@_) for $self->all_storages;
+}
+
+sub disconnect_call_do_sql {
+  my $self = shift;
+  $_->disconnect_call_do_sql(@_) for $self->all_storages;
+}
+
+sub _seems_connected {
+  my $self = shift;
+
+  return min map $_->_seems_connected, $self->all_storages;
+}
+
+sub _ping {
+  my $self = shift;
+
+  return min map $_->_ping, $self->all_storages;
+}
+
 =head1 GOTCHAS
 
 Due to the fact that replicants can lag behind a master, you must take care to

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Role/QueryCounter.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Role/QueryCounter.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Role/QueryCounter.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -19,7 +19,7 @@
 
 This package defines the following attributes.
 
-head2 _query_count
+=head2 _query_count
 
 Is the attribute holding the current query count.  It defines a public reader
 called 'query_count' which you can use to access the total number of queries
@@ -42,7 +42,7 @@
 
 =head2 _query_start
 
-override on the method so that we count the queries.
+Override on the method so that we count the queries.
 
 =cut
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/SQLAnywhere.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/SQLAnywhere.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/SQLAnywhere.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -25,7 +25,7 @@
 
   /opt/sqlanywhere11/sdk/perl
 
-Recommended L<DBIx::Class::Storage::DBI/connect_info> settings:
+Recommended L<connect_info|DBIx::Class::Storage::DBI/connect_info> settings:
 
   on_connect_call => 'datetime_setup'
 
@@ -43,6 +43,16 @@
       $source->column_info($_)->{is_auto_increment} 
   } $source->columns;
 
+# user might have an identity PK without is_auto_increment
+  if (not $identity_col) {
+    foreach my $pk_col ($source->primary_columns) {
+      if (not exists $to_insert->{$pk_col}) {
+        $identity_col = $pk_col;
+        last;
+      }
+    }
+  }
+
   if ($identity_col && (not exists $to_insert->{$identity_col})) {
     my $dbh = $self->_get_dbh;
     my $table_name = $source->from;
@@ -86,8 +96,8 @@
 
     on_connect_call => 'datetime_setup'
 
-In L<DBIx::Class::Storage::DBI/connect_info> to set the date and timestamp
-formats (as temporary options for the session) for use with
+In L<connect_info|DBIx::Class::Storage::DBI/connect_info> to set the date and
+timestamp formats (as temporary options for the session) for use with
 L<DBIx::Class::InflateColumn::DateTime>.
 
 The C<TIMESTAMP> data type supports up to 6 digits after the decimal point for
@@ -112,8 +122,36 @@
   );
 }
 
+sub _svp_begin {
+    my ($self, $name) = @_;
+
+    $self->_get_dbh->do("SAVEPOINT $name");
+}
+
+# can't release savepoints that have been rolled back
+sub _svp_release { 1 }
+
+sub _svp_rollback {
+    my ($self, $name) = @_;
+
+    $self->_get_dbh->do("ROLLBACK TO SAVEPOINT $name")
+}
+
 1;
 
+=head1 MAXIMUM CURSORS
+
+A L<DBIx::Class> application can use a lot of cursors, due to the usage of
+L<prepare_cached|DBI/prepare_cached>.
+
+The default cursor maximum is C<50>, which can be a bit too low. This limit can
+be turned off (or increased) by the DBA by executing:
+
+  set option max_statement_count = 0
+  set option max_cursor_count    = 0
+
+Highly recommended.
+
 =head1 AUTHOR
 
 See L<DBIx::Class/AUTHOR> and L<DBIx::Class/CONTRIBUTORS>.

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Sybase/ASE/NoBindVars.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Sybase/ASE/NoBindVars.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Sybase/ASE/NoBindVars.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -68,8 +68,8 @@
 
 =head1 DESCRIPTION
 
-If you're using this driver than your version of Sybase, or the libraries you
-use to connect to it, do not support placeholders.
+If you're using this driver then your version of Sybase or the libraries you
+use to connect to it do not support placeholders.
 
 You can also enable this driver explicitly using:
 
@@ -81,7 +81,7 @@
 $sth->execute >> for details on the pros and cons of using placeholders.
 
 One advantage of not using placeholders is that C<select @@identity> will work
-for obtainging the last insert id of an C<IDENTITY> column, instead of having to
+for obtaining the last insert id of an C<IDENTITY> column, instead of having to
 do C<select max(col)> in a transaction as the base Sybase driver does.
 
 When using this driver, bind variables will be interpolated (properly quoted of

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Sybase/ASE.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Sybase/ASE.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/Sybase/ASE.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -728,11 +728,10 @@
 sub _update_blobs {
   my ($self, $source, $blob_cols, $where) = @_;
 
-  my (@primary_cols) = $source->primary_columns;
+  my @primary_cols = eval { $source->_pri_cols };
+  $self->throw_exception("Cannot update TEXT/IMAGE column(s): $@")
+    if $@;
 
-  $self->throw_exception('Cannot update TEXT/IMAGE column(s) without a primary key')
-    unless @primary_cols;
-
 # check if we're updating a single row by PK
   my $pk_cols_in_where = 0;
   for my $col (@primary_cols) {
@@ -763,11 +762,10 @@
   my $table = $source->name;
 
   my %row = %$row;
-  my (@primary_cols) = $source->primary_columns;
+  my @primary_cols = eval { $source->_pri_cols} ;
+  $self->throw_exception("Cannot update TEXT/IMAGE column(s): $@")
+    if $@;
 
-  $self->throw_exception('Cannot update TEXT/IMAGE column(s) without a primary key')
-    unless @primary_cols;
-
   $self->throw_exception('Cannot update TEXT/IMAGE column(s) without primary key values')
     if ((grep { defined $row{$_} } @primary_cols) != @primary_cols);
 
@@ -977,7 +975,7 @@
 definitions in your Result classes, and are mapped to a Sybase type (if it isn't
 already) using a mapping based on L<SQL::Translator>.
 
-In other configurations, placeholers will work just as they do with the Sybase
+In other configurations, placeholders will work just as they do with the Sybase
 Open Client libraries.
 
 Inserts or updates of TEXT/IMAGE columns will B<NOT> work with FreeTDS.
@@ -998,8 +996,8 @@
 
 =head1 TRANSACTIONS
 
-Due to limitations of the TDS protocol, L<DBD::Sybase>, or both; you cannot
-begin a transaction while there are active cursors; nor can you use multiple
+Due to limitations of the TDS protocol, L<DBD::Sybase>, or both, you cannot
+begin a transaction while there are active cursors, nor can you use multiple
 active cursors within a transaction. An active cursor is, for example, a
 L<ResultSet|DBIx::Class::ResultSet> that has been executed using C<next> or
 C<first> but has not been exhausted or L<reset|DBIx::Class::ResultSet/reset>.

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/mysql.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/mysql.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI/mysql.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -5,7 +5,6 @@
 
 use base qw/
   DBIx::Class::Storage::DBI::MultiColumnIn
-  DBIx::Class::Storage::DBI::AmbiguousGlob
   DBIx::Class::Storage::DBI
 /;
 use mro 'c3';

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBI.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -16,11 +16,6 @@
 use Data::Dumper::Concise();
 use Sub::Name ();
 
-# what version of sqlt do we require if deploy() without a ddl_dir is invoked
-# when changing also adjust the corresponding author_require in Makefile.PL
-my $minimum_sqlt_version = '0.11002';
-
-
 __PACKAGE__->mk_group_accessors('simple' =>
   qw/_connect_info _dbi_connect_info _dbh _sql_maker _sql_maker_opts _conn_pid
      _conn_tid transaction_depth _dbh_autocommit _driver_determined savepoints/
@@ -195,7 +190,7 @@
 In addition to the standard L<DBI|DBI/ATTRIBUTES_COMMON_TO_ALL_HANDLES>
 L<connection|DBI/Database_Handle_Attributes> attributes, DBIx::Class recognizes
 the following connection options. These options can be mixed in with your other
-L<DBI> connection attributes, or placed in a seperate hashref
+L<DBI> connection attributes, or placed in a separate hashref
 (C<\%extra_attributes>) as shown above.
 
 Every time C<connect_info> is invoked, any previous settings for
@@ -347,7 +342,7 @@
 =item name_sep
 
 This only needs to be used in conjunction with C<quote_char>, and is used to
-specify the charecter that seperates elements (schemas, tables, columns) from
+specify the character that separates elements (schemas, tables, columns) from
 each other. In most cases this is simply a C<.>.
 
 The consequences of not supplying this value is that L<SQL::Abstract>
@@ -783,8 +778,8 @@
 
 =back
 
-Verifies that the the current database handle is active and ready to execute
-an SQL statement (i.e. the connection did not get stale, server is still
+Verifies that the current database handle is active and ready to execute
+an SQL statement (e.g. the connection did not get stale, server is still
 answering, etc.) This method is used internally by L</dbh>.
 
 =cut
@@ -1610,15 +1605,7 @@
   my $rsrc = $rs->result_source;
 
   # quick check if we got a sane rs on our hands
-  my @pcols = $rsrc->primary_columns;
-  unless (@pcols) {
-    $self->throw_exception (
-      sprintf (
-        "You must declare primary key(s) on source '%s' (via set_primary_key) in order to update or delete complex resultsets",
-        $rsrc->source_name || $rsrc->from
-      )
-    );
-  }
+  my @pcols = $rsrc->_pri_cols;
 
   my $sel = $rs->_resolved_attrs->{select};
   $sel = [ $sel ] unless ref $sel eq 'ARRAY';
@@ -1671,7 +1658,7 @@
   my ($rs, $op, $values) = @_;
 
   my $rsrc = $rs->result_source;
-  my @pcols = $rsrc->primary_columns;
+  my @pcols = $rsrc->_pri_cols;
 
   my $guard = $self->txn_scope_guard;
 
@@ -1905,8 +1892,34 @@
 #
 sub _subq_count_select {
   my ($self, $source, $rs_attrs) = @_;
-  return $rs_attrs->{group_by} if $rs_attrs->{group_by};
 
+  if (my $groupby = $rs_attrs->{group_by}) {
+
+    my $avail_columns = $self->_resolve_column_info ($rs_attrs->{from});
+
+    my $sel_index;
+    for my $sel (@{$rs_attrs->{select}}) {
+      if (ref $sel eq 'HASH' and $sel->{-as}) {
+        $sel_index->{$sel->{-as}} = $sel;
+      }
+    }
+
+    my @selection;
+    for my $g_part (@$groupby) {
+      if (ref $g_part or $avail_columns->{$g_part}) {
+        push @selection, $g_part;
+      }
+      elsif ($sel_index->{$g_part}) {
+        push @selection, $sel_index->{$g_part};
+      }
+      else {
+        $self->throw_exception ("group_by criteria '$g_part' not contained within current resultset source(s)");
+      }
+    }
+
+    return \@selection;
+  }
+
   my @pcols = map { join '.', $rs_attrs->{alias}, $_ } ($source->primary_columns);
   return @pcols ? \@pcols : [ 1 ];
 }
@@ -2255,8 +2268,9 @@
     %{$sqltargs || {}}
   };
 
-  $self->throw_exception("Can't create a ddl file without SQL::Translator: " . $self->_sqlt_version_error)
-    if !$self->_sqlt_version_ok;
+  unless (DBIx::Class::Optional::Dependencies->req_ok_for ('deploy')) {
+    $self->throw_exception("Can't create a ddl file without " . DBIx::Class::Optional::Dependencies->req_missing_for ('deploy') );
+  }
 
   my $sqlt = SQL::Translator->new( $sqltargs );
 
@@ -2398,8 +2412,9 @@
       return join('', @rows);
   }
 
-  $self->throw_exception("Can't deploy without either SQL::Translator or a ddl_dir: " . $self->_sqlt_version_error )
-    if !$self->_sqlt_version_ok;
+  unless (DBIx::Class::Optional::Dependencies->req_ok_for ('deploy') ) {
+    $self->throw_exception("Can't deploy without a ddl_dir or " . DBIx::Class::Optional::Dependencies->req_missing_for ('deploy') );
+  }
 
   # sources needs to be a parser arg, but for simplicty allow at top level
   # coming in
@@ -2449,7 +2464,7 @@
     }
     $self->_query_end($line);
   };
-  my @statements = $self->deployment_statements($schema, $type, undef, $dir, { %{ $sqltargs || {} }, no_comments => 1 } );
+  my @statements = $schema->deployment_statements($type, undef, $dir, { %{ $sqltargs || {} }, no_comments => 1 } );
   if (@statements > 1) {
     foreach my $statement (@statements) {
       $deploy->( $statement );
@@ -2523,33 +2538,6 @@
     return;
 }
 
-# SQLT version handling
-{
-  my $_sqlt_version_ok;     # private
-  my $_sqlt_version_error;  # private
-
-  sub _sqlt_version_ok {
-    if (!defined $_sqlt_version_ok) {
-      eval "use SQL::Translator $minimum_sqlt_version";
-      if ($@) {
-        $_sqlt_version_ok = 0;
-        $_sqlt_version_error = $@;
-      }
-      else {
-        $_sqlt_version_ok = 1;
-      }
-    }
-    return $_sqlt_version_ok;
-  }
-
-  sub _sqlt_version_error {
-    shift->_sqlt_version_ok unless defined $_sqlt_version_ok;
-    return $_sqlt_version_error;
-  }
-
-  sub _sqlt_minimum_version { $minimum_sqlt_version };
-}
-
 =head2 relname_to_table_alias
 
 =over 4

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBIHacks.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBIHacks.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/DBIHacks.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -97,7 +97,7 @@
   }
 
   # construct the inner $from for the subquery
-  # we need to prune first, because this will determine if we need a group_bu below
+  # we need to prune first, because this will determine if we need a group_by below
   my $inner_from = $self->_prune_unused_joins ($from, $inner_select, $where, $inner_attrs);
 
   # if a multi-type join was needed in the subquery - add a group_by to simulate the

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/TxnScopeGuard.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/TxnScopeGuard.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage/TxnScopeGuard.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -89,7 +89,7 @@
 =head2 commit
 
 Commit the transaction, and stop guarding the scope. If this method is not
-called and this object goes out of scope (i.e. an exception is thrown) then
+called and this object goes out of scope (e.g. an exception is thrown) then
 the transaction is rolled back, via L<DBIx::Class::Storage/txn_rollback>
 
 =cut
@@ -102,7 +102,7 @@
 
 Ash Berlin, 2008.
 
-Insipred by L<Scope::Guard> by chocolateboy.
+Inspired by L<Scope::Guard> by chocolateboy.
 
 This module is free software. It may be used, redistributed and/or modified
 under the same terms as Perl itself.

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class/Storage.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -353,7 +353,7 @@
 =head2 debugfh
 
 Set or retrieve the filehandle used for trace/debug output.  This should be
-an IO::Handle compatible ojbect (only the C<print> method is used.  Initially
+an IO::Handle compatible object (only the C<print> method is used.  Initially
 set to be STDERR - although see information on the
 L<DBIC_TRACE> environment variable.
 

Modified: DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/lib/DBIx/Class.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -6,6 +6,8 @@
 use MRO::Compat;
 use mro 'c3';
 
+use DBIx::Class::Optional::Dependencies;
+
 use vars qw($VERSION);
 use base qw/DBIx::Class::Componentised Class::Accessor::Grouped/;
 use DBIx::Class::StartupCheck;
@@ -25,7 +27,7 @@
 # Always remember to do all digits for the version even if they're 0
 # i.e. first release of 0.XX *must* be 0.XX000. This avoids fBSD ports
 # brain damage and presumably various other packaging systems too
-$VERSION = '0.08118_01';
+$VERSION = '0.08119_1';
 
 $VERSION = eval $VERSION; # numify for warning-free dev releases
 
@@ -54,14 +56,21 @@
 
 The community can be found via:
 
-  Mailing list: http://lists.scsys.co.uk/mailman/listinfo/dbix-class/
+=over
 
-  SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
+=item * IRC: L<irc.perl.org#dbix-class (click for instant chatroom login)
+|http://mibbit.com/chat/#dbix-class@irc.perl.org>
 
-  SVNWeb: http://dev.catalyst.perl.org/svnweb/bast/browse/DBIx-Class/
+=item * Mailing list: L<http://lists.scsys.co.uk/mailman/listinfo/dbix-class>
 
-  IRC: irc.perl.org#dbix-class
+=item * RT Bug Tracker: L<https://rt.cpan.org/Dist/Display.html?Queue=DBIx-Class>
 
+=item * SVNWeb: L<http://dev.catalyst.perl.org/svnweb/bast/browse/DBIx-Class/0.08>
+
+=item * SVN: L<http://dev.catalyst.perl.org/repos/bast/DBIx-Class/0.08>
+
+=back
+
 =head1 SYNOPSIS
 
 Create a schema class called MyDB/Schema.pm:
@@ -245,6 +254,8 @@
 
 debolaz: Anders Nor Berle <berle at cpan.org>
 
+dew: Dan Thomas <dan at godders.org>
+
 dkubb: Dan Kubb <dan.kubb-cpan at onautopilot.com>
 
 dnm: Justin Wheeler <jwheeler at datademons.com>
@@ -255,6 +266,8 @@
 
 frew: Arthur Axel "fREW" Schmidt <frioux at gmail.com>
 
+goraxe: Gordon Irving <goraxe at cpan.org>
+
 gphat: Cory G Watson <gphat at cpan.org>
 
 groditi: Guillermo Roditi <groditi at cpan.org>
@@ -297,6 +310,8 @@
 
 norbi: Norbert Buchmuller <norbi at nix.hu>
 
+nuba: Nuba Princigalli <nuba at cpan.org>
+
 Numa: Dan Sully <daniel at cpan.org>
 
 ovid: Curtis "Ovid" Poe <ovid at cpan.org>
@@ -365,7 +380,7 @@
 
 =head1 COPYRIGHT
 
-Copyright (c) 2005 - 2009 the DBIx::Class L</AUTHOR> and L</CONTRIBUTORS>
+Copyright (c) 2005 - 2010 the DBIx::Class L</AUTHOR> and L</CONTRIBUTORS>
 as listed above.
 
 =head1 LICENSE

Modified: DBIx-Class/0.08/branches/storage-interbase/script/dbicadmin
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/script/dbicadmin	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/script/dbicadmin	2010-02-19 11:17:57 UTC (rev 8755)
@@ -1,221 +1,95 @@
 #!/usr/bin/perl
+
 use strict;
 use warnings;
 
-use Getopt::Long;
-use Pod::Usage;
-use JSON::Any;
-
-
-my $json = JSON::Any->new(allow_barekey => 1, allow_singlequote => 1);
-
-GetOptions(
-    'schema=s'  => \my $schema_class,
-    'class=s'   => \my $resultset_class,
-    'connect=s' => \my $connect,
-    'op=s'      => \my $op,
-    'set=s'     => \my $set,
-    'where=s'   => \my $where,
-    'attrs=s'   => \my $attrs,
-    'format=s'  => \my $format,
-    'force'     => \my $force,
-    'trace'     => \my $trace,
-    'quiet'     => \my $quiet,
-    'help'      => \my $help,
-    'tlibs'      => \my $t_libs,
-);
-
-if ($t_libs) {
-    unshift( @INC, 't/lib', 'lib' );
+BEGIN {
+  use DBIx::Class;
+  die (  "The following modules are required for the dbicadmin utility\n"
+       . DBIx::Class::Optional::Dependencies->req_missing_for ('admin_script')
+  ) unless DBIx::Class::Optional::Dependencies->req_ok_for ('admin_script');
 }
 
-pod2usage(1) if ($help);
-$ENV{DBIC_TRACE} = 1 if ($trace);
+use Getopt::Long::Descriptive;
+use DBIx::Class::Admin;
 
-die('No op specified') if(!$op);
-die('Invalid op') if ($op!~/^insert|update|delete|select$/s);
-my $csv_class;
-if ($op eq 'select') {
-    $format ||= 'tsv';
-    die('Invalid format') if ($format!~/^tsv|csv$/s);
-    $csv_class = 'Text::CSV_XS';
-    eval{ require Text::CSV_XS };
-    if ($@) {
-        $csv_class = 'Text::CSV_PP';
-        eval{ require Text::CSV_PP };
-        die('The select op requires either the Text::CSV_XS or the Text::CSV_PP module') if ($@);
-    }
-}
-
-die('No schema specified') if(!$schema_class);
-eval("require $schema_class");
-die('Unable to load schema') if ($@);
-$connect = $json->jsonToObj( $connect ) if ($connect);
-my $schema = $schema_class->connect(
-    ( $connect ? @$connect : () )
+my ($opts, $usage) = describe_options(
+  "%c: %o",
+  (
+    ['Actions'],
+    ["action" => hidden => { one_of => [
+      ['create|c' => 'Create version diffs needs preversion',],
+      ['upgrade|u' => 'Upgrade the database to the current schema '],
+      ['install|i' => 'Install the schema to the database',],
+      ['deploy|d' => 'Deploy the schema to the database',],
+      ['select|s'   => 'Select data from the schema', ],
+      ['insert|i'   => 'Insert data into the schema', ],
+      ['update|u'   => 'Update data in the schema', ], 
+      ['delete|D'   => 'Delete data from the schema',],
+      ['op:s' => 'compatiblity option all of the above can be suppied as --op=<action>'],
+      ['help|h' => 'display this help'],
+    ], required=> 1 }],
+    ['Options'],
+    ['schema-class|schema|C:s' => 'The class of the schema to load', { required => 1 } ],
+    ['resultset|resultset_class|class|r:s' => 'The resultset to operate on for data manipulation' ],
+    ['config-stanza|S:s' => 'Where in the config to find the connection_info, supply in form MyApp::Model::DB',],
+    ['config|f:s' => 'Supply the config file for parsing by Config::Any', { depends => 'config_stanza'} ],
+    ['connect-info|n:s%' => 'Supply the connect info as additonal options ie -I dsn=<dsn> user=<user> password=<pass> '],
+    ['connect:s' => 'Supply the connect info as a json string' ],
+    ['sql-dir|q:s' => 'The directory where sql diffs will be created'],
+    ['sql-type|t:s' => 'The RDBMs flavour you wish to use'],
+    ['version|v:i' => 'Supply a version install'],
+    ['preversion|p:s' => 'The previous version to diff against',],
+    ['set:s' => 'JSON data used to perform data operations' ],
+    ['lib|I:s' => 'Additonal library path to search in'], 
+    ['attrs:s' => 'JSON string to be used for the second argument for search'],
+    ['where:s' => 'JSON string to be used for the where clause of search'],
+    ['force' => 'Be forceful with some operations'],
+    ['trace' => 'Turn on DBIx::Class trace output'],
+    ['quiet' => 'Be less verbose'],
+  )
 );
 
-die('No class specified') if(!$resultset_class);
-my $resultset = eval{ $schema->resultset($resultset_class) };
-die('Unable to load the class with the schema') if ($@);
+die "please only use one of --config or --connect-info\n" if ($opts->{config} and $opts->{connect_info});
 
-$set = $json->jsonToObj( $set ) if ($set);
-$where = $json->jsonToObj( $where ) if ($where);
-$attrs = $json->jsonToObj( $attrs ) if ($attrs);
-
-if ($op eq 'insert') {
-    die('Do not use the where option with the insert op') if ($where);
-    die('Do not use the attrs option with the insert op') if ($attrs);
-    my $obj = $resultset->create( $set );
-    print ''.ref($resultset).' ID: '.join(',',$obj->id())."\n" if (!$quiet);
+# option compatability mangle
+if($opts->{connect}) {
+  $opts->{connect_info} = delete $opts->{connect};
 }
-elsif ($op eq 'update') {
-    $resultset = $resultset->search( ($where||{}) );
-    my $count = $resultset->count();
-    print "This action will modify $count ".ref($resultset)." records.\n" if (!$quiet);
-    if ( $force || confirm() ) {
-        $resultset->update_all( $set );
-    }
-}
-elsif ($op eq 'delete') {
-    die('Do not use the set option with the delete op') if ($set);
-    $resultset = $resultset->search( ($where||{}), ($attrs||()) );
-    my $count = $resultset->count();
-    print "This action will delete $count ".ref($resultset)." records.\n" if (!$quiet);
-    if ( $force || confirm() ) {
-        $resultset->delete_all();
-    }
-}
-elsif ($op eq 'select') {
-    die('Do not use the set option with the select op') if ($set);
-    my $csv = $csv_class->new({
-        sep_char => ( $format eq 'tsv' ? "\t" : ',' ),
-    });
-    $resultset = $resultset->search( ($where||{}), ($attrs||()) );
-    my @columns = $resultset->result_source->columns();
-    $csv->combine( @columns );
-    print $csv->string()."\n";
-    while (my $row = $resultset->next()) {
-        my @fields;
-        foreach my $column (@columns) {
-            push( @fields, $row->get_column($column) );
-        }
-        $csv->combine( @fields );
-        print $csv->string()."\n";
-    }
-}
 
-sub confirm {
-    print "Are you sure you want to do this? (type YES to confirm) ";
-    my $response = <STDIN>;
-    return 1 if ($response=~/^YES/);
-    return;
-}
+my $admin = DBIx::Class::Admin->new( %$opts );
 
-__END__
 
-=head1 NAME
+my $action = $opts->{action};
 
-dbicadmin - Execute operations upon DBIx::Class objects.
+$action = $opts->{op} if ($action eq 'op');
 
-=head1 SYNOPSIS
+print "Performig action $action...\n";
 
-  dbicadmin --op=insert --schema=My::Schema --class=Class --set=JSON
-  dbicadmin --op=update --schema=My::Schema --class=Class --set=JSON --where=JSON
-  dbicadmin --op=delete --schema=My::Schema --class=Class --where=JSON
-  dbicadmin --op=select --schema=My::Schema --class=Class --where=JSON --format=tsv
+my $res = $admin->$action();
+if ($action eq 'select') {
 
-=head1 DESCRIPTION
+  my $format = $opts->{format} || 'tsv';
+  die('Invalid format') if ($format!~/^tsv|csv$/s);
 
-This utility provides the ability to run INSERTs, UPDATEs, 
-DELETEs, and SELECTs on any DBIx::Class object.
+  require Text::CSV;
 
-=head1 OPTIONS
+  my $csv = Text::CSV->new({
+    sep_char => ( $format eq 'tsv' ? "\t" : ',' ),
+  });
 
-=head2 op
+  foreach my $row (@$res) {
+    $csv->combine( @$row );
+    print $csv->string()."\n";
+  }
+}
 
-The type of operation.  Valid values are insert, update, delete, 
-and select.
-
-=head2 schema
-
-The name of your schema class.
-
-=head2 class
-
-The name of the class, within your schema, that you want to run 
-the operation on.
-
-=head2 connect
-
-A JSON array to be passed to your schema class upon connecting.  
-The array will need to be compatible with whatever the DBIC 
-->connect() method requires.
-
-=head2 set
-
-This option must be valid JSON data string and is passed in to 
-the DBIC update() method.  Use this option with the update 
-and insert ops.
-
-=head2 where
-
-This option must be valid JSON data string and is passed in as 
-the first argument to the DBIC search() method.  Use this 
-option with the update, delete, and select ops.
-
-=head2 attrs
-
-This option must be valid JSON data string and is passed in as 
-the second argument to the DBIC search() method.  Use this 
-option with the update, delete, and select ops.
-
-=head2 help
-
-Display this help page.
-
-=head2 force
-
-Suppresses the confirmation dialogues that are usually displayed 
-when someone runs a DELETE or UPDATE action.
-
-=head2 quiet
-
-Do not display status messages.
-
-=head2 trace
-
-Turns on tracing on the DBI storage, thus printing SQL as it is 
-executed.
-
-=head2 tlibs
-
-This option is purely for testing during the DBIC installation.  Do 
-not use it.
-
-=head1 JSON
-
-JSON is a lightweight data-interchange format.  It allows you 
-to express complex data structures for use in the where and 
-set options.
-
-This module turns on L<JSON>'s BareKey and QuotApos options so 
-that your data can look a bit more readable.
-
-  --where={"this":"that"} # generic JSON
-  --where={this:'that'}   # with BareKey and QuoteApos
-
-Consider wrapping your JSON in outer quotes so that you don't 
-have to escape your inner quotes.
-
-  --where={this:\"that\"} # no outer quote
-  --where='{this:"that"}' # outer quoted
-
 =head1 AUTHOR
 
-Aran Deltac <bluefeet at cpan.org>
+See L<DBIx::Class/CONTRIBUTORS>.
 
 =head1 LICENSE
 
-You may distribute this code under the same terms as Perl itself.
+You may distribute this code under the same terms as Perl itself
 
+=cut

Modified: DBIx-Class/0.08/branches/storage-interbase/t/03podcoverage.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/03podcoverage.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/03podcoverage.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -86,6 +86,14 @@
         /]
     },
 
+    'DBIx::Class::Storage::DBI::Replicated*'        => {
+        ignore => [ qw/
+            connect_call_do_sql
+            disconnect_call_do_sql
+        /]
+    },
+
+    'DBIx::Class::Admin::Types'                     => { skip => 1 },
     'DBIx::Class::ClassResolver::PassThrough'       => { skip => 1 },
     'DBIx::Class::Componentised'                    => { skip => 1 },
     'DBIx::Class::Relationship::*'                  => { skip => 1 },
@@ -95,7 +103,6 @@
     'DBIx::Class::Storage::DBI::Replicated::Types'  => { skip => 1 },
 
 # test some specific components whose parents are exempt below
-    'DBIx::Class::Storage::DBI::Replicated*'        => {},
     'DBIx::Class::Relationship::Base'               => {},
 
 # internals

Added: DBIx-Class/0.08/branches/storage-interbase/t/10optional_deps.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/10optional_deps.t	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/t/10optional_deps.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,70 @@
+use strict;
+use warnings;
+no warnings qw/once/;
+
+use Test::More;
+use lib qw(t/lib);
+use Scalar::Util; # load before we break require()
+
+use_ok 'DBIx::Class::Optional::Dependencies';
+
+my $sqlt_dep = DBIx::Class::Optional::Dependencies->req_list_for ('deploy');
+is_deeply (
+  [ keys %$sqlt_dep ],
+  [ 'SQL::Translator' ],
+  'Correct deploy() dependency list',
+);
+
+# make module loading impossible, regardless of actual libpath contents
+ at INC = (sub { die('Optional Dep Test') } );
+
+ok (
+  ! DBIx::Class::Optional::Dependencies->req_ok_for ('deploy'),
+  'deploy() deps missing',
+);
+
+like (
+  DBIx::Class::Optional::Dependencies->req_missing_for ('deploy'),
+  qr/^SQL::Translator \>\= \d/,
+  'expected missing string contents',
+);
+
+like (
+  DBIx::Class::Optional::Dependencies->req_errorlist_for ('deploy')->{'SQL::Translator'},
+  qr/Optional Dep Test/,
+  'custom exception found in errorlist',
+);
+
+
+#make it so module appears loaded
+$INC{'SQL/Translator.pm'} = 1;
+$SQL::Translator::VERSION = 999;
+
+ok (
+  ! DBIx::Class::Optional::Dependencies->req_ok_for ('deploy'),
+  'deploy() deps missing cached properly',
+);
+
+#reset cache
+%DBIx::Class::Optional::Dependencies::req_availability_cache = ();
+
+
+ok (
+  DBIx::Class::Optional::Dependencies->req_ok_for ('deploy'),
+  'deploy() deps present',
+);
+
+is (
+  DBIx::Class::Optional::Dependencies->req_missing_for ('deploy'),
+  '',
+  'expected null missing string',
+);
+
+is_deeply (
+  DBIx::Class::Optional::Dependencies->req_errorlist_for ('deploy'),
+  {},
+  'expected empty errorlist',
+);
+
+
+done_testing;

Modified: DBIx-Class/0.08/branches/storage-interbase/t/749sybase_asa.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/749sybase_asa.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/749sybase_asa.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -28,7 +28,9 @@
 
   next unless $dsn;
 
-  my $schema = DBICTest::Schema->connect($dsn, $user, $pass);
+  my $schema = DBICTest::Schema->connect($dsn, $user, $pass, {
+    auto_savepoint => 1
+  });
 
   my $dbh = $schema->storage->dbh;
 
@@ -58,6 +60,28 @@
   $new->discard_changes;
   is($new->artistid, 66, 'Explicit PK assigned');
 
+# test savepoints
+  eval {
+    $schema->txn_do(sub {
+      eval {
+        $schema->txn_do(sub {
+          $ars->create({ name => 'in_savepoint' });
+          die "rolling back savepoint";
+        });
+      };
+      ok ((not $ars->search({ name => 'in_savepoint' })->first),
+        'savepoint rolled back');
+      $ars->create({ name => 'in_outer_txn' });
+      die "rolling back outer txn";
+    });
+  };
+
+  like $@, qr/rolling back outer txn/,
+    'correct exception for rollback';
+
+  ok ((not $ars->search({ name => 'in_outer_txn' })->first),
+    'outer txn rolled back');
+
 # test populate
   lives_ok (sub {
     my @pop;

Modified: DBIx-Class/0.08/branches/storage-interbase/t/76select.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/76select.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/76select.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -157,10 +157,9 @@
   $sub_rs->single,
   {
     artist         => 1,
-    track_position => 2,
-    tracks         => {
+    tracks => {
+      title => 'Apiary',
       trackid => 17,
-      title   => 'Apiary',
     },
   },
   'columns/select/as fold properly on sub-searches',

Modified: DBIx-Class/0.08/branches/storage-interbase/t/86sqlt.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/86sqlt.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/86sqlt.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -6,12 +6,20 @@
 use DBICTest;
 
 BEGIN {
-  require DBIx::Class::Storage::DBI;
+  require DBIx::Class;
   plan skip_all =>
-      'Test needs SQL::Translator ' . DBIx::Class::Storage::DBI->_sqlt_minimum_version
-    if not DBIx::Class::Storage::DBI->_sqlt_version_ok;
+      'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for ('deploy')
+    unless DBIx::Class::Optional::Dependencies->req_ok_for ('deploy')
 }
 
+my $custom_deployment_statements_called = 0;
+
+sub DBICTest::Schema::deployment_statements {
+  $custom_deployment_statements_called = 1;
+  my $self = shift;
+  return $self->next::method(@_);
+}
+
 my $schema = DBICTest->init_schema (no_deploy => 1);
 
 
@@ -44,28 +52,35 @@
 
 
 
-# replace the sqlt calback with a custom version ading an index
-$schema->source('Track')->sqlt_deploy_callback(sub {
-  my ($self, $sqlt_table) = @_;
+{
+  my $deploy_hook_called = 0;
 
-  is (
-    $sqlt_table->schema->translator->producer_type,
-    join ('::', 'SQL::Translator::Producer', $schema->storage->sqlt_type),
-    'Production type passed to translator object',
-  );
+  # replace the sqlt calback with a custom version ading an index
+  $schema->source('Track')->sqlt_deploy_callback(sub {
+    my ($self, $sqlt_table) = @_;
 
-  if ($schema->storage->sqlt_type eq 'SQLite' ) {
-    $sqlt_table->add_index( name => 'track_title', fields => ['title'] )
-      or die $sqlt_table->error;
-  }
+    $deploy_hook_called = 1;
 
-  $self->default_sqlt_deploy_hook($sqlt_table);
-});
+    is (
+      $sqlt_table->schema->translator->producer_type,
+      join ('::', 'SQL::Translator::Producer', $schema->storage->sqlt_type),
+      'Production type passed to translator object',
+    );
 
-$schema->deploy; # do not remove, this fires the is() test in the callback above
+    if ($schema->storage->sqlt_type eq 'SQLite' ) {
+      $sqlt_table->add_index( name => 'track_title', fields => ['title'] )
+        or die $sqlt_table->error;
+    }
 
+    $self->default_sqlt_deploy_hook($sqlt_table);
+  });
 
+  $schema->deploy; # do not remove, this fires the is() test in the callback above
+  ok($deploy_hook_called, 'deploy hook got called');
+  ok($custom_deployment_statements_called, '->deploy used the schemas deploy_statements method');
+}
 
+
 my $translator = SQL::Translator->new( 
   parser_args => {
     'DBIx::Schema' => $schema,

Deleted: DBIx-Class/0.08/branches/storage-interbase/t/89dbicadmin.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/89dbicadmin.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/89dbicadmin.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -1,89 +0,0 @@
-# vim: filetype=perl
-use strict;
-use warnings;  
-
-use Test::More;
-use lib qw(t/lib);
-use DBICTest;
-
-
-eval 'require JSON::Any';
-plan skip_all => 'Install JSON::Any to run this test' if ($@);
-
-eval 'require Text::CSV_XS';
-if ($@) {
-    eval 'require Text::CSV_PP';
-    plan skip_all => 'Install Text::CSV_XS or Text::CSV_PP to run this test' if ($@);
-}
-
-my @json_backends = qw/XS JSON DWIW/;
-my $tests_per_run = 5;
-
-plan tests => $tests_per_run * @json_backends;
-
-for my $js (@json_backends) {
-
-    eval {JSON::Any->import ($js) };
-    SKIP: {
-        skip ("Json backend $js is not available, skip testing", $tests_per_run) if $@;
-
-        $ENV{JSON_ANY_ORDER} = $js;
-        eval { test_dbicadmin () };
-        diag $@ if $@;
-    }
-}
-
-sub test_dbicadmin {
-    my $schema = DBICTest->init_schema( sqlite_use_file => 1 );  # reinit a fresh db for every run
-
-    my $employees = $schema->resultset('Employee');
-
-    system( _prepare_system_args( qw|--op=insert --set={"name":"Matt"}| ) );
-    ok( ($employees->count()==1), "$ENV{JSON_ANY_ORDER}: insert count" );
-
-    my $employee = $employees->find(1);
-    ok( ($employee->name() eq 'Matt'), "$ENV{JSON_ANY_ORDER}: insert valid" );
-
-    system( _prepare_system_args( qw|--op=update --set={"name":"Trout"}| ) );
-    $employee = $employees->find(1);
-    ok( ($employee->name() eq 'Trout'), "$ENV{JSON_ANY_ORDER}: update" );
-
-    system( _prepare_system_args( qw|--op=insert --set={"name":"Aran"}| ) );
-
-    SKIP: {
-        skip ("MSWin32 doesn't support -| either", 1) if $^O eq 'MSWin32';
-
-        open(my $fh, "-|",  _prepare_system_args( qw|--op=select --attrs={"order_by":"name"}| ) ) or die $!;
-        my $data = do { local $/; <$fh> };
-        close($fh);
-        ok( ($data=~/Aran.*Trout/s), "$ENV{JSON_ANY_ORDER}: select with attrs" );
-    }
-
-    system( _prepare_system_args( qw|--op=delete --where={"name":"Trout"}| ) );
-    ok( ($employees->count()==1), "$ENV{JSON_ANY_ORDER}: delete" );
-}
-
-# Why do we need this crap? Apparently MSWin32 can not pass through quotes properly
-# (sometimes it will and sometimes not, depending on what compiler was used to build
-# perl). So we go the extra mile to escape all the quotes. We can't also use ' instead
-# of ", because JSON::XS (proudly) does not support "malformed JSON" as the author
-# calls it. Bleh.
-#
-sub _prepare_system_args {
-    my $perl = $^X;
-    my @args = (
-        qw|script/dbicadmin --quiet --schema=DBICTest::Schema --class=Employee --tlibs|,
-        q|--connect=["dbi:SQLite:dbname=t/var/DBIxClass.db","","",{"AutoCommit":1}]|,
-        qw|--force --tlibs|,
-        @_,
-    );
-
-    if ( $^O eq 'MSWin32' ) {
-        $perl = qq|"$perl"|;    # execution will fail if $^X contains paths
-        for (@args) {
-            $_ =~ s/"/\\"/g;
-        }
-    }
-
-    return ($perl, @args);
-}

Modified: DBIx-Class/0.08/branches/storage-interbase/t/94versioning.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/94versioning.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/94versioning.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -22,10 +22,10 @@
     || plan skip_all => 'Test needs Time::HiRes';
   Time::HiRes->import(qw/time sleep/);
 
-  require DBIx::Class::Storage::DBI;
+  require DBIx::Class;
   plan skip_all =>
-      'Test needs SQL::Translator ' . DBIx::Class::Storage::DBI->_sqlt_minimum_version
-    if not DBIx::Class::Storage::DBI->_sqlt_version_ok;
+      'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for ('deploy')
+    unless DBIx::Class::Optional::Dependencies->req_ok_for ('deploy')
 }
 
 use lib qw(t/lib);

Modified: DBIx-Class/0.08/branches/storage-interbase/t/99dbic_sqlt_parser.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/99dbic_sqlt_parser.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/99dbic_sqlt_parser.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -9,10 +9,10 @@
 use Scalar::Util ();
 
 BEGIN {
-  require DBIx::Class::Storage::DBI;
+  require DBIx::Class;
   plan skip_all =>
-      'Test needs SQL::Translator ' . DBIx::Class::Storage::DBI->_sqlt_minimum_version
-    if not DBIx::Class::Storage::DBI->_sqlt_version_ok;
+      'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for ('deploy')
+    unless DBIx::Class::Optional::Dependencies->req_ok_for ('deploy')
 }
 
 # Test for SQLT-related leaks

Added: DBIx-Class/0.08/branches/storage-interbase/t/admin/01load.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/admin/01load.t	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/t/admin/01load.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,15 @@
+use strict;
+use warnings;
+
+use Test::More;
+
+BEGIN {
+    require DBIx::Class;
+    plan skip_all => 'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for('admin')
+      unless DBIx::Class::Optional::Dependencies->req_ok_for('admin');
+}
+
+use_ok 'DBIx::Class::Admin';
+
+
+done_testing;

Added: DBIx-Class/0.08/branches/storage-interbase/t/admin/02ddl.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/admin/02ddl.t	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/t/admin/02ddl.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,130 @@
+use strict;
+use warnings;
+
+use Test::More;
+use Test::Exception;
+use Test::Warn;
+
+BEGIN {
+    require DBIx::Class;
+    plan skip_all => 'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for('admin')
+      unless DBIx::Class::Optional::Dependencies->req_ok_for('admin');
+
+    plan skip_all => 'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for('deploy')
+      unless DBIx::Class::Optional::Dependencies->req_ok_for('deploy');
+}
+
+use lib qw(t/lib);
+use DBICTest;
+
+use Path::Class;
+
+use ok 'DBIx::Class::Admin';
+
+
+my $sql_dir = dir(qw/t var/);
+my @connect_info = DBICTest->_database(
+  no_deploy=>1,
+  no_populate=>1,
+  sqlite_use_file  => 1,
+);
+{ # create the schema
+
+#  make sure we are  clean
+clean_dir($sql_dir);
+
+
+my $admin = DBIx::Class::Admin->new(
+  schema_class=> "DBICTest::Schema",
+  sql_dir=> $sql_dir,
+  connect_info => \@connect_info, 
+);
+isa_ok ($admin, 'DBIx::Class::Admin', 'create the admin object');
+lives_ok { $admin->create('MySQL'); } 'Can create MySQL sql';
+lives_ok { $admin->create('SQLite'); } 'Can Create SQLite sql';
+}
+
+{ # upgrade schema
+
+#my $schema = DBICTest->init_schema(
+#  no_deploy    => 1,
+#  no_populat    => 1,
+#  sqlite_use_file  => 1,
+#);
+
+clean_dir($sql_dir);
+require DBICVersion_v1;
+
+my $admin = DBIx::Class::Admin->new(
+  schema_class => 'DBICVersion::Schema', 
+  sql_dir =>  $sql_dir,
+  connect_info => \@connect_info,
+);
+
+my $schema = $admin->schema();
+
+lives_ok { $admin->create($schema->storage->sqlt_type(), {add_drop_table=>0}); } 'Can create DBICVersionOrig sql in ' . $schema->storage->sqlt_type;
+lives_ok { $admin->deploy(  ) } 'Can Deploy schema';
+
+# connect to now deployed schema
+lives_ok { $schema = DBICVersion::Schema->connect(@{$schema->storage->connect_info()}); } 'Connect to deployed Database';
+
+is($schema->get_db_version, $DBICVersion::Schema::VERSION, 'Schema deployed and versions match');
+
+
+require DBICVersion_v2;
+
+$admin = DBIx::Class::Admin->new(
+  schema_class => 'DBICVersion::Schema', 
+  sql_dir =>  $sql_dir,
+  connect_info => \@connect_info
+);
+
+lives_ok { $admin->create($schema->storage->sqlt_type(), {}, "1.0" ); } 'Can create diff for ' . $schema->storage->sqlt_type;
+{
+  local $SIG{__WARN__} = sub { warn $_[0] unless $_[0] =~ /DB version .+? is lower than the schema version/ };
+  lives_ok {$admin->upgrade();} 'upgrade the schema';
+}
+
+is($schema->get_db_version, $DBICVersion::Schema::VERSION, 'Schema and db versions match');
+
+}
+
+{ # install
+
+clean_dir($sql_dir);
+
+my $admin = DBIx::Class::Admin->new(
+  schema_class  => 'DBICVersion::Schema', 
+  sql_dir      => $sql_dir,
+  _confirm    => 1,
+  connect_info  => \@connect_info,
+);
+
+$admin->version("3.0");
+lives_ok { $admin->install(); } 'install schema version 3.0';
+is($admin->schema->get_db_version, "3.0", 'db thinks its version 3.0');
+dies_ok { $admin->install("4.0"); } 'cannot install to allready existing version';
+
+$admin->force(1);
+warnings_exist ( sub {
+  lives_ok { $admin->install("4.0") } 'can force install to allready existing version'
+}, qr/Forcing install may not be a good idea/, 'Force warning emitted' );
+is($admin->schema->get_db_version, "4.0", 'db thinks its version 4.0');
+#clean_dir($sql_dir);
+}
+
+sub clean_dir {
+  my ($dir) = @_;
+  $dir = $dir->resolve;
+  if ( ! -d $dir ) {
+    $dir->mkpath();
+  }
+  foreach my $file ($dir->children) {
+    # skip any hidden files
+    next if ($file =~ /^\./); 
+    unlink $file;
+  }
+}
+
+done_testing;

Added: DBIx-Class/0.08/branches/storage-interbase/t/admin/03data.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/admin/03data.t	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/t/admin/03data.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,65 @@
+use strict;
+use warnings;
+
+use Test::More;
+
+use Test::Exception;
+use Test::Deep;
+
+BEGIN {
+    require DBIx::Class;
+    plan skip_all => 'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for('admin')
+      unless DBIx::Class::Optional::Dependencies->req_ok_for('admin');
+}
+
+use lib 't/lib';
+use DBICTest;
+
+use ok 'DBIx::Class::Admin';
+
+
+{ # test data maniplulation functions
+
+  # create a DBICTest so we can steal its connect info
+  my $schema = DBICTest->init_schema(
+    sqlite_use_file => 1,
+  );
+
+  my $admin = DBIx::Class::Admin->new(
+    schema_class=> "DBICTest::Schema",
+    connect_info => $schema->storage->connect_info(),
+    quiet  => 1,
+    _confirm=>1,
+  );
+  isa_ok ($admin, 'DBIx::Class::Admin', 'create the admin object');
+
+  $admin->insert('Employee', { name => 'Matt' });
+  my $employees = $schema->resultset('Employee');
+  is ($employees->count(), 1, "insert okay" );
+
+  my $employee = $employees->find(1);
+  is($employee->name(),  'Matt', "insert valid" );
+
+  $admin->update('Employee', {name => 'Trout'}, {name => 'Matt'});
+
+  $employee = $employees->find(1);
+  is($employee->name(),  'Trout', "update Matt to Trout" );
+
+  $admin->insert('Employee', {name =>'Aran'});
+
+  my $expected_data = [ 
+    [$employee->result_source->columns() ],
+    [1,1,undef,undef,undef,'Trout'],
+    [2,2,undef,undef,undef,'Aran']
+  ];
+  my $data;
+  lives_ok { $data = $admin->select('Employee')} 'can retrive data from database';
+  cmp_deeply($data, $expected_data, 'DB matches whats expected');
+
+  $admin->delete('Employee', {name=>'Trout'});
+  my $del_rs  = $employees->search({name => 'Trout'});
+  is($del_rs->count(), 0, "delete Trout" );
+  is ($employees->count(), 1, "left Aran" );
+}
+
+done_testing;

Copied: DBIx-Class/0.08/branches/storage-interbase/t/admin/10script.t (from rev 8530, DBIx-Class/0.08/branches/storage-interbase/t/89dbicadmin.t)
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/admin/10script.t	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/t/admin/10script.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,91 @@
+# vim: filetype=perl
+use strict;
+use warnings;
+
+use Test::More;
+use Config;
+use lib qw(t/lib);
+$ENV{PERL5LIB} = join ($Config{path_sep}, @INC);
+use DBICTest;
+
+
+BEGIN {
+    require DBIx::Class;
+    plan skip_all => 'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for('admin_script')
+      unless DBIx::Class::Optional::Dependencies->req_ok_for('admin_script');
+}
+
+my @json_backends = qw/XS JSON DWIW/;
+my $tests_per_run = 5;
+
+plan tests => $tests_per_run * @json_backends;
+
+for my $js (@json_backends) {
+
+    eval {JSON::Any->import ($js) };
+    SKIP: {
+        skip ("Json backend $js is not available, skip testing", $tests_per_run) if $@;
+
+        $ENV{JSON_ANY_ORDER} = $js;
+        eval { test_dbicadmin () };
+        diag $@ if $@;
+    }
+}
+
+sub test_dbicadmin {
+    my $schema = DBICTest->init_schema( sqlite_use_file => 1 );  # reinit a fresh db for every run
+
+    my $employees = $schema->resultset('Employee');
+
+    system( _prepare_system_args( qw|--op=insert --set={"name":"Matt"}| ) );
+    ok( ($employees->count()==1), "$ENV{JSON_ANY_ORDER}: insert count" );
+
+    my $employee = $employees->find(1);
+    ok( ($employee->name() eq 'Matt'), "$ENV{JSON_ANY_ORDER}: insert valid" );
+
+    system( _prepare_system_args( qw|--op=update --set={"name":"Trout"}| ) );
+    $employee = $employees->find(1);
+    ok( ($employee->name() eq 'Trout'), "$ENV{JSON_ANY_ORDER}: update" );
+
+    system( _prepare_system_args( qw|--op=insert --set={"name":"Aran"}| ) );
+
+    SKIP: {
+        skip ("MSWin32 doesn't support -| either", 1) if $^O eq 'MSWin32';
+
+        open(my $fh, "-|",  _prepare_system_args( qw|--op=select --attrs={"order_by":"name"}| ) ) or die $!;
+        my $data = do { local $/; <$fh> };
+        close($fh);
+        if (!ok( ($data=~/Aran.*Trout/s), "$ENV{JSON_ANY_ORDER}: select with attrs" )) {
+          diag ("data from select is $data")
+        };
+    }
+
+    system( _prepare_system_args( qw|--op=delete --where={"name":"Trout"}| ) );
+    ok( ($employees->count()==1), "$ENV{JSON_ANY_ORDER}: delete" );
+}
+
+# Why do we need this crap? Apparently MSWin32 can not pass through quotes properly
+# (sometimes it will and sometimes not, depending on what compiler was used to build
+# perl). So we go the extra mile to escape all the quotes. We can't also use ' instead
+# of ", because JSON::XS (proudly) does not support "malformed JSON" as the author
+# calls it. Bleh.
+#
+sub _prepare_system_args {
+    my $perl = $^X;
+
+    my @args = (
+        qw|script/dbicadmin --quiet --schema=DBICTest::Schema --class=Employee|,
+        q|--connect=["dbi:SQLite:dbname=t/var/DBIxClass.db","","",{"AutoCommit":1}]|,
+        qw|--force|,
+        @_,
+    );
+
+    if ( $^O eq 'MSWin32' ) {
+        $perl = qq|"$perl"|;    # execution will fail if $^X contains paths
+        for (@args) {
+            $_ =~ s/"/\\"/g;
+        }
+    }
+
+    return ($perl, @args);
+}

Modified: DBIx-Class/0.08/branches/storage-interbase/t/count/distinct.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/count/distinct.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/count/distinct.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -74,7 +74,7 @@
   $rs = $schema->resultset('Tag')->search({ tag => 'Blue' }, { '+select' => { max => 'tagid' }, distinct => 1 });
   is($get_count->($rs), 4, 'Count with +select aggreggate');
 
-  $rs = $schema->resultset('Tag')->search({}, { select => 'length(me.tag)', distinct => 1 });
+  $rs = $schema->resultset('Tag')->search({}, { select => [\'length(me.tag)'], distinct => 1 });
   is($get_count->($rs), 3, 'Count by distinct function result as select literal');
 }
 

Added: DBIx-Class/0.08/branches/storage-interbase/t/count/group_by_func.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/count/group_by_func.t	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/t/count/group_by_func.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,36 @@
+use strict;
+use warnings;
+
+use Test::More;
+
+use lib qw(t/lib);
+
+use DBICTest;
+
+my $schema = DBICTest->init_schema();
+
+my $rs = $schema->resultset ('CD')->search ({}, {
+  select => [
+    { substr => [ 'title', 1, 1 ], -as => 'initial' },
+    { count => '*' },
+  ],
+  as => [qw/title_initial cnt/],
+  group_by => ['initial'],
+  order_by => { -desc => 'initial' },
+  result_class => 'DBIx::Class::ResultClass::HashRefInflator',
+});
+
+is_deeply (
+  [$rs->all],
+  [
+    { title_initial => 'S', cnt => '1' },
+    { title_initial => 'G', cnt => '1' },
+    { title_initial => 'F', cnt => '1' },
+    { title_initial => 'C', cnt => '2' },
+  ],
+  'Correct result',
+);
+
+is ($rs->count, 4, 'Correct count');
+
+done_testing;

Modified: DBIx-Class/0.08/branches/storage-interbase/t/inflate/datetime_sybase_asa.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/inflate/datetime_sybase_asa.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/inflate/datetime_sybase_asa.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -44,7 +44,7 @@
 
 # coltype, col, date
   my @dt_types = (
-    ['TIMESTAMP', 'last_updated_at', '2004-08-21 14:36:48.080444'],
+    ['TIMESTAMP', 'last_updated_at', '2004-08-21 14:36:48.080445'],
 # date only (but minute precision according to ASA docs)
     ['DATE', 'small_dt', '2004-08-21 00:00:00.000000'],
   );
@@ -73,6 +73,9 @@
       ->first
     );
     is( $row->$col, $dt, 'DateTime roundtrip' );
+
+    is $row->$col->nanosecond, $dt->nanosecond,
+        'nanoseconds survived' if 0+$dt->nanosecond;
   }
 }
 

Modified: DBIx-Class/0.08/branches/storage-interbase/t/inflate/hri.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/inflate/hri.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/inflate/hri.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -26,6 +26,9 @@
 
     my $cd1 = $rs->find ({cdid => 1});
     is_deeply ( $cd1, $datahashref1, 'first/find return the same thing');
+
+    my $cd2 = $rs->search({ cdid => 1 })->single;
+    is_deeply ( $cd2, $datahashref1, 'first/search+single return the same thing');
 }
 
 sub check_cols_of {

Modified: DBIx-Class/0.08/branches/storage-interbase/t/lib/DBICTest/AuthorCheck.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/lib/DBICTest/AuthorCheck.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/lib/DBICTest/AuthorCheck.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -27,26 +27,37 @@
   my $root = _find_co_root()
     or return;
 
+  my $optdeps = file('lib/DBIx/Class/Optional/Dependencies.pm');
+
   # not using file->stat as it invokes File::stat which in turn breaks stat(_)
-  my ($mf_pl_mtime, $mf_mtime) = ( map
+  my ($mf_pl_mtime, $mf_mtime, $optdeps_mtime) = ( map
     { (stat ($root->file ($_)) )[9] }
-    qw/Makefile.PL Makefile/
+    (qw|Makefile.PL  Makefile|, $optdeps)
   );
 
   return unless $mf_pl_mtime;   # something went wrong during co_root detection ?
 
-  if (
-    not -d $root->subdir ('inc') 
-      or
-    not $mf_mtime
-      or
-    $mf_mtime < $mf_pl_mtime
-  ) {
-    print STDERR <<'EOE';
+  my @fail_reasons;
 
+  if(not -d $root->subdir ('inc')) {
+    push @fail_reasons, "Missing ./inc directory";
+  }
 
+  if (not $mf_mtime) {
+    push @fail_reasons, "Missing ./Makefile";
+  }
+  elsif($mf_mtime < $mf_pl_mtime) {
+    push @fail_reasons, "./Makefile.PL is newer than ./Makefile";
+  }
 
+  if ($mf_mtime < $optdeps_mtime) {
+    push @fail_reasons, "./$optdeps is newer than ./Makefile";
+  }
 
+  if (@fail_reasons) {
+    print STDERR <<'EOE';
+
+
 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
 ======================== FATAL ERROR ===========================
 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -68,9 +79,15 @@
 The DBIC team
 
 
+Reasons you received this message:
 
 EOE
 
+    foreach my $r (@fail_reasons) {
+      print STDERR "  * $r\n";
+    }
+    print STDERR "\n\n\n";
+
     exit 1;
   }
 }

Modified: DBIx-Class/0.08/branches/storage-interbase/t/lib/DBICTest/Schema/ForceForeign.pm
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/lib/DBICTest/Schema/ForceForeign.pm	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/lib/DBICTest/Schema/ForceForeign.pm	2010-02-19 11:17:57 UTC (rev 8755)
@@ -12,30 +12,21 @@
 
 # Normally this would not appear as a FK constraint
 # since it uses the PK
-__PACKAGE__->might_have(
-			'artist_1', 'DBICTest::Schema::Artist', {
-			    'foreign.artistid' => 'self.artist',
-			}, {
-			    is_foreign_key_constraint => 1,
-			},
+__PACKAGE__->might_have('artist_1', 'DBICTest::Schema::Artist',
+  { 'foreign.artistid' => 'self.artist' },
+  { is_foreign_key_constraint => 1 },
 );
 
 # Normally this would appear as a FK constraint
-__PACKAGE__->might_have(
-			'cd_1', 'DBICTest::Schema::CD', {
-			    'foreign.cdid' => 'self.cd',
-			}, {
-			    is_foreign_key_constraint => 0,
-			},
+__PACKAGE__->might_have('cd_1', 'DBICTest::Schema::CD',
+  { 'foreign.cdid' => 'self.cd' },
+  { is_foreign_key_constraint => 0 },
 );
 
 # Normally this would appear as a FK constraint
-__PACKAGE__->belongs_to(
-			'cd_3', 'DBICTest::Schema::CD', {
-			    'foreign.cdid' => 'self.cd',
-			}, {
-			    is_foreign_key_constraint => 0,
-			},
+__PACKAGE__->belongs_to('cd_3', 'DBICTest::Schema::CD',
+  { 'foreign.cdid' => 'self.cd' },
+  { is_foreign_key_constraint => 0 },
 );
 
 1;

Added: DBIx-Class/0.08/branches/storage-interbase/t/resultset/is_ordered.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/resultset/is_ordered.t	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/t/resultset/is_ordered.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,90 @@
+use strict;
+use warnings;
+
+use lib qw(t/lib);
+use Test::More;
+use Test::Exception;
+use DBICTest;
+
+my $schema = DBICTest->init_schema();
+my $rs = $schema->resultset('Artist');
+
+ok !$rs->is_ordered, 'vanilla resultset is not ordered';
+
+# Simple ordering with a single column
+{
+  my $ordered = $rs->search(undef, { order_by => 'artistid' });
+  ok $ordered->is_ordered, 'Simple column ordering detected by is_ordered';
+}
+
+# Hashref order direction
+{
+  my $ordered = $rs->search(undef, { order_by => { -desc => 'artistid' } });
+  ok $ordered->is_ordered, 'resultset with order direction is_ordered';
+}
+
+# Column ordering with literal SQL
+{
+  my $ordered = $rs->search(undef, { order_by => \'artistid DESC' });
+  ok $ordered->is_ordered, 'resultset with literal SQL is_ordered';
+}
+
+# Multiple column ordering
+{
+  my $ordered = $rs->search(undef, { order_by => ['artistid', 'name'] });
+  ok $ordered->is_ordered, 'ordering with multiple columns as arrayref is ordered';
+}
+
+# More complicated ordering
+{
+  my $ordered = $rs->search(undef, { 
+    order_by => [
+      { -asc => 'artistid' }, 
+      { -desc => 'name' },
+    ] 
+  });
+  ok $ordered->is_ordered, 'more complicated resultset ordering is_ordered';
+}
+
+# Empty multi-column ordering arrayref
+{
+  my $ordered = $rs->search(undef, { order_by => [] });
+  ok !$ordered->is_ordered, 'ordering with empty arrayref is not ordered';
+}
+
+# Multi-column ordering syntax with empty hashref
+{
+  my $ordered = $rs->search(undef, { order_by => [{}] });
+  ok !$ordered->is_ordered, 'ordering with [{}] is not ordered';
+}
+
+# Remove ordering after being set
+{
+  my $ordered = $rs->search(undef, { order_by => 'artistid' });
+  ok $ordered->is_ordered, 'resultset with ordering applied works..';
+  my $unordered = $ordered->search(undef, { order_by => undef });
+  ok !$unordered->is_ordered, '..and is not ordered with ordering removed';
+}
+
+# Search without ordering
+{
+  my $ordered = $rs->search({ name => 'We Are Goth' }, { join => 'cds' });
+  ok !$ordered->is_ordered, 'WHERE clause but no order_by is not ordered';
+}
+
+# Other functions without ordering
+{
+  # Join
+  my $joined = $rs->search(undef, { join => 'cds' });
+  ok !$joined->is_ordered, 'join but no order_by is not ordered';
+
+  # Group By
+  my $grouped = $rs->search(undef, { group_by => 'rank' });
+  ok !$grouped->is_ordered, 'group_by but no order_by is not ordered';
+
+  # Paging
+  my $paged = $rs->search(undef, { page=> 5 });
+  ok !$paged->is_ordered, 'paging but no order_by is not ordered';
+}
+
+done_testing;

Added: DBIx-Class/0.08/branches/storage-interbase/t/search/select_chains.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/search/select_chains.t	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/t/search/select_chains.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,61 @@
+use strict;
+use warnings;
+
+use Test::More;
+use Test::Exception;
+
+use lib qw(t/lib);
+use DBIC::SqlMakerTest;
+use DBICTest;
+
+
+my $schema = DBICTest->init_schema();
+
+my @chain = (
+  {
+    columns     => [ 'cdid' ],
+    '+columns'  => [ { title_lc => { lower => 'title' } } ],
+    '+select'   => [ 'genreid' ],
+    '+as'       => [ 'genreid' ],
+  } => 'SELECT me.cdid, LOWER( title ), me.genreid FROM cd me',
+
+  {
+    '+columns'  => [ { max_year => { max => 'me.year' }}, ],
+    '+select'   => [ { count => 'me.cdid' }, ],
+    '+as'       => [ 'cnt' ],
+  } => 'SELECT me.cdid, LOWER( title ), MAX( me.year ), me.genreid, COUNT( me.cdid ) FROM cd me',
+
+  {
+    select      => [ { min => 'me.cdid' }, ],
+    as          => [ 'min_id' ],
+  } => 'SELECT MIN( me.cdid ) FROM cd me',
+
+  {
+    '+columns' => [ { cnt => { count => 'cdid' } } ],
+  } => 'SELECT MIN( me.cdid ), COUNT ( cdid ) FROM cd me',
+
+  {
+    columns => [ 'year' ],
+  } => 'SELECT me.year FROM cd me',
+);
+
+my $rs = $schema->resultset('CD');
+
+my $testno = 1;
+while (@chain) {
+  my $attrs = shift @chain;
+  my $sql = shift @chain;
+
+  $rs = $rs->search ({}, $attrs);
+
+  is_same_sql_bind (
+    $rs->as_query,
+    "($sql)",
+    [],
+    "Test $testno of SELECT assembly ok",
+  );
+
+  $testno++;
+}
+
+done_testing;

Copied: DBIx-Class/0.08/branches/storage-interbase/t/storage/replicated.t (from rev 8530, DBIx-Class/0.08/branches/storage-interbase/t/storage/replication.t)
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/storage/replicated.t	                        (rev 0)
+++ DBIx-Class/0.08/branches/storage-interbase/t/storage/replicated.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -0,0 +1,907 @@
+use strict;
+use warnings;
+use lib qw(t/lib);
+use Test::More;
+use Test::Exception;
+use DBICTest;
+use List::Util 'first';
+use Scalar::Util 'reftype';
+use File::Spec;
+use IO::Handle;
+
+BEGIN {
+    eval { require Test::Moose; Test::Moose->import() };
+    plan skip_all => "Need Test::Moose to run this test" if $@;
+      require DBIx::Class;
+
+    plan skip_all => 'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for ('replicated')
+      unless DBIx::Class::Optional::Dependencies->req_ok_for ('replicated');
+}
+
+use_ok 'DBIx::Class::Storage::DBI::Replicated::Pool';
+use_ok 'DBIx::Class::Storage::DBI::Replicated::Balancer';
+use_ok 'DBIx::Class::Storage::DBI::Replicated::Replicant';
+use_ok 'DBIx::Class::Storage::DBI::Replicated';
+
+use Moose();
+use MooseX::Types();
+diag "Using Moose version $Moose::VERSION and MooseX::Types version $MooseX::Types::VERSION";
+
+=head1 HOW TO USE
+
+    This is a test of the replicated storage system.  This will work in one of
+    two ways, either it was try to fake replication with a couple of SQLite DBs
+    and creative use of copy, or if you define a couple of %ENV vars correctly
+    will try to test those.  If you do that, it will assume the setup is properly
+    replicating.  Your results may vary, but I have demonstrated this to work with
+    mysql native replication.
+
+=cut
+
+
+## ----------------------------------------------------------------------------
+## Build a class to hold all our required testing data and methods.
+## ----------------------------------------------------------------------------
+
+TESTSCHEMACLASSES: {
+
+    ## --------------------------------------------------------------------- ##
+    ## Create an object to contain your replicated stuff.
+    ## --------------------------------------------------------------------- ##
+
+    package DBIx::Class::DBI::Replicated::TestReplication;
+
+    use DBICTest;
+    use base qw/Class::Accessor::Fast/;
+
+    __PACKAGE__->mk_accessors( qw/schema/ );
+
+    ## Initialize the object
+
+    sub new {
+        my ($class, $schema_method) = (shift, shift);
+        my $self = $class->SUPER::new(@_);
+
+        $self->schema( $self->init_schema($schema_method) );
+        return $self;
+    }
+
+    ## Get the Schema and set the replication storage type
+
+    sub init_schema {
+        # current SQLT SQLite producer does not handle DROP TABLE IF EXISTS, trap warnings here
+        local $SIG{__WARN__} = sub { warn @_ unless $_[0] =~ /no such table.+DROP TABLE/s };
+
+        my ($class, $schema_method) = @_;
+
+        my $method = "get_schema_$schema_method";
+        my $schema = $class->$method;
+
+        return $schema;
+    }
+
+    sub get_schema_by_storage_type {
+      DBICTest->init_schema(
+        sqlite_use_file => 1,
+        storage_type=>{
+          '::DBI::Replicated' => {
+            balancer_type=>'::Random',
+            balancer_args=>{
+              auto_validate_every=>100,
+          master_read_weight => 1
+            },
+          }
+        },
+        deploy_args=>{
+          add_drop_table => 1,
+        },
+      );
+    }
+
+    sub get_schema_by_connect_info {
+      DBICTest->init_schema(
+        sqlite_use_file => 1,
+        storage_type=> '::DBI::Replicated',
+        balancer_type=>'::Random',
+        balancer_args=> {
+          auto_validate_every=>100,
+      master_read_weight => 1
+        },
+        deploy_args=>{
+          add_drop_table => 1,
+        },
+      );
+    }
+
+    sub generate_replicant_connect_info {}
+    sub replicate {}
+    sub cleanup {}
+
+    ## --------------------------------------------------------------------- ##
+    ## Add a connect_info option to test option merging.
+    ## --------------------------------------------------------------------- ##
+    {
+    package DBIx::Class::Storage::DBI::Replicated;
+
+    use Moose;
+
+    __PACKAGE__->meta->make_mutable;
+
+    around connect_info => sub {
+      my ($next, $self, $info) = @_;
+      $info->[3]{master_option} = 1;
+      $self->$next($info);
+    };
+
+    __PACKAGE__->meta->make_immutable;
+
+    no Moose;
+    }
+
+    ## --------------------------------------------------------------------- ##
+    ## Subclass for when you are using SQLite for testing, this provides a fake
+    ## replication support.
+    ## --------------------------------------------------------------------- ##
+
+    package DBIx::Class::DBI::Replicated::TestReplication::SQLite;
+
+    use DBICTest;
+    use File::Copy;
+    use base 'DBIx::Class::DBI::Replicated::TestReplication';
+
+    __PACKAGE__->mk_accessors(qw/master_path slave_paths/);
+
+    ## Set the master path from DBICTest
+
+    sub new {
+        my $class = shift @_;
+        my $self = $class->SUPER::new(@_);
+
+        $self->master_path( DBICTest->_sqlite_dbfilename );
+        $self->slave_paths([
+            File::Spec->catfile(qw/t var DBIxClass_slave1.db/),
+            File::Spec->catfile(qw/t var DBIxClass_slave2.db/),
+        ]);
+
+        return $self;
+    }
+
+    ## Return an Array of ArrayRefs where each ArrayRef is suitable to use for
+    ## $storage->connect_info to be used for connecting replicants.
+
+    sub generate_replicant_connect_info {
+        my $self = shift @_;
+        my @dsn = map {
+            "dbi:SQLite:${_}";
+        } @{$self->slave_paths};
+
+        my @connect_infos = map { [$_,'','',{AutoCommit=>1}] } @dsn;
+
+        ## Make sure nothing is left over from a failed test
+        $self->cleanup;
+
+        ## try a hashref too
+        my $c = $connect_infos[0];
+        $connect_infos[0] = {
+          dsn => $c->[0],
+          user => $c->[1],
+          password => $c->[2],
+          %{ $c->[3] }
+        };
+
+        @connect_infos
+    }
+
+    ## Do a 'good enough' replication by copying the master dbfile over each of
+    ## the slave dbfiles.  If the master is SQLite we do this, otherwise we
+    ## just do a one second pause to let the slaves catch up.
+
+    sub replicate {
+        my $self = shift @_;
+        foreach my $slave (@{$self->slave_paths}) {
+            copy($self->master_path, $slave);
+        }
+    }
+
+    ## Cleanup after ourselves.  Unlink all gthe slave paths.
+
+    sub cleanup {
+        my $self = shift @_;
+        foreach my $slave (@{$self->slave_paths}) {
+            if(-e $slave) {
+                unlink $slave;
+            }
+        }
+    }
+
+    ## --------------------------------------------------------------------- ##
+    ## Subclass for when you are setting the databases via custom export vars
+    ## This is for when you have a replicating database setup that you are
+    ## going to test against.  You'll need to define the correct $ENV and have
+    ## two slave databases to test against, as well as a replication system
+    ## that will replicate in less than 1 second.
+    ## --------------------------------------------------------------------- ##
+
+    package DBIx::Class::DBI::Replicated::TestReplication::Custom;
+    use base 'DBIx::Class::DBI::Replicated::TestReplication';
+
+    ## Return an Array of ArrayRefs where each ArrayRef is suitable to use for
+    ## $storage->connect_info to be used for connecting replicants.
+
+    sub generate_replicant_connect_info {
+        return (
+            [$ENV{"DBICTEST_SLAVE0_DSN"}, $ENV{"DBICTEST_SLAVE0_DBUSER"}, $ENV{"DBICTEST_SLAVE0_DBPASS"}, {AutoCommit => 1}],
+            [$ENV{"DBICTEST_SLAVE1_DSN"}, $ENV{"DBICTEST_SLAVE1_DBUSER"}, $ENV{"DBICTEST_SLAVE1_DBPASS"}, {AutoCommit => 1}],
+        );
+    }
+
+    ## pause a bit to let the replication catch up
+
+    sub replicate {
+        sleep 1;
+    }
+}
+
+## ----------------------------------------------------------------------------
+## Create an object and run some tests
+## ----------------------------------------------------------------------------
+
+## Thi first bunch of tests are basic, just make sure all the bits are behaving
+
+my $replicated_class = DBICTest->has_custom_dsn ?
+    'DBIx::Class::DBI::Replicated::TestReplication::Custom' :
+    'DBIx::Class::DBI::Replicated::TestReplication::SQLite';
+
+my $replicated;
+
+for my $method (qw/by_connect_info by_storage_type/) {
+  undef $replicated;
+  ok $replicated = $replicated_class->new($method)
+      => "Created a replication object $method";
+
+  isa_ok $replicated->schema
+      => 'DBIx::Class::Schema';
+
+  isa_ok $replicated->schema->storage
+      => 'DBIx::Class::Storage::DBI::Replicated';
+
+  isa_ok $replicated->schema->storage->balancer
+      => 'DBIx::Class::Storage::DBI::Replicated::Balancer::Random'
+      => 'configured balancer_type';
+}
+
+### check that all Storage::DBI methods are handled by ::Replicated
+{
+  my @storage_dbi_methods = Class::MOP::Class
+    ->initialize('DBIx::Class::Storage::DBI')->get_all_method_names;
+
+  my @replicated_methods  = DBIx::Class::Storage::DBI::Replicated->meta
+    ->get_all_method_names;
+
+# remove constants and OTHER_CRAP
+  @storage_dbi_methods = grep !/^[A-Z_]+\z/, @storage_dbi_methods;
+
+# remove CAG accessors
+  @storage_dbi_methods = grep !/_accessor\z/, @storage_dbi_methods;
+
+# remove DBIx::Class (the root parent, with CAG and stuff) methods
+  my @root_methods = Class::MOP::Class->initialize('DBIx::Class')
+    ->get_all_method_names;
+  my %count;
+  $count{$_}++ for (@storage_dbi_methods, @root_methods);
+
+  @storage_dbi_methods = grep $count{$_} != 2, @storage_dbi_methods;
+
+# make hashes
+  my %storage_dbi_methods;
+  @storage_dbi_methods{@storage_dbi_methods} = ();
+  my %replicated_methods;
+  @replicated_methods{@replicated_methods} = ();
+
+# remove ::Replicated-specific methods
+  for my $method (@replicated_methods) {
+    delete $replicated_methods{$method}
+      unless exists $storage_dbi_methods{$method};
+  }
+  @replicated_methods = keys %replicated_methods;
+
+# check that what's left is implemented
+  %count = ();
+  $count{$_}++ for (@storage_dbi_methods, @replicated_methods);
+
+  if ((grep $count{$_} == 2, @storage_dbi_methods) == @storage_dbi_methods) {
+    pass 'all DBIx::Class::Storage::DBI methods implemented';
+  }
+  else {
+    my @unimplemented = grep $count{$_} == 1, @storage_dbi_methods;
+
+    fail 'the following DBIx::Class::Storage::DBI methods are unimplemented: '
+      . "@unimplemented";
+  }
+}
+
+ok $replicated->schema->storage->meta
+    => 'has a meta object';
+
+isa_ok $replicated->schema->storage->master
+    => 'DBIx::Class::Storage::DBI';
+
+isa_ok $replicated->schema->storage->pool
+    => 'DBIx::Class::Storage::DBI::Replicated::Pool';
+
+does_ok $replicated->schema->storage->balancer
+    => 'DBIx::Class::Storage::DBI::Replicated::Balancer';
+
+ok my @replicant_connects = $replicated->generate_replicant_connect_info
+    => 'got replication connect information';
+
+ok my @replicated_storages = $replicated->schema->storage->connect_replicants(@replicant_connects)
+    => 'Created some storages suitable for replicants';
+
+our %debug;
+$replicated->schema->storage->debug(1);
+$replicated->schema->storage->debugcb(sub {
+    my ($op, $info) = @_;
+    ##warn "\n$op, $info\n";
+    %debug = (
+        op => $op,
+        info => $info,
+        dsn => ($info=~m/\[(.+)\]/)[0],
+        storage_type => $info=~m/REPLICANT/ ? 'REPLICANT' : 'MASTER',
+    );
+});
+
+ok my @all_storages = $replicated->schema->storage->all_storages
+    => '->all_storages';
+
+is scalar @all_storages,
+    3
+    => 'correct number of ->all_storages';
+
+is ((grep $_->isa('DBIx::Class::Storage::DBI'), @all_storages),
+    3
+    => '->all_storages are correct type');
+
+my @all_storage_opts =
+  grep { (reftype($_)||'') eq 'HASH' }
+    map @{ $_->_connect_info }, @all_storages;
+
+is ((grep $_->{master_option}, @all_storage_opts),
+    3
+    => 'connect_info was merged from master to replicants');
+
+my @replicant_names = keys %{ $replicated->schema->storage->replicants };
+
+ok @replicant_names, "found replicant names @replicant_names";
+
+## Silence warning about not supporting the is_replicating method if using the
+## sqlite dbs.
+$replicated->schema->storage->debugobj->silence(1)
+  if first { m{^t/} } @replicant_names;
+
+isa_ok $replicated->schema->storage->balancer->current_replicant
+    => 'DBIx::Class::Storage::DBI';
+
+$replicated->schema->storage->debugobj->silence(0);
+
+ok $replicated->schema->storage->pool->has_replicants
+    => 'does have replicants';
+
+is $replicated->schema->storage->pool->num_replicants => 2
+    => 'has two replicants';
+
+does_ok $replicated_storages[0]
+    => 'DBIx::Class::Storage::DBI::Replicated::Replicant';
+
+does_ok $replicated_storages[1]
+    => 'DBIx::Class::Storage::DBI::Replicated::Replicant';
+
+does_ok $replicated->schema->storage->replicants->{$replicant_names[0]}
+    => 'DBIx::Class::Storage::DBI::Replicated::Replicant';
+
+does_ok $replicated->schema->storage->replicants->{$replicant_names[1]}
+    => 'DBIx::Class::Storage::DBI::Replicated::Replicant';
+
+## Add some info to the database
+
+$replicated
+    ->schema
+    ->populate('Artist', [
+        [ qw/artistid name/ ],
+        [ 4, "Ozric Tentacles"],
+    ]);
+
+    is $debug{storage_type}, 'MASTER',
+        "got last query from a master: $debug{dsn}";
+
+    like $debug{info}, qr/INSERT/, 'Last was an insert';
+
+## Make sure all the slaves have the table definitions
+
+$replicated->replicate;
+$replicated->schema->storage->replicants->{$replicant_names[0]}->active(1);
+$replicated->schema->storage->replicants->{$replicant_names[1]}->active(1);
+
+## Silence warning about not supporting the is_replicating method if using the
+## sqlite dbs.
+$replicated->schema->storage->debugobj->silence(1)
+  if first { m{^t/} } @replicant_names;
+
+$replicated->schema->storage->pool->validate_replicants;
+
+$replicated->schema->storage->debugobj->silence(0);
+
+## Make sure we can read the data.
+
+ok my $artist1 = $replicated->schema->resultset('Artist')->find(4)
+    => 'Created Result';
+
+## We removed testing here since master read weight is on, so we can't tell in
+## advance what storage to expect.  We turn master read weight off a bit lower
+## is $debug{storage_type}, 'REPLICANT'
+##     => "got last query from a replicant: $debug{dsn}, $debug{info}";
+
+isa_ok $artist1
+    => 'DBICTest::Artist';
+
+is $artist1->name, 'Ozric Tentacles'
+    => 'Found expected name for first result';
+
+## Check that master_read_weight is honored
+{
+    no warnings qw/once redefine/;
+
+    local
+    *DBIx::Class::Storage::DBI::Replicated::Balancer::Random::_random_number =
+    sub { 999 };
+
+    $replicated->schema->storage->balancer->increment_storage;
+
+    is $replicated->schema->storage->balancer->current_replicant,
+       $replicated->schema->storage->master
+       => 'master_read_weight is honored';
+
+    ## turn it off for the duration of the test
+    $replicated->schema->storage->balancer->master_read_weight(0);
+    $replicated->schema->storage->balancer->increment_storage;
+}
+
+## Add some new rows that only the master will have  This is because
+## we overload any type of write operation so that is must hit the master
+## database.
+
+$replicated
+    ->schema
+    ->populate('Artist', [
+        [ qw/artistid name/ ],
+        [ 5, "Doom's Children"],
+        [ 6, "Dead On Arrival"],
+        [ 7, "Watergate"],
+    ]);
+
+    is $debug{storage_type}, 'MASTER',
+        "got last query from a master: $debug{dsn}";
+
+    like $debug{info}, qr/INSERT/, 'Last was an insert';
+
+## Make sure all the slaves have the table definitions
+$replicated->replicate;
+
+## Should find some data now
+
+ok my $artist2 = $replicated->schema->resultset('Artist')->find(5)
+    => 'Sync succeed';
+
+is $debug{storage_type}, 'REPLICANT'
+    => "got last query from a replicant: $debug{dsn}";
+
+isa_ok $artist2
+    => 'DBICTest::Artist';
+
+is $artist2->name, "Doom's Children"
+    => 'Found expected name for first result';
+
+## What happens when we disconnect all the replicants?
+
+is $replicated->schema->storage->pool->connected_replicants => 2
+    => "both replicants are connected";
+
+$replicated->schema->storage->replicants->{$replicant_names[0]}->disconnect;
+$replicated->schema->storage->replicants->{$replicant_names[1]}->disconnect;
+
+is $replicated->schema->storage->pool->connected_replicants => 0
+    => "both replicants are now disconnected";
+
+## All these should pass, since the database should automatically reconnect
+
+ok my $artist3 = $replicated->schema->resultset('Artist')->find(6)
+    => 'Still finding stuff.';
+
+is $debug{storage_type}, 'REPLICANT'
+    => "got last query from a replicant: $debug{dsn}";
+
+isa_ok $artist3
+    => 'DBICTest::Artist';
+
+is $artist3->name, "Dead On Arrival"
+    => 'Found expected name for first result';
+
+is $replicated->schema->storage->pool->connected_replicants => 1
+    => "At Least One replicant reconnected to handle the job";
+
+## What happens when we try to select something that doesn't exist?
+
+ok ! $replicated->schema->resultset('Artist')->find(666)
+    => 'Correctly failed to find something.';
+
+is $debug{storage_type}, 'REPLICANT'
+    => "got last query from a replicant: $debug{dsn}";
+
+## test the reliable option
+
+TESTRELIABLE: {
+
+    $replicated->schema->storage->set_reliable_storage;
+
+    ok $replicated->schema->resultset('Artist')->find(2)
+        => 'Read from master 1';
+
+    is $debug{storage_type}, 'MASTER',
+        "got last query from a master: $debug{dsn}";
+
+    ok $replicated->schema->resultset('Artist')->find(5)
+        => 'Read from master 2';
+
+    is $debug{storage_type}, 'MASTER',
+        "got last query from a master: $debug{dsn}";
+
+    $replicated->schema->storage->set_balanced_storage;
+
+    ok $replicated->schema->resultset('Artist')->find(3)
+        => 'Read from replicant';
+
+    is $debug{storage_type}, 'REPLICANT',
+        "got last query from a replicant: $debug{dsn}";
+}
+
+## Make sure when reliable goes out of scope, we are using replicants again
+
+ok $replicated->schema->resultset('Artist')->find(1)
+    => 'back to replicant 1.';
+
+    is $debug{storage_type}, 'REPLICANT',
+        "got last query from a replicant: $debug{dsn}";
+
+ok $replicated->schema->resultset('Artist')->find(2)
+    => 'back to replicant 2.';
+
+    is $debug{storage_type}, 'REPLICANT',
+        "got last query from a replicant: $debug{dsn}";
+
+## set all the replicants to inactive, and make sure the balancer falls back to
+## the master.
+
+$replicated->schema->storage->replicants->{$replicant_names[0]}->active(0);
+$replicated->schema->storage->replicants->{$replicant_names[1]}->active(0);
+
+{
+    ## catch the fallback to master warning
+    open my $debugfh, '>', \my $fallback_warning;
+    my $oldfh = $replicated->schema->storage->debugfh;
+    $replicated->schema->storage->debugfh($debugfh);
+
+    ok $replicated->schema->resultset('Artist')->find(2)
+        => 'Fallback to master';
+
+    is $debug{storage_type}, 'MASTER',
+        "got last query from a master: $debug{dsn}";
+
+    like $fallback_warning, qr/falling back to master/
+        => 'emits falling back to master warning';
+
+    $replicated->schema->storage->debugfh($oldfh);
+}
+
+$replicated->schema->storage->replicants->{$replicant_names[0]}->active(1);
+$replicated->schema->storage->replicants->{$replicant_names[1]}->active(1);
+
+## Silence warning about not supporting the is_replicating method if using the
+## sqlite dbs.
+$replicated->schema->storage->debugobj->silence(1)
+  if first { m{^t/} } @replicant_names;
+
+$replicated->schema->storage->pool->validate_replicants;
+
+$replicated->schema->storage->debugobj->silence(0);
+
+ok $replicated->schema->resultset('Artist')->find(2)
+    => 'Returned to replicates';
+
+is $debug{storage_type}, 'REPLICANT',
+    "got last query from a replicant: $debug{dsn}";
+
+## Getting slave status tests
+
+SKIP: {
+    ## We skip this tests unless you have a custom replicants, since the default
+    ## sqlite based replication tests don't support these functions.
+
+    skip 'Cannot Test Replicant Status on Non Replicating Database', 10
+     unless DBICTest->has_custom_dsn && $ENV{"DBICTEST_SLAVE0_DSN"};
+
+    $replicated->replicate; ## Give the slaves a chance to catchup.
+
+    ok $replicated->schema->storage->replicants->{$replicant_names[0]}->is_replicating
+        => 'Replicants are replicating';
+
+    is $replicated->schema->storage->replicants->{$replicant_names[0]}->lag_behind_master, 0
+        => 'Replicant is zero seconds behind master';
+
+    ## Test the validate replicants
+
+    $replicated->schema->storage->pool->validate_replicants;
+
+    is $replicated->schema->storage->pool->active_replicants, 2
+        => 'Still have 2 replicants after validation';
+
+    ## Force the replicants to fail the validate test by required their lag to
+    ## be negative (ie ahead of the master!)
+
+    $replicated->schema->storage->pool->maximum_lag(-10);
+    $replicated->schema->storage->pool->validate_replicants;
+
+    is $replicated->schema->storage->pool->active_replicants, 0
+        => 'No way a replicant be be ahead of the master';
+
+    ## Let's be fair to the replicants again.  Let them lag up to 5
+
+    $replicated->schema->storage->pool->maximum_lag(5);
+    $replicated->schema->storage->pool->validate_replicants;
+
+    is $replicated->schema->storage->pool->active_replicants, 2
+        => 'Both replicants in good standing again';
+
+    ## Check auto validate
+
+    is $replicated->schema->storage->balancer->auto_validate_every, 100
+        => "Got the expected value for auto validate";
+
+        ## This will make sure we auto validatge everytime
+        $replicated->schema->storage->balancer->auto_validate_every(0);
+
+        ## set all the replicants to inactive, and make sure the balancer falls back to
+        ## the master.
+
+        $replicated->schema->storage->replicants->{$replicant_names[0]}->active(0);
+        $replicated->schema->storage->replicants->{$replicant_names[1]}->active(0);
+
+        ## Ok, now when we go to run a query, autovalidate SHOULD reconnect
+
+    is $replicated->schema->storage->pool->active_replicants => 0
+        => "both replicants turned off";
+
+    ok $replicated->schema->resultset('Artist')->find(5)
+        => 'replicant reactivated';
+
+    is $debug{storage_type}, 'REPLICANT',
+        "got last query from a replicant: $debug{dsn}";
+
+    is $replicated->schema->storage->pool->active_replicants => 2
+        => "both replicants reactivated";
+}
+
+## Test the reliably callback
+
+ok my $reliably = sub {
+
+    ok $replicated->schema->resultset('Artist')->find(5)
+        => 'replicant reactivated';
+
+    is $debug{storage_type}, 'MASTER',
+        "got last query from a master: $debug{dsn}";
+
+} => 'created coderef properly';
+
+$replicated->schema->storage->execute_reliably($reliably);
+
+## Try something with an error
+
+ok my $unreliably = sub {
+
+    ok $replicated->schema->resultset('ArtistXX')->find(5)
+        => 'replicant reactivated';
+
+} => 'created coderef properly';
+
+throws_ok {$replicated->schema->storage->execute_reliably($unreliably)}
+    qr/Can't find source for ArtistXX/
+    => 'Bad coderef throws proper error';
+
+## Make sure replication came back
+
+ok $replicated->schema->resultset('Artist')->find(3)
+    => 'replicant reactivated';
+
+is $debug{storage_type}, 'REPLICANT', "got last query from a replicant: $debug{dsn}";
+
+## make sure transactions are set to execute_reliably
+
+ok my $transaction = sub {
+
+    my $id = shift @_;
+
+    $replicated
+        ->schema
+        ->populate('Artist', [
+            [ qw/artistid name/ ],
+            [ $id, "Children of the Grave"],
+        ]);
+
+    ok my $result = $replicated->schema->resultset('Artist')->find($id)
+        => "Found expected artist for $id";
+
+    is $debug{storage_type}, 'MASTER',
+        "got last query from a master: $debug{dsn}";
+
+    ok my $more = $replicated->schema->resultset('Artist')->find(1)
+        => 'Found expected artist again for 1';
+
+    is $debug{storage_type}, 'MASTER',
+        "got last query from a master: $debug{dsn}";
+
+   return ($result, $more);
+
+} => 'Created a coderef properly';
+
+## Test the transaction with multi return
+{
+    ok my @return = $replicated->schema->txn_do($transaction, 666)
+        => 'did transaction';
+
+        is $return[0]->id, 666
+            => 'first returned value is correct';
+
+        is $debug{storage_type}, 'MASTER',
+            "got last query from a master: $debug{dsn}";
+
+        is $return[1]->id, 1
+            => 'second returned value is correct';
+
+        is $debug{storage_type}, 'MASTER',
+             "got last query from a master: $debug{dsn}";
+
+}
+
+## Test that asking for single return works
+{
+    ok my @return = $replicated->schema->txn_do($transaction, 777)
+        => 'did transaction';
+
+        is $return[0]->id, 777
+            => 'first returned value is correct';
+
+        is $return[1]->id, 1
+            => 'second returned value is correct';
+}
+
+## Test transaction returning a single value
+
+{
+    ok my $result = $replicated->schema->txn_do(sub {
+        ok my $more = $replicated->schema->resultset('Artist')->find(1)
+        => 'found inside a transaction';
+        is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
+        return $more;
+    }) => 'successfully processed transaction';
+
+    is $result->id, 1
+       => 'Got expected single result from transaction';
+}
+
+## Make sure replication came back
+
+ok $replicated->schema->resultset('Artist')->find(1)
+    => 'replicant reactivated';
+
+is $debug{storage_type}, 'REPLICANT', "got last query from a replicant: $debug{dsn}";
+
+## Test Discard changes
+
+{
+    ok my $artist = $replicated->schema->resultset('Artist')->find(2)
+        => 'got an artist to test discard changes';
+
+    is $debug{storage_type}, 'REPLICANT', "got last query from a replicant: $debug{dsn}";
+
+    ok $artist->get_from_storage({force_pool=>'master'})
+       => 'properly discard changes';
+
+    is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
+
+    ok $artist->discard_changes({force_pool=>'master'})
+       => 'properly called discard_changes against master (manual attrs)';
+
+    is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
+
+    ok $artist->discard_changes()
+       => 'properly called discard_changes against master (default attrs)';
+
+    is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
+
+    ok $artist->discard_changes({force_pool=>$replicant_names[0]})
+       => 'properly able to override the default attributes';
+
+    is $debug{storage_type}, 'REPLICANT', "got last query from a replicant: $debug{dsn}"
+}
+
+## Test some edge cases, like trying to do a transaction inside a transaction, etc
+
+{
+    ok my $result = $replicated->schema->txn_do(sub {
+        return $replicated->schema->txn_do(sub {
+            ok my $more = $replicated->schema->resultset('Artist')->find(1)
+            => 'found inside a transaction inside a transaction';
+            is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
+            return $more;
+        });
+    }) => 'successfully processed transaction';
+
+    is $result->id, 1
+       => 'Got expected single result from transaction';
+}
+
+{
+    ok my $result = $replicated->schema->txn_do(sub {
+        return $replicated->schema->storage->execute_reliably(sub {
+            return $replicated->schema->txn_do(sub {
+                return $replicated->schema->storage->execute_reliably(sub {
+                    ok my $more = $replicated->schema->resultset('Artist')->find(1)
+                      => 'found inside crazy deep transactions and execute_reliably';
+                    is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
+                    return $more;
+                });
+            });
+        });
+    }) => 'successfully processed transaction';
+
+    is $result->id, 1
+       => 'Got expected single result from transaction';
+}
+
+## Test the force_pool resultset attribute.
+
+{
+    ok my $artist_rs = $replicated->schema->resultset('Artist')
+        => 'got artist resultset';
+
+    ## Turn on Forced Pool Storage
+    ok my $reliable_artist_rs = $artist_rs->search(undef, {force_pool=>'master'})
+        => 'Created a resultset using force_pool storage';
+
+    ok my $artist = $reliable_artist_rs->find(2)
+        => 'got an artist result via force_pool storage';
+
+    is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
+}
+
+## Test the force_pool resultset attribute part two.
+
+{
+    ok my $artist_rs = $replicated->schema->resultset('Artist')
+        => 'got artist resultset';
+
+    ## Turn on Forced Pool Storage
+    ok my $reliable_artist_rs = $artist_rs->search(undef, {force_pool=>$replicant_names[0]})
+        => 'Created a resultset using force_pool storage';
+
+    ok my $artist = $reliable_artist_rs->find(2)
+        => 'got an artist result via force_pool storage';
+
+    is $debug{storage_type}, 'REPLICANT', "got last query from a replicant: $debug{dsn}";
+}
+## Delete the old database files
+$replicated->cleanup;
+
+done_testing;
+
+# vim: sw=4 sts=4 :

Deleted: DBIx-Class/0.08/branches/storage-interbase/t/storage/replication.t
===================================================================
--- DBIx-Class/0.08/branches/storage-interbase/t/storage/replication.t	2010-02-19 10:14:30 UTC (rev 8754)
+++ DBIx-Class/0.08/branches/storage-interbase/t/storage/replication.t	2010-02-19 11:17:57 UTC (rev 8755)
@@ -1,853 +0,0 @@
-use strict;
-use warnings;
-use lib qw(t/lib);
-use Test::More;
-use Test::Exception;
-use DBICTest;
-use List::Util 'first';
-use Scalar::Util 'reftype';
-use File::Spec;
-use IO::Handle;
-
-BEGIN {
-    eval "use DBIx::Class::Storage::DBI::Replicated; use Test::Moose";
-    plan skip_all => "Deps not installed: $@" if $@;
-}
-
-use_ok 'DBIx::Class::Storage::DBI::Replicated::Pool';
-use_ok 'DBIx::Class::Storage::DBI::Replicated::Balancer';
-use_ok 'DBIx::Class::Storage::DBI::Replicated::Replicant';
-use_ok 'DBIx::Class::Storage::DBI::Replicated';
-
-use Moose();
-use MooseX::Types();
-diag "Using Moose version $Moose::VERSION and MooseX::Types version $MooseX::Types::VERSION";
-
-=head1 HOW TO USE
-
-    This is a test of the replicated storage system.  This will work in one of
-    two ways, either it was try to fake replication with a couple of SQLite DBs
-    and creative use of copy, or if you define a couple of %ENV vars correctly
-    will try to test those.  If you do that, it will assume the setup is properly
-    replicating.  Your results may vary, but I have demonstrated this to work with
-    mysql native replication.
-
-=cut
-
-
-## ----------------------------------------------------------------------------
-## Build a class to hold all our required testing data and methods.
-## ----------------------------------------------------------------------------
-
-TESTSCHEMACLASSES: {
-
-    ## --------------------------------------------------------------------- ##
-    ## Create an object to contain your replicated stuff.
-    ## --------------------------------------------------------------------- ##
-
-    package DBIx::Class::DBI::Replicated::TestReplication;
-
-    use DBICTest;
-    use base qw/Class::Accessor::Fast/;
-
-    __PACKAGE__->mk_accessors( qw/schema/ );
-
-    ## Initialize the object
-
-    sub new {
-        my ($class, $schema_method) = (shift, shift);
-        my $self = $class->SUPER::new(@_);
-
-        $self->schema( $self->init_schema($schema_method) );
-        return $self;
-    }
-
-    ## Get the Schema and set the replication storage type
-
-    sub init_schema {
-        # current SQLT SQLite producer does not handle DROP TABLE IF EXISTS, trap warnings here
-        local $SIG{__WARN__} = sub { warn @_ unless $_[0] =~ /no such table.+DROP TABLE/s };
-
-        my ($class, $schema_method) = @_;
-
-        my $method = "get_schema_$schema_method";
-        my $schema = $class->$method;
-
-        return $schema;
-    }
-
-    sub get_schema_by_storage_type {
-      DBICTest->init_schema(
-        sqlite_use_file => 1,
-        storage_type=>{
-          '::DBI::Replicated' => {
-            balancer_type=>'::Random',
-            balancer_args=>{
-              auto_validate_every=>100,
-          master_read_weight => 1
-            },
-          }
-        },
-        deploy_args=>{
-          add_drop_table => 1,
-        },
-      );
-    }
-
-    sub get_schema_by_connect_info {
-      DBICTest->init_schema(
-        sqlite_use_file => 1,
-        storage_type=> '::DBI::Replicated',
-        balancer_type=>'::Random',
-        balancer_args=> {
-          auto_validate_every=>100,
-      master_read_weight => 1
-        },
-        deploy_args=>{
-          add_drop_table => 1,
-        },
-      );
-    }
-
-    sub generate_replicant_connect_info {}
-    sub replicate {}
-    sub cleanup {}
-
-    ## --------------------------------------------------------------------- ##
-    ## Add a connect_info option to test option merging.
-    ## --------------------------------------------------------------------- ##
-    {
-    package DBIx::Class::Storage::DBI::Replicated;
-
-    use Moose;
-
-    __PACKAGE__->meta->make_mutable;
-
-    around connect_info => sub {
-      my ($next, $self, $info) = @_;
-      $info->[3]{master_option} = 1;
-      $self->$next($info);
-    };
-
-    __PACKAGE__->meta->make_immutable;
-
-    no Moose;
-    }
-
-    ## --------------------------------------------------------------------- ##
-    ## Subclass for when you are using SQLite for testing, this provides a fake
-    ## replication support.
-    ## --------------------------------------------------------------------- ##
-
-    package DBIx::Class::DBI::Replicated::TestReplication::SQLite;
-
-    use DBICTest;
-    use File::Copy;
-    use base 'DBIx::Class::DBI::Replicated::TestReplication';
-
-    __PACKAGE__->mk_accessors(qw/master_path slave_paths/);
-
-    ## Set the master path from DBICTest
-
-    sub new {
-        my $class = shift @_;
-        my $self = $class->SUPER::new(@_);
-
-        $self->master_path( DBICTest->_sqlite_dbfilename );
-        $self->slave_paths([
-            File::Spec->catfile(qw/t var DBIxClass_slave1.db/),
-            File::Spec->catfile(qw/t var DBIxClass_slave2.db/),
-        ]);
-
-        return $self;
-    }
-
-    ## Return an Array of ArrayRefs where each ArrayRef is suitable to use for
-    ## $storage->connect_info to be used for connecting replicants.
-
-    sub generate_replicant_connect_info {
-        my $self = shift @_;
-        my @dsn = map {
-            "dbi:SQLite:${_}";
-        } @{$self->slave_paths};
-
-        my @connect_infos = map { [$_,'','',{AutoCommit=>1}] } @dsn;
-
-        ## Make sure nothing is left over from a failed test
-        $self->cleanup;
-
-        ## try a hashref too
-        my $c = $connect_infos[0];
-        $connect_infos[0] = {
-          dsn => $c->[0],
-          user => $c->[1],
-          password => $c->[2],
-          %{ $c->[3] }
-        };
-
-        @connect_infos
-    }
-
-    ## Do a 'good enough' replication by copying the master dbfile over each of
-    ## the slave dbfiles.  If the master is SQLite we do this, otherwise we
-    ## just do a one second pause to let the slaves catch up.
-
-    sub replicate {
-        my $self = shift @_;
-        foreach my $slave (@{$self->slave_paths}) {
-            copy($self->master_path, $slave);
-        }
-    }
-
-    ## Cleanup after ourselves.  Unlink all gthe slave paths.
-
-    sub cleanup {
-        my $self = shift @_;
-        foreach my $slave (@{$self->slave_paths}) {
-            if(-e $slave) {
-                unlink $slave;
-            }
-        }
-    }
-
-    ## --------------------------------------------------------------------- ##
-    ## Subclass for when you are setting the databases via custom export vars
-    ## This is for when you have a replicating database setup that you are
-    ## going to test against.  You'll need to define the correct $ENV and have
-    ## two slave databases to test against, as well as a replication system
-    ## that will replicate in less than 1 second.
-    ## --------------------------------------------------------------------- ##
-
-    package DBIx::Class::DBI::Replicated::TestReplication::Custom;
-    use base 'DBIx::Class::DBI::Replicated::TestReplication';
-
-    ## Return an Array of ArrayRefs where each ArrayRef is suitable to use for
-    ## $storage->connect_info to be used for connecting replicants.
-
-    sub generate_replicant_connect_info {
-        return (
-            [$ENV{"DBICTEST_SLAVE0_DSN"}, $ENV{"DBICTEST_SLAVE0_DBUSER"}, $ENV{"DBICTEST_SLAVE0_DBPASS"}, {AutoCommit => 1}],
-            [$ENV{"DBICTEST_SLAVE1_DSN"}, $ENV{"DBICTEST_SLAVE1_DBUSER"}, $ENV{"DBICTEST_SLAVE1_DBPASS"}, {AutoCommit => 1}],
-        );
-    }
-
-    ## pause a bit to let the replication catch up
-
-    sub replicate {
-        sleep 1;
-    }
-}
-
-## ----------------------------------------------------------------------------
-## Create an object and run some tests
-## ----------------------------------------------------------------------------
-
-## Thi first bunch of tests are basic, just make sure all the bits are behaving
-
-my $replicated_class = DBICTest->has_custom_dsn ?
-    'DBIx::Class::DBI::Replicated::TestReplication::Custom' :
-    'DBIx::Class::DBI::Replicated::TestReplication::SQLite';
-
-my $replicated;
-
-for my $method (qw/by_connect_info by_storage_type/) {
-  undef $replicated;
-  ok $replicated = $replicated_class->new($method)
-      => "Created a replication object $method";
-
-  isa_ok $replicated->schema
-      => 'DBIx::Class::Schema';
-
-  isa_ok $replicated->schema->storage
-      => 'DBIx::Class::Storage::DBI::Replicated';
-
-  isa_ok $replicated->schema->storage->balancer
-      => 'DBIx::Class::Storage::DBI::Replicated::Balancer::Random'
-      => 'configured balancer_type';
-}
-
-ok $replicated->schema->storage->meta
-    => 'has a meta object';
-
-isa_ok $replicated->schema->storage->master
-    => 'DBIx::Class::Storage::DBI';
-
-isa_ok $replicated->schema->storage->pool
-    => 'DBIx::Class::Storage::DBI::Replicated::Pool';
-
-does_ok $replicated->schema->storage->balancer
-    => 'DBIx::Class::Storage::DBI::Replicated::Balancer';
-
-ok my @replicant_connects = $replicated->generate_replicant_connect_info
-    => 'got replication connect information';
-
-ok my @replicated_storages = $replicated->schema->storage->connect_replicants(@replicant_connects)
-    => 'Created some storages suitable for replicants';
-
-our %debug;
-$replicated->schema->storage->debug(1);
-$replicated->schema->storage->debugcb(sub {
-    my ($op, $info) = @_;
-    ##warn "\n$op, $info\n";
-    %debug = (
-        op => $op,
-        info => $info,
-        dsn => ($info=~m/\[(.+)\]/)[0],
-        storage_type => $info=~m/REPLICANT/ ? 'REPLICANT' : 'MASTER',
-    );
-});
-
-ok my @all_storages = $replicated->schema->storage->all_storages
-    => '->all_storages';
-
-is scalar @all_storages,
-    3
-    => 'correct number of ->all_storages';
-
-is ((grep $_->isa('DBIx::Class::Storage::DBI'), @all_storages),
-    3
-    => '->all_storages are correct type');
-
-my @all_storage_opts =
-  grep { (reftype($_)||'') eq 'HASH' }
-    map @{ $_->_connect_info }, @all_storages;
-
-is ((grep $_->{master_option}, @all_storage_opts),
-    3
-    => 'connect_info was merged from master to replicants');
-
-my @replicant_names = keys %{ $replicated->schema->storage->replicants };
-
-ok @replicant_names, "found replicant names @replicant_names";
-
-## Silence warning about not supporting the is_replicating method if using the
-## sqlite dbs.
-$replicated->schema->storage->debugobj->silence(1)
-  if first { m{^t/} } @replicant_names;
-
-isa_ok $replicated->schema->storage->balancer->current_replicant
-    => 'DBIx::Class::Storage::DBI';
-
-$replicated->schema->storage->debugobj->silence(0);
-
-ok $replicated->schema->storage->pool->has_replicants
-    => 'does have replicants';
-
-is $replicated->schema->storage->pool->num_replicants => 2
-    => 'has two replicants';
-
-does_ok $replicated_storages[0]
-    => 'DBIx::Class::Storage::DBI::Replicated::Replicant';
-
-does_ok $replicated_storages[1]
-    => 'DBIx::Class::Storage::DBI::Replicated::Replicant';
-
-does_ok $replicated->schema->storage->replicants->{$replicant_names[0]}
-    => 'DBIx::Class::Storage::DBI::Replicated::Replicant';
-
-does_ok $replicated->schema->storage->replicants->{$replicant_names[1]}
-    => 'DBIx::Class::Storage::DBI::Replicated::Replicant';
-
-## Add some info to the database
-
-$replicated
-    ->schema
-    ->populate('Artist', [
-        [ qw/artistid name/ ],
-        [ 4, "Ozric Tentacles"],
-    ]);
-
-    is $debug{storage_type}, 'MASTER',
-        "got last query from a master: $debug{dsn}";
-
-    like $debug{info}, qr/INSERT/, 'Last was an insert';
-
-## Make sure all the slaves have the table definitions
-
-$replicated->replicate;
-$replicated->schema->storage->replicants->{$replicant_names[0]}->active(1);
-$replicated->schema->storage->replicants->{$replicant_names[1]}->active(1);
-
-## Silence warning about not supporting the is_replicating method if using the
-## sqlite dbs.
-$replicated->schema->storage->debugobj->silence(1)
-  if first { m{^t/} } @replicant_names;
-
-$replicated->schema->storage->pool->validate_replicants;
-
-$replicated->schema->storage->debugobj->silence(0);
-
-## Make sure we can read the data.
-
-ok my $artist1 = $replicated->schema->resultset('Artist')->find(4)
-    => 'Created Result';
-
-## We removed testing here since master read weight is on, so we can't tell in
-## advance what storage to expect.  We turn master read weight off a bit lower
-## is $debug{storage_type}, 'REPLICANT'
-##     => "got last query from a replicant: $debug{dsn}, $debug{info}";
-
-isa_ok $artist1
-    => 'DBICTest::Artist';
-
-is $artist1->name, 'Ozric Tentacles'
-    => 'Found expected name for first result';
-
-## Check that master_read_weight is honored
-{
-    no warnings qw/once redefine/;
-
-    local
-    *DBIx::Class::Storage::DBI::Replicated::Balancer::Random::_random_number =
-    sub { 999 };
-
-    $replicated->schema->storage->balancer->increment_storage;
-
-    is $replicated->schema->storage->balancer->current_replicant,
-       $replicated->schema->storage->master
-       => 'master_read_weight is honored';
-
-    ## turn it off for the duration of the test
-    $replicated->schema->storage->balancer->master_read_weight(0);
-    $replicated->schema->storage->balancer->increment_storage;
-}
-
-## Add some new rows that only the master will have  This is because
-## we overload any type of write operation so that is must hit the master
-## database.
-
-$replicated
-    ->schema
-    ->populate('Artist', [
-        [ qw/artistid name/ ],
-        [ 5, "Doom's Children"],
-        [ 6, "Dead On Arrival"],
-        [ 7, "Watergate"],
-    ]);
-
-    is $debug{storage_type}, 'MASTER',
-        "got last query from a master: $debug{dsn}";
-
-    like $debug{info}, qr/INSERT/, 'Last was an insert';
-
-## Make sure all the slaves have the table definitions
-$replicated->replicate;
-
-## Should find some data now
-
-ok my $artist2 = $replicated->schema->resultset('Artist')->find(5)
-    => 'Sync succeed';
-
-is $debug{storage_type}, 'REPLICANT'
-    => "got last query from a replicant: $debug{dsn}";
-
-isa_ok $artist2
-    => 'DBICTest::Artist';
-
-is $artist2->name, "Doom's Children"
-    => 'Found expected name for first result';
-
-## What happens when we disconnect all the replicants?
-
-is $replicated->schema->storage->pool->connected_replicants => 2
-    => "both replicants are connected";
-
-$replicated->schema->storage->replicants->{$replicant_names[0]}->disconnect;
-$replicated->schema->storage->replicants->{$replicant_names[1]}->disconnect;
-
-is $replicated->schema->storage->pool->connected_replicants => 0
-    => "both replicants are now disconnected";
-
-## All these should pass, since the database should automatically reconnect
-
-ok my $artist3 = $replicated->schema->resultset('Artist')->find(6)
-    => 'Still finding stuff.';
-
-is $debug{storage_type}, 'REPLICANT'
-    => "got last query from a replicant: $debug{dsn}";
-
-isa_ok $artist3
-    => 'DBICTest::Artist';
-
-is $artist3->name, "Dead On Arrival"
-    => 'Found expected name for first result';
-
-is $replicated->schema->storage->pool->connected_replicants => 1
-    => "At Least One replicant reconnected to handle the job";
-
-## What happens when we try to select something that doesn't exist?
-
-ok ! $replicated->schema->resultset('Artist')->find(666)
-    => 'Correctly failed to find something.';
-
-is $debug{storage_type}, 'REPLICANT'
-    => "got last query from a replicant: $debug{dsn}";
-
-## test the reliable option
-
-TESTRELIABLE: {
-
-    $replicated->schema->storage->set_reliable_storage;
-
-    ok $replicated->schema->resultset('Artist')->find(2)
-        => 'Read from master 1';
-
-    is $debug{storage_type}, 'MASTER',
-        "got last query from a master: $debug{dsn}";
-
-    ok $replicated->schema->resultset('Artist')->find(5)
-        => 'Read from master 2';
-
-    is $debug{storage_type}, 'MASTER',
-        "got last query from a master: $debug{dsn}";
-
-    $replicated->schema->storage->set_balanced_storage;
-
-    ok $replicated->schema->resultset('Artist')->find(3)
-        => 'Read from replicant';
-
-    is $debug{storage_type}, 'REPLICANT',
-        "got last query from a replicant: $debug{dsn}";
-}
-
-## Make sure when reliable goes out of scope, we are using replicants again
-
-ok $replicated->schema->resultset('Artist')->find(1)
-    => 'back to replicant 1.';
-
-    is $debug{storage_type}, 'REPLICANT',
-        "got last query from a replicant: $debug{dsn}";
-
-ok $replicated->schema->resultset('Artist')->find(2)
-    => 'back to replicant 2.';
-
-    is $debug{storage_type}, 'REPLICANT',
-        "got last query from a replicant: $debug{dsn}";
-
-## set all the replicants to inactive, and make sure the balancer falls back to
-## the master.
-
-$replicated->schema->storage->replicants->{$replicant_names[0]}->active(0);
-$replicated->schema->storage->replicants->{$replicant_names[1]}->active(0);
-
-{
-    ## catch the fallback to master warning
-    open my $debugfh, '>', \my $fallback_warning;
-    my $oldfh = $replicated->schema->storage->debugfh;
-    $replicated->schema->storage->debugfh($debugfh);
-
-    ok $replicated->schema->resultset('Artist')->find(2)
-        => 'Fallback to master';
-
-    is $debug{storage_type}, 'MASTER',
-        "got last query from a master: $debug{dsn}";
-
-    like $fallback_warning, qr/falling back to master/
-        => 'emits falling back to master warning';
-
-    $replicated->schema->storage->debugfh($oldfh);
-}
-
-$replicated->schema->storage->replicants->{$replicant_names[0]}->active(1);
-$replicated->schema->storage->replicants->{$replicant_names[1]}->active(1);
-
-## Silence warning about not supporting the is_replicating method if using the
-## sqlite dbs.
-$replicated->schema->storage->debugobj->silence(1)
-  if first { m{^t/} } @replicant_names;
-
-$replicated->schema->storage->pool->validate_replicants;
-
-$replicated->schema->storage->debugobj->silence(0);
-
-ok $replicated->schema->resultset('Artist')->find(2)
-    => 'Returned to replicates';
-
-is $debug{storage_type}, 'REPLICANT',
-    "got last query from a replicant: $debug{dsn}";
-
-## Getting slave status tests
-
-SKIP: {
-    ## We skip this tests unless you have a custom replicants, since the default
-    ## sqlite based replication tests don't support these functions.
-
-    skip 'Cannot Test Replicant Status on Non Replicating Database', 10
-     unless DBICTest->has_custom_dsn && $ENV{"DBICTEST_SLAVE0_DSN"};
-
-    $replicated->replicate; ## Give the slaves a chance to catchup.
-
-    ok $replicated->schema->storage->replicants->{$replicant_names[0]}->is_replicating
-        => 'Replicants are replicating';
-
-    is $replicated->schema->storage->replicants->{$replicant_names[0]}->lag_behind_master, 0
-        => 'Replicant is zero seconds behind master';
-
-    ## Test the validate replicants
-
-    $replicated->schema->storage->pool->validate_replicants;
-
-    is $replicated->schema->storage->pool->active_replicants, 2
-        => 'Still have 2 replicants after validation';
-
-    ## Force the replicants to fail the validate test by required their lag to
-    ## be negative (ie ahead of the master!)
-
-    $replicated->schema->storage->pool->maximum_lag(-10);
-    $replicated->schema->storage->pool->validate_replicants;
-
-    is $replicated->schema->storage->pool->active_replicants, 0
-        => 'No way a replicant be be ahead of the master';
-
-    ## Let's be fair to the replicants again.  Let them lag up to 5
-
-    $replicated->schema->storage->pool->maximum_lag(5);
-    $replicated->schema->storage->pool->validate_replicants;
-
-    is $replicated->schema->storage->pool->active_replicants, 2
-        => 'Both replicants in good standing again';
-
-    ## Check auto validate
-
-    is $replicated->schema->storage->balancer->auto_validate_every, 100
-        => "Got the expected value for auto validate";
-
-        ## This will make sure we auto validatge everytime
-        $replicated->schema->storage->balancer->auto_validate_every(0);
-
-        ## set all the replicants to inactive, and make sure the balancer falls back to
-        ## the master.
-
-        $replicated->schema->storage->replicants->{$replicant_names[0]}->active(0);
-        $replicated->schema->storage->replicants->{$replicant_names[1]}->active(0);
-
-        ## Ok, now when we go to run a query, autovalidate SHOULD reconnect
-
-    is $replicated->schema->storage->pool->active_replicants => 0
-        => "both replicants turned off";
-
-    ok $replicated->schema->resultset('Artist')->find(5)
-        => 'replicant reactivated';
-
-    is $debug{storage_type}, 'REPLICANT',
-        "got last query from a replicant: $debug{dsn}";
-
-    is $replicated->schema->storage->pool->active_replicants => 2
-        => "both replicants reactivated";
-}
-
-## Test the reliably callback
-
-ok my $reliably = sub {
-
-    ok $replicated->schema->resultset('Artist')->find(5)
-        => 'replicant reactivated';
-
-    is $debug{storage_type}, 'MASTER',
-        "got last query from a master: $debug{dsn}";
-
-} => 'created coderef properly';
-
-$replicated->schema->storage->execute_reliably($reliably);
-
-## Try something with an error
-
-ok my $unreliably = sub {
-
-    ok $replicated->schema->resultset('ArtistXX')->find(5)
-        => 'replicant reactivated';
-
-} => 'created coderef properly';
-
-throws_ok {$replicated->schema->storage->execute_reliably($unreliably)}
-    qr/Can't find source for ArtistXX/
-    => 'Bad coderef throws proper error';
-
-## Make sure replication came back
-
-ok $replicated->schema->resultset('Artist')->find(3)
-    => 'replicant reactivated';
-
-is $debug{storage_type}, 'REPLICANT', "got last query from a replicant: $debug{dsn}";
-
-## make sure transactions are set to execute_reliably
-
-ok my $transaction = sub {
-
-    my $id = shift @_;
-
-    $replicated
-        ->schema
-        ->populate('Artist', [
-            [ qw/artistid name/ ],
-            [ $id, "Children of the Grave"],
-        ]);
-
-    ok my $result = $replicated->schema->resultset('Artist')->find($id)
-        => "Found expected artist for $id";
-
-    is $debug{storage_type}, 'MASTER',
-        "got last query from a master: $debug{dsn}";
-
-    ok my $more = $replicated->schema->resultset('Artist')->find(1)
-        => 'Found expected artist again for 1';
-
-    is $debug{storage_type}, 'MASTER',
-        "got last query from a master: $debug{dsn}";
-
-   return ($result, $more);
-
-} => 'Created a coderef properly';
-
-## Test the transaction with multi return
-{
-    ok my @return = $replicated->schema->txn_do($transaction, 666)
-        => 'did transaction';
-
-        is $return[0]->id, 666
-            => 'first returned value is correct';
-
-        is $debug{storage_type}, 'MASTER',
-            "got last query from a master: $debug{dsn}";
-
-        is $return[1]->id, 1
-            => 'second returned value is correct';
-
-        is $debug{storage_type}, 'MASTER',
-             "got last query from a master: $debug{dsn}";
-
-}
-
-## Test that asking for single return works
-{
-    ok my @return = $replicated->schema->txn_do($transaction, 777)
-        => 'did transaction';
-
-        is $return[0]->id, 777
-            => 'first returned value is correct';
-
-        is $return[1]->id, 1
-            => 'second returned value is correct';
-}
-
-## Test transaction returning a single value
-
-{
-    ok my $result = $replicated->schema->txn_do(sub {
-        ok my $more = $replicated->schema->resultset('Artist')->find(1)
-        => 'found inside a transaction';
-        is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
-        return $more;
-    }) => 'successfully processed transaction';
-
-    is $result->id, 1
-       => 'Got expected single result from transaction';
-}
-
-## Make sure replication came back
-
-ok $replicated->schema->resultset('Artist')->find(1)
-    => 'replicant reactivated';
-
-is $debug{storage_type}, 'REPLICANT', "got last query from a replicant: $debug{dsn}";
-
-## Test Discard changes
-
-{
-    ok my $artist = $replicated->schema->resultset('Artist')->find(2)
-        => 'got an artist to test discard changes';
-
-    is $debug{storage_type}, 'REPLICANT', "got last query from a replicant: $debug{dsn}";
-
-    ok $artist->get_from_storage({force_pool=>'master'})
-       => 'properly discard changes';
-
-    is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
-
-    ok $artist->discard_changes({force_pool=>'master'})
-       => 'properly called discard_changes against master (manual attrs)';
-
-    is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
-
-    ok $artist->discard_changes()
-       => 'properly called discard_changes against master (default attrs)';
-
-    is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
-
-    ok $artist->discard_changes({force_pool=>$replicant_names[0]})
-       => 'properly able to override the default attributes';
-
-    is $debug{storage_type}, 'REPLICANT', "got last query from a replicant: $debug{dsn}"
-}
-
-## Test some edge cases, like trying to do a transaction inside a transaction, etc
-
-{
-    ok my $result = $replicated->schema->txn_do(sub {
-        return $replicated->schema->txn_do(sub {
-            ok my $more = $replicated->schema->resultset('Artist')->find(1)
-            => 'found inside a transaction inside a transaction';
-            is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
-            return $more;
-        });
-    }) => 'successfully processed transaction';
-
-    is $result->id, 1
-       => 'Got expected single result from transaction';
-}
-
-{
-    ok my $result = $replicated->schema->txn_do(sub {
-        return $replicated->schema->storage->execute_reliably(sub {
-            return $replicated->schema->txn_do(sub {
-                return $replicated->schema->storage->execute_reliably(sub {
-                    ok my $more = $replicated->schema->resultset('Artist')->find(1)
-                      => 'found inside crazy deep transactions and execute_reliably';
-                    is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
-                    return $more;
-                });
-            });
-        });
-    }) => 'successfully processed transaction';
-
-    is $result->id, 1
-       => 'Got expected single result from transaction';
-}
-
-## Test the force_pool resultset attribute.
-
-{
-    ok my $artist_rs = $replicated->schema->resultset('Artist')
-        => 'got artist resultset';
-
-    ## Turn on Forced Pool Storage
-    ok my $reliable_artist_rs = $artist_rs->search(undef, {force_pool=>'master'})
-        => 'Created a resultset using force_pool storage';
-
-    ok my $artist = $reliable_artist_rs->find(2)
-        => 'got an artist result via force_pool storage';
-
-    is $debug{storage_type}, 'MASTER', "got last query from a master: $debug{dsn}";
-}
-
-## Test the force_pool resultset attribute part two.
-
-{
-    ok my $artist_rs = $replicated->schema->resultset('Artist')
-        => 'got artist resultset';
-
-    ## Turn on Forced Pool Storage
-    ok my $reliable_artist_rs = $artist_rs->search(undef, {force_pool=>$replicant_names[0]})
-        => 'Created a resultset using force_pool storage';
-
-    ok my $artist = $reliable_artist_rs->find(2)
-        => 'got an artist result via force_pool storage';
-
-    is $debug{storage_type}, 'REPLICANT', "got last query from a replicant: $debug{dsn}";
-}
-## Delete the old database files
-$replicated->cleanup;
-
-done_testing;
-
-# vim: sw=4 sts=4 :




More information about the Bast-commits mailing list