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

Include response in the exception of an invalid routing response #764

Closed
SimonBradley1993 opened this issue Aug 25, 2022 · 1 comment
Closed

Comments

@SimonBradley1993
Copy link
Contributor

Recently my team had issues with our optimisation process using Vroom and OSRM. After some investigation it turned out that our infrastructure was timing out a request that Vroom makes to OSRM - which took longer than the default 15 seconds.

To identify this root cause we modified Vroom to include the actual response that was received.

It would be really great to have this change included so we can continue to use the tagged version of Vroom.

The changes that were needed were in http_wrapper.cpp with the following code block :

// Removing headers.
  auto start = response.find("{");
  if (start == std::string::npos) {
    throw RoutingException("Invalid routing response: " + response);
  }
  auto end = response.rfind("}");
  if (end == std::string::npos) {
    throw RoutingException("Invalid routing response: " + response);
  }
@jcoupey
Copy link
Collaborator

jcoupey commented Aug 30, 2022

Done in #765.

@jcoupey jcoupey closed this as completed Aug 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants