0

Consider the following code:

    <amq:transportConnectors>
        <amq:transportConnector uri="${esb.endpoint}"/>
    </amq:transportConnectors>

It is not able to resolve the uri value. The error I am getting is :

STACKTRACE:
at com.mincom.util.gadget.Starter.run(Starter.java:40)
THROWABLE: org.springframework.beans.factory.BeanDefinitionStoreException: Invalid bean
definition with name 'org.apache.activemq.xbean.XBeanBrokerService#0' defined in class 
path resource [minestar/esbadapter/service/EsbEmbeddedApacheContext.xml]: Could not 
resolve placeholder 'esb.endpoint' in string value "${esb.endpoint}"; nested exception 
is java.lang.IllegalArgumentException: Could not resolve placeholder 'esb.endpoint' in 
string value "${esb.endpoint}"

Am I doing anything wrong here?

Vihar
  • 3,626
  • 2
  • 24
  • 47
Nagendra Singh
  • 61
  • 1
  • 11

1 Answers1

0

It is quite evident that spring is unable to find the properties file easiest way is to see the configuration of properties file

my way is to do it like this:

<context:property-placeholder location="required.properties" />

for this you will need to add following in your spring namespace

xmlns:context="http://www.springframework.org/schema/context"
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.2.xsd

hope it helps,

Good luck!

Vihar
  • 3,626
  • 2
  • 24
  • 47