Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 485
  • Last Modified:

unable to get servlet working

I am trying to deploy an application in Tomcat 5.0

I have put the JSP pages in
   /webapps/ROOT/test/index.jsp
and the servlets in the package
   /webapps/ROOT/WEB-INF/classes/sample/Logintest.class
and the WEB.XML in
   /webapps/ROOT/WEB-INF/web.xml

but I get .
Am i missing something , i have the same thing running Tomcat 4.0.6 and have nor problem . I am using a linux m/c

The requested resource (/servlet/sample.Logintest) is not available.

Thank q
0
applekanna
Asked:
applekanna
  • 4
  • 4
  • 2
  • +1
2 Solutions
 
TimYatesCommented:
try it with a servlet mapping in web.xml:

  <servlet>
    <servlet-name>logintest</servlet-name>
    <servlet-class>sample.Logintest</servlet-class>
  </servlet>
  <servlet-mapping>
    <servlet-name>logintest</servlet-name>
    <url-pattern>*.login</url-pattern>
  </servlet-mapping>

restart Tomcat, and go to:

http://localhost:8080/test.login
0
 
jimmackCommented:
Have you tried the URL without the /servlet/ ?
0
 
applekannaAuthor Commented:
yes we have it running on a tomcat 4.0.6 already , but unable to get it to deploy on a new machine and we installed tomcat 5.

0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
jimmackCommented:
Morning Tim.  You're very active lately ;-)
0
 
jimmackCommented:
From the Tomcat 5 Release Notes:

------------------------
Enabling invoker servlet:
------------------------

Starting with Tomcat 4.1.12, the invoker servlet is no longer available by
default in all webapps. Enabling it for all webapps is possible by editing
$CATALINA_HOME/conf/web.xml to uncomment the "/servlet/*" servlet-mapping
definition.

Using the invoker servlet in a production environment is not recommended and
is unsupported.

This might explain it ;-)
0
 
TimYatesCommented:
> This might explain it ;-)

And my solution should fix it ;-)

Hee hee!

>  Morning Tim.  You're very active lately ;-)

Messing round with Axis, CSS, SOAP, RPC and stuff...  It's cool, but I come here to think about other things, and try to have a revelation about what I'm doing wrong ;-)

Hee hee

Tim
0
 
TimYatesCommented:
PS:  Morning!!!! :-)
0
 
CEHJCommented:
>>Messing round with Axis, CSS, SOAP, RPC and stuff.

Well there's a coincidence - so am i - but not with much enthusiasm ;-) Maybe we should offline about it? ;-)
0
 
TimYatesCommented:
:-) You can find my contact details with a bit of investigation into my profile ;-)  hee hee
0
 
applekannaAuthor Commented:
Thx a lot guys, it worked like a charm.
0
 
jimmackCommented:
;-)
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 4
  • 4
  • 2
  • +1
Tackle projects and never again get stuck behind a technical roadblock.
Join Now