(fixed description - was in "enviornment" by mistake)
Part of the issue here is that "No stored data found for..." message is actually fairly important it most cases – if you are actively using managed resources (for something like managed synonyms) this WARN log type message is the only thing that will help you catch a possible situation where the storage file got deleted out from under you inadvertantly.
This is really very similar to the way we currently log a warning on startup if there is not "index" directory – it's an exceptional enough situation that we want to warn you about it so that you can find it in your logs later if things aren't working as you expect – but as soon as we log that warning we continue with the assumption that it's expected and we should automatically create it for you
The right solution here is probably:
- Anytime ManageResource sees that no storage exists for something it's managing, it should immediately create an "empty" storage for it and log a WARN along the lines of "No stored data found for /rest/foo/bar/yak .... creating new empty storage"
- This will mean that as people upgrade from old versions of solr to new versions of solr, they get this WARN exactly once for /rest/managed as the new (empty file is created)
- If/when people add new managed analysis factories to their schema.xml, they will likewise get a WARN once as empty storage files are created (even if they restart several times before they PUT any stopwords/synonyms into these managed resources)
- In our example configs, just like we ship pre-populated _schema_analysis_stopwords_english.json and _schema_analysis_synonyms_english.json files, we should ship a "pre-populated" (ie: empty) _rest_managed.json file
- which would ensure that no new user, who starts fresh with the "current" example configs, ever sees a warning about "No stored data found for /rest/managed"
The "No registered observers for..." message seems like something that has no business being a WARN, and should be switched to DEBUG or INFO – but i may just be missunderstanding the purpose of that message.