org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'defaultAWSCloudClient' defined in URL [jar:file:/home/hygieia/aws-cloud-collector-2.0.2-SNAPSHOT.jar!/com/capitalone/dashboard/collector/DefaultAWSCloudClient.class]: Bean instantiation via constructor failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.capitalone.dashboard.collector.DefaultAWSCloudClient]: Constructor threw exception; nested exception is java.lang.NullPointerException

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via Stack Overflow by KapilS
, 2 years ago
Error creating bean with name 'org.springframework.aop.aspectj.AspectJPointcutAdvisor#2': Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [org.springframework.aop.aspectj.AspectJPointcutAdvisor]: Constructor threw exception; nested exception is java.lang.IllegalArgumentException
via Stack Overflow by coder
, 2 years ago
Error creating bean with name 'mongoTemplate' defined in class path resource [applicationContext.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [org.springframework.data.mongodb.core.MongoTemplate]: Constructor threw exception; nested exception is java.lang.ExceptionInInitializerError
via Stack Overflow by user93796
, 2 years ago
Error creating bean with name 'personToDept' defined in class path resource [spring-configuration/application/appconfig-beans.xml]: Could not resolve matching constructor (hint: specify index/type/name arguments for simple parameters to avoid type ambiguities)
via Stack Overflow by Ganesh
, 1 year ago
Error creating bean with name 'mongoTemplate' defined in class path resource [Beans.xml]: Bean instantiation via constructor failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate
via Stack Overflow by user3548196
, 2 years ago
Error creating bean with name 'org.springframework.integration.sftp.gateway.SftpOutboundGateway#0': Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class
via Spring JIRA by Nick Padgett, 1 year ago
Error creating bean with name 'org.springframework.integration.filter.MethodInvokingSelector#0': Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'defaultAWSCloudClient' defined in URL [jar:file:/home/hygieia/aws-cloud-collector-2.0.2-SNAPSHOT.jar!/com/capitalone/dashboard/collector/DefaultAWSCloudClient.class]: Bean instantiation via constructor failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.capitalone.dashboard.collector.DefaultAWSCloudClient]: Constructor threw exception; nested exception is java.lang.NullPointerException
at java.util.Hashtable.put(Hashtable.java:459)
at com.capitalone.dashboard.collector.DefaultAWSCloudClient.setClients(DefaultAWSCloudClient.java:72)
at com.capitalone.dashboard.collector.DefaultAWSCloudClient.(DefaultAWSCloudClient.java:67)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:147)
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:122)
at org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:267)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:1139)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1042)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:504)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:476)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:303)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:299)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:757)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:686)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:320)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:957)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:946)
at com.capitalone.dashboard.Application.main(Application.java:38)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at java.lang.Thread.run(Thread.java:745)

Users with the same issue

4 times, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 2 years ago
Samebug visitor profile picture
Unknown user
Once, 3 weeks ago
Once, 1 month ago
4 times, 1 month ago
22 more bugmates

Know the solutions? Share your knowledge to help other developers to debug faster.