Tomcat 5.0 Released
aquarium writes "The Apache Jakarta Project announces the release of the first stable version of Tomcat 5.0. Improvements include performance optimizations, scalability and reliability enhancements, and improved Taglibs handling."
> Java is designed to scale well on big programs
How exactly is a language designed to scale well ? In LoC ?
Sorry but, while J2EE might be designed to scale well, Java is a language, and beyond that, was not designed for scalability, but portability. Remember it was an embedded language on the beginning.
Though the author of the post also defines scaling differently, I believe anyone talking Java scaling versus PHP, etc, should read this /. post in the context of this chapter of Designing Enterprise Applications with the J2EE(tm) Platform, Second Edition that deals with "Web-Tier Application Framework Design", particularly Model-View-Controller ("MVC") style frameworks.
...
.NET). You can quickly and easily usher these items around in a mature, object-oriented environment. Define an interface and a generic controller and you'll be able to swap around [in theory] fully-QA'd data delivery mechanisms in a modular fashion.
/. post I linked to above.
;^)
In that paper "Model 1" and "Model 2" set-ups are described in some detail. In short, Model 1 is what most of us web hackers have probably done for years --
1.) A [php/jsp/asp] page for user data entry (data entry GUI) which forwards you to...
2.) Another [php/jsp/asp] for business logic that inserts the jive into an RDBMS, which then forwards you to...
3.) Another page where you might review your data, with links to (1.) or
4.) Another page to edit info which links to...
5.) Another page that edits/updates/deletes existing entries and sends you back to 3.)
You get the point. You've got php script or vbscript or Java slapped in between tags that dynamically create pages. That's Model 1.
Model 1 doesn't scale well. It is, however, a great way to get up quickly, and perfect for smaller sites. That's where PHP and dime store hackers find a home, and that ability comprises the "revolution" asp brought to the web.
Model 2 has a controller which tries to abstract as much as possible out of process described above. Check out this image from the Sun chapter mentioned above. See all the steps that go on from each POST from the client interface.
The point of it is that Java/JSP/J2EE allows -- and has the infrastructure as a langauge to support -- this sort of Model 2, MVC interface (As an aside, this is also one of the big advantages of
In PHP -- and even asp 3.0 -- this is a more difficult thing to pull off, as mentioned in the
And this is where Tomcat shines -- as a key part of the infrastructure that allows more complex, scalable, generic objects and architectures. Most importantly, since J2EE is a language specification, saying Java scales well is accurate. It provides a true OO platform allowing you to implement Model 2's without jumping through hoops. PHP simply (in my experience) doesn't lend itself to this nearly so straighforwardly.
Now what Tomcat 5 does for me that 4 didn't to achieve this scalability (which many posts have well-documented) is what's most interesting about this story, to which I'll now return.
It's all 0s and 1s. Or it's not.
I have a few. One of the bigger design flaws PHP has is the lack of a compiled-archive format.
We have long known scripting languages do not scale well partially because they have to be evaluated entirely at runtime.
PHP's method of archives, ie. include some_library.inc.php is not as rigorous/reliable as import com.example.some_library as the application increases in size in my experience.
I don't know why but, having hundreds of *.inc.php files makes things very difficult to debug. Compared to a large number of packages to import.
PHP should introduce a binary opcode storage format. A standard format that would allow the use of binary archives/modules and runtime opcode caching. Maybe those files would be called .phpc for php compiled or something. These phpc files can seen as the php runtime as compiled independent modules ala .so and Java packages.
Based on upvotes, Ageism is the only "-ism" Slashdotters care about and think isn't SJW