properties files priority?

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

properties files priority?

bjohnson
I'm a little confused about how these properties files work, and how the
properties are named.

Is there a precedence to these properties files?  i.e. if I see a property
in the properties-form-runner.xml and have the same property in
properties-local.xml, does properties-local always override the one from the
properties-form-runner.xml file?

Is it a full override or more of an "AND" or some other logical evaluation?

Is there a way to determine what properties can be overridden in
properties-local.xml and which ones cannot?

I've noticed that some properties in properties-local.xml are parsed/enabled
as soon as the file is saved and the users's browser is refreshed.  Some
require a restart of the service.  Is there a way to determine which ones
work which way?

I see properties-form-runner.xml in the installed .war compressed file.
Does having another version of that file in the install folder
(uncompressed) override any or all of the properties in the .war?  Will it
only override properties that exist in the file and leave the others intact,
or do i need to include all properties from properties-form-runner.xml in
the uncompressed version of the file?

Thanks.

--
Sent from: http://discuss.orbeon.com/

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/orbeon/1572372491355-0.post%40n4.nabble.com.
Reply | Threaded
Open this post in threaded view
|

Re: properties files priority?

Alessandro  Vernet
Administrator
Hi,

Properties in your `properties-local.xml` override the default values of
properties (e.g. in `properties-form-runner.xml`,
`properties-form-builder.xml`, etc). Also, with properties accepting
wildcards (`*`), more specific properties override less specific properties
(see 1st link below). You can override all properties in
`properties-local.xml`, even if we don't recommend you override properties
defined in `properties-internal.xml`. In general, you don't need to restart
your server for properties to be taken into account. There are very few
exceptions to this rule, and the only one that comes to mind is properties
used to override resources (see 2nd link below). Finally, you can override
entire files: if you have the same path/file in multiple resources
locations, the one with the lowest priority as defined with the
`oxf.resources.priority` parameters in your `web.xml` (or with Tomcat a
`<Parameter>` inside the `<Context>`) will take precedence. Does this answer
your questions?

https://doc.orbeon.com/configuration/properties/#wildcards-in-properties
https://doc.orbeon.com/configuration/properties/form-runner#overriding-resources

‑Alex

-----
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
--
Sent from: http://discuss.orbeon.com/

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/orbeon/1572545475426-0.post%40n4.nabble.com.
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
Reply | Threaded
Open this post in threaded view
|

Re: properties files priority?

bjohnson
YES!  Thank you for explaining this, Alex.  It's good to know we can override
any property from properties-local.xml.  I had tried to override properties
by duplicating the other properties files in my installation and it wasn't
working.  Maybe I wasn't duplicating the same path.

--
Sent from: http://discuss.orbeon.com/

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/orbeon/1572550235990-0.post%40n4.nabble.com.
Reply | Threaded
Open this post in threaded view
|

Re: properties files priority?

Alessandro  Vernet
Administrator
Perfect, I'm glad that helped. And it's really better to just override
resources in the `properties-local.xml`, as this will make upgrading easier
for you in the future.

‑Alex

-----
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
--
Sent from: http://discuss.orbeon.com/

--
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/orbeon/1572561834208-0.post%40n4.nabble.com.
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet