Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6605699
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T19:18:55+00:00 2026-05-25T19:18:55+00:00

I have been trying to get a basic example of a servlet endpoint to

  • 0

I have been trying to get a basic example of a servlet endpoint to work in camel. My example is based on this:http://camel.apache.org/servlet-tomcat-example.html

When I try to run this in Jetty though I get the following exception: ‘java.lang.IllegalStateException: No resource at org.apache.camel.component.servlet.CamelHttpTransportServlet/httpRegistry’

Here is my Web.xml

    <!-- Camel servlet -->
<servlet>
    <servlet-name>CamelServlet</servlet-name>
    <servlet-class>org.apache.camel.component.servlet.CamelHttpTransportServlet</servlet-class>
    <init-param>
        <param-name>matchOnUriPrefix</param-name>
        <param-value>true</param-value>
    </init-param>
    <load-on-startup>1</load-on-startup>
</servlet>

<!-- Camel servlet mapping -->
<servlet-mapping>
    <servlet-name>CamelServlet</servlet-name>
    <url-pattern>/camel/*</url-pattern>
</servlet-mapping>


<!-- the listener that kick-starts Spring -->
<listener>
    <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
<!-- location of spring xml files -->
<context-param>
    <param-name>contextConfigLocation</param-name>
    <param-value>/WEB-INF/applicationContext.xml</param-value>
</context-param>

And here is my applicationContext.xml:

<bean id="route" class="com.routes.smppRoute" />
<!-- the camel context -->
<camelContext xmlns="http://camel.apache.org/schema/spring" id="camel">
    <routeBuilder ref="route" />
</camelContext>

The route simple takes the input and outputs it to the console

public class smppRoute extends RouteBuilder {
@Override
public void configure() throws Exception {
    from("servlet:///").to("stream:out");

}

}

I am pretty sure I have all the dependencies in, here is the pom.xml:

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

<modelVersion>4.0.0</modelVersion>

<groupId>com.fundamo</groupId>
<artifactId>fundamo-platform-smpp-camel</artifactId>
<version>1.0-SNAPSHOT</version>

<name>Camel Router Application</name>
<description>Camel project that deploys the Camel routes as a WAR</description>
<url>http://www.myorganization.org</url>

<packaging>war</packaging>

<repositories>
    <repository>
        <id>org.apache.camel</id>
        <url>https://repository.apache.org/content/groups/snapshots-group</url>
    </repository>
</repositories>

<dependencies>

    <!-- Camel Dependencies -->
    <dependency>
        <groupId>org.apache.camel</groupId>
        <artifactId>camel-core</artifactId>
        <version>2.7-SNAPSHOT</version>
    </dependency>
    <dependency>
        <groupId>org.apache.camel</groupId>
        <artifactId>camel-spring</artifactId>
        <version>2.7-SNAPSHOT</version>
    </dependency>
    <dependency>
        <groupId>org.apache.camel</groupId>
        <artifactId>camel-stream</artifactId>
        <version>2.7-SNAPSHOT</version>
    </dependency>
    <dependency>
        <groupId>org.apache.camel</groupId>
        <artifactId>camel-servlet</artifactId>
        <version>2.7-SNAPSHOT</version>
    </dependency>
    <!-- Spring Web -->
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-web</artifactId>
        <version>3.0.5.RELEASE</version>
    </dependency>

    <!-- logging -->
    <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-log4j12</artifactId>
        <version>1.5.11</version>
    </dependency>
    <dependency>
        <groupId>log4j</groupId>
        <artifactId>log4j</artifactId>
        <version>1.2.16</version>
    </dependency>

</dependencies>

<build>
    <defaultGoal>install</defaultGoal>

    <plugins>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>2.3.2</version>
            <configuration>
                <source>1.6</source>
                <target>1.6</target>
            </configuration>
        </plugin>

        <!-- plugin so you can run mvn jetty:run -->
        <plugin>
            <groupId>org.mortbay.jetty</groupId>
            <artifactId>jetty-maven-plugin</artifactId>
            <version>7.2.2.v20101205</version>

            <configuration>
                <webAppConfig>
                    <contextPath>/</contextPath>
                </webAppConfig>

                <systemProperties>
                    <!-- enable easy JMX connection to JConsole -->
                    <systemProperty>
                        <name>com.sun.management.jmxremote</name>
                        <value />
                    </systemProperty>
                </systemProperties>
                <scanIntervalSeconds>10</scanIntervalSeconds>
            </configuration>
        </plugin>
    </plugins>
</build>

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T19:18:55+00:00Added an answer on May 25, 2026 at 7:18 pm

    Can you try to change the version to 2.8.1 instead of using the 2.7-SNAPSHOT ?
    I just did some test on the camel-example-servlet-tomcat in the Camel trunk, it doesn’t throw such a error.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been trying to get around this error for a day now and
I have been trying to get the Fusion Charts to work on Android 2.2
I have been trying to get more in to TDD. Currently keeping it simple
I have been trying for a long time to get SQL Server Express on
I have been having some problems trying to get my PHP running. When I
I have been trying to work my way through Project Euler, and have noticed
I've been trying to get the UNIQUE constraint placed on some attributes I have
I've been stuck for quite a while now trying to get this query to
I've been trying to get a basic program going with the windows API (WinMain
I understand this is a basic question... but I have been stuck on it

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.