You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by hwaastad <he...@waastad.org> on 2016/05/27 06:39:28 UTC

tomee.xml resources and system properties

Hi,
I'm wondering about something.

It seems I can use system props in a jdbc resource in tomee.xml, but it
seems it's not working for jms resources.

eks
<Resource id="MyDS" type="DataSource">
        JdbcDriver      = com.microsoft.sqlserver.jdbc.SQLServerDriver
        JdbcUrl         = ${db.jdbc}
        UserName        = ${db.username}
        Password        = ${db.password}
        testOnBorrow    = true
        validationQuery = SELECT 1
        logSql          = true
    </Resource>

Is working fine, but:

<Resource id="MyResourceAdaptor" type="ActiveMQResourceAdapter">
        # Do not start the embedded ActiveMQ broker
        BrokerXmlConfig  =
        ServerUrl = tcp://activemq:61616
        Username = ${jms.user}
        Password = ${jms.password}
    </Resource>

is not.

Is this correct?

/hw



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/tomee-xml-resources-and-system-properties-tp4678627.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: tomee.xml resources and system properties

Posted by Romain Manni-Bucau <rm...@gmail.com>.
for some versions it was only supported for resources.xml and not tomee.xml
but <id>.<property> always has been supported.


Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com> | JavaEE Factory
<https://javaeefactory-rmannibucau.rhcloud.com>

2016-05-27 10:05 GMT+02:00 Jean-Louis Monteiro <jl...@tomitribe.com>:

> Hi,
>
> Yes, the property place holders replacement happens the same way as far as
> I can recall.
>
> JLouis
>
> --
> Jean-Louis Monteiro
> http://twitter.com/jlouismonteiro
> http://www.tomitribe.com
>
> On Fri, May 27, 2016 at 9:18 AM, hwaastad <he...@waastad.org> wrote:
>
> > Partially answering my own question:
> >
> > Better overrriding based on resourceid......
> >
> > /hw
> >
> >
> >
> > --
> > View this message in context:
> >
> http://tomee-openejb.979440.n4.nabble.com/tomee-xml-resources-and-system-properties-tp4678627p4678628.html
> > Sent from the TomEE Users mailing list archive at Nabble.com.
> >
>

Re: tomee.xml resources and system properties

Posted by Jean-Louis Monteiro <jl...@tomitribe.com>.
Hi,

Yes, the property place holders replacement happens the same way as far as
I can recall.

JLouis

--
Jean-Louis Monteiro
http://twitter.com/jlouismonteiro
http://www.tomitribe.com

On Fri, May 27, 2016 at 9:18 AM, hwaastad <he...@waastad.org> wrote:

> Partially answering my own question:
>
> Better overrriding based on resourceid......
>
> /hw
>
>
>
> --
> View this message in context:
> http://tomee-openejb.979440.n4.nabble.com/tomee-xml-resources-and-system-properties-tp4678627p4678628.html
> Sent from the TomEE Users mailing list archive at Nabble.com.
>

Re: tomee.xml resources and system properties

Posted by hwaastad <he...@waastad.org>.
Partially answering my own question:

Better overrriding based on resourceid......

/hw



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/tomee-xml-resources-and-system-properties-tp4678627p4678628.html
Sent from the TomEE Users mailing list archive at Nabble.com.