-
Notifications
You must be signed in to change notification settings - Fork 5k
Annotate BuildTree-scope services #31990
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
Conversation
with respect to service annotations
e5889f5
to
34bd938
Compare
@bot-gradle test without pts |
This comment has been minimized.
This comment has been minimized.
The following builds have passed: |
public BuildTreeState(BuildInvocationScopeId buildInvocationScopeId, ServiceRegistry parent, BuildTreeModelControllerServices.Supplier modelServices) { | ||
services = ServiceRegistryBuilder.builder() | ||
.scope(Scope.BuildTree.class) | ||
.scopeStrictly(Scope.BuildTree.class) |
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.
ℹ️ Ensure services in the scope are strictly annotated
"org.gradle.cache.internal.ProducerGuard", | ||
"org.gradle.internal.typeconversion.NotationParser", | ||
|
||
"org.gradle.caching.internal.origin.OriginMetadataFactory", |
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.
💅 would be nice to have a comment describing the reason for suppression
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.
LGTM!
Annotate all
BuildTree
-scoped services with the appropriate service scopes, and require any new services to be properly annotated.Follow-up for #31965
The changes are across many files but they are mostly trivial and of two types:
@ServiceScope
annotation to the service interface/classThe latter is done either by updating the returned type from a factory method or by adding an explicit service type in the registration.add() call.