Hi Graham,
The LDAP DAS is sitting in Tuscany. It would need an EMF based model though,
as it is designed to work with the EMF API / EMF SDO API. The longer term plan
is to have it work with the Tuscany SDO API as well + support Transactions,
etc. Also note that the persistance to ADS is done by convention and the
model's XML Schema Namespace is used to create the root DN within ADS.
In general the way it works is you would generate an EMF model (Basically model
Pojo's ehanced by the EMF API, similar to what modello does for maven) from an
source such as XML Schema, Annotated Java Interfaces, or XMI and then use the
DAS to store the model instance in ADS. When doing CRUD stuff, the DAS loads a
model from ADS and then uses SDO's change summary capability to handle updates.
I still need to do the Developer Use Case documentation (Or the How To), but
the tests are pretty thorough so giving it a go should be easy. If you need
Object to DN mapping though that's not by convention (XML Namespace) I think
some of the other tools mentioned would suit you better. It's pretty easy to
implement mapping with the SDO / EMF API using annotations, but I need more
days :-).
Cheers,
- Ole
Emmanuel Lecharny wrote:
Hi Graham,
Ole Ersoy has worked on such a piece of code a while back. I think it
has matured in the Tuscany project.
Otherwise, you have to know that there is a Java schema containing all
the Objectclasses you need to describe a Java class, and to store a
serialized object. Not sure that it will fit your need.
In any case, as we are redesigning the JNDI API to be closer to what we
need, it will be a pleasure to include a Java<->Ldap OL-Mapping tool in
ADS project (OL = ObjectLdap, with Object-Relational-mapping in mind :)
Graham Leggett wrote:
Hi all,
Although not directly related to the directory server itself, I thought I
would ask here as the concentration of LDAP experts is high :)
Has anybody heard of a Java package that does object to LDAP mapping,
along the lines of Hibernate or Torque in the land of SQL?
In other words, I would like a Java class hierarchy of objects
representing LDAP objectlasses and LDAP objects.
If such a thing doesn't exist, would the directory project be keen to
adopt such a new piece of code as its home, if it were to be written?
Regards,
Graham
--