-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: Two Jars
PostPosted: Tue Dec 22, 2009 1:10 pm 
Newbie

Joined: Thu Mar 15, 2007 8:03 am
Posts: 8
Hi all,

In my application i have two parts.

- Server: This Jar contains all Hibernate functions to connect do database (entities, dao's, etc)

- Client: call server methods (I include Server Jar in this project)


My question is... Client side needs all hibernate jars? eg hibernate-annotations.jar etc....?


tnks!


Top
 Profile  
 
 Post subject: Re: Two Jars
PostPosted: Tue Dec 22, 2009 2:23 pm 
Beginner
Beginner

Joined: Tue Nov 03, 2009 9:38 am
Posts: 24
I assume your client will not make any remote calls. If this is correct, then yes you need the hibernate jars.

If your client calls the server methods remotely, it doesn't need the hibernate jars. But in this case you should consider another design:

1. an API jar that contains interfaces for your services (home and remote) etc.
2. your server jar that includes the API jar and all the implementations

This way, your client only sees what it needs to see: the service interfaces.
If you need to pass the entities to the client, you might also need to provide interfaces that are put into the API jar.
Thus you get a serialized version of the entity on the client but don't need to know about the implementation (which will contain JPA/Hibernate annotations).


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.