CDK-770: Improve resource cleanup for clients of SolrLocator