473,396 Members | 1,967 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Python v PHP for web, and restarting Apache?

I think I have read somewhere that using Python to develop
web-applications requires some restarting of the Apache server, whereas
PHP does not.

Also, I seem to remember reading something about PHP being able to
recover from Apache restarting more easily than Python.

I am not trying to suggest anything here. I'm just asking.

Nov 17 '06 #1
9 1926
In <11********************@j44g2000cwa.googlegroups.c om>, walterbyrd
wrote:
I am not trying to suggest anything here. I'm just asking.
Asking what? Asking something usually involves a question. ;-)

Ciao,
Marc 'BlackJack' Rintsch
Nov 17 '06 #2
walterbyrd wrote:
I think I have read somewhere that using Python to develop
web-applications requires some restarting of the Apache server, whereas
PHP does not.
first thing... there are many many ways how to run a python-apache web
application..

- mod_python
- cgi
- fastcgi
- sci
- proxy

also the same way, for php:
- mod_php
- fastcgi
- cgi
- (maybe something more, i'm not much experienced with php)

so first you should tell us which python-solution would you like to
compare to which php-solution..
gabor
Nov 17 '06 #3
walterbyrd wrote:
I think I have read somewhere that using Python to develop
web-applications requires some restarting of the Apache server, whereas
PHP does not.
Using Python to develop web-applications is a very broad topic.

E.g. you don't have to restart Apache if you develop simple
short-running CGI-BIN programs. With a long-running web app (e.g. with
FastCGI) you might only kill the web app's process etc. Or you implement
a graceful restart in your web app or...
Also, I seem to remember reading something about PHP being able to
recover from Apache restarting more easily than Python.
As usual it depends.

Ciao, Michael.
Nov 17 '06 #4
On Nov 17, 12:07 pm, "walterbyrd" <walterb...@iname.comwrote:
I think I have read somewhere that using Python to develop
web-applications requires some restarting of the Apache server, whereas
PHP does not.
It depends what you do. CGI's operate much like PHP. mod_python has
auto-reloading (and by implication most frameworks that build on it.) A
poorly designed web application may require a restart. (Some people
also disable auto-reload for production servers for performance
advantages.)
Also, I seem to remember reading something about PHP being able to
recover from Apache restarting more easily than Python.
I can think of no reason why that would be true. Perhaps these are
poorly designed python applications?
I am not trying to suggest anything here. I'm just asking.
Ask away. The only bad question is an unasked question. Most of us can
act like adults here (although we all forget that from time to time.)

Python is much better suited to writing and mainting large web
applications though. Being both an experienced php and python
programmer, I can tell you I don't use php any more unless I have no
other choice.

-Sandra

Nov 18 '06 #5


On Nov 17, 4:46 pm, sandra.el...@gmail.com wrote:
On Nov 17, 12:07 pm, "walterbyrd" <walterb...@iname.comwrote:
I think I have read somewhere that using Python to develop
web-applications requires some restarting of the Apache server, whereas
PHP does not.It depends what you do. CGI's operate much like PHP. mod_python has
auto-reloading (and by implication most frameworks that build on it.) A
poorly designed web application may require a restart. (Some people
also disable auto-reload for production servers for performance
advantages.)
Also, I seem to remember reading something about PHP being able to
recover from Apache restarting more easily than Python.I can think of no reason why that would be true. Perhaps these are
poorly designed python applications?
I am not trying to suggest anything here. I'm just asking.Ask away. The only bad question is an unasked question. Most of us can
act like adults here (although we all forget that from time to time.)

Python is much better suited to writing and mainting large web
applications though. Being both an experienced php and python
programmer, I can tell you I don't use php any more unless I have no
other choice.

-Sandra
Sandra do you us ethe msot up to date php and python?
how fast is fastcgi v mod_python?
Have you ever used medusa? or some other python server directly?

Nov 18 '06 #6

sa**********@gmail.com wrote:
>
Python is much better suited to writing and mainting large web
applications though.
I have to ask: why is that? Because Python is more readable? Because
Python runs faster? Is Python more stable for large scale applications?
Does this apply when using Python with CGI, FastCGI, mod_python, or
what?

Nov 18 '06 #7
walterbyrd wrote:
>Python is much better suited to writing and mainting large web
applications though.

I have to ask: why is that?
modularity, modularity, and modularity.

</F>

Nov 18 '06 #8

Fredrik Lundh wrote:
>
modularity, modularity, and modularity.
Can't PHP be made to be just as modular?

As a matter of popular practise, I suppose that is not done. I would
think that it could be.

My big problem with PHP is the lack of backward compatibility. My big
problem with Python is that popular frameworks like django and
turbogears have sky-high system requirements. Few web-hosters have
Apache 2.X, mod_python 3.x, FastCGI, or Python 2.4.

Nov 18 '06 #9
walterbyrd a écrit :
Fredrik Lundh wrote:

>>modularity, modularity, and modularity.


Can't PHP be made to be just as modular?
PHP has no notion of modules.
As a matter of popular practise, I suppose that is not done. I would
think that it could be.
Certainly not the way Python is modular...

Nov 19 '06 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: Chang LI | last post by:
Does python support threads safely along with Apache 2.0 in web applications. Chang
3
by: eduardo.rosa | last post by:
Hy people, I'm new in python and comming from JAVA. Something I really like in java is the easy way to add a library to the project. Just put the jar file in the folder ( WEB-INF/lib ) and...
852
by: Mark Tarver | last post by:
How do you compare Python to Lisp? What specific advantages do you think that one has over the other? Note I'm not a Python person and I have no axes to grind here. This is just a question for...
113
by: John Nagle | last post by:
The major complaint I have about Python is that the packages which connect it to other software components all seem to have serious problems. As long as you don't need to talk to anything outside...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.