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

Polish MicrometerHttpClientInterceptor changes #1921

Merged
merged 1 commit into from
Mar 20, 2020

Conversation

izeye
Copy link
Contributor

@izeye izeye commented Mar 20, 2020

This PR polishes the MicrometerHttpClientInterceptor changes made in #1886.

@izeye
Copy link
Contributor Author

izeye commented Mar 20, 2020

The build has failed due to the dependency locking as follows:

* What went wrong:
Execution failed for task ':micrometer-samples-boot2:compileJava'.
> Could not resolve all files for configuration ':micrometer-samples-boot2:compileClasspath'.
   > Resolved 'org.latencyutils:LatencyUtils:2.0.3' which is not part of the dependency lock state
   > Resolved 'io.micrometer:micrometer-core:1.3.0' which is not part of the dependency lock state

I couldn't reproduce it locally.

@izeye izeye mentioned this pull request Mar 20, 2020
@shakuzen
Copy link
Member

I made this pull request partially for the purpose of seeing if the failure would happen there. It didn't. So I'm wondering if it has something to do with the build running on your CircleCI instance rather than the Micrometer one?

@shakuzen shakuzen added the polish A general improvement (naming things, fixing minor issues, etc.) label Mar 20, 2020
@shakuzen shakuzen added this to the 1.4.0 milestone Mar 20, 2020
@shakuzen shakuzen merged commit e6ca290 into micrometer-metrics:1.4.x Mar 20, 2020
@izeye izeye deleted the http-client-interceptor branch March 20, 2020 23:52
@izeye
Copy link
Contributor Author

izeye commented Mar 21, 2020

@shakuzen Thanks for the review and the build check! Your assumption seems right although I'm not sure why and how it happened as it used to work before and there's nothing changed or special there.

@shakuzen
Copy link
Member

I'm not sure why and how it happened

I'm not sure either. If I had to guess, it might have something to do with how we're caching things with CircleCI, which has always been in the back of my mind as something to iterate on and improve, but it hasn't had more urgency than other things so far. Namely, the cache key is based only on a checksum of the root build.gradle, but the build dependencies (and anything else in ~/.gradle) could change due to changes in a number of other files. I've always wished this was taken care of more out of the box rather than us having to figure out the right cache key to use. This is perhaps something that if I enable Gradle Enterprise features we could have a better experience. This is all assuming that this has anything to do with the build failure mentioned here. My theory is that something was cached with a previous build having the same root build.gradle file that doesn't play nicely with changes to other files, but is still loaded due to the cache key. Just a guess, though.

@izeye
Copy link
Contributor Author

izeye commented Mar 21, 2020

@shakuzen Thanks for the info!

I invalidated the cache by adding a newline at the end of the build.gradle and confirmed a cache miss as follows:

No cache is found for key: gradle-dependencies-09FfXX5vix3yF+XMTk87ckzATHWfdbQlECqdU2t+rsg=

But I still see the same failures.

See https://circleci.com/gh/izeye/micrometer/678

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
polish A general improvement (naming things, fixing minor issues, etc.)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants