This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Other Java Products and Servers and the fly likes war / glassfish: call java class on deployment, make available as a resource Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Products » Other Java Products and Servers
Bookmark "war / glassfish: call java class on deployment, make available as a resource" Watch "war / glassfish: call java class on deployment, make available as a resource" New topic
Author

war / glassfish: call java class on deployment, make available as a resource

William Koos
Greenhorn

Joined: Jan 08, 2010
Posts: 3
I am deploying a war with webservices on Glassfish. One of these webservices needs a number documents to be indexed using apache lucene. I have a java class that indexes the documents using lucene.

How do I make sure that on deployment of the war the constructor of the java class that indexes the documents is called and that the object is then then made available as a resource to the webservice?

I suspect that this should be done by using annotations and resource injection, but I can't find a guide that is clear enough for me as a java novice. I am using netbeans as an IDE. Any pointers / help are appreciated.





 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: war / glassfish: call java class on deployment, make available as a resource
 
Similar Threads
websphere 7.0 JAXWS webservice deployed in tomcat 6.0.32 not working
@Resource For A Non-EJB
Overhead of Collection Classes
developing web services using netbeans (error on deploying application)
Lucene and already indexed data