Discussions

Web tier: servlets, JSP, Web frameworks: Tomcat + Eclipse + Lomboz problem, can't run servlet

  1. Hi, here are some numbers:
    Tomcat 5.0.25
    Eclipse 2.13
    Lomboz 2.13

    I can run the example servlet bundle with Tomcat, and i follow the instruction on Lomboz website. I can get a JSP file work.

    However, when I try to add a servlet of that web module, everything seems get broke down. the previouly working JSP and the newly created servlet, both don't wok and Tomcat give me a 404

    After I depoly using lomboz, it create all files under Tomcat, my web module call "FirstModule", the package-less servlet is call "FirstServlet", so the directory looks like

    ($Tomcat Home)/webapp/Firstmodule
                                        ---> /web-inf (which contains web.xml)
                                        ---> /class (which contains FirstServlet.class)

    all the entry in web.xml (class-name, servlet-name.....) are "FirstServlet",
    URL Mapping is also "FirstServlet"

    however when I try http://localhost:8080/Firstmodule.FirstServlet, I got 404

    anything I overlook?

    Regards

    Threaded Messages (2)

  2. URL MApping[ Go to top ]

    If it is not misspelled!

    "http://localhost:8080/Firstmodule.FirstServlet" change de "." for "/".

    http://localhost:8080/Firstmodule/FirstServlet

    Also:
       Be sure to check your URL Mapping ... if it says "FirstServlet" try putting "/" first, so it will look like "/FirstServlet"

    Saludos,
       <Rory/>
  3. URL MApping[ Go to top ]

    yes, my bad, ^^ (what a silly question I was asking ...)
    the URL mapping should be /MyServlet

    Thanks