Return-Path: Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: (qmail 90082 invoked from network); 2 Aug 2007 20:43:58 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 2 Aug 2007 20:43:58 -0000 Received: (qmail 14149 invoked by uid 500); 2 Aug 2007 20:43:47 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 14132 invoked by uid 500); 2 Aug 2007 20:43:47 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 14121 invoked by uid 99); 2 Aug 2007 20:43:47 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 02 Aug 2007 13:43:47 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of hassan.schroeder@gmail.com designates 64.233.162.224 as permitted sender) Received: from [64.233.162.224] (HELO nz-out-0506.google.com) (64.233.162.224) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 02 Aug 2007 20:43:23 +0000 Received: by nz-out-0506.google.com with SMTP id z6so269790nzd for ; Thu, 02 Aug 2007 13:43:21 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=TE2GX8bmJFT1mBhRGTvhXpJbftm7ta+/D/PwNZWpPOhcQ9lcYWjxvzXhimYgOiBvshVH8YA63IM1s+mQvQGjRIfOEd0YhJM/DgCJaY3IycTIIko9jgnnTrB3SWXKi+IibaAE0cfVAyNG9qvPWjklhybMNttILW1w2gHekyhxVB0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=FMbyAZ7P1m7p5OWpODuPCvi/OCg+Wnhms3v4N8ZvW32ArgeOUydU9z6lcXDPYb2qp3AtX3UbV4JYVeVmSUxu9IEujn4rltMgNdF+ts0IujO4jmARHoGm/BAcP/30rVM/WzIRAL5j0PKnXIuP1eGz48sm4P+R/vjuknEn8D5KMFc= Received: by 10.142.50.15 with SMTP id x15mr102824wfx.1186087401319; Thu, 02 Aug 2007 13:43:21 -0700 (PDT) Received: by 10.142.84.4 with HTTP; Thu, 2 Aug 2007 13:43:21 -0700 (PDT) Message-ID: <4eedb92a0708021343v5607fd09kc8572757ad605841@mail.gmail.com> Date: Thu, 2 Aug 2007 13:43:21 -0700 From: "Hassan Schroeder" To: "Tomcat Users List" Subject: Re: javax.servlet.ServletException: Cannot allocate servlet instancefor path /servlet/HelloWorld (repost I don't resolve the problem with your reply) In-Reply-To: <46B237C5.1040206@poste.it> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <46B237C5.1040206@poste.it> X-Virus-Checked: Checked by ClamAV on apache.org On 8/2/07, Fabbris Pierluigi wrote: > javax.servlet.ServletException: Cannot allocate servlet instance for path /servlet/HelloWorld > *My first servlet in directory classes is:* Uh, well -- this *isn't* a servlet. I'm guessing that's the problem :-) javax.servlet.Servlet is an interface -- your servlet needs to extend it (actually HttpServlet in this case). > class HelloWorld { > public static void main(String[] args) > { > System.out.println("Hello World!"); > } > } See the examples packaged with Tomcat, and take a look at the Servlet Spec JavaDocs. HTH, -- Hassan Schroeder ------------------------ hassan.schroeder@gmail.com --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org