Skip to content

Conversation

@ssalinas
Copy link
Member

@ssalinas ssalinas commented Feb 2, 2018

Previously, when using multiple auth methods, if all failed singularity would only return the message from the final one attempted. Also, the AsyncHttpClient used for webhook auth calls had all of the default timeouts and retries set, which are too high to auth calls.

This PR updates the multiple auth method caller to gather exception messages from each attempted auth method and return a combined message. It also updates the webhook auth http client to user much shorter timeouts (now defaults to 2s connect, 2s request, 2 retries) which are configurable in the auth configuration

.refreshAfterWrite(webhookAuthConfiguration.getCacheValidationMs(), TimeUnit.MILLISECONDS)
.build(new CacheLoader<String, SingularityUserPermissionsResponse>() {
@Override
public SingularityUserPermissionsResponse load(String authHeaderVaule) throws Exception {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

s/authHeaderVaule/authHeaderValue

@ssalinas ssalinas added the hs_qa label Feb 5, 2018
@pschoenfelder
Copy link
Contributor

🚢

@ssalinas ssalinas added this to the 0.19.0 milestone Feb 7, 2018
@ssalinas ssalinas merged commit 3c357b3 into master Feb 7, 2018
@ssalinas ssalinas deleted the timeouts branch February 7, 2018 14:09
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.

4 participants