org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mvcContentNegotiationManager': Invocation of init method failed; nested exception is java.lang.ClassCastException: org.springframework.web.accept.HeaderContentNegotiationStrategy cannot be cast to org.springframework.web.accept.ContentNegotiationStrategy

  1. 0

    Getting Exception while deplowing a web Spring web aplication in karaf

    Stack Overflow | 5 months ago | Gabriel Duchateau
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mvcContentNegotiationManager': Invocation of init method failed; nested exception is java.lang.ClassCastException: org.springframework.web.accept.HeaderContentNegotiationStrategy cannot be cast to org.springframework.web.accept.ContentNegotiationStrategy
  2. 0

    Spring | Develop and Conquer | Page 2

    wordpress.com | 1 year ago
    java.lang.ClassCastException: java.lang.String cannot be cast to org.springframework.http.MediaType
  3. 0

    ClassCastException | Develop and Conquer

    wordpress.com | 1 year ago
    java.lang.ClassCastException: java.lang.String cannot be cast to org.springframework.http.MediaType
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Spring Community Forums - Spring Framework Support Forums (archive ID #595) - Read it at RSS2.com

    rss2.com | 1 year ago
    java.lang.ClassCastException: java.lang.String cannot be cast to org.springframework.http.MediaType
  6. 0

    Spring | Develop and Conquer | Page 3

    wordpress.com | 5 months ago
    java.lang.ClassCastException: java.lang.String cannot be cast to org.springframework.http.MediaType

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.ClassCastException

      org.springframework.web.accept.HeaderContentNegotiationStrategy cannot be cast to org.springframework.web.accept.ContentNegotiationStrategy

      at org.springframework.web.accept.ContentNegotiationManager.<init>()
    2. Spring
      ContentNegotiationManagerFactoryBean.afterPropertiesSet
      1. org.springframework.web.accept.ContentNegotiationManager.<init>(ContentNegotiationManager.java:87)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      2. org.springframework.web.accept.ContentNegotiationManagerFactoryBean.afterPropertiesSet(ContentNegotiationManagerFactoryBean.java:241)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      2 frames
    3. Spring Beans
      DefaultListableBeanFactory.preInstantiateSingletons
      1. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1633)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      2. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1570)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      3. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:539)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      4. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:476)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      5. org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:303)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      6. org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      7. org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:299)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      8. org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      9. org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:736)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      9 frames
    4. Spring Context
      AbstractApplicationContext.refresh
      1. org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:757)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      2. org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:480)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      2 frames
    5. Spring
      ContextLoaderListener.contextInitialized
      1. org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:434)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      2. org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:306)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      3. org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:106)[191:ASM-InfraMngr-ServerManagement-Module:0.0.1]
      3 frames
    6. OPS4J Pax Web - Jetty
      HttpServiceContext$3.call
      1. org.ops4j.pax.web.service.jetty.internal.HttpServiceContext$3.call(HttpServiceContext.java:338)[109:org.ops4j.pax.web.pax-web-jetty:4.2.2]
      2. org.ops4j.pax.web.service.jetty.internal.HttpServiceContext$3.call(HttpServiceContext.java:334)[109:org.ops4j.pax.web.pax-web-jetty:4.2.2]
      2 frames
    7. OPS4J Pax Swissbox :: OSGi Core
      ContextClassLoaderUtils.doWithClassLoader
      1. org.ops4j.pax.swissbox.core.ContextClassLoaderUtils.doWithClassLoader(ContextClassLoaderUtils.java:60)[109:org.ops4j.pax.web.pax-web-jetty:4.2.2]
      1 frame
    8. OPS4J Pax Web - Jetty
      HttpServiceContext.callContextInitialized
      1. org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.callContextInitialized(HttpServiceContext.java:333)[109:org.ops4j.pax.web.pax-web-jetty:4.2.2]
      1 frame
    9. Jetty
      ContextHandler.doStart
      1. org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:791)[81:org.eclipse.jetty.server:9.2.10.v20150310]
      2. org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:294)[82:org.eclipse.jetty.servlet:9.2.10.v20150310]
      3. org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:741)[81:org.eclipse.jetty.server:9.2.10.v20150310]
      3 frames
    10. OPS4J Pax Web - Jetty
      HttpServiceContext.doStart
      1. org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doStart(HttpServiceContext.java:245)[109:org.ops4j.pax.web.pax-web-jetty:4.2.2]
      1 frame
    11. Jetty
      AbstractLifeCycle.start
      1. org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)[84:org.eclipse.jetty.util:9.2.10.v20150310]
      1 frame
    12. OPS4J Pax Web - Jetty
      JettyServerImpl$1.start
      1. org.ops4j.pax.web.service.jetty.internal.JettyServerImpl$1.start(JettyServerImpl.java:258)[109:org.ops4j.pax.web.pax-web-jetty:4.2.2]
      1 frame
    13. OPS4J Pax Web - Runtime
      HttpServiceProxy.end
      1. org.ops4j.pax.web.service.internal.HttpServiceStarted.end(HttpServiceStarted.java:1047)[111:org.ops4j.pax.web.pax-web-runtime:4.2.2]
      2. org.ops4j.pax.web.service.internal.HttpServiceProxy.end(HttpServiceProxy.java:413)[111:org.ops4j.pax.web.pax-web-runtime:4.2.2]
      2 frames
    14. OPS4J Pax Web - Extender - WAR
      WebAppPublisher$WebAppDependencyListener.addingService
      1. org.ops4j.pax.web.extender.war.internal.RegisterWebAppVisitorWC.end(RegisterWebAppVisitorWC.java:380)[107:org.ops4j.pax.web.pax-web-extender-war:4.2.2]
      2. org.ops4j.pax.web.extender.war.internal.model.WebApp.accept(WebApp.java:692)[107:org.ops4j.pax.web.pax-web-extender-war:4.2.2]
      3. org.ops4j.pax.web.extender.war.internal.WebAppPublisher$WebAppDependencyListener.register(WebAppPublisher.java:237)[107:org.ops4j.pax.web.pax-web-extender-war:4.2.2]
      4. org.ops4j.pax.web.extender.war.internal.WebAppPublisher$WebAppDependencyListener.addingService(WebAppPublisher.java:182)[107:org.ops4j.pax.web.pax-web-extender-war:4.2.2]
      5. org.ops4j.pax.web.extender.war.internal.WebAppPublisher$WebAppDependencyListener.addingService(WebAppPublisher.java:135)[107:org.ops4j.pax.web.pax-web-extender-war:4.2.2]
      5 frames
    15. OSGi
      ServiceTracker.open
      1. org.osgi.util.tracker.ServiceTracker$Tracked.customizerAdding(ServiceTracker.java:941)[org.osgi.core-6.0.0.jar:]
      2. org.osgi.util.tracker.ServiceTracker$Tracked.customizerAdding(ServiceTracker.java:870)[org.osgi.core-6.0.0.jar:]
      3. org.osgi.util.tracker.AbstractTracked.trackAdding(AbstractTracked.java:256)[org.osgi.core-6.0.0.jar:]
      4. org.osgi.util.tracker.AbstractTracked.trackInitial(AbstractTracked.java:183)[org.osgi.core-6.0.0.jar:]
      5. org.osgi.util.tracker.ServiceTracker.open(ServiceTracker.java:318)[org.osgi.core-6.0.0.jar:]
      6. org.osgi.util.tracker.ServiceTracker.open(ServiceTracker.java:261)[org.osgi.core-6.0.0.jar:]
      6 frames
    16. OPS4J Pax Web - Extender - WAR
      AbstractExtender$1.run
      1. org.ops4j.pax.web.extender.war.internal.WebAppPublisher.publish(WebAppPublisher.java:101)[107:org.ops4j.pax.web.pax-web-extender-war:4.2.2]
      2. org.ops4j.pax.web.extender.war.internal.WebObserver.deploy(WebObserver.java:219)[107:org.ops4j.pax.web.pax-web-extender-war:4.2.2]
      3. org.ops4j.pax.web.extender.war.internal.WebObserver$1.doStart(WebObserver.java:179)[107:org.ops4j.pax.web.pax-web-extender-war:4.2.2]
      4. org.ops4j.pax.web.extender.war.internal.extender.SimpleExtension.start(SimpleExtension.java:59)[107:org.ops4j.pax.web.pax-web-extender-war:4.2.2]
      5. org.ops4j.pax.web.extender.war.internal.extender.AbstractExtender$1.run(AbstractExtender.java:280)[107:org.ops4j.pax.web.pax-web-extender-war:4.2.2]
      5 frames
    17. Java RT
      Thread.run
      1. java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)[:1.8.0_66]
      2. java.util.concurrent.FutureTask.run(FutureTask.java:266)[:1.8.0_66]
      3. java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)[:1.8.0_66]
      4. java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)[:1.8.0_66]
      5. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[:1.8.0_66]
      6. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[:1.8.0_66]
      7. java.lang.Thread.run(Thread.java:745)[:1.8.0_66]
      7 frames