felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael Niedermaier (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (FELIX-3324) Allow maven-bundle-plugin:manifest to dump SCR component definitions generated by bnd
Date Thu, 10 Oct 2013 12:57:41 GMT

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

Michael Niedermaier commented on FELIX-3324:
--------------------------------------------

I have the tycho m2e plugin installed:
http://nexus.tesla.io:8081/nexus/content/sites/m2e.extras/m2eclipse-tycho/0.7.0/N/0.7.0.201302171659/

when running the project in eclipse via an OSGI runtime, I have the problem, when I generate
the Service Component definitions with the maven-scr-plugin everything works fine until I
set the manifestLocation to "META-INF" (where eclipse expects it normally) then the service
component definitions will not be found. 
The built jar works as expected, only running the project from eclipse does not work.

my pom looks like this:
...
		<dependency>
			<groupId>org.apache.felix</groupId>
			<artifactId>org.apache.felix.scr.annotations</artifactId>
			<version>1.9.6</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>
			<plugin>
				<groupId>org.apache.felix</groupId>
				<artifactId>maven-bundle-plugin</artifactId>
				<version>2.4.0</version>
				<extensions>true</extensions>
				<configuration>
					<manifestLocation>META-INF</manifestLocation>
					<instructions>
						<Service-Component>OSGI-INF/*.xml</Service-Component>
						<Bundle-SymbolicName>mygroup.test.one</Bundle-SymbolicName>
						<Export-Package></Export-Package>
					</instructions>
				</configuration>
			</plugin>
...

> Allow maven-bundle-plugin:manifest to dump SCR component definitions generated by bnd
> -------------------------------------------------------------------------------------
>
>                 Key: FELIX-3324
>                 URL: https://issues.apache.org/jira/browse/FELIX-3324
>             Project: Felix
>          Issue Type: Improvement
>          Components: Maven Bundle Plugin
>    Affects Versions: maven-bundle-plugin-2.3.6
>            Reporter: Ivan Dubrov
>              Labels: patch
>             Fix For: maven-bundle-plugin-2.4.1
>
>         Attachments: export-scr.patch
>
>   Original Estimate: 2h
>  Remaining Estimate: 2h
>
> maven-bundle-plugin allows dumping generated MANIFEST.MF, but does not allow dumping
SCR component definitions generated by the bnd (based on the component annotations). For example,
this could be useful if you need those files to run the OSGi framework from the IDE without
packaging everything. "unpackBundle" allows achieving the desired behaviour, but it could
be too heavy for large bundles.
> I suggest adding two properties to the plugin, "exportScr" to enable SCR definitions
export and "scrLocation" to specify directory to dump those definitions.



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Mime
View raw message