You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Dan Tran (JIRA)" <de...@myfaces.apache.org> on 2007/08/11 02:31:42 UTC
[jira] Created: (ORCHESTRA-3) PropertyPlaceholderConfigurer STOPS
working after the introduction of orchestra into my configuration
PropertyPlaceholderConfigurer STOPS working after the introduction of orchestra into my configuration
------------------------------------------------------------------------------------------------------
Key: ORCHESTRA-3
URL: https://issues.apache.org/jira/browse/ORCHESTRA-3
Project: MyFaces Orchestra
Issue Type: Bug
Components: Conversation
Environment: xp, spring 2.0.6, jsf-1.2 ri
Reporter: Dan Tran
Here is my configuration, any thoughts? or can some one confirm this?
<!-- Configurer that replaces ${...} placeholders with values from a properties file -->
<!-- (in this case, JDBC-related settings for the dataSource definition below) -->
<!-- THIS STOPS WORKING SINCE INTRODUCTION OF ORCHESTRA BEANS -->
<bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="location" value="/WEB-INF/jdbc-hsqldb.properties"/>
</bean>
<!-- EL expression is not translated -->
<bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource">
<property name="driverClassName" value="${jdbc.driverClassName}"/>
<property name="url" value="${jdbc.url}"/>
<property name="username" value="${jdbc.username}"/>
<property name="password" value="${jdbc.password}"/>
</bean>
The error is
Caused by: org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC driver class '${jdbc.driverClassName}'
It is producable using orchestra example
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (ORCHESTRA-3) PropertyPlaceholderConfigurer STOPS
working after the introduction of orchestra into my configuration
Posted by "Mario Ivankovits (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/ORCHESTRA-3?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mario Ivankovits resolved ORCHESTRA-3.
--------------------------------------
Resolution: Fixed
Assignee: Mario Ivankovits
According to the spring forum thread aop:scoped-proxy IS a way to go. So I'll leave it that way. FAQ needs to be created.
> PropertyPlaceholderConfigurer STOPS working after the introduction of orchestra into my configuration
> ------------------------------------------------------------------------------------------------------
>
> Key: ORCHESTRA-3
> URL: https://issues.apache.org/jira/browse/ORCHESTRA-3
> Project: MyFaces Orchestra
> Issue Type: Bug
> Components: Conversation
> Environment: xp, spring 2.0.6, jsf-1.2 ri
> Reporter: Dan Tran
> Assignee: Mario Ivankovits
>
> Here is my configuration, any thoughts? or can some one confirm this?
> <!-- Configurer that replaces ${...} placeholders with values from a properties file -->
> <!-- (in this case, JDBC-related settings for the dataSource definition below) -->
> <!-- THIS STOPS WORKING SINCE INTRODUCTION OF ORCHESTRA BEANS -->
>
> <bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
> <property name="location" value="/WEB-INF/jdbc-hsqldb.properties"/>
> </bean>
> <!-- EL expression is not translated -->
> <bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource">
> <property name="driverClassName" value="${jdbc.driverClassName}"/>
> <property name="url" value="${jdbc.url}"/>
> <property name="username" value="${jdbc.username}"/>
> <property name="password" value="${jdbc.password}"/>
> </bean>
> The error is
> Caused by: org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC driver class '${jdbc.driverClassName}'
> It is producable using orchestra example
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (ORCHESTRA-3) PropertyPlaceholderConfigurer STOPS
working after the introduction of orchestra into my configuration
Posted by "Mario Ivankovits (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/ORCHESTRA-3?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12519214 ]
Mario Ivankovits commented on ORCHESTRA-3:
------------------------------------------
This looks like a bug in spring.
The problem is, that org.springframework.orm.jpa.AbstractEntityManagerFactoryBean implements the method afterPropertiesSet() which will be called before the PropertyPlaceholderConfigurer was able to do its job.
I think the AbstractEntityManagerFactoryBean should implement the BeanFactoryPostProcessor instead so that one can make use of the ordered attribute.
I'll raise this on the spring ml.
> PropertyPlaceholderConfigurer STOPS working after the introduction of orchestra into my configuration
> ------------------------------------------------------------------------------------------------------
>
> Key: ORCHESTRA-3
> URL: https://issues.apache.org/jira/browse/ORCHESTRA-3
> Project: MyFaces Orchestra
> Issue Type: Bug
> Components: Conversation
> Environment: xp, spring 2.0.6, jsf-1.2 ri
> Reporter: Dan Tran
>
> Here is my configuration, any thoughts? or can some one confirm this?
> <!-- Configurer that replaces ${...} placeholders with values from a properties file -->
> <!-- (in this case, JDBC-related settings for the dataSource definition below) -->
> <!-- THIS STOPS WORKING SINCE INTRODUCTION OF ORCHESTRA BEANS -->
>
> <bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
> <property name="location" value="/WEB-INF/jdbc-hsqldb.properties"/>
> </bean>
> <!-- EL expression is not translated -->
> <bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource">
> <property name="driverClassName" value="${jdbc.driverClassName}"/>
> <property name="url" value="${jdbc.url}"/>
> <property name="username" value="${jdbc.username}"/>
> <property name="password" value="${jdbc.password}"/>
> </bean>
> The error is
> Caused by: org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC driver class '${jdbc.driverClassName}'
> It is producable using orchestra example
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (ORCHESTRA-3) PropertyPlaceholderConfigurer STOPS
working after the introduction of orchestra into my configuration
Posted by "Mario Ivankovits (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/ORCHESTRA-3?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12519215 ]
Mario Ivankovits commented on ORCHESTRA-3:
------------------------------------------
http://forum.springframework.org/showthread.php?t=42549
> PropertyPlaceholderConfigurer STOPS working after the introduction of orchestra into my configuration
> ------------------------------------------------------------------------------------------------------
>
> Key: ORCHESTRA-3
> URL: https://issues.apache.org/jira/browse/ORCHESTRA-3
> Project: MyFaces Orchestra
> Issue Type: Bug
> Components: Conversation
> Environment: xp, spring 2.0.6, jsf-1.2 ri
> Reporter: Dan Tran
>
> Here is my configuration, any thoughts? or can some one confirm this?
> <!-- Configurer that replaces ${...} placeholders with values from a properties file -->
> <!-- (in this case, JDBC-related settings for the dataSource definition below) -->
> <!-- THIS STOPS WORKING SINCE INTRODUCTION OF ORCHESTRA BEANS -->
>
> <bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
> <property name="location" value="/WEB-INF/jdbc-hsqldb.properties"/>
> </bean>
> <!-- EL expression is not translated -->
> <bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource">
> <property name="driverClassName" value="${jdbc.driverClassName}"/>
> <property name="url" value="${jdbc.url}"/>
> <property name="username" value="${jdbc.username}"/>
> <property name="password" value="${jdbc.password}"/>
> </bean>
> The error is
> Caused by: org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC driver class '${jdbc.driverClassName}'
> It is producable using orchestra example
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (ORCHESTRA-3) PropertyPlaceholderConfigurer STOPS
working after the introduction of orchestra into my configuration
Posted by "Mario Ivankovits (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/ORCHESTRA-3?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12519241 ]
Mario Ivankovits commented on ORCHESTRA-3:
------------------------------------------
During debugging the situation I found a workaround you can try.
Add the aop:scoped-proxy to the "persistentContextConversationInterceptor" bean. It should look like the following then:
<bean id="persistentContextConversationInterceptor"
class="org.apache.myfaces.orchestra.conversation.spring.PersistenceContextConversationInterceptor">
<aop:scoped-proxy/>
<property name="persistenceContextFactory" ref="persistentContextFactory"/>
</bean>
Due to the aop:scoped-proxy configuration the initialization of the dataSource will happen on the first real request to the scope and thus happens after the spring property configuration replacement.
> PropertyPlaceholderConfigurer STOPS working after the introduction of orchestra into my configuration
> ------------------------------------------------------------------------------------------------------
>
> Key: ORCHESTRA-3
> URL: https://issues.apache.org/jira/browse/ORCHESTRA-3
> Project: MyFaces Orchestra
> Issue Type: Bug
> Components: Conversation
> Environment: xp, spring 2.0.6, jsf-1.2 ri
> Reporter: Dan Tran
>
> Here is my configuration, any thoughts? or can some one confirm this?
> <!-- Configurer that replaces ${...} placeholders with values from a properties file -->
> <!-- (in this case, JDBC-related settings for the dataSource definition below) -->
> <!-- THIS STOPS WORKING SINCE INTRODUCTION OF ORCHESTRA BEANS -->
>
> <bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
> <property name="location" value="/WEB-INF/jdbc-hsqldb.properties"/>
> </bean>
> <!-- EL expression is not translated -->
> <bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource">
> <property name="driverClassName" value="${jdbc.driverClassName}"/>
> <property name="url" value="${jdbc.url}"/>
> <property name="username" value="${jdbc.username}"/>
> <property name="password" value="${jdbc.password}"/>
> </bean>
> The error is
> Caused by: org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC driver class '${jdbc.driverClassName}'
> It is producable using orchestra example
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.