On Mar 18, 2009, at 1:55 AM, Jean-Louis MONTEIRO wrote:

Something came to my mind.
As a useful feature, OpenEJB performs a lot of automatic actions (creating
queues, datasources, adapting datasources, ....) which is fine for
development and testing.

But it can be very dramatic when putting OpenEJB in production (the real
life ;-)).
From my point of view, it would be nice to add a property to disable such a
feature. In production, we must be sure the datasource used in the
persistence.xml file exists. If not, deployment must fail !

Do you agree ?

We have something which will do all the above except for preventing the persistence.xml datasource adapting. See the ConfigurationFactory 'offline' boolean. It does stop the part of the persistence.xml adjusting where datasources are created, but doesn't stop the adjusting where they were one or both were left blank and various things like that. We can certainly add it.

We don't have a flag to set it, mostly used by Geronimo right now. We can easily add one in the no-arg constructor of the ConfigurationFactory so it doesn't always default to offline false.

Not sure "production" is a good name as I think it's ultimately too subjective to be so prescriptive. Better just to name the flags after what they do in the most literal sense and let people decide which they want enabled.

Maybe something like openejb.configuration.strict ?

-David



Reply via email to