File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Services and the fly likes Web Services with Hibernate Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "Web Services with Hibernate" Watch "Web Services with Hibernate" New topic
Author

Web Services with Hibernate

kashwini Kulkarni
Ranch Hand

Joined: Aug 07, 2009
Posts: 63
Hello All,

I want to know what is the procedure to make hibernate and web services work together.I am using netbeans IDE with Glassfish.I am not getting where to put my hibernate.cfg.xml and .hbm files so that my web service can access them.I tried a lot of search but found nothing complete.Any help in this direction is appreciated.





Thanks in Advance
Kashwini
William P O'Sullivan
Ranch Hand

Joined: Mar 28, 2012
Posts: 860

Those are two different stacks.

Once your web service has defined it's contract (wsdl), it is up to you to integrate the request and response
processing with the DB layer via some form of DAO pattern.

In your case, the service layer would access a DAO intermediate layer, generate value objects and have them
converted to SOAP XML to return to the client.

WP
kashwini Kulkarni
Ranch Hand

Joined: Aug 07, 2009
Posts: 63
Hello William,


Thanks a lot for your reply.Now I can go further with what you suggested.




Thank you
Kashwini82
kashwini Kulkarni
Ranch Hand

Joined: Aug 07, 2009
Posts: 63


Can you please elaborate on the same or suggest me a link to some example (so that I can develop my web service accordingly) ?


Thank you
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60055
    
  65

Apparently you did not understand the answer. Your DAO layer will be completely independent of the web service. You can develop it and test it separately. Information on DAOs is readily available on the web.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Web Services with Hibernate
 
Similar Threads
Want to learn Web Services
Hibernate should hit db every single time
A simple question
Is Spring Web Services good enough?
J2EE version for the Assignment + Hibernate / Web Services