Announcement Announcement Module
No announcement yet.
ClassNotFoundException:org.springframework.web.con text.ContextLoaderListener Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • ClassNotFoundException:org.springframework.web.con text.ContextLoaderListener

    Hi guys

    I'm newbie and study springframework webservice(with Apache CXF)

    I have some questions about 'ContextLoaderListener '

    in web.xml

    then, these ERRORs are shown
    Error configuring application listener of class org.springframework.web.context.ContextLoaderListener
    java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener
    	at org.apache.catalina.loader.WebappClassLoader.loadClass(
    	at org.apache.catalina.loader.WebappClassLoader.loadClass(
    	at org.apache.catalina.core.StandardContext.listenerStart(
    	at org.apache.catalina.core.StandardContext.start(
    	at org.apache.catalina.core.ContainerBase.start(
    	at org.apache.catalina.core.StandardHost.start(
    	at org.apache.catalina.core.ContainerBase.start(
    	at org.apache.catalina.core.StandardEngine.start(
    	at org.apache.catalina.core.StandardService.start(
    	at org.apache.catalina.core.StandardServer.start(
    	at org.apache.catalina.startup.Catalina.start(
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    	at java.lang.reflect.Method.invoke(Unknown Source)
    	at org.apache.catalina.startup.Bootstrap.start(
    	at org.apache.catalina.startup.Bootstrap.main(

    about tutorial..

    help me plz guys..TT

  • #2
    put spring.jar file in lib folder or your classpath and try...


    • #3
      thank you for your answer

      I resovled this problem..

      cause, tomcat is not recogized librarys in folder

      I'll use build tools (ant or maven..)



      • #4
        Error configuring application listener org.springframework.web.context.contextloaderl

        When im trying to integrate JSF and SPring 2.5.0 RC1 im getting the below error.
        SEVERE: Error configuring application listener of class org.springframework.web.context.ContextLoaderListe ner
        java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListe ner
        at org.apache.catalina.loader.WebappClassLoader.loadC lass(
        at org.apache.catalina.loader.WebappClassLoader.loadC lass(
        at org.apache.catalina.core.StandardContext.listenerS tart(
        at org.apache.catalina.core.StandardContext.start(Sta
        at org.apache.catalina.core.ContainerBase.addChildInt ernal(
        at org.apache.catalina.core.ContainerBase.addChild(Co
        at org.apache.catalina.core.StandardHost.addChild(Sta
        at org.apache.catalina.startup.HostConfig.deployWAR(H
        at org.apache.catalina.startup.HostConfig.deployWARs(
        at org.apache.catalina.startup.HostConfig.deployApps(
        at org.apache.catalina.startup.HostConfig.start(HostC
        at org.apache.catalina.startup.HostConfig.lifecycleEv ent(
        at org.apache.catalina.util.LifecycleSupport.fireLife cycleEvent(
        at org.apache.catalina.core.ContainerBase.start(Conta
        at org.apache.catalina.core.StandardHost.start(Standa
        at org.apache.catalina.core.ContainerBase.start(Conta
        at org.apache.catalina.core.StandardEngine.start(Stan
        at org.apache.catalina.core.StandardService.start(Sta
        at org.apache.catalina.core.StandardServer.start(Stan
        at org.apache.catalina.startup.Catalina.start(Catalin
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Nativ e Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknow n Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Un known Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.apache.catalina.startup.Bootstrap.start(Bootst
        at org.apache.catalina.startup.Bootstrap.main(Bootstr

        Wht could be the prob for the following? Any help is appreciated....
        Thanks in advance



        • #5
          Hi Basu,

          As I mention put spring.jar that come with the dist in the coresponding spring version.
          If you dont want the whole spring modules you can just include spring-web.jar in your class path.try it...


          • #6
            If you're using Eclipse and Maven, then the problem is with one particular project settings option:
            project properties -> Java EE Module Dependencies -> Maven Dependencies
            the last option must be checked (which isn't by default).

            Grzegorz Grzybek


            • #7

              in later versions the same effect can be had in Maven projects by checking "Automatically update dependencies" in Project Properties -> Spring -> Dependency Management.
              Last edited by MiB; Mar 21st, 2011, 08:35 AM.


              • #8
                I fixed the error with Maven by going to project properties -> Deployment Assembley and adding the Maven Dependency Build Path entry


                • #9
                  Thanks, this fixed the problem that my dependencies showed up in the root of the project layout.


                  • #10
                    Originally posted by mcgin View Post
                    I fixed the error with Maven by going to project properties -> Deployment Assembley and adding the Maven Dependency Build Path entry
                    Hi, Can you pls explain how exactly you added the Maven Dependency Build path.

                    I am trying to do the same but in java build path entry I dont see any thing related to maven.


                    • #11

                      Much has changed since March Now all works when you use M2E ( + M2E-WTP (

                      Almost everything works out of the box (the only thing left - for me - is overlay filtering)

                      Grzegorz Grzybek


                      • #12
                        For what it's worth, running a spring app from within eclipse can be a very frustrating experience, especially when insisting on the latest and greatest + maven. I found that the Maven dependencies are not included in WEB-INF/lib unless the project is configured as shown in the attached screenie. May it save you precious development time! Happy Hacking!!!

                        Attached Files
                        Last edited by npg; Sep 9th, 2011, 05:59 AM.


                        • #13
                          If you correctly created your project from a Maven pom.xml file, then you should be able to add the Maven Dependencies this way:
                          Deployment Assembly / Add... / Java Build Path Entries / (select Maven Dependencies)


                          • #14
                            Having the same problem in a project set on flash builder. How can I add Maven support to solve this problem?

                            class org.springframework.web.context.ContextLoaderListe ner not found.




                            • #15
                              Hi ,
                              You can add maven dependency and for deployment using maven add the dependency in pom.xml