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

Refactor to allow for additional HTTP headers #353

Closed
cosmocracy opened this issue Mar 31, 2017 · 1 comment
Closed

Refactor to allow for additional HTTP headers #353

cosmocracy opened this issue Mar 31, 2017 · 1 comment

Comments

@cosmocracy
Copy link

cosmocracy commented Mar 31, 2017

For new/experimental functionality, the GitHub API requires the submission of an additional header to enable features (see, for example, the API documentation note below related to the new Topics attributes):

image

Currently while the HTTP mechanisms are well-factored, they are only plugable via changes to the source code of this library. To ease extensibility (and meet the needs of additional headers), please consider either:

  • Implementing a Factory-style improvement that would allow for us to provide a Requester that could, for examlpe include the headers within the implementation of buildRequest, or
  • Provide a pathway for injecting headers into the Requester's headers property, possibly via a static-level "DefaultHeaders" that is publicly available.
@kohsuke
Copy link
Collaborator

kohsuke commented Sep 9, 2017

I don't understand the motivation for this. This library has no "extensibility" in the sense of defining additional API (like "topics" in your example) outside. The only way to do so is to change the source code of this library.

@kohsuke kohsuke closed this as completed Sep 9, 2017
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

No branches or pull requests

2 participants