Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Use entrySet() instead of keySet()+get() in WARCSpout and Solr IndexerBolt

Closed Beginner friendly
#2,264 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

@GitMehdi-sys is already working on this.

Since Oct 25, 2026.

  • #2265 by @GitMehdi-sys — merged

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
82/100
Issue type
Refactor
Clarity
Clearly specified
Activity status
Active
Tech stack
java
Domain
backend

Research direction

Inspect external/warc/.../WARCSpout.java in open() and external/solr/.../bolt/IndexerBolt.java in execute(). Find the loops that iterate keySet() and call get() for each key, then check how each loop uses the map values. Done when both loops use entrySet() and the existing behavior is unchanged.

Written by the indexing model from the issue text.

Description

SpotBugs reports WMI_WRONG_MAP_ITERATOR in two places, where the code
iterates keySet() and then calls get() for each key:

  • external/warc/.../WARCSpout.java (open(), reading the HDFS config map)
  • external/solr/.../bolt/IndexerBolt.java (execute(), iterating metadata)

Iterating entrySet() avoids the extra lookup per entry. The change has no
behavior impact. Would you accept a small PR for this? Happy to do it.

Dominant language
Java
Stars
1k
Forks
295
Avg merge
1d 14h
Merged PRs (30d)
62

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from apache/stormcrawler

All issues in apache/stormcrawler

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.