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

Send User-Agent #412

Merged
merged 4 commits into from
Jun 30, 2017
Merged

Send User-Agent #412

merged 4 commits into from
Jun 30, 2017

Conversation

sarahsnow1
Copy link
Member

Overview

This updates MapzenMap, MapzenSearch, and MapzenRouter to use a new base implementation of GenericHttpHandler to send a custom User-Agent for all requests. The User-Agent is in the format <sdk_name>;<sdk_version>;<os_version>. So for example, android-sdk;1.4.1-SNAPSHOT;7.1.2. It also begins work to simplify & standardize how developers customize query parameters and headers sent for requests.

Proposed Changes

  • Introduces GenericHttpHandler interface to standardize how implementing developers customize requests (future work will expand this interface Expand GenericHttpHandler #410, Allow setting GenericHttpHandler on Mapzen API objects #411). Currently developers need to access the underlying Pelias/Tangram/Valhalla API object and set a subclass of that object's http handler. Each object has a slightly different api which is less than ideal
  • Adds TmpHttpHandler to allow setting headers in tile requests (will be removed when related Tangram work is completed Remove TmpHttpHandler #409)
  • Possible future work could also provide the ability to use a single GenericHttpHandler for all MapzenMap, MapzenSearch, and MapzenRouter APIs

Closes #382

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.

1 participant