[icedtea-web] RFC: Reduce URLConnection knowledge in CacheEntry

Andrew Azores aazores at redhat.com
Fri May 2 18:53:30 UTC 2014


On 05/02/2014 01:23 PM, Omair Majid wrote:
> Hi,
>
> I had to work on CacheEntry for a few fixes (I will be posting those
> later) and the class seems to be doing a bit too much. The knowledge of
> URLConnection is especially troubling, since the metadata for a
> CacheEntry doesn't really match the URL in the presence of compression.
>
> The attached patch tries to reduce how much CacheEntry knows about
> URLConnection.
>
> Okay to push?
>
> Thanks,
> Omair
>

Looks good. One nit: should #getLongKey() return 0 on exception? 0 may 
actually be a valid result. Perhaps -1 instead, since this is being 
refactored anyway? And please consider logging the exception as well.

Thanks,

-- 
Andrew A



More information about the distro-pkg-dev mailing list