[ 
https://issues.apache.org/jira/browse/SLING-12181?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17797151#comment-17797151
 ] 

Konrad Windszus edited comment on SLING-12181 at 12/15/23 12:14 PM:
--------------------------------------------------------------------

This is the same as for provider type retrieved via {{META-INF/api-info.json}}. 
And yes, for bundles who are supposed to implement/extend providers it must not 
be used! Also the readme is pretty clear in this regard:

bq. This module contains a Bnd plugin enforcing that no class of the current 
bundle extends or implements a provider type. Note that using a provider type 
(i.e. calling its methods without implementing or extending it) is still 
allowed (even for consumers).


was (Author: kwin):
This is the same as for provider type retrieved via {{META-INF/api-info.json}}. 
And yes, for bundles who are supposed to implement/extend providers it must not 
be used!

> Evaluate provider type information also directly from annotations
> -----------------------------------------------------------------
>
>                 Key: SLING-12181
>                 URL: https://issues.apache.org/jira/browse/SLING-12181
>             Project: Sling
>          Issue Type: Improvement
>    Affects Versions: Provider Type Checker Bnd Plugin 1.0.0
>            Reporter: Konrad Windszus
>            Assignee: Konrad Windszus
>            Priority: Major
>             Fix For: Provider Type Checker Bnd Plugin 1.1.0
>
>
> Currently the check implemented in SLING-12026 only retrieves the provider 
> type information from the META-INF/api-info.json (being generated by 
> SLING-12135).
> As fallback there should be direct evaluation of the annotations.
> The logic needs to be the same as in 
> https://github.com/bndtools/bnd/blob/d06df066f402f1433b70c51f568c40a444b4518d/biz.aQute.bndlib/src/aQute/bnd/osgi/Analyzer.java#L1991,
>  i.e. the annotation provider type needs to be evaluated both on package as 
> well as on type level.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to