[
https://issues.apache.org/jira/browse/NUTCH-3111?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17986564#comment-17986564
]
Sebastian Nagel commented on NUTCH-3111:
----------------------------------------
Hi [~xcxr], thanks! Let us know if you need support regarding code formatting.
There is an [Eclipse code format
definition|https://github.com/apache/nutch/blob/master/eclipse-codeformat.xml].
> Fix some potential resource leak
> --------------------------------
>
> Key: NUTCH-3111
> URL: https://issues.apache.org/jira/browse/NUTCH-3111
> Project: Nutch
> Issue Type: Improvement
> Components: plugin, tool, util
> Affects Versions: 1.20
> Reporter: Chengxin Xu
> Priority: Major
> Fix For: 1.20
>
>
> I found some resources that were not properly handled(never closed/possibly
> can not reach), and using try-with stmt to fix them
> src/java/org/apache/nutch/tools/ResolveUrls.java#
> resolveUrls
> src/java/org/apache/nutch/util/EncodingDetector.java#
> main
> src/java/org/apache/nutch/util/GZIPUtils.java#
> unzip
> src/plugin/scoring-similarity/src/java/org/apache/nutch/scoring/similarity/cosine/Model.java#
> createModel
> src/plugin/subcollection/src/java/org/apache/nutch/collection/CollectionManager.java#
> save
--
This message was sent by Atlassian Jira
(v8.20.10#820010)