Slashdot Mirror


Apache Tomcat 4.0 Final Released

A reader writes "The latest version of the Apache Java Servlet engine has been released. 'The 4.0 release implements the Servlet 2.3 and JSP 1.2 specifications.' Read more at The Apache Group's Jakarta site."

20 of 288 comments (clear)

  1. Tomcat looks good by claes · · Score: 5, Informative

    Tomcat is getting pretty good. Version 4 makes it very easy to deploy new webapps: it includes a web admin interface, and new apps can be deployed without restarting it. As a standalone webserver it is also fairly competent, at least for specialised applications with smaller user numbers.

    Apache does some great things with Java. I have worked both with Tomcat (servlet container), Xerces (XML parser) and Xalan (XSLT engine). Thanks to the good work to come out from Apache, Java has become a very strong competitor to MS .NET. Actually I think it is ahead. In the future we will get the XML Binding API, that makes it possible to compile XML Schemas to java "xml manipulator" classes that can be used to manipulate XML instances of these schemas. XML parsing and manipulation will then be childs play. Define your schema, compile it and you have code that is specialised to work with these documents!

    With a strong XML foundation in place, Java's future is looking really good.

  2. very cool by Dalroth · · Score: 5, Informative

    I'm not completely up to speed on what Java Web development enhancements this brings to the table. However, I can honestly say that in my dealings with ßeta versions of Tomcat 4.0, the configuration files for Tomcat 4.0 are 1000x times easier and more sensible! The configuration files for Tomcat 3.x look like they were designed by a monkey on crack (or a Sendmail developer). Tomcat 4.0 config files are finally well thought out and usable. Can't wait to get my systems upgraded! :)

  3. WOW - 6 hours by icoloma · · Score: 2, Informative

    Tomcat 4 was waiting for the new servlet standrd from Sun to become from draft to final.

    THAT WAS TODAY. Less than six hours later (I don't know the exact amount of time) Tomcat was announcing the official release of Tomcat 4. That is going fast! :)

  4. And that also means... by vanza · · Score: 2, Informative

    That the 2.3 Servlet specification and 1.2 JSP Specification have been released as final.

    --
    Marcelo Vanzin
  5. Re:Hehe by Dg93 · · Score: 3, Informative

    The 3.x and 4.x trees are completely different codebases... My understanding is that the 3.x tree will continue to get a certain amount of maintenance and development while the 4.x tree gets shaken out.

    4.x has been in beta for a while, they've mainly been waiting for Sun to finalize the specs.

    --
    --Dg
  6. Very Mini howto... by (H)elix1 · · Score: 5, Informative
    Download the file - lets say on a Win2K they have locked down at work. No admin rights? no problem... (Win2K assumptions here, though most OS's work about the same)

    Make sure you have a JDK installed, like Sun's Windows version.

    Unzip to a directory - taking the defaults sets you up in c:\jakarta-tomcat-4.0.

    Go to the control pannel, click system, click advanced, click Environment Variables. Click new button on system variables and create a JAVA_HOME with a path to where you extracted your JDK. (My box has javac located in c:\jdk\bin, so my JAVA_HOME is c:\jdk). Create a TOMCAT_HOME as above pointing to c:\jakarta-tomcat-4.0.

    Open up a command prompt, cd to c:\jakarta-tomcat-4.0\bin and run startup.bat.

    Open a browser and type in http://localhost:8080, you should see it...

    Happy hacking in the example code!

    1. Re:Very Mini howto... by hansk · · Score: 3, Informative

      Create a TOMCAT_HOME as above pointing to c:\jakarta-tomcat-4.0

      This should actually be CATALINA_HOME. The TOMCAT_HOME var was in the older versions.

      The RUNNING.txt file included in the distributions contains the installation steps and, yes, they are very simple.

  7. Hopefully it intalls easier... by Teancom · · Score: 3, Informative

    I wasted a week of my life trying to get tomcat 3.2.x up and going on a solaris machine. The documentation was the worst that I had *ever* run across, with "how-tos" sporadically jumping back and forth between version 3.1 and 3.3, with not one single "clear, concise, consistent" document available for 3.2 (the previously current stable version). Even step involved downloading another package from the jakarta project, trying to figure out *it's* documentation, installing it, testing, and then finally getting back to tomcat just to discover (generally buried in some obscure comment four pages into a mostly-irrelevant faq) that you need to go get something else.

    Frankly, it wasn't until I got it going on a debian/x86 machine (apt-get install tomcat) that I was able to trace my way back and install it on solaris. Not that apache itself was much better, trying to get apxs working.

    Then, after it was going, I tried to enable .jsp support in all my user's home directories, the same way we do with cgi's (this is intranet, and we have a lot of people running things out of their ~username). Can't be done. Absa-no-freaking way. Either you configure each directory individually, basically "giving" the /public_html/ dir to tomcat and bypassing apache completely, or you make everybody create a new directory and then configure them *individually*. If someone has a work around for this, I would *love* to hear it. Note the main problem is that tomcat doesn't understand the ~ syntax, so the url passed by apache when a .jsp page is requested is "foo.com/~user/baz.jsp", and then tomcat complains that ~user/baz.jsp doesn't exist. This is the #1 reason jsp/servlets aren't used more where I work.

    So, I am *eager* to try out this release, and I truly hope that my complaints are now foundless. I would love nothing better than to be proven wrong, that the documentation has been completely overhauled, that it now understands the common ~username, that it works with any jdk besides blackdown's (on linux), and that it basically doesn't suck. But I'm not holding my breath.

  8. slightly offtopic, other jakarta stuff by frknfrk · · Score: 3, Informative

    also ant 1.4 was released recently (couple weeks ago). ant is a great build tool, i don't want to get into its features here (java and xml based build, replaces makefiles for my java builds, integrates with some IDEs and build verification/unit test tools (JUnit)). the reason i post here is because ant started out as a little tool with which tomcat developers build tomcat, and grew into its own tool. ant home page on jakarta.

    --
    The REAL sam_at_caveman_dot_org is user ID 13833.
  9. Re:J2EE-ish support? (for java CA) by thelexx · · Score: 2, Informative

    From what I've read on the Tomcat-user list, Tomcat does not do EJB and JBoss is the usual recommendation.

    LEXX

    --
    "Gold still represents the ultimate form of payment in the world." - Alan Greenspan, 1999
  10. Re:Hehe by JediTrainer · · Score: 3, Informative

    The 3.x and 4.x trees are completely different codebases... My understanding is that the 3.x tree will continue to get a certain amount of maintenance
    and development while the 4.x tree gets shaken out.


    I know. Actually, 3.x was based on the Sun Java Server, whose source code was donated.

    The irony is that it's taking longer for the 3.x line to get fixed properly than it is for the developers to have worked from scratch on a rewrite of the whole thing. There are quite a few things wrong with 3.2 which I won't get into (yes, we DO use it in production). I know that these things have been addressed in 4.0, while 3.3 is still working on it.

    --

    You can accomplish anything you set your mind to. The impossible just takes a little longer.
  11. Re:J-Run by jefflinwood · · Score: 3, Informative
    Yes, they're competitors in a way.

    JRun is commercial, from Allaire/Macromedia. You can download it for free, though, at Allaire. They have several different versions to download. Professional and Enterprise are the full version of the product, but with a 30-day time limit. You'll need a license key. The difference between them is that Enterprise supports EJB, JTA, and JMS, which are Java API's for building complex applications on the server. Tomcat is like Professional in that it supports JSP and servlets, which are similar to PHP and CGI Perl for all you non-java slashdotters.

    I actually don't have performance numbers for Tomcat 4.0 and JRun 3.1, since Catalina just got GA'd. If you can live without the support for JRun from Macromedia, and you want to save about a thousand bucks a server, give Tomcat a chance. You're probably not using EJB (Enterprise JavaBeans) anyway, since they were only supported in JRun 3.x.

  12. Re:Why use PHP? by jefflinwood · · Score: 2, Informative
    One big reason PHP is popular is that servlet/JSP web hosting is expensive compared to PHP for small sites that use shared web servers. If anyone knows of any cheap (less than $15/mo) places that let you run your own servlets against a database, let me know.

    For $10/mo, I get PHP/MySQL, unlimited bandwith, unlimited hard drive space, unlimited POPs, etc.

    Plus there's cool stuff like PHPNuke, just getting a simple contact me mail-to form to work in PHP is a piece of cake.

    Oh and a small correction - JavaScript has nothing to do with JSP or Java programming at all.

  13. Re:Why use PHP? by crisco · · Score: 5, Informative
    • Because Java / JSP is just getting to the point of ease of use that PHP was a couple of years ago? In terms of strength as a language and a platform, JSP and Servlets have PHP beat. But the entry level is much higher, think of the arcane xml files to get your programs working in the directories you want. With PHP you just drop things in and they work, often easier than CGI. Consider how many people start, diving in and messing with code. Now imagine you wanna do that with a servlet? Not that it is difficult, it is just a little harder than with PHP.
    • Because PHP / MySQL are standard at many cheap webhosts and with many Linux distros? And jsp / servlets aren't.
    • The OSS community's mistrust of Java and Sun and anything related to them.
    • Momentum and established codebase. Need a shopping cart, weblog, photogallery, or bulletin board? Head over to freshmeat and take your pick of PHP and Perl solutions. Want it in Java? Hmm, slim pickings...
    --

    Bleh!

  14. Re:J2EE-ish support? (for java CA) by mmcshane · · Score: 2, Informative

    Tomcat is a servlet container, not an EJB container. As such, it can only run servlets, jsp's (which really are just special cases of servlets), and javabeans. You need an EJB container to run EJB's. The most popular open-source EJB container is JBoss (it also integrates very well with Tomcat).

    Your are correct in saying that you never instantiate an EJB directly, you ask the container for a reference to an EJB and the container can instantiate a new EJB for you or reuse an old one or pull one out of a pre-existing pool.

    BTW, you may want to look into using JAAS (Java Authentication and Authorization Services) which was released today as a component of J2EE 1.3 for some of your security needs.

  15. Re:Tomcat lacks documents? by GrayArea · · Score: 2, Informative

    Actually, I find the 4.0 documentation to be much better than previous versions. It also has very good quality in general when you compare it to 99% of other open source projects out there, not to mention some commercial products. You should check out their how-to's, you'll see what I'm talking about.

    --
    "The deluded are always filled with absolutes. The rest of us have to live with ambiguity." - Aristoi, Walter Jon Willia
  16. Re:J-Run by Tsujigiri · · Score: 3, Informative

    And if you do need EJB support, give JBoss a look. It's open source and intergrates well with Tomcat to provide the EJB side of things.

    --

    "I'll take the red pill. No! Blue! AAAaaaahhhhhhhhh"
    - Monty Python meets the Matrix

  17. Re:Why use PHP? by Gollo · · Score: 2, Informative

    And if you wish to continue to use JSPs, check out Jakarta Struts. Struts provides a very nice way to continue using JSPs whilst still getting complete separation of presentation/controller/business logic. Highly recommended.

    Gollo.

  18. Some reasons to use PHP by TheInternet · · Score: 2, Informative

    but I'm curious as to why PHP is so popular when JSP provides a much more robust solution

    PHP is not a one-fits-all type of solution. It does not provide the same infrastructure that Java solutions do, and it is not a pure OO language. However, there are some good reasons to use it, depending on your situation:

    [1] Easier to learn than Java
    [2] Simpler to setup than many Java solutions
    [3] A great selection of extremely useful, easily accessible, built-in functions
    [4] Wide selection of books that don't assume you're already an experienced engineer

    The creators of PHP went to great lengths to remove as many of the needless annoyances of web development as possible. They provide a lot of ready made solutions to small, but annoying common problems. The language has bent itself to developer needs, rather than the other way around.

    PHP's creators realize that people just want the damn thing work, which is even evident in the installation instructions and documentation. This philopsophy, while starlingly rare in the open source world, is probably at the core of why PHP has such a devoted following.

    The strip_tags function is probably a good example of this. You give it a text string and it will remove all HTML tags contained therein. That's it. You can optionally tell it specific tags that you would like to leave in. This function is built into the language. PHP users love this. Many other languages would expect you to write a custom regex routine or go find some code somewhere to take care of it. Or you can start playing the module dependency game. These isn't the kind of stuff I want to do at 2am.

    - Scott

    --
    Scott Stevenson
    Tree House Ideas
  19. Re:It's no use if you want to use it on your web s by Westley · · Score: 2, Informative

    That's *one* licence it grants. The JRE *also* grants you the licence to use it in a normal way. This really isn't a problem - people have been distributing the JRE with their apps for ages.

    Jon