'Misuse' of Resource#getFile()

Cantor, Scott cantor.2 at osu.edu
Wed Dec 30 10:41:18 EST 2015


On 12/30/15, 5:59 AM, "dev on behalf of Rod Widdowson" <dev-bounces at shibboleth.net on behalf of rdw at steadingsoftware.com> wrote:



>Obviously these can be fixed topically in the IdP by calling either
>ByteStreams.toByteArray() or some equivalent for the String case.  But this
>mail is to ask whether we think it is worth extending the above three
>classes to take InputStreams?

I think generally speaking the answer is yes because a lot of the advanced solutions to configuration management tend to involve using things other than files.

>As a secondary question should these functions close their InputStream – a
>common paradigm appears to be that they should not, but I’d take guidance.

I don't know enough about the contracts involved with Resource.

-- Scott



More information about the dev mailing list