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

Use RetentionPolicy CLASS in new 'ServiceContextKey' OSGi property type #1587

Conversation

HannesWell
Copy link
Member

And permit only types as target.

If the RetentionPolicy is only SOURCE Tycho does not recognize the annotation because the underlying BND library only operates on compiled classes and not on sources.

RetentionPolicy.CLASS is the default, but I still declared it to be specific in this case.

Copy link
Contributor

Test Results

 1 758 files  ±0   1 758 suites  ±0   1h 33m 7s ⏱️ + 6m 32s
 4 170 tests ±0   4 148 ✅ ±0   22 💤 ±0  0 ❌ ±0 
13 107 runs  ±0  12 943 ✅ ±0  164 💤 ±0  0 ❌ ±0 

Results for commit f246856. ± Comparison against base commit e14565e.

@HannesWell HannesWell merged commit e84143a into eclipse-platform:master Oct 14, 2024
17 checks passed
@HannesWell HannesWell deleted the retain-ServiceContextKey-at-class branch October 14, 2024 20:13
@laeubi
Copy link
Contributor

laeubi commented Oct 15, 2024

Probably PDE should warn if a property type is using source retention even though the spec only says

To be used in this way, the component property type must be annotated with the ComponentPropertyType meta-annotation so that, at build time, the annotation is recognized as a component property type.

there is really no benefit in using SOURCE retention type and it actually limits the usefulness with other tools (e.g. bnd/tycho).

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.

2 participants