Alex Blewitt created FELIX-4413:
-----------------------------------
Summary: Update maven-scr-plugin to use standard OSGi annotations
Key: FELIX-4413
URL: https://issues.apache.org/jira/browse/FELIX-4413
Project: Felix
Issue Type: Bug
Components: Maven SCR Plugin
Affects Versions: maven-scr-plugin 1.15.0
Reporter: Alex Blewitt
Priority: Minor
The maven-scr-1.15.0 plugin complains when org.apache.felix.scr.annotations is
missing, and even when present appears to ignore components registered with the
standard OSGi annotations in the OSGi Enterprise 5.0 specification.
This class generates the maven scr data:
import org.apache.felix.scr.annotations.Component;
//import org.osgi.service.component.annotations.Component;
@Component(name = "Test")
public class Test implements Runnable {
public void run() {
}
}
This one does not:
//import org.apache.felix.scr.annotations.Component;
import org.osgi.service.component.annotations.Component;
@Component(name = "Test")
public class Test implements Runnable {
public void run() {
}
}
This was compiled with the following dependencies set:
<dependencies>
<dependency>
<groupId>org.apache.felix</groupId>
<artifactId>org.apache.felix.scr.annotations</artifactId>
<version>1.9.6</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.enterprise</artifactId>
<version>5.0.0</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-scr-plugin</artifactId>
<version>1.15.0</version>
<executions>
<execution>
<id>generate-scr-scrdescriptor</id>
<goals>
<goal>scr</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)