jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sandro Boehme <sandro.boe...@gmx.de>
Subject Re: David's Model question : nt:unstructured and SNS
Date Tue, 17 Nov 2009 12:50:06 GMT
Alexander Klimetschek schrieb:
> 2009/11/16 Fabián Mandelbaum <fmandelbaum@gmail.com>:
>> It's simpler than fiddling around with this low-level stuff actually:
>>
>> Just create a DAO to abstract all JCR operations (as you should be
>> doing already)
> 
> (To give my usual opinion about object content mapping and JCR:) If
> you use DAOs this of course is a straight-forward solution (but only
> for the code that uses the DAO layer), but I think that using JCR
> directly is not "low-level" stuff:
> 
> - JCR Node already is like a DAO, and a more flexible one (nt:unstructured)
> - nodetypes can give you validation
> - session (+ transactions) provide all you need for managing the
> object's lifetime and separation into sessions
> - access control, versioning, search etc. are quite high-level IMO, so
> you should use them directly
> 
> I see the point for DAOs only when you really want to be sure that
> application coders can only use the properties you designed for them.
> Or when you have a relational model and are required to map it onto an
> object model, but that's not the case with JCR. An OCM only adds an
> additional layer of code and complexity.
> 
> Just my 2 cents...
> Alex
> 
In my opinion an OCM adds statical type checking and the ability to add 
functionality (e.g. finder methods) to this types.

Cheers,

Sandro

-- 
Sandro Böhme

Systems Development
Project Management

Wir nutzen Technologien, um unsere Kunden glücklich zu machen.
Und uns selbst.

inovex GmbH
Karlsruher Strasse 71
D-75179 Pforzheim
Tel: 07231 31 91-80
Fax: 07231 31 91-91
sandro.boehme@inovex.de
www.inovex.de

Sitz der Gesellschaft: Pforzheim
AG Mannheim, HRB 502126
Geschäftsführer: Stephan Müller


Mime
View raw message