camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ben O'Day" <ben.o...@initekconsulting.com>
Subject Re: JPA DB Connection Properties
Date Tue, 25 Jan 2011 18:29:10 GMT
Claudio, you can use the "jpaProperties" and Spring property-placeholder to
do this...

    <ctx:property-placeholder ignore-unresolvable="true"
location="classpath:context.properties"/>

    <bean id="entityManagerFactory"
class="org.springframework.orm.jpa.LocalEntityManagerFactoryBean">
        <property name="persistenceUnitName" value="camel"/>
        <property name="jpaProperties">
            <props>
                <prop key="openjpa.ConnectionURL">${openjpa.url}</prop>
            </props>
        </property>
    </bean>

Ben


On Tue, Jan 25, 2011 at 8:12 AM, davsclaus <cib_rejse@yahoo.dk> wrote:

>
> I think this is a general question how to do this with JPA. How to use
> property placeholders in the persistence.xml file. Its not Camel specific.
>
> I think you should google and ask at JPA community how to do that.
>
> If you find a solution then please keep us posted. As others may see this
> question and would like to find a solution as well.
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/JPA-DB-Connection-Properties-tp3355378p3356539.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message