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

Split JtsSpatialContext etc. to separate module and 'jar'.

Open
#143 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
35/100
Issue type
Refactor
Clarity
Mostly clear
Activity status
Stale
Tech stack
java
Domain
build-system

Research direction

No files or tests are named. Start by locating JtsSpatialContext and the other JTS-using classes, then inspect how spatial4j.jar is built and packaged. Done means those classes can be shipped in a separate JTS-related jar while the core jar remains usable without the JTS dependency.

Written by the indexing model from the issue text.

Description

enhancement

I was bemoaning the inconvenience in Solr that the JTS jar file has to be placed in WEB-INF/lib instead of being placeable in more convenient places, like the 'lib' of the node or at a core level. Essentially, this is because spatial4j.jar is inside WEB-INF/lib which is loaded by a lower-level more internal classloader, and so it can only refer to things at its level or lower still.

If all the JTS using classes in Spatial4j were spun off into a separate jar, perhaps named spatial4j-jts-ctx.jar then that jar could go into a convenient lib dir as well as JTS, and it should work.

Another side benefit is that anyone fearing that Spatial4j is somehow tainted in that it refers to LGPL code (even though it's "optional") would be assuaged.

On the down side, especially for anyone without any classpath conundrums, this is yet another 'jar' file. I think it's worth it though.

Dominant language
Java
Stars
962
Forks
174
PR merge metrics
No merged PRs in 30d

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 locationtech/spatial4j

All issues in locationtech/spatial4j

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.