Page 1 of 1

issue integrating broadleaf, when running standalone

Posted: Sat Feb 18, 2012 10:05 pm
by sai
I tried to integrate my application in broadleaf. Right now running the site-war in standalone tomcat is generating the below error.

[ERROR] 21:44:51 DispatcherServlet - Context initialization failed
org.springframework.beans.factory.BeanDefinitionStoreException: Invalid bean definition with name 'blUploadUrlMapping' defined in class path resource [applicationContext-servlet-cms-contentClient.xml]: Could not resolve placeholder 'asset.server.url.prefix'
at org.springframework.beans.factory.config.PropertyPlaceholderConfigurer.processProperties(PropertyPlaceholderConfigurer.java:287)
at org.springframework.beans.factory.config.PropertyResourceConfigurer.postProcessBeanFactory(PropertyResourceConfigurer.java:75)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:663)
at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:638)

Any suggestion/advise is much appreciated.

Re: issue integrating broadleaf, when running standalone

Posted: Tue Feb 21, 2012 11:12 am
by jefffischer
What version of broadleaf are you referencing from your pom.xml files? You may need to add the following to your applicationContext-servlet.xml:

Code: Select all

<bean id="blConfiguration" class="org.broadleafcommerce.common.config.RuntimeEnvironmentPropertiesConfigurer">
      <property name="propertyLocations">
         <set>
            <value>classpath:config/bc/</value>
         </set>
      </property>
      <property name="environments">
         <set>
            <value>production</value>
            <value>staging</value>
            <value>integration</value>
            <value>development</value>
         </set>
      </property>
      <property name="defaultEnvironment" value="development"/>
      <property name="ignoreUnresolvablePlaceholders" value="true"/>
   </bean>