Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / June 2007

Tip: Looking for answers? Try searching our database.

EJB3 with hand-coded ORM in JDBC

Thread view: 
anondude123@gmail.com - 15 Jun 2007 07:48 GMT
Hi all,
I am writing a Stateless session bean in with an EJB 3.0 container
(using JBoss 4.2 right now, and possibly Glassfish later). This bean
is going to provide reading/writing from the DB supplemented by some
business logic (using hand-written JDBC DAO's for my objects). The
EJB3 annotations for everything non-persistence are great and they
work for me. However, my underlying data model is more like a EAV (key-
value pair-ish) type of stuff which does not at all fit into the
object-relational mapping provided by the EntityManager. So, my
question is this, is it possibly for me to use EJB3 (so I get all the
non-persistence annotations), but hand-code my own persistence. I know
I can just open a JDBC connection myself from the method on the bean,
but I'd still need to have the txns be container managed. Sorta like
pre-EJB3 for persistence, but EJB3 for everything non-persistence.
The problem is that every book/manual/article I've read on EJB 3.0 so
far uses the persistence annotations and they use hibernate (or some
other abstraction layer). I just need to be able do my own with JDBC.
Please please tell me it's possible.
Any help would be greatly appreciated.
Thanks,

Clive
Lew - 15 Jun 2007 12:01 GMT
> Hi all,
> I am writing a Stateless session bean in with an EJB 3.0 container
[quoted text clipped - 16 lines]
> Any help would be greatly appreciated.
> Thanks,

Please do not multi-post.  I have consolidated the multi-posts that I found so
that respondents can follow an unfragmented thread.

Signature

Lew



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.