Hi, It works without the "<executions>" stuff, because we have the plugin in the pluginManagement of the parent POM in Sling, while I assume you don't have such a configuration.
Therefore you have to explicitly configure it in your project. Regards Felix On 29.01.2010 15:43, Ben Short wrote: > Altering the scr plugin config to the following makes it generate > the Service Component Descriptors and add them to the pom. > > <plugin> > <groupId>org.apache.felix</groupId> > <artifactId>maven-scr-plugin</artifactId> > <version>1.4.2</version> > <executions> > <execution> > <id>generate-scr-scrdescriptor</id> > <goals> > <goal>scr</goal> > </goals> > </execution> > </executions> > </plugin> > > I'm not sure why it works with out the executions bit in the sample > application. > > 2010/1/29 Ben Short <[email protected]> > >> OK I have been looking at the Sample Post Servlet Extensions and my pom is >> pretty much the same. >> >> <build> >> <plugins> >> <plugin> >> <groupId>org.apache.maven.plugins</groupId> >> <artifactId>maven-compiler-plugin</artifactId> >> <configuration> >> <source>1.5</source> >> <target>1.5</target> >> </configuration> >> </plugin> >> <plugin> >> <groupId>org.apache.maven.plugins</groupId> >> <artifactId>maven-dependency-plugin</artifactId> >> </plugin> >> <plugin> >> <groupId>org.apache.felix</groupId> >> <artifactId>maven-scr-plugin</artifactId> >> <version>1.4.2</version> >> </plugin> >> <plugin> >> <groupId>org.apache.felix</groupId> >> <artifactId>maven-bundle-plugin</artifactId> >> <extensions>true</extensions> >> <configuration> >> <instructions> >> >> >> <Sling-Initial-Content>initial-content;overwrite:=true;uninstall=true</Sling-Initial-Content> >> <Private-Package> >> com.daisytechnologies.basket >> </Private-Package> >> </instructions> >> </configuration> >> </plugin> >> </plugins> >> </build> >> >> When I do a mvn package on the samples module I see that >> a scr-plugin-generated directory is created. But when I do a mvn package on >> my app it not created. >> >> >> 2010/1/29 Bertrand Delacretaz <[email protected]> >> >>> On Fri, Jan 29, 2010 at 2:59 PM, Vidar Ramdal <[email protected]> wrote: >>> >>>> ...Check the Felix web console >>>> (http://localhost:8080/system/console/bundles) and see that your >>>> bundle is listed there, and is "active". If it is not, click to expand >>>> it and check if any of the imports are listed in red. >>>> You can also tail your sling.log, and see what is output when you >>>> start your bundle.... >>> >>> And the "components" page of the console should also show your >>> CreateBasketPostOperation as active. >>> >>> -Bertrand >>> >> >> >
