Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:33368 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 43849 invoked by uid 1010); 21 Nov 2007 15:34:20 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 43832 invoked from network); 21 Nov 2007 15:34:19 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 21 Nov 2007 15:34:19 -0000 Authentication-Results: pb1.pair.com smtp.mail=mls@pooteeweet.org; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=mls@pooteeweet.org; sender-id=unknown Received-SPF: error (pb1.pair.com: domain pooteeweet.org from 85.10.196.195 cause and error) X-PHP-List-Original-Sender: mls@pooteeweet.org X-Host-Fingerprint: 85.10.196.195 serveforce1.backendmedia.com Linux 2.6 Received: from [85.10.196.195] ([85.10.196.195:44052] helo=serveforce1.backendmedia.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 55/9A-07490-9FF44474 for ; Wed, 21 Nov 2007 10:34:18 -0500 Received: from [77.74.2.63] (guest-77-74-2-63.pwlan.abanet.ch [77.74.2.63]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (Client did not present a certificate) by serveforce1.backendmedia.com (Postfix) with ESMTP id 36D3412241AC; Wed, 21 Nov 2007 16:35:00 +0100 (CET) Mime-Version: 1.0 (Apple Message framework v752.3) In-Reply-To: <7ca798440711210726v14f5e8b0mc8adccde33df40b7@mail.gmail.com> References: <7ca798440711210726v14f5e8b0mc8adccde33df40b7@mail.gmail.com> Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-ID: Content-Transfer-Encoding: 7bit Date: Wed, 21 Nov 2007 16:34:04 +0100 To: Nuno Lopes , PHP Developers Mailing List X-Mailer: Apple Mail (2.752.3) X-backendmedia-com-MailScanner-Information: Please contact the ISP for more information X-backendmedia-com-MailScanner: Found to be clean X-backendmedia-com-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=0.075, required 6, AWL -0.03, RDNS_DYNAMIC 0.10) X-backendmedia-com-MailScanner-From: mls@pooteeweet.org X-Spam-Status: No Subject: Re: [PHP-DEV] web applications architectures comparison From: mls@pooteeweet.org (Lukas Kahwe Smith) On 21.11.2007, at 16:26, Nuno Lopes wrote: > Hi, > > I was assigned a class work in the university to compare web > applications architectures, mainly PHP vs > Java+Hibernate+Struts/Stripes. I'll need to provide some benchmarks > for some typical web apps. > > Well, I'm a bit afraid that Java may win, because of the usage of > Hibernate, which caches sql stuff in memory. The first request is > usually very slow (10 seconds or more), but following requests are > much faster. I would not be afraid of that. The question people have to solve is not one of performance but one of scalability and maintainability. Java tends to force people into this frame of mind to rely on one monolithic piece if software to solve all of their problems. This means a simple project ends up being way more complex from day one. Moreover if their single monolithic software fails them, they have a problem. This is the key point that Rasmus keeps saying .. what you want is a layered approach that allows you to solve your real world problems as they appear. So if Java beats PHP in serving a half way complex page from a single server in # of requests per second I am still not impressed. The question is how long did it take to setup that server. How long will it take until it becomes too expensive to keep adding to this one server? What will you do for failover? etc .. regards, Lukas