org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.mongodb.MongoDbFactory]: Factory method 'mongoDbFactory' threw exception; nested exception is java.lang.IllegalAccessError: tried to access method org.bson.types.ObjectId.<init>(III)V from class com.mongodb.Bytes ERROR_DETAILS: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mongoDbFactory' defined in class path resource [com/comcast/sparrow/activatorweb/repository/MongoDBConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.mongodb.MongoDbFactory]: Factory method 'mongoDbFactory' threw exception; nested exception is java.lang.IllegalAccessError: tried to access method org.bson.types.ObjectId.<init>(III)V from class com.mongodb.Bytes

GitHub | pradeepkusingh | 5 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Cloud foundry issue while upgrading spring libraries with Build pack 3.9

    GitHub | 5 months ago | pradeepkusingh
    org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.mongodb.MongoDbFactory]: Factory method 'mongoDbFactory' threw exception; nested exception is java.lang.IllegalAccessError: tried to access method org.bson.types.ObjectId.<init>(III)V from class com.mongodb.Bytes ERROR_DETAILS: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mongoDbFactory' defined in class path resource [com/comcast/sparrow/activatorweb/repository/MongoDBConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.mongodb.MongoDbFactory]: Factory method 'mongoDbFactory' threw exception; nested exception is java.lang.IllegalAccessError: tried to access method org.bson.types.ObjectId.<init>(III)V from class com.mongodb.Bytes
  2. 0

    MOngo DB 3.2.2 java driver and error

    Google Groups | 5 months ago | Pradeep Singh
    org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.mongodb.MongoDbFactory]: Factory method 'mongoDbFactory' threw exception; nested exception is java.lang.IllegalAccessError: tried to access method
  3. 0

    upgrading from spring 3.2.0 to 4.1.2 with java8 env. and hibernate 3, getting exceptions

    Stack Overflow | 2 years ago | Rajith Gupta
    org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.aop.framework.autoproxy.InfrastructureAdvisorAutoProxyCreator]: Constructor threw exception; nested exception is java.lang.NoSuchMethodError: org.springframework.core.CollectionFactory.createConcurrentMapIfPossible(I)Ljava/util/Map;
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    OpenNMS / Mailing Lists

    sourceforge.net | 2 years ago
    org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [org.springframework.context.support.ClassPathXmlApplicationContext]: Constructor threw exception; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'resourceDao' defined in class path resource [META-INF/opennms/applicationContext-dao.xml]: Invocation of init method failed; nested exception is java.lang.NullPointerException
  6. 0

    All comments on JSF & PrimeFaces & Spring tutorial 9: Spring Data JPA & Hibernate : javavids - YouTube

    youtube.com | 1 year ago
    org.springframework.beans.BeanInstantiationException: Failed to instantiate [javax.sql.DataSource]: Factory method 'dataSource' threw exception; nested exception is java.lang.UnsupportedClassVersionError: com/zaxxer/hikari/HikariDataSource : Unsupported major.minor version 52.0

    1 unregistered visitors
    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. org.springframework.beans.BeanInstantiationException

      Failed to instantiate [org.springframework.data.mongodb.MongoDbFactory]: Factory method 'mongoDbFactory' threw exception; nested exception is java.lang.IllegalAccessError: tried to access method org.bson.types.ObjectId.<init>(III)V from class com.mongodb.Bytes ERROR_DETAILS: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mongoDbFactory' defined in class path resource [com/comcast/sparrow/activatorweb/repository/MongoDBConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.mongodb.MongoDbFactory]: Factory method 'mongoDbFactory' threw exception; nested exception is java.lang.IllegalAccessError: tried to access method org.bson.types.ObjectId.<init>(III)V from class com.mongodb.Bytes

      at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod()
    2. Spring Beans
      AbstractBeanFactory.getBean
      1. org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:599)
      2. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1128)
      3. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1023)
      4. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:510)
      5. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482)
      6. org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306)
      7. org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
      8. org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302)
      9. org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
      9 frames
    3. Spring Context
      ConfigurationClassEnhancer$BeanMethodInterceptor.intercept
      1. org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:381)
      1 frame
    4. com.comcast.sparrow
      MongoDBConfiguration$$EnhancerBySpringCGLIB$$bd6b329d$$FastClassBySpringCGLIB$$ecc75b5b.invoke
      1. com.comcast.sparrow.activatorweb.repository.MongoDBConfiguration$$EnhancerBySpringCGLIB$$bd6b329d.mongoDbFactory(<generated>)
      2. com.comcast.sparrow.activatorweb.repository.MongoDBConfiguration.mongoTemplate(MongoDBConfiguration.java:68)
      3. com.comcast.sparrow.activatorweb.repository.MongoDBConfiguration$$EnhancerBySpringCGLIB$$bd6b329d.CGLIB$mongoTemplate$0(<generated>)
      4. com.comcast.sparrow.activatorweb.repository.MongoDBConfiguration$$EnhancerBySpringCGLIB$$bd6b329d$$FastClassBySpringCGLIB$$ecc75b5b.invoke(<generated>)
      4 frames
    5. Spring Core
      MethodProxy.invokeSuper
      1. org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228)
      1 frame
    6. Spring Context
      ConfigurationClassEnhancer$BeanMethodInterceptor.intercept
      1. org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:356)
      1 frame
    7. com.comcast.sparrow
      MongoDBConfiguration$$EnhancerBySpringCGLIB$$bd6b329d.mongoTemplate
      1. com.comcast.sparrow.activatorweb.repository.MongoDBConfiguration$$EnhancerBySpringCGLIB$$bd6b329d.mongoTemplate(<generated>)
      1 frame
    8. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      4. java.lang.reflect.Method.invoke(Method.java:498)
      4 frames
    9. Spring Beans
      ConstructorResolver.instantiateUsingFactoryMethod
      1. org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:162)
      2. org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:588)
      2 frames