SOLR-5009 and SOLR-4948: I fixed almost all places where Solr creates SolrResourceLoaders lazily. Solr should only create a SolrResourceLoader when the CoreContainer starts up and when a new Core is created (as a child SolrResourceLoader). There are already issues open to fix the hierarchy, but this issue is about corrcetly closing the SolrResourceLoader, as this is mandatory for correct class unloading and freeing up system resources, including closing JAR files (to be able to delete them on windows).
SolrCore currently does not close its own SolrResourceLoader and the logic for reopening is un-understandable to me. In addition the SolrResourceLoader is shared by the config and the core and sometimes also the reopened core. I have no idea when it can be closed safely.