|
From: Jost B. <jos...@ya...> - 2005-10-29 12:08:17
|
Hi Kevin, > The servlet seems to be calling php on the > commandline (CGI) instead > of through Apache. CGI is only used when the controller servlet (PhpJavaServlet) receives a get or post request. Usually apache listens on the http standard port :80 and php instances are allocated from the apache pool. The php instances in turn connect to the :8080 backend using put requests. mod_jk becomes obsolete if one doesn't have .jsp files anymore. [request to port 80:] > and I can see the > test.php file if I use Apache directly. It > indicates that Java is > enabled. Okay. [development setup] > I've installed the JavaBridge war (opened it in > Eclipse, actually), > and added my php-cgi.exe and associated .dll files > to the WEB-INF/cgi > directory. I updated the web.xml to indicate that > the file is called > php-cgi.exe Okay. [request to :8080] > My requests to .php files seem to be serviced by the > PhpJavaServlet, I > can place debugging breakpoints there. The > requests, being GET > requests are serviced by the doGet method. The doGet invokes the cgi machinery, yes. It is there to help during development, where it is difficult to work with two servers. For a production system, however, it is assumed that all requests go through the standard http port and that a native http server listens on this port. -- The reason is that java cannot drop privileges, so it is not possible to connect a java servlet engine to port 80. > Is there some configuration I need in my web.xml > file to tell the > Servlet how to connect back through the Apache > service? Just use http://localhost/JavaBridge/test.php instead of http://localhost:8080/JavaBridge/test.php Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |