[
https://issues.apache.org/jira/browse/SOLR-12386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16488164#comment-16488164
]
Hoss Man commented on SOLR-12386:
---------------------------------
bq. Unfortunately there is no Class#getResources(), it's only on classloader.
Why does that matter? Doesn't {{Class.getResourceAsStream()}} just call
{{Class.getClassLoader().getResourceAsStream()}} ? we could still replace it
with a helper utility like you're describing by passing
{{Class.getClassLoader()}}
bq. But we should fix the underlying issue (the leaks first), then think about
improving that situation.
My point before is that there may not actually *be* a leak -- it may very well
be that all streams are getting closed properly, but that some tests are
opening just enough resources that (depending on what other tests ran in the
same JVM and what classes got loaded) they are hitting the ulimit for open
files -- but instead of a clear error to that effect, we're getting "null" from
{{getResourceAsStream()}}
ie: i agree with you that if there is a file handle leak we should fix it, but
that is an indepenent possibility from the fact that we can/should "fix" the
code we have which opens Resources to better report/propogate when we hit
'IOException: Too many open files' under the covers so people aren't baffled
and confused by "Can't find resource" for files that definitely exist.
> Test fails for "Can't find resource" for files in the _default configset
> ------------------------------------------------------------------------
>
> Key: SOLR-12386
> URL: https://issues.apache.org/jira/browse/SOLR-12386
> Project: Solr
> Issue Type: Test
> Security Level: Public(Default Security Level. Issues are Public)
> Components: SolrCloud
> Reporter: David Smiley
> Priority: Minor
> Attachments: cant find resource, stacktrace.txt
>
>
> Some tests, especially ConcurrentCreateRoutedAliasTest, have failed
> sporadically failed with the message "Can't find resource" pertaining to a
> file that is in the default ConfigSet yet mysteriously can't be found. This
> happens when a collection is being created that ultimately fails for this
> reason.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]