Hey

Just FYI.

In a moment of inspiration :-) I added the JAWS (Just Another Web Store)
CMP-plugin to "The Server" 2.0 codebase.

Features:
* Configurable table name
* Configurable column/field mappings
* Tuned updates (only stores changed fields on ejbStore, and no SQL
calls if no changes!)
* Support for EJB-references (i.e. if a Account-bean has a Customer as a
field, then the reference will be properly maintained)
  Example: if an Account has a "owner" field of type Customer, and
Customer has a CMP-field "id" which is the pk, then the "account"-table 
           will have a column "owner_id" whose value is the pk of the
owner of that account. This allows EJB-references to be stored nicely 
           (i.e. not BLOBed), which in turn allows finders to work on
EJB-references(see below!)
* Support for automatic finder methods
  * findAll = get all Entities
  * findByX(someval) = find all Entities whose CMP-field X matches
someval (this is very useful if X is a EJB-reference!!!)
* Automatic table creation at deployment time

That's about it. IMHO this should cover most of the basic
CMP-requirements, as well as some of the more advanced ones.

The funny thing is that since there is a low penalty for using
EntityBeans in "The Server", this basically gives us O/R support. I.e.,
instead of doing Address dependent objects as JavaBeans, one could do
them as EntityBeans and have finders etc. on them. It will be
interesting how well this works in practice, but I wouldn't be surprised
if the result is pretty good.

/Rickard

-- 
Rickard �berg

@home: +46 13 177937
Email: [EMAIL PROTECTED]
http://www.dreambean.com
Question reality


--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to