Alzabo

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN


- Fixed another caching bug related to objects that were deleted and
  then another row was inserted with the same primary key.  Note to
  self: premature optimization is the root of all evil.

---------------------------------------------------------------------------

0.33 Feb 21, 2001

- The linking table methods generated by Alzabo::MethodMaker were
  broken.  Fixed this.

- Changed how order by clauses can be passed to select operations.
  Also changed the docs, which were way out of sync with the changes
  in this area.

- Attempting to update more than one value at once was broken.  Fixed
  this.

- Added Alzabo::Runtime::Table->func method to allow arbitrary column
  aggregate functions like MAX, MIN, AVG, etc.

- Fixed schema creator bug.  It was not possible to change a column's
  NULLability after it was created.

- When changing a column's type, Alzabo now removes any column
  attributes that are not valid for that column.  In addition, if the
  existing length and precision parameters are not valid, they will be
  set to undef.

- Fixed the code to get rid of weird error messages that came from DBI
  with Perl 5.6.0+ when the Alzabo::Create::Schema->create or
  Alzabo::Create::Schema->reverse_engineer methods were called.  For
  the curious, this has to do with the DBI object passing through
  Storable::dclone.

---------------------------------------------------------------------------

0.32 Feb 7, 2001

- Forgot to include data browser files in MANIFEST.  Caused weirdness
  if you said you wanted it when asked during install.  Reported by
  Remi Cohen-Scali.

---------------------------------------------------------------------------

0.31 Feb 5, 2001

Bug fixes only

- Fix bugs in Alzabo::MethodMaker.  The insert, update, lookup_table,
  and self_relation (parent portion only) were broken.

- A bug in the SQL making code was causing some queries to appear as
  if they failed when they didn't.

---------------------------------------------------------------------------

0.30 Feb 4, 2001

- The convert.pl script in eg/ has been updated to handle the new
  release.  IMPORTANT: I forgot to include a mention of this in the
  last release but you need to run the script _before_ installing a
  new version of Alzabo.

- Many improvements and updates to Alzabo::MethodMaker.  Highlights
  include fixing a bug that prevented the insert and update methods
  from being created, a new callback system that allows you to specify
  all the method names to be generated, and a new 'self_relations'
  option for tables that have parent/child relationships with
  themself.

- Fix handling of NULL columns for inserts and updates.  Now, Alzabo
  only throws an exception if the column is not nullable and has no
  default.  If it has a default and is specified as NULL then it will
  not be included in the INSERT clause (in which case the RDBMS should
  insert the default value itself).

- Fix bugs in Postgres reverse engineering.  Defaults were not handled
  properly, nor were numeric column type length and precision.

- The schema creator and data browser now allow you to enter the host
  for database connections where needed.

- Foreign keys can now span multiple columns.  This means you can have
  a relation from foo.foo_id and foo.index_id to bar.foo_id and
  bar.index_id.  This required some changes to the interface for the
  foreign key objects.  Notably, the Alzabo::ForeignKey->column_from
  and Alzabo::ForeignKey->column_to methods are now
  Alzabo::ForeignKey->columns_from and Alzabo::ForeignKey->columns_to.
  In addition, the parameters given to the
  Alzabo::Create::Schema->add_relation have changed.

- Major changes to caching architecture.  The caching code has been
  split up.  There is now a 'storing' class, which holds onto the
  objects (the cache).  Then there is a 'sync' class.  This class
  handles expiration and deletion tracking.  These two classes can be
  mixed and matched.  Right now there is only one storage class (which
  stores the objects in memory).  There are 3 syncing classes.  One,
  NullSync, doesn't actually sync objects.  It does track deletions,
  but not expirations.  The others, IPCSync and DBMSync, use IPC or
  DBM files to track expiration and deletion of objects.

- Doing this work highlighted some bugs in the caching/syncing code.
  One oversight was that if you deleted an object and then inserted
  another row with the exact same primary key, the cache continued to
  think the object was deleted.  Other bugs also surfaced.  These have
  been fixed and the test suite has been updated so caching should be
  stable (if not, I'll have to cry).

- When viewing an existing column in the schema creator, defaults,
  lengths, and precision of 0 were not being shown.

- Alzabo::Runtime::Table->row_count can now take a where clause.

- Fix bugs in Alzabo::Create::Table.  This was causing problems with
  indexes when the table name was changed.

- Fixed a bug in Alzabo::Util that caused the test cases to fail if
  Alzabo hadn't been previously installed.  Reported by Robert Goff.

- The SQLMaker class is now smarter about not letting you make bad
  SQL.  For example, if you try to make a WHERE clause with tables not
  mentioned in the FROM clause, it will throw an exception.  This will
  hopefully help catch logic errors in your code a bit sooner.

- Removed use of prepare_cached in Alzabo::Driver.  This has the
  potential to cause some strange errors under Alzabo.  Because of the
  way Alzabo works, it is possible to have a Cursor object holding
  onto a statement handle that needs to be used elsewhere (by a row
  object, for example).  It is safer to let a new statement handle be
  created in this case.

INCOMPATIBILITIES

- See the note above about the changes required to support
  multi-column foreign keys.

- Because of the aforementioned changes to the caching architecture,
  caching just does not work the way it used to.

  1. By default, there is no caching at all.

  2. To get the old behavior, which defaulted to an in-process memory
  cache with no inter-process syncing (meaning deletes are tracked but
  there is no such thing as expiration), you can do this in your code:

    use Alzabo::ObjectCache( store => 'Alzabo::ObjectCache::MemoryStore',
                             sync  => 'Alzabo::ObjectCache::NullSync' );

  or just:

    use Alzabo::ObjectCache;  # the above modules are the defaults

  3. To get the behavior of the old Alzabo::ObjectCacheIPC module, do:

    use Alzabo::ObjectCache( store => 'Alzabo::ObjectCache::MemoryStore',
                             sync  => 'Alzabo::ObjectCache::IPCSync' );

  However, the new DBMSync module will probably scale better, and
  performance should be about the same for smaller applications.  To
  use it, do:

    use Alzabo::ObjectCache( store => 'Alzabo::ObjectCache::MemoryStore',
                             sync  => 'Alzabo::ObjectCache::DBMSync' );

  4. If you run without any caching at all then the
  Alzabo::Runtime::Row class's behavior has changed somewhat.  In



( run in 0.618 second using v1.01-cache-2.11-cpan-98e64b0badf )