maplibre / maplibre/maplibre-java

Add support to serialize/deserialize from `Source`/`Sink`

Open
#41 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
21
Forks
15
PR merge metrics
No merged PRs in 30d

Description

As a follow-up to #40, no reason to expand the scope of that PR with this:

kotlinx-serialization-json-io supports deserialization from a Source and serialization to a Sink. These are the multiplatform equivalents to Java's InputStream and OutputStream, respectively.

Being able to directly serialize/deserialize to/from a stream of bytes (as served from a HTTP connection or reading a file) will improve speed and memory footprint when dealing with large GeoJsons because the step to first put it all into a string is omitted.

This could be offered as an additional optional dependency, because kotlinx-serialization-json-io pulls in another dependency, kotlinx-io.

Contributor guide

Open the contributing guide

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.

Research direction

The issue names no files or tests. Start by reviewing the serialization support from #40 and the dependency configuration, then trace how GeoJSON is currently converted through strings. Done means supporting Source and Sink-based serialization and deserialization, with any optional dependency configured appropriately.

Written by the indexing model from the issue text.

Assessment

Tech stack
kotlin
Domain
data
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.