Hi,

On Wed, Dec 4, 2019 at 11:00 AM Carsten Ziegeler <[email protected]> wrote:
> ...The servlets resolver bundle
> already provides such a capability, so we can build on that one.
> If developers use the annotations, we can use the bnd functionality to
> automatically generate the requirement if the annotation using the new
> functionality is used....

Thank you Carsten and Konrad for your comments (and Radu for the +1s),
I agree with the need to be fully backwards compatible and avoid
surprises. Using OSGi capabilities makes total sense.

I haven't worked much with OSGi capabilities, can you confirm my
understanding of how they should be used and generated?

We can discuss separately whether "strict" is the right base name.
Naming is hard ;-)

1) When this is implemented, the o.a.s.servlets.resolver bundle gets
an additional (static, in pom.xml) value for its Provide-Capability
header. Suggested value:

  org.apache.sling.servlets.resolver;strict.mode.support:Version=1.0.0

2) The bnd functionality is modified to add the corresponding
Require-Capability header (require strict.mode.support >= 1.0.0) when
building bundles that contain at least one servlet with both a
sling.servlet.paths and a sling.servlet.resolution service property.
At this stage I don't know where this needs to be implemented.

-Bertrand

(note to self; 
https://osgi.org/specification/osgi.core/7.0.0/framework.module.html#d0e2821
is the Capabilities spec)

Reply via email to