Skip to content

Wrappers refactoring - #1373

Merged
jcoupey merged 0 commit into
masterfrom
refactoring/wrapper-refactoring
Nov 17, 2026
Merged

jcoupey merged 0 commit into
masterfrom
refactoring/wrapper-refactoring

Conversation

@lleuthar

@lleuthar lleuthar commented Nov 17, 2026 •

Copy link
Copy Markdown
Collaborator

Issue

Refactoring the wrappers that allow HTTP requests to be sent to the following services:

  • OSRM
  • ORS
  • Valhalla
  • OSRM POST API

Related to #1372

Tasks

  • Added the OsrmRoutedWrapper class, which is the parent class of OsrmGetWrapper and OsrmPostWrapper. This class groups together the features common to the OSRM classes. The OsrmGetWrapper and OsrmPostWrapper classes represent the implementations for the GET and POST methods.
  • Refactored the ORS and Valhalla wrappers, which previously built JSON natively using strings. Now, JSON is built using RapidJSON and then converted to a string. This change results in a minimal delay when preparing requests for sending, but greatly improves code readability.
  • Changes to the changelog.

Checklist

  • 🟢 No AI usage: written by humans, for humans
  • 🟡 AI-assisted: AI helped with the coding, but I understand every line
  • 🔴 AI-generated: AI did everything, review with caution

Comment thread src/structures/typedefs.h Resolved
Comment thread src/routing/osrm_routed_wrapper.h Resolved
Comment thread src/routing/ors_wrapper.cpp Resolved
Comment thread CHANGELOG.md Resolved
@lleuthar lleuthar self-assigned this Nov 17, 2026
@jcoupey jcoupey added this to the v1.16.0 milestone Nov 17, 2026
@jcoupey
jcoupey merged commit 877c2dd into master Nov 17, 2026
4 checks passed
@jcoupey
jcoupey deleted the refactoring/wrapper-refactoring branch November 17, 2026 16:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants