[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Proposed changes for PGObject 2.0


This concerns only the base low-level module.  I have a PR here: https://github.com/ledgersmb/PGObject/pull/15

The major changes I am looking at making are:

1.  Separation of concerns relating to db procedure dispatching and data deserialization hooks.   The proposed change moves the data deserialization logic into a Perl module that acts as a sort of service provider.  This makes it much easier to plug into and test seriaization logic separate from using it in PGObject per se.

2.  Deprecating or removing various functions relating to the deserialization of things from the db.  The only current CPAN module which should be broken by this is the PGObject::Type::Composite handler.  This can be fixed however quickly and easily.  Other Type handlers may throw warnings until they are corrected.

3.  When registering a type for deserialization, tightening up the precondition checks.  My PR now throws an error if you fail to load the type first, or if you fail to pass a required input in.  

Please take a look at the PR and offer feedback.  Tests are passing and test coverage has improved.  If this seems positive, then I would get the type handlers ready and then we can release these in sequence.

After the type handlers, we can work on the next versions of PGObject::Simple, etc.

Best Wishes,
Chris Travers

Efficito:  Hosted Accounting and ERP.  Robust and Flexible.  No vendor lock-in.
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
Ledger-smb-devel mailing list