Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » Teneo plan to support java5 annotations instead of EMF?
Teneo plan to support java5 annotations instead of EMF? [message #74257] Thu, 08 March 2007 14:44 Go to next message
Jean-Denis Boudreault is currently offline Jean-Denis BoudreaultFriend
Messages: 55
Registered: July 2009
Member
Hello,


im really just a newbie to teneo, EMF and EJB3 but i was wondering about
this:

i was just reading about the new proposed eclipse project DALI which if i
understand correctly, will assist in mapping of EJB3 persistence in code.
From what I understand about EJB3 is that it uses java 5 annotations to
define mapping of them model and that it is the JDK standard for persisted
entities.


Teneo uses EMF model annotations, which are NOT java 5 annotations. Is
there a particular reason for not using Java5 annotations? Does the Teneo
team envision eventually switching to annotations eventually? or at least,
support them too?

and if Teneo remains with EMF annotations, what will be the impact of
being incompatible with the 'EJB3' standard and the tools that will be
developed for it?


thanks for helping me understand your vision and i really think teneo
rocks!
Re: Teneo plan to support java5 annotations instead of EMF? [message #74546 is a reply to message #74257] Fri, 09 March 2007 01:17 Go to previous messageGo to next message
Martin Taal is currently offline Martin TaalFriend
Messages: 5468
Registered: July 2009
Senior Member
Hi Jean-Denis,
All valid questions.
First what we will not do (at least not in the foreseeable future): Teneo will not generate java 5
annotations in the source code. The source code generation is handled by native emf and not by Teneo
and native emf does not know about persistence. Teneo will neither provide custom code generation
templates to get this solved. The reason for this is that this is a great amount of work and would
not necessarily work if users also have their own templates. Also (but this is my personal opinion)
I am not that much in favor of adding jpa annotations (with for example column/table names) in the
java code. I think it is nicer if this is specified separately (as allowed by the jpa/ejb3 spec in
a separate xml file). But I fully understand that views on this differ.

Then what we will do/already do related to following the standard:
The jpa/ejb3 spec also allows annotations to be specified in xml. Teneo currently also allows you to
specify annotations in xml. This xml follows practically the same standard as ejb3/jpa (with some
additions for usability). Also the annotations in the model follow the jpa/ejb3 standard.
Currently teneo generates hbm and jdo xml files. In the short future we will add support for
generating ejb3/jpa xml files which follow the standard exactly. This jpa/ejb3 mapping file can then
be edited (with tool support) in the dali tools environment. This supports a so-called
meet-in-the-middle scenario (for which the dali tools are an targeted afaics).

Teneo has two specifics (which are different than jpa/ejb3):
- Teneo supports automatic mapping of your model to a relational model. With Teneo you only need to
specify annotations to override default behavior while the jpa/ejb3 spec specifies that annotations
are mandatory. So even if you don't annotate your model Teneo will still map it to the db (and
generate a hibernate/jpox and later ejb3/jpa mapping file).
- With teneo not the java class/members are mapped to the relational database but the model is
mapped to the relational database. This allows support for dynamic emf. At runtime teneo resolves
the model to actual implementation classes (or uses dynamic emf).

gr. Martin


Jean-Denis Boudreault wrote:
> Hello,
>
>
> im really just a newbie to teneo, EMF and EJB3 but i was wondering about
> this:
>
> i was just reading about the new proposed eclipse project DALI which if
> i understand correctly, will assist in mapping of EJB3 persistence in
> code. From what I understand about EJB3 is that it uses java 5
> annotations to define mapping of them model and that it is the JDK
> standard for persisted entities.
>
>
> Teneo uses EMF model annotations, which are NOT java 5 annotations. Is
> there a particular reason for not using Java5 annotations? Does the
> Teneo team envision eventually switching to annotations eventually? or
> at least, support them too?
>
> and if Teneo remains with EMF annotations, what will be the impact of
> being incompatible with the 'EJB3' standard and the tools that will be
> developed for it?
>
>
> thanks for helping me understand your vision and i really think teneo
> rocks!
>
>
>
>


--

With Regards, Martin Taal

Springsite/Elver.org
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@springsite.com - mtaal@elver.org
Web: www.springsite.com - www.elver.org
Re: Teneo plan to support java5 annotations instead of EMF? [message #74564 is a reply to message #74546] Fri, 09 March 2007 01:54 Go to previous message
Jean-Denis Boudreault is currently offline Jean-Denis BoudreaultFriend
Messages: 55
Registered: July 2009
Member
Thanks Martin,

this is all very interesting and i understand your point of view and im
glad to know more about the Teneo vision. In any case, teneo is really a
great project, its not for nothing we are migrating our
POJO/Hibernate/XDoclet model to EMF/Teneo/Hibernate. :)

As for annotations, I did create a feature request for EMF 3.0 to add
the possibility to support java5 annotations in the future. But of
course, this is just a generic feature and has a broad range of
applications (like the very useful attribute programming in .NET); i
fully understand why Teneo prefers to avoid EJB 3 specs to offer a more
flexibly product.

thanks!



Martin Taal wrote:
> Hi Jean-Denis,
> All valid questions.
> First what we will not do (at least not in the foreseeable future):
> Teneo will not generate java 5 annotations in the source code. The
> source code generation is handled by native emf and not by Teneo and
> native emf does not know about persistence. Teneo will neither provide
> custom code generation templates to get this solved. The reason for
> this is that this is a great amount of work and would not necessarily
> work if users also have their own templates. Also (but this is my
> personal opinion) I am not that much in favor of adding jpa
> annotations (with for example column/table names) in the java code. I
> think it is nicer if this is specified separately (as allowed by the
> jpa/ejb3 spec in a separate xml file). But I fully understand that
> views on this differ.
>
> Then what we will do/already do related to following the standard:
> The jpa/ejb3 spec also allows annotations to be specified in xml.
> Teneo currently also allows you to specify annotations in xml. This
> xml follows practically the same standard as ejb3/jpa (with some
> additions for usability). Also the annotations in the model follow the
> jpa/ejb3 standard.
> Currently teneo generates hbm and jdo xml files. In the short future
> we will add support for generating ejb3/jpa xml files which follow the
> standard exactly. This jpa/ejb3 mapping file can then be edited (with
> tool support) in the dali tools environment. This supports a so-called
> meet-in-the-middle scenario (for which the dali tools are an targeted
> afaics).
>
> Teneo has two specifics (which are different than jpa/ejb3):
> - Teneo supports automatic mapping of your model to a relational
> model. With Teneo you only need to specify annotations to override
> default behavior while the jpa/ejb3 spec specifies that annotations
> are mandatory. So even if you don't annotate your model Teneo will
> still map it to the db (and generate a hibernate/jpox and later
> ejb3/jpa mapping file).
> - With teneo not the java class/members are mapped to the relational
> database but the model is mapped to the relational database. This
> allows support for dynamic emf. At runtime teneo resolves the model to
> actual implementation classes (or uses dynamic emf).
>
> gr. Martin
>
>
> Jean-Denis Boudreault wrote:
>> Hello,
>>
>>
>> im really just a newbie to teneo, EMF and EJB3 but i was wondering
>> about this:
>>
>> i was just reading about the new proposed eclipse project DALI which
>> if i understand correctly, will assist in mapping of EJB3 persistence
>> in code. From what I understand about EJB3 is that it uses java 5
>> annotations to define mapping of them model and that it is the JDK
>> standard for persisted entities.
>>
>>
>> Teneo uses EMF model annotations, which are NOT java 5 annotations.
>> Is there a particular reason for not using Java5 annotations? Does
>> the Teneo team envision eventually switching to annotations
>> eventually? or at least, support them too?
>>
>> and if Teneo remains with EMF annotations, what will be the impact of
>> being incompatible with the 'EJB3' standard and the tools that will
>> be developed for it?
>>
>>
>> thanks for helping me understand your vision and i really think teneo
>> rocks!
>>
>>
>>
>>
>
>
Re: Teneo plan to support java5 annotations instead of EMF? [message #603340 is a reply to message #74257] Fri, 09 March 2007 01:17 Go to previous message
Martin Taal is currently offline Martin TaalFriend
Messages: 5468
Registered: July 2009
Senior Member
Hi Jean-Denis,
All valid questions.
First what we will not do (at least not in the foreseeable future): Teneo will not generate java 5
annotations in the source code. The source code generation is handled by native emf and not by Teneo
and native emf does not know about persistence. Teneo will neither provide custom code generation
templates to get this solved. The reason for this is that this is a great amount of work and would
not necessarily work if users also have their own templates. Also (but this is my personal opinion)
I am not that much in favor of adding jpa annotations (with for example column/table names) in the
java code. I think it is nicer if this is specified separately (as allowed by the jpa/ejb3 spec in
a separate xml file). But I fully understand that views on this differ.

Then what we will do/already do related to following the standard:
The jpa/ejb3 spec also allows annotations to be specified in xml. Teneo currently also allows you to
specify annotations in xml. This xml follows practically the same standard as ejb3/jpa (with some
additions for usability). Also the annotations in the model follow the jpa/ejb3 standard.
Currently teneo generates hbm and jdo xml files. In the short future we will add support for
generating ejb3/jpa xml files which follow the standard exactly. This jpa/ejb3 mapping file can then
be edited (with tool support) in the dali tools environment. This supports a so-called
meet-in-the-middle scenario (for which the dali tools are an targeted afaics).

Teneo has two specifics (which are different than jpa/ejb3):
- Teneo supports automatic mapping of your model to a relational model. With Teneo you only need to
specify annotations to override default behavior while the jpa/ejb3 spec specifies that annotations
are mandatory. So even if you don't annotate your model Teneo will still map it to the db (and
generate a hibernate/jpox and later ejb3/jpa mapping file).
- With teneo not the java class/members are mapped to the relational database but the model is
mapped to the relational database. This allows support for dynamic emf. At runtime teneo resolves
the model to actual implementation classes (or uses dynamic emf).

gr. Martin


Jean-Denis Boudreault wrote:
> Hello,
>
>
> im really just a newbie to teneo, EMF and EJB3 but i was wondering about
> this:
>
> i was just reading about the new proposed eclipse project DALI which if
> i understand correctly, will assist in mapping of EJB3 persistence in
> code. From what I understand about EJB3 is that it uses java 5
> annotations to define mapping of them model and that it is the JDK
> standard for persisted entities.
>
>
> Teneo uses EMF model annotations, which are NOT java 5 annotations. Is
> there a particular reason for not using Java5 annotations? Does the
> Teneo team envision eventually switching to annotations eventually? or
> at least, support them too?
>
> and if Teneo remains with EMF annotations, what will be the impact of
> being incompatible with the 'EJB3' standard and the tools that will be
> developed for it?
>
>
> thanks for helping me understand your vision and i really think teneo
> rocks!
>
>
>
>


--

With Regards, Martin Taal

Springsite/Elver.org
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
The Netherlands
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@springsite.com - mtaal@elver.org
Web: www.springsite.com - www.elver.org
Re: Teneo plan to support java5 annotations instead of EMF? [message #603345 is a reply to message #74546] Fri, 09 March 2007 01:54 Go to previous message
Jean-Denis Boudreault is currently offline Jean-Denis BoudreaultFriend
Messages: 55
Registered: July 2009
Member
Thanks Martin,

this is all very interesting and i understand your point of view and im
glad to know more about the Teneo vision. In any case, teneo is really a
great project, its not for nothing we are migrating our
POJO/Hibernate/XDoclet model to EMF/Teneo/Hibernate. :)

As for annotations, I did create a feature request for EMF 3.0 to add
the possibility to support java5 annotations in the future. But of
course, this is just a generic feature and has a broad range of
applications (like the very useful attribute programming in .NET); i
fully understand why Teneo prefers to avoid EJB 3 specs to offer a more
flexibly product.

thanks!



Martin Taal wrote:
> Hi Jean-Denis,
> All valid questions.
> First what we will not do (at least not in the foreseeable future):
> Teneo will not generate java 5 annotations in the source code. The
> source code generation is handled by native emf and not by Teneo and
> native emf does not know about persistence. Teneo will neither provide
> custom code generation templates to get this solved. The reason for
> this is that this is a great amount of work and would not necessarily
> work if users also have their own templates. Also (but this is my
> personal opinion) I am not that much in favor of adding jpa
> annotations (with for example column/table names) in the java code. I
> think it is nicer if this is specified separately (as allowed by the
> jpa/ejb3 spec in a separate xml file). But I fully understand that
> views on this differ.
>
> Then what we will do/already do related to following the standard:
> The jpa/ejb3 spec also allows annotations to be specified in xml.
> Teneo currently also allows you to specify annotations in xml. This
> xml follows practically the same standard as ejb3/jpa (with some
> additions for usability). Also the annotations in the model follow the
> jpa/ejb3 standard.
> Currently teneo generates hbm and jdo xml files. In the short future
> we will add support for generating ejb3/jpa xml files which follow the
> standard exactly. This jpa/ejb3 mapping file can then be edited (with
> tool support) in the dali tools environment. This supports a so-called
> meet-in-the-middle scenario (for which the dali tools are an targeted
> afaics).
>
> Teneo has two specifics (which are different than jpa/ejb3):
> - Teneo supports automatic mapping of your model to a relational
> model. With Teneo you only need to specify annotations to override
> default behavior while the jpa/ejb3 spec specifies that annotations
> are mandatory. So even if you don't annotate your model Teneo will
> still map it to the db (and generate a hibernate/jpox and later
> ejb3/jpa mapping file).
> - With teneo not the java class/members are mapped to the relational
> database but the model is mapped to the relational database. This
> allows support for dynamic emf. At runtime teneo resolves the model to
> actual implementation classes (or uses dynamic emf).
>
> gr. Martin
>
>
> Jean-Denis Boudreault wrote:
>> Hello,
>>
>>
>> im really just a newbie to teneo, EMF and EJB3 but i was wondering
>> about this:
>>
>> i was just reading about the new proposed eclipse project DALI which
>> if i understand correctly, will assist in mapping of EJB3 persistence
>> in code. From what I understand about EJB3 is that it uses java 5
>> annotations to define mapping of them model and that it is the JDK
>> standard for persisted entities.
>>
>>
>> Teneo uses EMF model annotations, which are NOT java 5 annotations.
>> Is there a particular reason for not using Java5 annotations? Does
>> the Teneo team envision eventually switching to annotations
>> eventually? or at least, support them too?
>>
>> and if Teneo remains with EMF annotations, what will be the impact of
>> being incompatible with the 'EJB3' standard and the tools that will
>> be developed for it?
>>
>>
>> thanks for helping me understand your vision and i really think teneo
>> rocks!
>>
>>
>>
>>
>
>
Previous Topic:[Teneo] Invalid subclass tag in hibernate mapping file .
Next Topic:EclipseCon 2007 - Teneo presentation and demo files
Goto Forum:
  


Current Time: Tue Apr 16 19:56:24 GMT 2024

Powered by FUDForum. Page generated in 1.76727 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top