Re: Mission Impossible: Tomcat + Apache ???
First of all, make sure that you appended addition to the apache configuration file generated by tomcat (see tomcat-apache documentation). After that clear, do the following. I have found, that the best way to do "directory merger" as you do, by using virtual server facility on both tomcat and apache. The "real" directory is under tomcat's webapps. Then do symbolic link to apache's htdocs (or whatever). Point tomcat's virtual server's document root to "real" directory and apache's to symlink. This will result in adding jsp handler and mounting appropriate servlet directories while keeping the same directory for both tomcat and apache. Virtual servers would allow for clean structure since tomcat normally has distinctively separate contecsts under webapps which otherwise may confuse apache. Additional remark. If you use both jsp and servlets, the best idea is to "use bean" approach in jsp rather than calling servlet through http protocol. In this case, among other advantages, you get rid of the hassle to keeping track of servlet directory mounts. Nikolai Lance Dyas wrote: > Yoav wrote: > >> Hiya all, >> >> >> >> We're trying to migrate from running JSP's and servlets under JWS2.0 >> to Apache+Tomcat. >> >> >> >> It seems like the simplest and most basic configuration, yet I could >> find nowhere a way to make this work!! >> >> >> >> The same way JWS works, (and Apache-Jserv+GnuJsp) also: >> >> >> >> 1) Apache serves all static content. >> >> 2) Tomcat serves servlets/JSP's (through apj12) >> >> 3) They both share the same directory structure. (C:\apache\htdocs) >> and *.jsp files can be anywhere in that directory tree - not *ONLY* >> in the /examples dir or /jsp dir (!@!@#???) >> >> >> >> Did someone actually made this work? >> >> how, exactly ? >> >> >> >> >> >> H E L P !! >> > Hmmm I have apache serving static content > tomcat serving jsps and servlets through apj12 > but not number3 as I have distinct directory structures. > > Lance Dyas > Dynamic Mapping > www.dyasdesigns.com/TNTservlet > >
Re: Mission Impossible: Tomcat + Apache ???
Yoav wrote: > Hiya all, > > > > We're trying to migrate from running JSP's and servlets under JWS2.0 > to Apache+Tomcat. > > > > It seems like the simplest and most basic configuration, yet I could > find nowhere a way to make this work!! > > > > The same way JWS works, (and Apache-Jserv+GnuJsp) also: > > > > 1) Apache serves all static content. > > 2) Tomcat serves servlets/JSP's (through apj12) > > 3) They both share the same directory structure. (C:\apache\htdocs) > and *.jsp files can be anywhere in that directory tree - not *ONLY* in > the /examples dir or /jsp dir (!@!@#???) > > > > Did someone actually made this work? > > how, exactly ? > > > > > > H E L P !! > Hmmm I have apache serving static content tomcat serving jsps and servlets through apj12 but not number3 as I have distinct directory structures. Lance Dyas Dynamic Mapping www.dyasdesigns.com/TNTservlet
Re: Mission Impossible: Tomcat + Apache ???
No one works like that, (well I don't) =) You can configure the Apache's virtual host to point to a tomcat dir... let's say you have your webapps in /tomcat/webapps/myApp/ you should have the following directory structure : /tomcat/webapps/myApp/ WEB-INF/ /classes In apache's virtual host config, set the HTML root to /tomcat/webapps/myApp All the static HTML in myApp/ will be served by Apache All the *.jsp and servlets will be served by Tomcat That should do it. Putting your *.jsp in c:\apache\htdocs won't work, cause that path is not in the directive of mod_jk.conf Regards, Arnaud "I'm confusing you more" Dostes. - Original Message - From: Yoav To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Tuesday, April 24, 2001 3:29 PM Subject: Re: Mission Impossible: Tomcat + Apache ??? That's what I'm talking about !! That's the problem I couldn't solve!! In all other JSP/servlets engines (JavaWebServer, Apache_Jserv+GnuJsp) - All the HTML & JSP files are mixed in the SAME directory structure. How can I implement this under Apache-tomcat ? All available configurations hold all the JSP files in some webapps\ROOT directory... C'mon! there's gotta be a way. I find it hard to believe that everyone works like that. Yoav. - Original Message - From: Sam Newman To: [EMAIL PROTECTED] Sent: Tuesday, April 24, 2001 1:36 PM Subject: Re: Mission Impossible: Tomcat + Apache ??? the mod_jk.conf-auto tomcat creates authomatically generates the apache directives so apache can see the contexts setup under tomcat. Whilst they use different document roots, you can easily make them look the same my tweaking the generated directives. The .jsp files & servlets have to sit under the tomcat webapps directory for them to get picked up by the tomcat classloader. The jsp file actually gets compiled at runtime to a servlet before being viewed. sam - Original Message - From: Yoav To: [EMAIL PROTECTED] Sent: Tuesday, April 24, 2001 12:51 PM Subject: Re: Mission Impossible: Tomcat + Apache ??? Yes, I've read the apache-tomcat howto, and followed it's instructions step by step. BUT When I've put (as a test...) snoop.jsp in the c:\apache\htdocs directory - it couldn't find it! Only once I've put it in the c:\jakarta-tomcat\webapps\ROOT it was found and compiled. So, I figured out that by default they (Apache vs. Tomcat ) have different "DocumentRoot" structure. That's my question. I've also tried to point in the mod_jk.conf and server.xml the "/" dir of the tomcat to use c:\apache\htdocs - but still no luck...
Re: Mission Impossible: Tomcat + Apache ???
That's what I'm talking about !! That's the problem I couldn't solve!! In all other JSP/servlets engines (JavaWebServer, Apache_Jserv+GnuJsp) - All the HTML & JSP files are mixed in the SAME directory structure. How can I implement this under Apache-tomcat ? All available configurations hold all the JSP files in some webapps\ROOT directory... C'mon! there's gotta be a way. I find it hard to believe that everyone works like that. Yoav. - Original Message - From: Sam Newman To: [EMAIL PROTECTED] Sent: Tuesday, April 24, 2001 1:36 PM Subject: Re: Mission Impossible: Tomcat + Apache ??? the mod_jk.conf-auto tomcat creates authomatically generates the apache directives so apache can see the contexts setup under tomcat. Whilst they use different document roots, you can easily make them look the same my tweaking the generated directives. The .jsp files & servlets have to sit under the tomcat webapps directory for them to get picked up by the tomcat classloader. The jsp file actually gets compiled at runtime to a servlet before being viewed. sam - Original Message - From: Yoav To: [EMAIL PROTECTED] Sent: Tuesday, April 24, 2001 12:51 PM Subject: Re: Mission Impossible: Tomcat + Apache ??? Yes, I've read the apache-tomcat howto, and followed it's instructions step by step. BUT When I've put (as a test...) snoop.jsp in the c:\apache\htdocs directory - it couldn't find it! Only once I've put it in the c:\jakarta-tomcat\webapps\ROOT it was found and compiled. So, I figured out that by default they (Apache vs. Tomcat ) have different "DocumentRoot" structure. That's my question. I've also tried to point in the mod_jk.conf and server.xml the "/" dir of the tomcat to use c:\apache\htdocs - but still no luck...
Re: Mission Impossible: Tomcat + Apache ???
the mod_jk.conf-auto tomcat creates authomatically generates the apache directives so apache can see the contexts setup under tomcat. Whilst they use different document roots, you can easily make them look the same my tweaking the generated directives. The .jsp files & servlets have to sit under the tomcat webapps directory for them to get picked up by the tomcat classloader. The jsp file actually gets compiled at runtime to a servlet before being viewed. sam - Original Message - From: Yoav To: [EMAIL PROTECTED] Sent: Tuesday, April 24, 2001 12:51 PM Subject: Re: Mission Impossible: Tomcat + Apache ??? Yes, I've read the apache-tomcat howto, and followed it's instructions step by step. BUT When I've put (as a test...) snoop.jsp in the c:\apache\htdocs directory - it couldn't find it! Only once I've put it in the c:\jakarta-tomcat\webapps\ROOT it was found and compiled. So, I figured out that by default they (Apache vs. Tomcat ) have different "DocumentRoot" structure. That's my question. I've also tried to point in the mod_jk.conf and server.xml the "/" dir of the tomcat to use c:\apache\htdocs - but still no luck...
RE: Mission Impossible: Tomcat + Apache ???
Hiya all, We're trying to migrate from running JSP's and servlets under JWS2.0 to Apache+Tomcat. It seems like the simplest and most basic configuration, yet I could find nowhere a way to make this work!! The same way JWS works, (and Apache-Jserv+GnuJsp) also: 1) Apache serves all static content. 2) Tomcat serves servlets/JSP's (through apj12) 3) They both share the same directory structure. (C:\apache\htdocs) and *.jsp files can be anywhere in that directory tree - not *ONLY* under the jakarta-tomcat directory tree, but in c:\apache\htdocs mixed with the HTMLs !! Did someone actually made this work? how, exactly ? H E L P !!
Re: Mission Impossible: Tomcat + Apache ???
Yes, I've read the apache-tomcat howto, and followed it's instructions step by step. BUT When I've put (as a test...) snoop.jsp in the c:\apache\htdocs directory - it couldn't find it! Only once I've put it in the c:\jakarta-tomcat\webapps\ROOT it was found and compiled. So, I figured out that by default they (Apache vs. Tomcat ) have different "DocumentRoot" structure. That's my question. I've also tried to point in the mod_jk.conf and server.xml the "/" dir of the tomcat to use c:\apache\htdocs - but still no luck... - Original Message - From: Sam Newman To: [EMAIL PROTECTED] Sent: Tuesday, April 24, 2001 10:59 AM Subject: Re: Mission Impossible: Tomcat + Apache ??? Have you read the Apache-Tomcat howto in the docs (comes with tomcat)? If so, can you give us more specific info on your problems? regards, sam - Original Message - From: Yoav To: [EMAIL PROTECTED] Sent: Tuesday, April 24, 2001 10:58 AM Subject: Mission Impossible: Tomcat + Apache ??? Hiya all, We're trying to migrate from running JSP's and servlets under JWS2.0 to Apache+Tomcat. It seems like the simplest and most basic configuration, yet I could find nowhere a way to make this work!! The same way JWS works, (and Apache-Jserv+GnuJsp) also: 1) Apache serves all static content. 2) Tomcat serves servlets/JSP's (through apj12) 3) They both share the same directory structure. (C:\apache\htdocs) and *.jsp files can be anywhere in that directory tree - not *ONLY* in the /examples dir or /jsp dir (!@!@#???) Did someone actually made this work? how, exactly ? H E L P !!
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Title: Re: Mission Impossible: Tomcat + Apache ??? Undeliverable mail.
Re: Mission Impossible: Tomcat + Apache ???
Have you read the Apache-Tomcat howto in the docs (comes with tomcat)? If so, can you give us more specific info on your problems? regards, sam - Original Message - From: Yoav To: [EMAIL PROTECTED] Sent: Tuesday, April 24, 2001 10:58 AM Subject: Mission Impossible: Tomcat + Apache ??? Hiya all, We're trying to migrate from running JSP's and servlets under JWS2.0 to Apache+Tomcat. It seems like the simplest and most basic configuration, yet I could find nowhere a way to make this work!! The same way JWS works, (and Apache-Jserv+GnuJsp) also: 1) Apache serves all static content. 2) Tomcat serves servlets/JSP's (through apj12) 3) They both share the same directory structure. (C:\apache\htdocs) and *.jsp files can be anywhere in that directory tree - not *ONLY* in the /examples dir or /jsp dir (!@!@#???) Did someone actually made this work? how, exactly ? H E L P !!
Mission Impossible: Tomcat + Apache ???
Hiya all, We're trying to migrate from running JSP's and servlets under JWS2.0 to Apache+Tomcat. It seems like the simplest and most basic configuration, yet I could find nowhere a way to make this work!! The same way JWS works, (and Apache-Jserv+GnuJsp) also: 1) Apache serves all static content. 2) Tomcat serves servlets/JSP's (through apj12) 3) They both share the same directory structure. (C:\apache\htdocs) and *.jsp files can be anywhere in that directory tree - not *ONLY* in the /examples dir or /jsp dir (!@!@#???) Did someone actually made this work? how, exactly ? H E L P !!