-
Notifications
You must be signed in to change notification settings - Fork 370
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
OkHttp3 #223
OkHttp3 #223
Conversation
@bitwiseman no need to upload plugin archives to Drive! And never hand out |
src/main/java/org/jenkinsci/plugins/github_branch_source/OkHttp3Connector.java
Outdated
Show resolved
Hide resolved
@jglick Yes, if the build weren't breaking the incremental-release would be what I'd use. But it is, so ... |
Well now it looks legit:
|
@jglick Legit on java9+. This is still an early alpha experiment. |
FWIW I would then just patch |
So, I don't think that was sufficient, although I think it was necessary. Dependencies and Class Loading suggests:
I think the lazy choice is the former, which appears to look like this: |
This PR is supposed to help fix JENKINS-54126 |
@jsoref |
aa94134
to
52a0b90
Compare
Most of the code that was in this change has been added to github-api and is tested in that library. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks ok to me...
a5c4f37
to
5bac543
Compare
e2163c3
to
a5716d0
Compare
ecde54c
to
f73096b
Compare
GitHubAppCredentials could not use the existing Connector.connect() and so created its own GithubBuilder. However, that means that is missing a number of standard settings provided by Connector.connect(), including okhttp, Jenkins proxy settings, and rate limit handling. This change refactors Connector to add an internal createGitHubBuilder() method that returns a GitHubBuilder with those features configured. For simplicity, The returned GitHubBuilder is not cached and also does not cache responses. If there turns out to be a need for it, that behavior can be added later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes look good, but there are some test failures that don't make sense to me:
java.lang.Error: Plugin github-api failed to start
...
Caused by: java.io.IOException: GitHub API Plugin version 1.111.4 failed to load.
- You must update Jenkins from version 2.164.1 to version 2.164.3 or later to run this plugin.
This plugin already depends on 2.164.3, same as GitHub API Plugin 1.111.4, so I'm not sure what's happening here.
@dwnusbaum It's the jenkinsfile build configurations. |
@timja I updated |
buildPlugin(configurations: [ | ||
[ platform: "linux", jdk: "8"], | ||
[ platform: "windows", jdk: "8"], | ||
[ platform: "linux", jdk: "11", jenkins: "2.176.4", javaLevel: "8" ] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any reason you aren’t testing a more recent lts here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Trying to keep things simple-ish in this PR.
Created https://issues.jenkins-ci.org/browse/JENKINS-62652 for "A connection to https://api.github.com/ was leaked. Did you forget to close a response body?" |
also:
|
okhttp3 3.12.12