aspose file tools*
The moose likes Servlets and the fly likes can i use Jsp with apache server Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "can i use Jsp with apache server" Watch "can i use Jsp with apache server" New topic
Author

can i use Jsp with apache server

Anonymous
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
Hi,
I want to use jsp but i have only apache server. can i use jsp with apache server. if so how.
with tomcat i can use JSP. do i have to remove my apache server to install tomcat.

Regds
Rahul

[This message has been edited by rahul_mkar (edited July 20, 2000).]
Frank Carver
Sheriff

Joined: Jan 07, 1999
Posts: 6920
You can plug in one of several servlet/jsp containers to run with Apache. Personally, I use Resin (www.caucho.com) which plugs in to Apache or runs standalone, and provides fast and effective servlet, JSP and XSLT support. Also consider Tomcat, JRun, and ServletExec, which all also plug in to Apache if required.


Read about me at frankcarver.me ~ Raspberry Alpha Omega ~ Frank's Punchbarrel Blog
Anonymous
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
hi Frank,
I do not understand the architecture of how the plugin and the apache server work.
what i wanted to know is how to undertake configuring the plugin to work with the server. when a client of mine makes a request to the apache server how does it know how to pass the request to the tomcat server to process the request(of Jsp page) and get back the result.
Basically i do not understand how both apache and tomcat are to be configured so as to work together to give me jsp pages.
I hope i am clear.
Regds.
Rahul
[This message has been edited by rahul_mkar (edited July 20, 2000).]
Frank Carver
Sheriff

Joined: Jan 07, 1999
Posts: 6920
All decent modern web servers support some sort of "plugin" architecture. Apache can dynamically load "modules" which are specified in the httpd.conf file.
The best way to understand this is to examine your httpd.conf, and also check out the installation instructions for any of the add-on servlet/JSP engines. In brief, though, you compile the "module" (if necessary), place it somewhere where Apache can see it, and add two sections to the httpd.conf. The first addition tells Apache how to load the module; the second addition configures it and tells Apache when to invoke it.
Most servlet containers use a small module which can be configured to respond to either a URL-path (all URLs starting with "/servlets/" for example) or specific file patterns ("*.jsp" for example). When invoked, the module communicates with the servlet container, typically over a local socket connection, passes it the request details and gathers up the response generated which it then gives to Apache to send to the client.
This may sound a bit complicated, but in practice it is very efficient, and allows Apache to do what it is best at (serving static files and directories) while the Servlet container just handles servlets, JSPs and other Java stuff.
Anonymous
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
hi Frank,
Thanks will do the needful.
Regds.
Rahul
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: can i use Jsp with apache server