You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Software2 <ry...@software2.co.uk> on 2011/05/31 17:53:59 UTC

PHP Webapp on Tomcat Server

Hi,

I am currently working on a project to develop an "add-on" for a network
attached device. Hard to explain but basically what we currently have is a
device that runs apache tomcat with a java webapp. I want to host on the
same device, a seperate webapp. I have done some java programming in the
past but am primarily a PHP developer, so my options are:

1) Re-learn Java for developing the new webapp
2) Stick to PHP and work out how to host it as a webapp on the tomcat server
3) Install another PHP stack (xampp) on the device to host the PHP app
 
To me, option 2 seemed most sensible, utilising my current skillset and the
current server stack, but there doesnt seem to be much talk of how to do
this over the last year, lots of tutorials mention php_java.dll and
php5servlet.dll, which seem to have been deprecated and removed from pecl
respectively.

Any recent advice on how to host a PHP app on a tomcat server, whether it is
worth it, or generally what you would advise given my situation would be
appreciated!

Cheers
Ryan
-- 
View this message in context: http://old.nabble.com/PHP-Webapp-on-Tomcat-Server-tp31742122p31742122.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: PHP Webapp on Tomcat Server

Posted by Jonathan Rosenberg <jr...@tabbysplace.org>.
No, I'm missing something: a brain.  You're correct.  I hadn't read
the OP description carefully.

--
Jonathan Rosenberg
Founder & Executive Director
Tabby's Place, a Cat Sanctuary


On Tue, May 31, 2011 at 12:07 PM, André Warnier <aw...@ice-sa.com> wrote:
> Looking just at the schema on the project homepage, that seems to be a
> solution similar to the OP's #3) however : you use another webserver as
> front-end to Tomcat.
> I do not see at first how this solution is much different than an Apache
> httpd front-end, which proxies to Tomcat what belongs to Tomcat (aka
> targeting the Java apps), and runs locally (using mod_php e.g.) the PHP
> apps.
>
> The php-java-bridge looks more like a "device" which allows PHP applications
> running on the front-end, to interact directly with Java apps running on the
> Tomcat back-end.
>
> Or am I missing something ?
>
>
> Jonathan Rosenberg wrote:
>>
>> Check out this
>>
>>       http://php-java-bridge.sourceforge.net/pjb/
>>
>> I did a quick install & test of this a few months ago & it worked
>> right out of the box.  I did not dig into it in detail, however.
>>
>> --
>> Jonathan Rosenberg
>> Founder & Executive Director
>> Tabby's Place, a Cat Sanctuary
>>
>>
>> On Tue, May 31, 2011 at 11:53 AM, Software2 <ry...@software2.co.uk>
>> wrote:
>>>
>>> Hi,
>>>
>>> I am currently working on a project to develop an "add-on" for a network
>>> attached device. Hard to explain but basically what we currently have is
>>> a
>>> device that runs apache tomcat with a java webapp. I want to host on the
>>> same device, a seperate webapp. I have done some java programming in the
>>> past but am primarily a PHP developer, so my options are:
>>>
>>> 1) Re-learn Java for developing the new webapp
>>> 2) Stick to PHP and work out how to host it as a webapp on the tomcat
>>> server
>>> 3) Install another PHP stack (xampp) on the device to host the PHP app
>>>
>>> To me, option 2 seemed most sensible, utilising my current skillset and
>>> the
>>> current server stack, but there doesnt seem to be much talk of how to do
>>> this over the last year, lots of tutorials mention php_java.dll and
>>> php5servlet.dll, which seem to have been deprecated and removed from pecl
>>> respectively.
>>>
>>> Any recent advice on how to host a PHP app on a tomcat server, whether it
>>> is
>>> worth it, or generally what you would advise given my situation would be
>>> appreciated!
>>>
>>> Cheers
>>> Ryan
>>> --
>>> View this message in context:
>>> http://old.nabble.com/PHP-Webapp-on-Tomcat-Server-tp31742122p31742122.html
>>> Sent from the Tomcat - User mailing list archive at Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>>> For additional commands, e-mail: users-help@tomcat.apache.org
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: PHP Webapp on Tomcat Server

Posted by André Warnier <aw...@ice-sa.com>.
Looking just at the schema on the project homepage, that seems to be a solution similar to 
the OP's #3) however : you use another webserver as front-end to Tomcat.
I do not see at first how this solution is much different than an Apache httpd front-end, 
which proxies to Tomcat what belongs to Tomcat (aka targeting the Java apps), and runs 
locally (using mod_php e.g.) the PHP apps.

The php-java-bridge looks more like a "device" which allows PHP applications running on 
the front-end, to interact directly with Java apps running on the Tomcat back-end.

Or am I missing something ?


Jonathan Rosenberg wrote:
> Check out this
> 
>        http://php-java-bridge.sourceforge.net/pjb/
> 
> I did a quick install & test of this a few months ago & it worked
> right out of the box.  I did not dig into it in detail, however.
> 
> --
> Jonathan Rosenberg
> Founder & Executive Director
> Tabby's Place, a Cat Sanctuary
> 
> 
> On Tue, May 31, 2011 at 11:53 AM, Software2 <ry...@software2.co.uk> wrote:
>> Hi,
>>
>> I am currently working on a project to develop an "add-on" for a network
>> attached device. Hard to explain but basically what we currently have is a
>> device that runs apache tomcat with a java webapp. I want to host on the
>> same device, a seperate webapp. I have done some java programming in the
>> past but am primarily a PHP developer, so my options are:
>>
>> 1) Re-learn Java for developing the new webapp
>> 2) Stick to PHP and work out how to host it as a webapp on the tomcat server
>> 3) Install another PHP stack (xampp) on the device to host the PHP app
>>
>> To me, option 2 seemed most sensible, utilising my current skillset and the
>> current server stack, but there doesnt seem to be much talk of how to do
>> this over the last year, lots of tutorials mention php_java.dll and
>> php5servlet.dll, which seem to have been deprecated and removed from pecl
>> respectively.
>>
>> Any recent advice on how to host a PHP app on a tomcat server, whether it is
>> worth it, or generally what you would advise given my situation would be
>> appreciated!
>>
>> Cheers
>> Ryan
>> --
>> View this message in context: http://old.nabble.com/PHP-Webapp-on-Tomcat-Server-tp31742122p31742122.html
>> Sent from the Tomcat - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: PHP Webapp on Tomcat Server

Posted by Software2 <ry...@software2.co.uk>.
Oh right, cheers. I had a look at that and got the impression it was more
running/calling Java code using PHP, ill check it out!


Jonathan Rosenberg-2 wrote:
> 
> Check out this
> 
>        http://php-java-bridge.sourceforge.net/pjb/
> 
> I did a quick install & test of this a few months ago & it worked
> right out of the box.  I did not dig into it in detail, however.
> 
> --
> Jonathan Rosenberg
> Founder & Executive Director
> Tabby's Place, a Cat Sanctuary
> 
> 
> On Tue, May 31, 2011 at 11:53 AM, Software2 <ry...@software2.co.uk>
> wrote:
>>
>> Hi,
>>
>> I am currently working on a project to develop an "add-on" for a network
>> attached device. Hard to explain but basically what we currently have is
>> a
>> device that runs apache tomcat with a java webapp. I want to host on the
>> same device, a seperate webapp. I have done some java programming in the
>> past but am primarily a PHP developer, so my options are:
>>
>> 1) Re-learn Java for developing the new webapp
>> 2) Stick to PHP and work out how to host it as a webapp on the tomcat
>> server
>> 3) Install another PHP stack (xampp) on the device to host the PHP app
>>
>> To me, option 2 seemed most sensible, utilising my current skillset and
>> the
>> current server stack, but there doesnt seem to be much talk of how to do
>> this over the last year, lots of tutorials mention php_java.dll and
>> php5servlet.dll, which seem to have been deprecated and removed from pecl
>> respectively.
>>
>> Any recent advice on how to host a PHP app on a tomcat server, whether it
>> is
>> worth it, or generally what you would advise given my situation would be
>> appreciated!
>>
>> Cheers
>> Ryan
>> --
>> View this message in context:
>> http://old.nabble.com/PHP-Webapp-on-Tomcat-Server-tp31742122p31742122.html
>> Sent from the Tomcat - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 
> 
> 

-- 
View this message in context: http://old.nabble.com/PHP-Webapp-on-Tomcat-Server-tp31742122p31742460.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: PHP Webapp on Tomcat Server

Posted by Jonathan Rosenberg <jr...@tabbysplace.org>.
Check out this

       http://php-java-bridge.sourceforge.net/pjb/

I did a quick install & test of this a few months ago & it worked
right out of the box.  I did not dig into it in detail, however.

--
Jonathan Rosenberg
Founder & Executive Director
Tabby's Place, a Cat Sanctuary


On Tue, May 31, 2011 at 11:53 AM, Software2 <ry...@software2.co.uk> wrote:
>
> Hi,
>
> I am currently working on a project to develop an "add-on" for a network
> attached device. Hard to explain but basically what we currently have is a
> device that runs apache tomcat with a java webapp. I want to host on the
> same device, a seperate webapp. I have done some java programming in the
> past but am primarily a PHP developer, so my options are:
>
> 1) Re-learn Java for developing the new webapp
> 2) Stick to PHP and work out how to host it as a webapp on the tomcat server
> 3) Install another PHP stack (xampp) on the device to host the PHP app
>
> To me, option 2 seemed most sensible, utilising my current skillset and the
> current server stack, but there doesnt seem to be much talk of how to do
> this over the last year, lots of tutorials mention php_java.dll and
> php5servlet.dll, which seem to have been deprecated and removed from pecl
> respectively.
>
> Any recent advice on how to host a PHP app on a tomcat server, whether it is
> worth it, or generally what you would advise given my situation would be
> appreciated!
>
> Cheers
> Ryan
> --
> View this message in context: http://old.nabble.com/PHP-Webapp-on-Tomcat-Server-tp31742122p31742122.html
> Sent from the Tomcat - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: PHP Webapp on Tomcat Server

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Ryan,

On 5/31/2011 11:53 AM, Software2 wrote:
> 1) Re-learn Java for developing the new webapp
> 2) Stick to PHP and work out how to host it as a webapp on the tomcat server
> 3) Install another PHP stack (xampp) on the device to host the PHP app

I think it probably comes down to the complexity of the new webapp.

If it's somewhat modest, maybe you could use this opportunity to use
Java again. It's certainly the easiest from a configuration point of
view. :)

If you must have a very complicated webapp, then probably sticking to
PHP is a better idea.

There is another option which is to install Apache httpd as the primary
web server and have that proxy some requests to Tomcat via
mod_proxy_http, mod_proxy_ajp, or mod_jk and "proxy" some other requests
to your php scripts (mod_php).

(If you didn't know, mod_proxy_http comes with httpd and proxys using
the HTTP protocol, mod_proxy_ajp comes with httpd and proxys using the
AJP protocol, and mod_jk is separate from httpd and proxys using the AJP
protocol. mod_proxy_* have the same configuration syntax and are shipped
with httpd so there are two advantages there. mod_jk has more
configuration options and an older somewhat more trustworthy code base,
so there are two advantages there).

Hope that helps,
- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk3lVyIACgkQ9CaO5/Lv0PBCcACdFQdS/7RjjkxjM6lacwlRnDWR
D44An1H4PSTDFaw1v3TBwsEUBG8kh1vF
=ATu4
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org