# ResourceMap keys

**URL:** <https://openturns.discourse.group/t/resourcemap-keys/323>\
**Category:** Development\
**Created:** [October 24, 2023, 10:21am UTC](https://openturns.discourse.group/t/resourcemap-keys/323 "2023-10-24T10:21:21Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![MichaelBaudin](https://yyz2.discourse-cdn.com/free1/user_avatar/openturns.discourse.group/michaelbaudin/32/9_2.png) [@MichaelBaudin](https://openturns.discourse.group/u/MichaelBaudin)\
**Post date:** [October 24, 2023, 10:21am UTC](https://openturns.discourse.group/t/resourcemap-keys/323/1 "2023-10-24T10:21:21Z")

</div>

Hi!  
When we update (or create or remove) a new `ResourceMap` key, we have to change 2 different files:

- [openturns.conf.in](https://github.com/openturns/openturns/blob/master/lib/etc/openturns.conf.in)
- [ResourceMap.cxx](https://github.com/openturns/openturns/blob/b87964f772baa184fd447de16d4de7024da69815/lib/src/Base/Common/ResourceMap.cxx)

For example, the key “SmolyakExperiment-MergeRelativeEpsilon” is defined in 2 different files:

- [openturns.conf.in#L823](https://github.com/openturns/openturns/blob/b87964f772baa184fd447de16d4de7024da69815/lib/etc/openturns.conf.in#L823)
- [ResourceMap.cxx#L1636](https://github.com/openturns/openturns/blob/b87964f772baa184fd447de16d4de7024da69815/lib/src/Base/Common/ResourceMap.cxx#L1636C29-L1636C29)

This might produce bugs, e.g. if we use different strings in the files.

Why are there duplicate key references ? Is is possible to make so that a single file manages all features?

Best regards,

Michaël

---

<div class="post-metadata">

**Author:** ![schueller](https://yyz2.discourse-cdn.com/free1/user_avatar/openturns.discourse.group/schueller/32/3_2.png) [@schueller](https://openturns.discourse.group/u/schueller)\
**Post date:** [October 25, 2023, 8:57am UTC](https://openturns.discourse.group/t/resourcemap-keys/323/2 "2023-10-25T08:57:02Z")

</div>

when openturns is loaded it initializes keys from ResourceMap.cxx, then reads openturns.conf that allows to override some of these keys  
openturns.conf could be automatically generated from the defaults in ResourceMap.cxx,  
but it has to be still possible even when cross-compiling
