java.lang.IllegalArgumentException: Host cannot be empty

GitHub | jvalkeal | 5 months ago
  1. 0

    Add support for @GetMapping, @PostMapping etc. introduced in Spring 4.3 in ControllerLinkBuilder

    GitHub | 4 months ago | xak2000
    java.lang.IllegalArgumentException: 'uriTemplate' must not be null
  2. 0

    Spring Boot setting up MongoDB repository

    Stack Overflow | 4 months ago | Em Ae
    org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'bookService': Unsatisfied dependency expressed through field 'bookRepository': Error creating bean with name 'bookRepository': Cannot resolve reference to bean 'mongoTemplate' while setting bean property 'mongoOperations'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mongoTemplate' defined in class path resource [com/project/path/to/config/DbConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.mongodb.core.MongoTemplate]: Factory method 'mongoTemplate' threw exception; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mongoDbFactory' defined in class path resource [com/project/path/to/config/DbConfiguration.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.IllegalArgumentException: Database name must not be empty; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'bookRepository': Cannot resolve reference to bean 'mongoTemplate' while setting bean property 'mongoOperations'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mongoTemplate' defined in class path resource [com/project/path/to/config/DbConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.data.mongodb.core.MongoTemplate]: Factory method 'mongoTemplate' threw exception; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mongoDbFactory' defined in class path resource [com/project/path/to/config/DbConfiguration.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.IllegalArgumentException: Database name must not be empty
  3. Speed up your debug routine!

    Automated exception search integrated into your IDE

  4. 0

    mongoProperties properties are null

    Stack Overflow | 3 months ago | user3034559
    java.lang.IllegalArgumentException: Database name must not be empty
  5. 0

    Error when invoking completion

    GitHub | 3 months ago | ericbottard
    java.lang.IllegalArgumentException: name must not be empty nor null
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.IllegalArgumentException

    Host cannot be empty

    at org.springframework.util.Assert.hasText()
  2. Spring Core
    Assert.hasText
    1. org.springframework.util.Assert.hasText(Assert.java:168)[spring-core-4.2.6.RELEASE.jar!/:4.2.6.RELEASE]
    1 frame
  3. org.springframework.integration
    ZookeeperConfiguration$BrokerToBrokerAddressFunction.valueOf
    1. org.springframework.integration.kafka.core.BrokerAddress.<init>(BrokerAddress.java:38)[spring-integration-kafka-1.3.1.RELEASE.jar!/:na]
    2. org.springframework.integration.kafka.core.ZookeeperConfiguration$BrokerToBrokerAddressFunction.valueOf(ZookeeperConfiguration.java:101)[spring-integration-kafka-1.3.1.RELEASE.jar!/:na]
    3. org.springframework.integration.kafka.core.ZookeeperConfiguration$BrokerToBrokerAddressFunction.valueOf(ZookeeperConfiguration.java:96)[spring-integration-kafka-1.3.1.RELEASE.jar!/:na]
    3 frames
  4. Goldman Sachs Collections Main Library
    FastList.collect
    1. com.gs.collections.impl.list.mutable.FastList.collect(FastList.java:943)[gs-collections-5.0.0.jar!/:na]
    2. com.gs.collections.impl.list.mutable.FastList.collect(FastList.java:807)[gs-collections-5.0.0.jar!/:na]
    2 frames
  5. org.springframework.integration
    DefaultConnectionFactory.refreshMetadata
    1. org.springframework.integration.kafka.core.ZookeeperConfiguration.doGetBrokerAddresses(ZookeeperConfiguration.java:82)[spring-integration-kafka-1.3.1.RELEASE.jar!/:na]
    2. org.springframework.integration.kafka.core.AbstractConfiguration.getBrokerAddresses(AbstractConfiguration.java:158)[spring-integration-kafka-1.3.1.RELEASE.jar!/:na]
    3. org.springframework.integration.kafka.core.DefaultConnectionFactory.refreshMetadata(DefaultConnectionFactory.java:175)[spring-integration-kafka-1.3.1.RELEASE.jar!/:na]
    3 frames
  6. org.springframework.cloud
    KafkaMessageChannelBinder$3.doWithRetry
    1. org.springframework.cloud.stream.binder.kafka.KafkaMessageChannelBinder$3.doWithRetry(KafkaMessageChannelBinder.java:409)[spring-cloud-stream-binder-kafka-1.0.2.RELEASE.jar!/:1.0.2.RELEASE]
    2. org.springframework.cloud.stream.binder.kafka.KafkaMessageChannelBinder$3.doWithRetry(KafkaMessageChannelBinder.java:405)[spring-cloud-stream-binder-kafka-1.0.2.RELEASE.jar!/:1.0.2.RELEASE]
    2 frames
  7. Spring Retry
    RetryTemplate.execute
    1. org.springframework.retry.support.RetryTemplate.doExecute(RetryTemplate.java:263)[spring-retry-1.1.2.RELEASE.jar!/:na]
    2. org.springframework.retry.support.RetryTemplate.execute(RetryTemplate.java:154)[spring-retry-1.1.2.RELEASE.jar!/:na]
    2 frames
  8. org.springframework.cloud
    OutputBindingLifecycle.start
    1. org.springframework.cloud.stream.binder.kafka.KafkaMessageChannelBinder.ensureTopicCreated(KafkaMessageChannelBinder.java:405)[spring-cloud-stream-binder-kafka-1.0.2.RELEASE.jar!/:1.0.2.RELEASE]
    2. org.springframework.cloud.stream.binder.kafka.KafkaMessageChannelBinder.doBindProducer(KafkaMessageChannelBinder.java:296)[spring-cloud-stream-binder-kafka-1.0.2.RELEASE.jar!/:1.0.2.RELEASE]
    3. org.springframework.cloud.stream.binder.kafka.KafkaMessageChannelBinder.doBindProducer(KafkaMessageChannelBinder.java:121)[spring-cloud-stream-binder-kafka-1.0.2.RELEASE.jar!/:1.0.2.RELEASE]
    4. org.springframework.cloud.stream.binder.AbstractBinder.bindProducer(AbstractBinder.java:184)[spring-cloud-stream-1.0.2.RELEASE.jar!/:1.0.2.RELEASE]
    5. org.springframework.cloud.stream.binding.ChannelBindingService.bindProducer(ChannelBindingService.java:113)[spring-cloud-stream-1.0.2.RELEASE.jar!/:1.0.2.RELEASE]
    6. org.springframework.cloud.stream.binding.BindableProxyFactory.bindOutputs(BindableProxyFactory.java:206)[spring-cloud-stream-1.0.2.RELEASE.jar!/:1.0.2.RELEASE]
    7. org.springframework.cloud.stream.binding.OutputBindingLifecycle.start(OutputBindingLifecycle.java:57)[spring-cloud-stream-1.0.2.RELEASE.jar!/:1.0.2.RELEASE]
    7 frames
  9. Spring Context
    AbstractApplicationContext.finishRefresh
    1. org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:173)[spring-context-4.2.6.RELEASE.jar!/:4.2.6.RELEASE]
    2. org.springframework.context.support.DefaultLifecycleProcessor.access$200(DefaultLifecycleProcessor.java:51)[spring-context-4.2.6.RELEASE.jar!/:4.2.6.RELEASE]
    3. org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:346)[spring-context-4.2.6.RELEASE.jar!/:4.2.6.RELEASE]
    4. org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:149)[spring-context-4.2.6.RELEASE.jar!/:4.2.6.RELEASE]
    5. org.springframework.context.support.DefaultLifecycleProcessor.onRefresh(DefaultLifecycleProcessor.java:112)[spring-context-4.2.6.RELEASE.jar!/:4.2.6.RELEASE]
    6. org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:852)[spring-context-4.2.6.RELEASE.jar!/:4.2.6.RELEASE]
    6 frames
  10. Spring Boot
    EmbeddedWebApplicationContext.finishRefresh
    1. org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.finishRefresh(EmbeddedWebApplicationContext.java:140)[spring-boot-1.3.5.RELEASE.jar!/:1.3.5.RELEASE]
    1 frame
  11. Spring Context
    AbstractApplicationContext.refresh
    1. org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:541)[spring-context-4.2.6.RELEASE.jar!/:4.2.6.RELEASE]
    1 frame
  12. Spring Boot
    SpringApplication.run
    1. org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118)[spring-boot-1.3.5.RELEASE.jar!/:1.3.5.RELEASE]
    2. org.springframework.boot.SpringApplication.refresh(SpringApplication.java:766)[spring-boot-1.3.5.RELEASE.jar!/:1.3.5.RELEASE]
    3. org.springframework.boot.SpringApplication.createAndRefreshContext(SpringApplication.java:361)[spring-boot-1.3.5.RELEASE.jar!/:1.3.5.RELEASE]
    4. org.springframework.boot.SpringApplication.run(SpringApplication.java:307)[spring-boot-1.3.5.RELEASE.jar!/:1.3.5.RELEASE]
    5. org.springframework.boot.SpringApplication.run(SpringApplication.java:1191)[spring-boot-1.3.5.RELEASE.jar!/:1.3.5.RELEASE]
    6. org.springframework.boot.SpringApplication.run(SpringApplication.java:1180)[spring-boot-1.3.5.RELEASE.jar!/:1.3.5.RELEASE]
    6 frames
  13. org.springframework.cloud
    TimeSourceKafkaApplication.main
    1. org.springframework.cloud.stream.app.time.source.kafka.TimeSourceKafkaApplication.main(TimeSourceKafkaApplication.java:29)[time-source-kafka-1.0.0.BUILD-SNAPSHOT.jar!/:1.0.0.BUILD-SNAPSHOT]
    1 frame
  14. Java RT
    Method.invoke
    1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[na:1.8.0_91]
    2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)[na:1.8.0_91]
    3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[na:1.8.0_91]
    4. java.lang.reflect.Method.invoke(Method.java:498)[na:1.8.0_91]
    4 frames
  15. Spring Boot Loader
    MainMethodRunner.run
    1. org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:54)[time-source-kafka-1.0.0.BUILD-SNAPSHOT.jar!/:1.0.0.BUILD-SNAPSHOT]
    1 frame
  16. Java RT
    Thread.run
    1. java.lang.Thread.run(Thread.java:745)[na:1.8.0_91]
    1 frame