Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JSON support for changeset upload #407

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mmd-osm
Copy link
Collaborator

@mmd-osm mmd-osm commented May 25, 2024

Back in openstreetmap/openstreetmap-website#3501 we've talked about adding JSON support for a few remaining endpoints. Unfortunately, this project never took off. Why not give it another try now.

I found a streaming json parser based on yajl called sjparser, that has schema support. It offers a much saner interface than yajl alone, and emits one OSM element at a time. It also hides all that ugly state handling, unlike the XML parser we have in place today.

  • Define new format specifications for JSON based messages:
    • /api/0.6/changeset/nnn/upload
      • Input: OSMChange, based on OSM JSON format -> some examples in test_parse_osmchange_json_input.cpp
      • Output: diffResult: TODO

There are a few other changeset related endpoints (create / update) that don't support JSON. This can be addressed in another PR. Single object edit operations will continue be out of scope for this repo.

@mmd-osm mmd-osm force-pushed the feature/jsonparser branch 4 times, most recently from c597dda to 39a4eec Compare May 28, 2024 05:45
@mmd-osm
Copy link
Collaborator Author

mmd-osm commented May 28, 2024

@mmd-osm mmd-osm force-pushed the feature/jsonparser branch 4 times, most recently from 2d85c4e to 4ae0d45 Compare May 30, 2024 16:54
@mmd-osm
Copy link
Collaborator Author

mmd-osm commented May 30, 2024

json_upload

@mmd-osm mmd-osm marked this pull request as ready for review June 30, 2024 09:05
@mmd-osm mmd-osm mentioned this pull request Jul 6, 2024
@mmd-osm mmd-osm force-pushed the feature/jsonparser branch 2 times, most recently from 4a84bcc to b6b9c52 Compare July 7, 2024 19:34
@mmd-osm mmd-osm force-pushed the feature/jsonparser branch 3 times, most recently from 48089f5 to 6cd7819 Compare July 28, 2024 17:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant