This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Servlets and the fly likes How to invoke a jar file on the server side. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "How to invoke a jar file on the server side." Watch "How to invoke a jar file on the server side." New topic

How to invoke a jar file on the server side.

cake naiyou

Joined: Apr 29, 2011
Posts: 27
I download some open source software, like weka or any other ones, as a jar file. I can run it on linux machine using command line as

At present, I want to learn how to integrate this jar file into an web-based applications. In other words, I want this jar file to be run and wait on a server; I can create a web page, and let user submit the request, like
This request will be transferred to the waiting jar file, and get the result.

I have no previous experience on server programming, so I do not know whether java servlet is the correct tool for fulfill this kind of task? And if you can share any suggestion, hint, or example, that would be wonderful. Thanks.
rinku agarwal

Joined: Feb 10, 2010
Posts: 6
I think your problem is that you dont know how to use external jar file in a web application. you can just include it in the classpath of the web application or you can check where other jar files in your applications are placed and then you can place it over there. then you can use the classes of the jar file as normal java classes written by you.
jQuery in Action, 2nd edition
subject: How to invoke a jar file on the server side.
Similar Threads
Can't connect to MySQL database with Hibernate
Design problem
Servlet - Standalone App communication (file transer)
how to run a jar file in serverbased application
Embeded applet within a JSP page. Will it process on the server or client side?