Return-Path: X-Original-To: apmail-camel-users-archive@www.apache.org Delivered-To: apmail-camel-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 55148184BC for ; Fri, 26 Jun 2015 17:21:06 +0000 (UTC) Received: (qmail 80947 invoked by uid 500); 26 Jun 2015 17:21:05 -0000 Delivered-To: apmail-camel-users-archive@camel.apache.org Received: (qmail 80903 invoked by uid 500); 26 Jun 2015 17:21:05 -0000 Mailing-List: contact users-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@camel.apache.org Delivered-To: mailing list users@camel.apache.org Received: (qmail 80872 invoked by uid 99); 26 Jun 2015 17:21:05 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 26 Jun 2015 17:21:05 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of tdudgeon.ml@gmail.com designates 209.85.212.169 as permitted sender) Received: from [209.85.212.169] (HELO mail-wi0-f169.google.com) (209.85.212.169) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 26 Jun 2015 17:18:49 +0000 Received: by wiga1 with SMTP id a1so23160444wig.0 for ; Fri, 26 Jun 2015 10:20:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=cicTgpBtxDoXgVYLI31ERjsdY7kCjMZvSobuZXp124U=; b=iCTQthlSftFo9wyv5oTtyXCLeVyQYSRjPx0zXwBmQegptFvQ9A0AHDH0LTKp2vpWGV 7hONtZoUDOztEmv0tADn7diW+M6xxqBSUlZOmOMcbJTd5y9IWEP2DPGQKLPYrDx92uVv H2FTk9augSSLSNN0LKWd5JndwYIbefqYQHRiNw/rYgKrxDlaLnABT258irCbGfyy1YFy ajuD1iNYSczYK5ImrlYAUQvCO2dbWGIQuVWflv7DhPLdVFaeFdxY3HWWm4D/09P2zU6+ 31TSu3oHUmvG2qeJm5is43+hX50ht1/BOCFVQtnoOb5H4ivWs5Xf2tt8Ilz1eDHMXJzF u3Cg== X-Received: by 10.195.17.199 with SMTP id gg7mr4937645wjd.121.1435339237523; Fri, 26 Jun 2015 10:20:37 -0700 (PDT) Received: from timbomac.home (host86-147-76-119.range86-147.btcentralplus.com. [86.147.76.119]) by mx.google.com with ESMTPSA id ym2sm51299678wjc.44.2015.06.26.10.20.36 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 26 Jun 2015 10:20:36 -0700 (PDT) Message-ID: <558D89E2.9050602@gmail.com> Date: Fri, 26 Jun 2015 18:20:34 +0100 From: Tim Dudgeon User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: users@camel.apache.org Subject: Re: nonsense ClassCastException References: <558C3608.7090309@gmail.com> In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked by ClamAV on apache.org Yes, seems so. I fixed it by managing the dependencies, but what was happening made no sense to me as two seemingly "identical" setups behaved differently. Tim On 26/06/2015 11:21, Henryk Konsek wrote: > Hi, > > It looks like you have incompatible Servlet API jars included in your WAR. > So your jars do not match the API used by your Tomcat. > > Cheers! > > czw., 25.06.2015 o 19:11 użytkownik Tim Dudgeon > napisał: > >> I'm trying to run some routes in tomcat using the servlet component >> (CamelHttpTransportServlet in the web.xml) >> In a simple example I've got it running fine, but when I try this in the >> real example I get a startup exception that makes no sense at all. >> >> Marking servlet CamelServlet as unavailable >> Servlet [CamelServlet] in web application [/job-services] threw load() >> exception >> java.lang.ClassCastException: >> org.apache.camel.component.servlet.CamelHttpTransportServlet cannot be >> cast to javax.servlet.Servlet >> at >> >> org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1148) >> at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1087) >> at >> >> org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5262) >> at >> >> org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5550) >> at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) >> at >> >> org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1575) >> at >> >> org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1565) >> at java.util.concurrent.FutureTask.run(FutureTask.java:266) >> at >> >> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) >> at >> >> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) >> at java.lang.Thread.run(Thread.java:745) >> >> >> Clearly CamelHttpTransportServlet can be cast to javax.servlet.Servlet. >> Anyone got any ideas what to look at for this? >> >> Tim >> >>