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

feat: Add topojson graph export rebase #1926

Merged
merged 26 commits into from
Dec 16, 2024
Merged

Conversation

MichaelsJP
Copy link
Member

@MichaelsJP MichaelsJP commented Dec 4, 2024

Pull Request Checklist

  • 1. I have [rebased][rebase] the latest version of the main branch into my feature branch and all conflicts
    have been resolved.
  • 2. I have added information about the change/addition to functionality to the CHANGELOG.md file under the
    [Unreleased] heading.
  • 3. I have documented my code using JDocs tags.
  • 4. I have removed unnecessary commented out code, imports and System.out.println statements.
  • 5. I have written JUnit tests for any new methods/classes and ensured that they pass.
  • 6. I have created API tests for any new functionality exposed to the API.
  • 7. If changes/additions are made to the ors-config.json file, I have added these to the [ors config documentation][config]
    along with a short description of what it is for, and documented this in the Pull Request (below).
  • 8. I have built graphs with my code of the Heidelberg.osm.gz file and run the api-tests with all test passing
  • 9. I have referenced the Issue Number in the Pull Request (if the changes were from an issue).
  • 10. For new features or changes involving building of graphs, I have tested on a larger dataset
    (at least Germany), and the graphs build without problems (i.e. no out-of-memory errors).
  • 11. For new features or changes involving the graphbuilding process (i.e. changing encoders, updating the
    importer etc.), I have generated longer distance routes for the affected profiles with different options
    (avoid features, max weight etc.) and compared these with the routes of the same parameters and start/end
    points generated from the current live ORS.
    If there are differences then the reasoning for these MUST be documented in the pull request.
  • 12. I have written in the Pull Request information about the changes made including their intended usage
    and why the change was needed.
  • 13. For changes touching the API documentation, I have tested that the API playground [renders correctly][api].

Information about the changes

  • Key functionality added:
    TopoJSON response type on the export endpoint. Returns a TopoJSON representation of the graph within a given bounding box containing the ORS edges and nodes, OSM ways with ID, a flag is passable both ways, speeds and distances.

@MichaelsJP MichaelsJP force-pushed the feat/add-topojson-graph-export-rebase branch from 807ea6d to aff6244 Compare December 4, 2024 21:06
@takb takb requested review from koebi and sfendrich December 10, 2024 10:55
@github-actions github-actions bot added feature and removed feature labels Dec 10, 2024
Copy link
Contributor

@sfendrich sfendrich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@github-actions github-actions bot added feature and removed feature labels Dec 10, 2024
@takb takb marked this pull request as ready for review December 10, 2024 11:04
@github-actions github-actions bot added feature and removed feature labels Dec 10, 2024
@takb takb force-pushed the feat/add-topojson-graph-export-rebase branch from e60e4aa to 9b7530f Compare December 10, 2024 13:52
@takb takb requested review from sfendrich and koebi December 10, 2024 16:12
@github-actions github-actions bot added feature and removed feature labels Dec 10, 2024
@takb takb force-pushed the feat/add-topojson-graph-export-rebase branch from 2b1cfa4 to 3f8ad0d Compare December 10, 2024 16:17
@Chwiggy Chwiggy linked an issue Dec 12, 2024 that may be closed by this pull request
@takb takb requested a review from sfendrich December 12, 2024 14:08
@github-actions github-actions bot added feature and removed feature labels Dec 12, 2024
Copy link
Contributor

@sfendrich sfendrich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you!

Chwiggy and others added 23 commits December 16, 2024 10:41
includes pingtests in various permutations of faulty and correct input
Let's not add Lombok to existing classes. Only new ones for now. Hence, this fiel gets a typical setter.
Before the "coordinates" keyword was still serialized wrongly into the topojson structure creating a wrong arcs structure.
Reduce unnecessary duplication and streamline the export serialization with e.g. JsonExportResponse. The only difference is that it doesn't extent the ExportResponse. This is also not necessary. ExportResponse holds no value for the TopoJson export.
Layers is not necessary. It can be represented by a HashMap of layers where the key is the layer name. In our case "network".
… properties replacing weight with speed/distance, fallback for cases where OSM ids are not available, using OSM way geometries (with option to turn off and get only node coordinates (beeline graph) instead)
@Chwiggy Chwiggy force-pushed the feat/add-topojson-graph-export-rebase branch from 96ea04e to 69b0efb Compare December 16, 2024 09:42
@takb takb merged commit d21f124 into main Dec 16, 2024
27 checks passed
@takb takb deleted the feat/add-topojson-graph-export-rebase branch December 16, 2024 10:33
@takb takb restored the feat/add-topojson-graph-export-rebase branch December 16, 2024 10:35
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.

Add merge strategy for duplicate geometries
5 participants