Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

geonetwork: not overriding as intended? #87

Open
severo opened this issue Nov 30, 2018 · 0 comments
Open

geonetwork: not overriding as intended? #87

severo opened this issue Nov 30, 2018 · 0 comments
Assignees
Labels

Comments

@severo
Copy link
Contributor

severo commented Nov 30, 2018

In config-security-georchestra.xml, we have:

<ctx:property-override location="WEB-INF/config-security/config-security-overrides.properties" order="2"/>
<ctx:property-override location="file:${georchestra.datadir}/geonetwork/geonetwork-security-overrides.properties" order="1" ignore-resource-not-found="true" />
<!-- using the one from the geOrchestra datadir first (if available) -->
<ctx:property-placeholder location="file:${georchestra.datadir}/geonetwork/geonetwork.properties" ignore-resource-not-found="true" ignore-unresolvable="true" order="1"/>

and the comments seem to mean that file:${georchestra.datadir}/geonetwork/geonetwork.properties would be the file of highest priority to override the beans properties.

But the property-placeholder tag used is not intended for that, it only provides the XML Spring configuration file with values for the placeholders. Meanwhile, the property-override tag used in the previous two lines is intended to directly replace the properties of bean, without using a placeholder. To do that, the properties inside the file:${georchestra.datadir}/geonetwork/geonetwork-security-overrides.properties file, for example, explicitly mention the bean to be modified (see , it will replace the mapping[name] property inside the ldapUserContextMapper bean).

I don't know if it's the expected behavior, but clearly, the file:${georchestra.datadir}/geonetwork/geonetwork.properties file shouldn't be used with the property-override tag, since the format of the strings is different between the "placeholder" and the "override" properties files.

Note that it's somewhat related to georchestra/georchestra#2123.

@severo severo changed the title geonetwork: not overriding as intended geonetwork: not overriding as intended? Nov 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants