I'm still open to any comments or idea on this one. I did create PRs for
option 2 below for both master and the tomee-1.7.x branches.

Any feedback on those would also be most welcome.

Thanks

Jon

On Tue, Jul 25, 2017 at 10:56 AM, Jonathan Gallimore <
[email protected]> wrote:

> Hi
>
> We recently added support for controlling MDB endpoint activation using
> the MdbActiveOnStartup and MdbJMXControl deployment properties - so you'd
> add something like this to openejb-jar.xml:
>
>   <ejb-deployment ejb-name="MyEjb">
>     <properties>
>       MdbActiveOnStartup = true
>       MdbJMXControl = true
>     </properties>
>   </ejb-deployment>
>
> This works great, but the trouble is, you need to provide these properties
> for every single MDB, which if you have a lot of them, is a pain. For
> activation properties, we have the means to specify a setting using the
> mdb.activation.[property]=[value] system property, which will apply to
> all MDBs, unless those MDBs specify that activation property themselves. It
> would be great if this worked the same way.
>
> I'm wondering what the community thinks - I have a couple of ideas:
>
> 1. Allow EJB deployment properties to have overrides in the same way that
> activation properties do. This might mean adding similar logic
> to org.apache.openejb.config.BeanProperties from org.apache.openejb.
> config.ActivationConfigPropertyOverride (or add a new DynamicDeployer)
> 2. Change the MdbActiveOnStartup / MdbJMXControl feature to activation
> properties. These can still be specified in openejb-jar.xml:
>
>   <ejb-deployment ejb-name="MyEjb">
>     <properties>
>       activation.MdbActiveOnStartup = true
>       activation.MdbJMXControl = true
>     </properties>
>   </ejb-deployment>
>
> but would also allow the setting to be configured for all beans through
> the existing method:
>
> mdb.activation.MdbActiveOnStartup=true
> mdb.activation. MdbJMXControl =true
>
> Given that this config hasn't appeared in a released version yet, now
> might be a good time to change it.
>
> What do you think? I think I'm leaning towards option 2 at the moment. I'd
> appreciate any thoughts, or alternative ideas. I'm happy to propose the
> code change for review whichever way we go.
>
> Cheers
>
> Jon
>

Reply via email to