You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@felix.apache.org by gn...@apache.org on 2009/06/18 22:57:26 UTC
svn commit: r786262 [1/3] - in /felix/trunk/karaf: ./ assembly/
assembly/src/main/descriptors/ assembly/src/main/filtered-resources/
assembly/src/main/filtered-resources/etc/ deployer/blueprint/
deployer/blueprint/src/main/resources/META-INF/spring/ de...
Author: gnodet
Date: Thu Jun 18 20:57:23 2009
New Revision: 786262
URL: http://svn.apache.org/viewvc?rev=786262&view=rev
Log:
Switch from spring-dm to blueprint
Added:
felix/trunk/karaf/deployer/blueprint/src/main/resources/OSGI-INF/
felix/trunk/karaf/deployer/blueprint/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/deployer/blueprint/src/main/resources/OSGI-INF/blueprint/blueprint-deployer.xml
felix/trunk/karaf/deployer/features/src/main/resources/OSGI-INF/
felix/trunk/karaf/deployer/features/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/deployer/features/src/main/resources/OSGI-INF/blueprint/features-deployer.xml
felix/trunk/karaf/deployer/spring/src/main/resources/OSGI-INF/
felix/trunk/karaf/deployer/spring/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/deployer/spring/src/main/resources/OSGI-INF/blueprint/spring-deployer.xml
felix/trunk/karaf/gshell/gshell-admin/src/main/resources/OSGI-INF/
felix/trunk/karaf/gshell/gshell-admin/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/gshell/gshell-admin/src/main/resources/OSGI-INF/blueprint/gshell-admin.xml
felix/trunk/karaf/gshell/gshell-config/src/main/resources/OSGI-INF/
felix/trunk/karaf/gshell/gshell-config/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/gshell/gshell-config/src/main/resources/OSGI-INF/blueprint/gshell-config.xml
felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/CommandResolverImpl.java
felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/geronimo/gshell/vfs/config/CacheStrategyConverter.java
felix/trunk/karaf/gshell/gshell-core/src/main/resources/OSGI-INF/
felix/trunk/karaf/gshell/gshell-core/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/gshell/gshell-core/src/main/resources/OSGI-INF/blueprint/gshell-namespacehandler.xml
felix/trunk/karaf/gshell/gshell-core/src/main/resources/org/apache/felix/karaf/gshell/core/karaf-gshell.xsd
- copied, changed from r785868, felix/trunk/karaf/gshell/gshell-core/src/main/resources/org/apache/felix/karaf/gshell/core/servicemix-gshell.xsd
felix/trunk/karaf/gshell/gshell-features/src/main/resources/OSGI-INF/
felix/trunk/karaf/gshell/gshell-features/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/gshell/gshell-features/src/main/resources/OSGI-INF/blueprint/gshell-features.xml
felix/trunk/karaf/gshell/gshell-log/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/gshell/gshell-log/src/main/resources/OSGI-INF/blueprint/gshell-log.xml
felix/trunk/karaf/gshell/gshell-osgi/src/main/java/org/apache/felix/karaf/gshell/osgi/BlueprintListener.java
felix/trunk/karaf/gshell/gshell-osgi/src/main/resources/OSGI-INF/
felix/trunk/karaf/gshell/gshell-osgi/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/gshell/gshell-osgi/src/main/resources/OSGI-INF/blueprint/gshell-osgi.xml
felix/trunk/karaf/gshell/gshell-packages/src/main/resources/OSGI-INF/
felix/trunk/karaf/gshell/gshell-packages/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/gshell/gshell-packages/src/main/resources/OSGI-INF/blueprint/gshell-packages.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/gshell/gshell-run/src/main/resources/OSGI-INF/blueprint/gshell-commands.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/OSGI-INF/blueprint/gshell-local.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/OSGI-INF/blueprint/gshell-osgi.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/OSGI-INF/blueprint/gshell-remote.xml
- copied, changed from r785868, felix/trunk/karaf/gshell/gshell-run/src/main/resources/META-INF/spring/gshell-remote.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/OSGI-INF/blueprint/gshell-vfs.xml
- copied, changed from r785868, felix/trunk/karaf/gshell/gshell-run/src/main/resources/META-INF/spring/gshell-vfs.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/OSGI-INF/blueprint/gshell.xml
- copied, changed from r785868, felix/trunk/karaf/gshell/gshell-run/src/main/resources/META-INF/spring/gshell.xml
felix/trunk/karaf/gshell/gshell-wrapper/src/main/resources/OSGI-INF/
felix/trunk/karaf/gshell/gshell-wrapper/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/gshell/gshell-wrapper/src/main/resources/OSGI-INF/blueprint/gshell-wrapper.xml
felix/trunk/karaf/jaas/jaas-config/src/main/resources/OSGI-INF/
felix/trunk/karaf/jaas/jaas-config/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/jaas/jaas-config/src/main/resources/OSGI-INF/blueprint/karaf-jaas.xml
felix/trunk/karaf/jaas/jaas-modules/src/main/resources/OSGI-INF/
felix/trunk/karaf/jaas/jaas-modules/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/jaas/jaas-modules/src/main/resources/OSGI-INF/blueprint/karaf-jaas-module.xml
felix/trunk/karaf/management/src/main/resources/OSGI-INF/blueprint/
felix/trunk/karaf/management/src/main/resources/OSGI-INF/blueprint/karaf-management.xml
Removed:
felix/trunk/karaf/deployer/blueprint/src/main/resources/META-INF/spring/blueprint-deployer.xml
felix/trunk/karaf/deployer/features/src/main/resources/META-INF/spring/features-deployer.xml
felix/trunk/karaf/deployer/spring/src/main/resources/META-INF/spring/spring-deployer.xml
felix/trunk/karaf/gshell/gshell-admin/src/main/resources/META-INF/spring/gshell-admin.xml
felix/trunk/karaf/gshell/gshell-config/src/main/resources/META-INF/spring/gshell-config.xml
felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/BeanContainerAwareProcessor.java
felix/trunk/karaf/gshell/gshell-core/src/main/resources/META-INF/spring.handlers
felix/trunk/karaf/gshell/gshell-core/src/main/resources/META-INF/spring.schemas
felix/trunk/karaf/gshell/gshell-core/src/main/resources/org/apache/felix/karaf/gshell/core/servicemix-gshell.xsd
felix/trunk/karaf/gshell/gshell-features/src/main/resources/META-INF/spring/gshell-features.xml
felix/trunk/karaf/gshell/gshell-log/src/main/resources/META-INF/spring/gshell-log.xml
felix/trunk/karaf/gshell/gshell-osgi/src/main/java/org/apache/felix/karaf/gshell/osgi/SpringApplicationListener.java
felix/trunk/karaf/gshell/gshell-osgi/src/main/resources/META-INF/spring/gshell-osgi.xml
felix/trunk/karaf/gshell/gshell-packages/src/main/resources/META-INF/spring/gshell-packages.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/META-INF/spring/gshell-commands.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/META-INF/spring/gshell-local.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/META-INF/spring/gshell-osgi.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/META-INF/spring/gshell-remote.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/META-INF/spring/gshell-vfs.xml
felix/trunk/karaf/gshell/gshell-run/src/main/resources/META-INF/spring/gshell.xml
felix/trunk/karaf/gshell/gshell-wrapper/src/main/resources/META-INF/spring/gshell-wrapper.xml
felix/trunk/karaf/jaas/jaas-config/src/main/java/org/apache/felix/karaf/jaas/config/impl/ConfigParser.java
felix/trunk/karaf/jaas/jaas-config/src/main/java/org/apache/felix/karaf/jaas/config/impl/ResourceKeystoreInstanceParser.java
felix/trunk/karaf/jaas/jaas-config/src/main/resources/META-INF/spring.handlers
felix/trunk/karaf/jaas/jaas-config/src/main/resources/META-INF/spring.schemas
felix/trunk/karaf/jaas/jaas-config/src/main/resources/META-INF/spring/karaf-jaas.xml
felix/trunk/karaf/jaas/jaas-config/src/test/java/org/apache/felix/karaf/jaas/config/NamespaceHandlerTest.java
felix/trunk/karaf/jaas/jaas-config/src/test/resources/config.xml
felix/trunk/karaf/jaas/jaas-config/src/test/resources/privatestore.jks
felix/trunk/karaf/jaas/jaas-modules/src/main/resources/META-INF/spring/karaf-jaas-module.xml
felix/trunk/karaf/management/src/main/resources/META-INF/spring/karaf-management.xml
Modified:
felix/trunk/karaf/assembly/pom.xml
felix/trunk/karaf/assembly/src/main/descriptors/unix-bin.xml
felix/trunk/karaf/assembly/src/main/descriptors/windows-bin.xml
felix/trunk/karaf/assembly/src/main/filtered-resources/etc/startup.properties
felix/trunk/karaf/assembly/src/main/filtered-resources/features.xml
felix/trunk/karaf/deployer/blueprint/pom.xml
felix/trunk/karaf/deployer/features/pom.xml
felix/trunk/karaf/deployer/spring/pom.xml
felix/trunk/karaf/deployer/spring/src/test/java/org/apache/felix/karaf/deployer/spring/SpringDeploymentListenerTest.java
felix/trunk/karaf/gshell/gshell-admin/pom.xml
felix/trunk/karaf/gshell/gshell-config/pom.xml
felix/trunk/karaf/gshell/gshell-config/src/main/java/org/apache/felix/karaf/gshell/config/completers/ConfigurationCompleter.java
felix/trunk/karaf/gshell/gshell-core/pom.xml
felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/ApplicationManagerImpl.java
felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/BeanContainerWrapper.java
felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/OsgiCommandRegistry.java
felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/config/NamespaceHandler.java
felix/trunk/karaf/gshell/gshell-features/pom.xml
felix/trunk/karaf/gshell/gshell-features/src/main/java/org/apache/felix/karaf/gshell/features/internal/FeatureImpl.java
felix/trunk/karaf/gshell/gshell-features/src/main/java/org/apache/felix/karaf/gshell/features/internal/FeaturesServiceImpl.java
felix/trunk/karaf/gshell/gshell-features/src/main/java/org/apache/felix/karaf/gshell/features/internal/RepositoryImpl.java
felix/trunk/karaf/gshell/gshell-features/src/main/java/org/apache/felix/karaf/gshell/features/management/ManagedFeaturesRegistry.java
felix/trunk/karaf/gshell/gshell-log/pom.xml
felix/trunk/karaf/gshell/gshell-obr/pom.xml
felix/trunk/karaf/gshell/gshell-osgi/pom.xml
felix/trunk/karaf/gshell/gshell-osgi/src/main/java/org/apache/felix/karaf/gshell/osgi/ListBundles.java
felix/trunk/karaf/gshell/gshell-packages/pom.xml
felix/trunk/karaf/gshell/gshell-run/pom.xml
felix/trunk/karaf/gshell/gshell-wrapper/pom.xml
felix/trunk/karaf/jaas/jaas-config/pom.xml
felix/trunk/karaf/jaas/jaas-config/src/main/java/org/apache/felix/karaf/jaas/config/impl/NamespaceHandler.java
felix/trunk/karaf/jaas/jaas-config/src/main/resources/org/apache/felix/karaf/jaas/config/servicemix-jaas.xsd
felix/trunk/karaf/jaas/jaas-modules/pom.xml
felix/trunk/karaf/management/pom.xml
felix/trunk/karaf/pom.xml
Modified: felix/trunk/karaf/assembly/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/assembly/pom.xml?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/assembly/pom.xml (original)
+++ felix/trunk/karaf/assembly/pom.xml Thu Jun 18 20:57:23 2009
@@ -246,6 +246,10 @@
<groupId>org.apache.felix</groupId>
<artifactId>org.apache.felix.framework</artifactId>
</dependency>
+ <dependency>
+ <groupId>org.apache.geronimo</groupId>
+ <artifactId>blueprint-bundle</artifactId>
+ </dependency>
</dependencies>
<build>
<resources>
Modified: felix/trunk/karaf/assembly/src/main/descriptors/unix-bin.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/assembly/src/main/descriptors/unix-bin.xml?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/assembly/src/main/descriptors/unix-bin.xml (original)
+++ felix/trunk/karaf/assembly/src/main/descriptors/unix-bin.xml Thu Jun 18 20:57:23 2009
@@ -147,6 +147,7 @@
<include>org.ops4j.pax.url:pax-url-wrap</include>
</includes>
</dependencySet>
+ <!--
<dependencySet>
<outputDirectory>/system</outputDirectory>
<unpack>false</unpack>
@@ -170,6 +171,7 @@
<include>org.springframework.osgi:spring-osgi-io</include>
</includes>
</dependencySet>
+ -->
<dependencySet>
<outputDirectory>/system</outputDirectory>
<unpack>false</unpack>
@@ -177,7 +179,9 @@
<outputFileNameMapping>org/apache/geronimo/specs/${artifact.artifactId}/${artifact.baseVersion}/${artifact.artifactId}-${artifact.baseVersion}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
<includes>
<include>org.apache.geronimo.specs:geronimo-servlet_2.5_spec</include>
+ <!--
<include>org.apache.geronimo.specs:geronimo-annotation_1.0_spec</include>
+ -->
</includes>
</dependencySet>
<dependencySet>
@@ -186,8 +190,10 @@
<useProjectArtifact>false</useProjectArtifact>
<outputFileNameMapping>org/apache/servicemix/bundles/${artifact.artifactId}/${artifact.baseVersion}/${artifact.artifactId}-${artifact.baseVersion}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
<includes>
+ <!--
<include>org.apache.servicemix.bundles:org.apache.servicemix.bundles.aopalliance</include>
<include>org.apache.servicemix.bundles:org.apache.servicemix.bundles.cglib</include>
+ -->
<include>org.apache.servicemix.bundles:org.apache.servicemix.bundles.jaxp-ri</include>
<include>org.apache.servicemix.bundles:org.apache.servicemix.bundles.oro</include>
<include>org.apache.servicemix.bundles:org.apache.servicemix.bundles.commons-jexl</include>
@@ -298,6 +304,15 @@
<include>org.eclipse:osgi</include>
</includes>
</dependencySet>
+ <dependencySet>
+ <outputDirectory>/system</outputDirectory>
+ <unpack>false</unpack>
+ <useProjectArtifact>false</useProjectArtifact>
+ <outputFileNameMapping>org/apache/geronimo/${artifact.artifactId}/${artifact.baseVersion}/${artifact.artifactId}-${artifact.baseVersion}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
+ <includes>
+ <include>org.apache.geronimo:blueprint-bundle</include>
+ </includes>
+ </dependencySet>
</dependencySets>
Modified: felix/trunk/karaf/assembly/src/main/descriptors/windows-bin.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/assembly/src/main/descriptors/windows-bin.xml?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/assembly/src/main/descriptors/windows-bin.xml (original)
+++ felix/trunk/karaf/assembly/src/main/descriptors/windows-bin.xml Thu Jun 18 20:57:23 2009
@@ -139,6 +139,7 @@
<include>org.ops4j.pax.url:pax-url-wrap</include>
</includes>
</dependencySet>
+ <!--
<dependencySet>
<outputDirectory>/system</outputDirectory>
<unpack>false</unpack>
@@ -162,6 +163,7 @@
<include>org.springframework.osgi:spring-osgi-io</include>
</includes>
</dependencySet>
+ -->
<dependencySet>
<outputDirectory>/system</outputDirectory>
<unpack>false</unpack>
@@ -169,7 +171,9 @@
<outputFileNameMapping>org/apache/geronimo/specs/${artifact.artifactId}/${artifact.baseVersion}/${artifact.artifactId}-${artifact.baseVersion}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
<includes>
<include>org.apache.geronimo.specs:geronimo-servlet_2.5_spec</include>
+ <!--
<include>org.apache.geronimo.specs:geronimo-annotation_1.0_spec</include>
+ -->
</includes>
</dependencySet>
<dependencySet>
@@ -178,8 +182,10 @@
<useProjectArtifact>false</useProjectArtifact>
<outputFileNameMapping>org/apache/servicemix/bundles/${artifact.artifactId}/${artifact.baseVersion}/${artifact.artifactId}-${artifact.baseVersion}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
<includes>
+ <!--
<include>org.apache.servicemix.bundles:org.apache.servicemix.bundles.aopalliance</include>
<include>org.apache.servicemix.bundles:org.apache.servicemix.bundles.cglib</include>
+ -->
<include>org.apache.servicemix.bundles:org.apache.servicemix.bundles.jaxp-ri</include>
<include>org.apache.servicemix.bundles:org.apache.servicemix.bundles.oro</include>
<include>org.apache.servicemix.bundles:org.apache.servicemix.bundles.commons-jexl</include>
@@ -290,6 +296,15 @@
<include>org.eclipse:osgi</include>
</includes>
</dependencySet>
+ <dependencySet>
+ <outputDirectory>/system</outputDirectory>
+ <unpack>false</unpack>
+ <useProjectArtifact>false</useProjectArtifact>
+ <outputFileNameMapping>org/apache/geronimo/${artifact.artifactId}/${artifact.baseVersion}/${artifact.artifactId}-${artifact.baseVersion}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
+ <includes>
+ <include>org.apache.geronimo:blueprint-bundle</include>
+ </includes>
+ </dependencySet>
</dependencySets>
Modified: felix/trunk/karaf/assembly/src/main/filtered-resources/etc/startup.properties
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/assembly/src/main/filtered-resources/etc/startup.properties?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/assembly/src/main/filtered-resources/etc/startup.properties (original)
+++ felix/trunk/karaf/assembly/src/main/filtered-resources/etc/startup.properties Thu Jun 18 20:57:23 2009
@@ -32,29 +32,31 @@
org/apache/servicemix/bundles/org.apache.servicemix.bundles.jaxp-ri/${jaxp.ri.version}/org.apache.servicemix.bundles.jaxp-ri-${jaxp.ri.version}.jar=10
org/apache/felix/org.osgi.compendium/${felix.compendium.version}/org.osgi.compendium-${felix.compendium.version}.jar=10
org/apache/felix/org.apache.felix.configadmin/${felix.configadmin.version}/org.apache.felix.configadmin-${felix.configadmin.version}.jar=10
-org/apache/geronimo/specs/geronimo-annotation_1.0_spec/${geronimo.annotation.version}/geronimo-annotation_1.0_spec-${geronimo.annotation.version}.jar=10
+#org/apache/geronimo/specs/geronimo-annotation_1.0_spec/${geronimo.annotation.version}/geronimo-annotation_1.0_spec-${geronimo.annotation.version}.jar=10
org/apache/felix/org.apache.felix.prefs/${felix.prefs.version}/org.apache.felix.prefs-${felix.prefs.version}.jar=10
org/apache/felix/karaf/deployer/org.apache.felix.karaf.deployer.filemonitor/${pom.version}/org.apache.felix.karaf.deployer.filemonitor-${pom.version}.jar=15
#
# The rest of the services..
#
+org/apache/geronimo/blueprint-bundle/${geronimo.blueprint.version}/blueprint-bundle-${geronimo.blueprint.version}.jar=20
+
org/apache/felix/karaf/gshell/org.apache.felix.karaf.gshell.core/${pom.version}/org.apache.felix.karaf.gshell.core-${pom.version}.jar=30
org/apache/servicemix/bundles/org.apache.servicemix.bundles.jline/${jline.version}/org.apache.servicemix.bundles.jline-${jline.version}.jar=30
-org/apache/servicemix/bundles/org.apache.servicemix.bundles.aopalliance/${aopalliance.version}/org.apache.servicemix.bundles.aopalliance-${aopalliance.version}.jar=30
-org/apache/servicemix/bundles/org.apache.servicemix.bundles.cglib/${cglib.version}/org.apache.servicemix.bundles.cglib-${cglib.version}.jar=30
+#org/apache/servicemix/bundles/org.apache.servicemix.bundles.aopalliance/${aopalliance.version}/org.apache.servicemix.bundles.aopalliance-${aopalliance.version}.jar=30
+#org/apache/servicemix/bundles/org.apache.servicemix.bundles.cglib/${cglib.version}/org.apache.servicemix.bundles.cglib-${cglib.version}.jar=30
org/apache/servicemix/bundles/org.apache.servicemix.bundles.oro/${oro.version}/org.apache.servicemix.bundles.oro-${oro.version}.jar=30
org/apache/servicemix/bundles/org.apache.servicemix.bundles.commons-codec/${commons.codec.version}/org.apache.servicemix.bundles.commons-codec-${commons.codec.version}.jar=30
org/apache/servicemix/bundles/org.apache.servicemix.bundles.commons-httpclient/${commons.httpclient.version}/org.apache.servicemix.bundles.commons-httpclient-${commons.httpclient.version}.jar=30
org/apache/servicemix/bundles/org.apache.servicemix.bundles.commons-jexl/${commons.jexl.version}/org.apache.servicemix.bundles.commons-jexl-${commons.jexl.version}.jar=30
org/apache/servicemix/bundles/org.apache.servicemix.bundles.commons-vfs/${commons.vfs.version}/org.apache.servicemix.bundles.commons-vfs-${commons.vfs.version}.jar=30
-org/springframework/spring-aop/${spring.version}/spring-aop-${spring.version}.jar=30
-org/springframework/spring-beans/${spring.version}/spring-beans-${spring.version}.jar=30
-org/springframework/spring-context/${spring.version}/spring-context-${spring.version}.jar=30
-org/springframework/spring-core/${spring.version}/spring-core-${spring.version}.jar=30
-org/springframework/osgi/spring-osgi-core/${spring.osgi.version}/spring-osgi-core-${spring.osgi.version}.jar=30
-org/springframework/osgi/spring-osgi-extender/${spring.osgi.version}/spring-osgi-extender-${spring.osgi.version}.jar=30
-org/springframework/osgi/spring-osgi-io/${spring.osgi.version}/spring-osgi-io-${spring.osgi.version}.jar=30
+#org/springframework/spring-aop/${spring.version}/spring-aop-${spring.version}.jar=30
+#org/springframework/spring-beans/${spring.version}/spring-beans-${spring.version}.jar=30
+#org/springframework/spring-context/${spring.version}/spring-context-${spring.version}.jar=30
+#org/springframework/spring-core/${spring.version}/spring-core-${spring.version}.jar=30
+#org/springframework/osgi/spring-osgi-core/${spring.osgi.version}/spring-osgi-core-${spring.osgi.version}.jar=30
+#org/springframework/osgi/spring-osgi-extender/${spring.osgi.version}/spring-osgi-extender-${spring.osgi.version}.jar=30
+#org/springframework/osgi/spring-osgi-io/${spring.osgi.version}/spring-osgi-io-${spring.osgi.version}.jar=30
org/apache/felix/karaf/deployer/org.apache.felix.karaf.deployer.spring/${pom.version}/org.apache.felix.karaf.deployer.spring-${pom.version}.jar=30
org/apache/felix/karaf/deployer/org.apache.felix.karaf.deployer.blueprint/${pom.version}/org.apache.felix.karaf.deployer.blueprint-${pom.version}.jar=30
org/apache/felix/karaf/deployer/org.apache.felix.karaf.deployer.features/${pom.version}/org.apache.felix.karaf.deployer.features-${pom.version}.jar=30
Modified: felix/trunk/karaf/assembly/src/main/filtered-resources/features.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/assembly/src/main/filtered-resources/features.xml?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/assembly/src/main/filtered-resources/features.xml (original)
+++ felix/trunk/karaf/assembly/src/main/filtered-resources/features.xml Thu Jun 18 20:57:23 2009
@@ -17,6 +17,23 @@
limitations under the License.
-->
<features>
+ <feature name="spring" version="${spring.version}">
+ <bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.aopalliance/${aopalliance.version}</bundle>
+ <bundle>mvn:org.springframework/spring-aop/${spring.version}</bundle>
+ <bundle>mvn:org.springframework/spring-beans/${spring.version}</bundle>
+ <bundle>mvn:org.springframework/spring-context/${spring.version}</bundle>
+ <bundle>mvn:org.springframework/spring-context-support/${spring.version}</bundle>
+ <bundle>mvn:org.springframework/spring-core/${spring.version}</bundle>
+ </feature>
+ <feature name="spring-dm" version="${spring.osgi.version}">
+ <feature version="${spring.version}">spring</feature>
+ <bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.cglib/${cglib.version}</bundle>
+ <bundle>mvn:org.springframework.osgi/spring-osgi-core/${spring.osgi.version}</bundle>
+ <bundle>mvn:org.springframework.osgi/spring-osgi-annotation/${spring.osgi.version}</bundle>
+ <bundle>mvn:org.springframework.osgi/spring-osgi-io/${spring.osgi.version}</bundle>
+ <bundle>mvn:org.springframework.osgi/spring-osgi-extender/${spring.osgi.version}</bundle>
+ <bundle>mvn:org.apache.felix.karaf.deployer/org.apache.felix.karaf.deployer.spring/${version}</bundle>
+ </feature>
<feature name="wrapper" version="${version}">
<bundle>mvn:org.apache.felix.karaf.gshell/org.apache.felix.karaf.gshell.wrapper/${version}</bundle>
</feature>
Modified: felix/trunk/karaf/deployer/blueprint/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/deployer/blueprint/pom.xml?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/deployer/blueprint/pom.xml (original)
+++ felix/trunk/karaf/deployer/blueprint/pom.xml Thu Jun 18 20:57:23 2009
@@ -65,7 +65,6 @@
<Bundle-SymbolicName>${pom.artifactId}</Bundle-SymbolicName>
<Export-Package>${pom.artifactId}*;version=${project.version}</Export-Package>
<Private-Package>org.apache.felix.karaf.deployer.blueprint</Private-Package>
- <Spring-Context>*;publish-context:=false;create-asynchronously:=true</Spring-Context>
<_versionpolicy>${bnd.version.policy}</_versionpolicy>
</instructions>
</configuration>
Added: felix/trunk/karaf/deployer/blueprint/src/main/resources/OSGI-INF/blueprint/blueprint-deployer.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/deployer/blueprint/src/main/resources/OSGI-INF/blueprint/blueprint-deployer.xml?rev=786262&view=auto
==============================================================================
--- felix/trunk/karaf/deployer/blueprint/src/main/resources/OSGI-INF/blueprint/blueprint-deployer.xml (added)
+++ felix/trunk/karaf/deployer/blueprint/src/main/resources/OSGI-INF/blueprint/blueprint-deployer.xml Thu Jun 18 20:57:23 2009
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+ xmlns:cm="http://www.osgi.org/xmlns/blueprint-cm/v1.0.0">
+
+ <service interface="org.apache.felix.karaf.deployer.filemonitor.DeploymentListener">
+ <bean class="org.apache.felix.karaf.deployer.blueprint.BlueprintDeploymentListener"/>
+ </service>
+
+ <service interface="org.osgi.service.url.URLStreamHandlerService">
+ <service-properties>
+ <entry key="url.handler.protocol" value="blueprint"/>
+ </service-properties>
+ <bean class="org.apache.felix.karaf.deployer.blueprint.BlueprintURLHandler"/>
+ </service>
+
+</blueprint>
Modified: felix/trunk/karaf/deployer/features/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/deployer/features/pom.xml?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/deployer/features/pom.xml (original)
+++ felix/trunk/karaf/deployer/features/pom.xml Thu Jun 18 20:57:23 2009
@@ -69,7 +69,6 @@
<Bundle-SymbolicName>${pom.artifactId}</Bundle-SymbolicName>
<Export-Package>${pom.artifactId}*;version=${project.version}</Export-Package>
<Private-Package>org.apache.felix.karaf.deployer.features</Private-Package>
- <Spring-Context>*;publish-context:=false;create-asynchronously:=true</Spring-Context>
<_versionpolicy>${bnd.version.policy}</_versionpolicy>
</instructions>
</configuration>
Added: felix/trunk/karaf/deployer/features/src/main/resources/OSGI-INF/blueprint/features-deployer.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/deployer/features/src/main/resources/OSGI-INF/blueprint/features-deployer.xml?rev=786262&view=auto
==============================================================================
--- felix/trunk/karaf/deployer/features/src/main/resources/OSGI-INF/blueprint/features-deployer.xml (added)
+++ felix/trunk/karaf/deployer/features/src/main/resources/OSGI-INF/blueprint/features-deployer.xml Thu Jun 18 20:57:23 2009
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+ xmlns:cm="http://www.osgi.org/xmlns/blueprint-cm/v1.0.0">
+
+ <service interface="org.apache.felix.karaf.deployer.filemonitor.DeploymentListener"
+ ref="featureDeploymentListener"/>
+
+ <bean id="featureDeploymentListener" class="org.apache.felix.karaf.deployer.features.FeatureDeploymentListener"
+ init-method="init" destroy-method="destroy" initialization="lazy">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ <property name="featuresService">
+ <reference interface="org.apache.felix.karaf.gshell.features.FeaturesService"/>
+ </property>
+ </bean>
+
+</blueprint>
Modified: felix/trunk/karaf/deployer/spring/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/deployer/spring/pom.xml?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/deployer/spring/pom.xml (original)
+++ felix/trunk/karaf/deployer/spring/pom.xml Thu Jun 18 20:57:23 2009
@@ -65,7 +65,6 @@
<Bundle-SymbolicName>${pom.artifactId}</Bundle-SymbolicName>
<Export-Package>${pom.artifactId}*;version=${project.version}</Export-Package>
<Private-Package>org.apache.felix.karaf.deployer.spring</Private-Package>
- <Spring-Context>*;publish-context:=false;create-asynchronously:=true</Spring-Context>
<_versionpolicy>${bnd.version.policy}</_versionpolicy>
</instructions>
</configuration>
Added: felix/trunk/karaf/deployer/spring/src/main/resources/OSGI-INF/blueprint/spring-deployer.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/deployer/spring/src/main/resources/OSGI-INF/blueprint/spring-deployer.xml?rev=786262&view=auto
==============================================================================
--- felix/trunk/karaf/deployer/spring/src/main/resources/OSGI-INF/blueprint/spring-deployer.xml (added)
+++ felix/trunk/karaf/deployer/spring/src/main/resources/OSGI-INF/blueprint/spring-deployer.xml Thu Jun 18 20:57:23 2009
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
+ xmlns:cm="http://www.osgi.org/xmlns/blueprint-cm/v1.0.0">
+
+ <service interface="org.apache.felix.karaf.deployer.filemonitor.DeploymentListener">
+ <bean class="org.apache.felix.karaf.deployer.spring.SpringDeploymentListener"/>
+ </service>
+
+ <service interface="org.osgi.service.url.URLStreamHandlerService">
+ <service-properties>
+ <entry key="url.handler.protocol" value="spring"/>
+ </service-properties>
+ <bean class="org.apache.felix.karaf.deployer.spring.SpringURLHandler"/>
+ </service>
+
+</blueprint>
Modified: felix/trunk/karaf/deployer/spring/src/test/java/org/apache/felix/karaf/deployer/spring/SpringDeploymentListenerTest.java
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/deployer/spring/src/test/java/org/apache/felix/karaf/deployer/spring/SpringDeploymentListenerTest.java?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/deployer/spring/src/test/java/org/apache/felix/karaf/deployer/spring/SpringDeploymentListenerTest.java (original)
+++ felix/trunk/karaf/deployer/spring/src/test/java/org/apache/felix/karaf/deployer/spring/SpringDeploymentListenerTest.java Thu Jun 18 20:57:23 2009
@@ -36,7 +36,7 @@
public void testPackagesExtraction() throws Exception {
SpringDeploymentListener l = new SpringDeploymentListener();
- File f = new File(getClass().getClassLoader().getResource("META-INF/spring/spring-deployer.xml").toURI());
+ File f = new File(getClass().getClassLoader().getResource("test.xml").toURI());
Set<String> pkgs = SpringTransformer.analyze(new DOMSource(SpringTransformer.parse(f.toURL())));
assertNotNull(pkgs);
assertEquals(2, pkgs.size());
Modified: felix/trunk/karaf/gshell/gshell-admin/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/gshell/gshell-admin/pom.xml?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/gshell/gshell-admin/pom.xml (original)
+++ felix/trunk/karaf/gshell/gshell-admin/pom.xml Thu Jun 18 20:57:23 2009
@@ -168,7 +168,6 @@
*
</Import-Package>
<Private-Package>org.apache.felix.karaf.jpm.*</Private-Package>
- <Spring-Context>*;publish-context:=false;create-asynchronously:=true</Spring-Context>
<_versionpolicy>${bnd.version.policy}</_versionpolicy>
</instructions>
</configuration>
Added: felix/trunk/karaf/gshell/gshell-admin/src/main/resources/OSGI-INF/blueprint/gshell-admin.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/gshell/gshell-admin/src/main/resources/OSGI-INF/blueprint/gshell-admin.xml?rev=786262&view=auto
==============================================================================
--- felix/trunk/karaf/gshell/gshell-admin/src/main/resources/OSGI-INF/blueprint/gshell-admin.xml (added)
+++ felix/trunk/karaf/gshell/gshell-admin/src/main/resources/OSGI-INF/blueprint/gshell-admin.xml Thu Jun 18 20:57:23 2009
@@ -0,0 +1,98 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0">
+
+ <command-bundle xmlns="http://felix.apache.org/karaf/xmlns/gshell/v1.0.0">
+ <command name="admin/create">
+ <action class="org.apache.felix.karaf.gshell.admin.internal.commands.CreateCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ <property name="adminService" ref="adminService" />
+ </action>
+ </command>
+ <command name="admin/connect">
+ <action class="org.apache.felix.karaf.gshell.admin.internal.commands.ConnectCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ <property name="adminService" ref="adminService" />
+ </action>
+ <completers>
+ <ref component-id="instanceCompleter" />
+ <null/>
+ </completers>
+ </command>
+ <command name="admin/list">
+ <action class="org.apache.felix.karaf.gshell.admin.internal.commands.ListCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ <property name="adminService" ref="adminService" />
+ </action>
+ </command>
+ <command name="admin/start">
+ <action class="org.apache.felix.karaf.gshell.admin.internal.commands.StartCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ <property name="adminService" ref="adminService" />
+ </action>
+ <completers>
+ <ref component-id="instanceCompleter" />
+ <null/>
+ </completers>
+ </command>
+ <command name="admin/stop">
+ <action class="org.apache.felix.karaf.gshell.admin.internal.commands.StopCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ <property name="adminService" ref="adminService" />
+ </action>
+ <completers>
+ <ref component-id="instanceCompleter" />
+ <null/>
+ </completers>
+ </command>
+ <command name="admin/destroy">
+ <action class="org.apache.felix.karaf.gshell.admin.internal.commands.DestroyCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ <property name="adminService" ref="adminService" />
+ </action>
+ <completers>
+ <ref component-id="instanceCompleter" />
+ <null/>
+ </completers>
+ </command>
+ <command name="admin/change-port">
+ <action class="org.apache.felix.karaf.gshell.admin.internal.commands.ChangePortCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ <property name="adminService" ref="adminService" />
+ </action>
+ <completers>
+ <ref component-id="instanceCompleter" />
+ <null/>
+ </completers>
+ </command>
+ </command-bundle>
+
+ <reference id="preferences" interface="org.osgi.service.prefs.PreferencesService" availability="optional"/>
+
+ <bean id="adminService" class="org.apache.felix.karaf.gshell.admin.internal.AdminServiceImpl" init-method="init">
+ <property name="preferences" ref="preferences" />
+ </bean>
+
+ <bean id="instanceCompleter" class="org.apache.felix.karaf.gshell.admin.internal.completers.InstanceCompleter">
+ <property name="adminService" ref="adminService" />
+ </bean>
+
+
+</blueprint>
Modified: felix/trunk/karaf/gshell/gshell-config/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/gshell/gshell-config/pom.xml?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/gshell/gshell-config/pom.xml (original)
+++ felix/trunk/karaf/gshell/gshell-config/pom.xml Thu Jun 18 20:57:23 2009
@@ -83,7 +83,6 @@
*
</Import-Package>
<Private-Package>!*</Private-Package>
- <Spring-Context>*;publish-context:=false;create-asynchronously:=true</Spring-Context>
<_versionpolicy>${bnd.version.policy}</_versionpolicy>
</instructions>
</configuration>
Modified: felix/trunk/karaf/gshell/gshell-config/src/main/java/org/apache/felix/karaf/gshell/config/completers/ConfigurationCompleter.java
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/gshell/gshell-config/src/main/java/org/apache/felix/karaf/gshell/config/completers/ConfigurationCompleter.java?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/gshell/gshell-config/src/main/java/org/apache/felix/karaf/gshell/config/completers/ConfigurationCompleter.java (original)
+++ felix/trunk/karaf/gshell/gshell-config/src/main/java/org/apache/felix/karaf/gshell/config/completers/ConfigurationCompleter.java Thu Jun 18 20:57:23 2009
@@ -23,8 +23,6 @@
import java.util.Collection;
import java.util.List;
-import javax.annotation.PostConstruct;
-
import jline.Completor;
import org.apache.geronimo.gshell.console.completer.StringsCompleter;
import org.osgi.service.cm.Configuration;
@@ -48,7 +46,6 @@
this.admin = admin;
}
- @PostConstruct
public void init() {
Configuration[] configs;
try {
Added: felix/trunk/karaf/gshell/gshell-config/src/main/resources/OSGI-INF/blueprint/gshell-config.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/gshell/gshell-config/src/main/resources/OSGI-INF/blueprint/gshell-config.xml?rev=786262&view=auto
==============================================================================
--- felix/trunk/karaf/gshell/gshell-config/src/main/resources/OSGI-INF/blueprint/gshell-config.xml (added)
+++ felix/trunk/karaf/gshell/gshell-config/src/main/resources/OSGI-INF/blueprint/gshell-config.xml Thu Jun 18 20:57:23 2009
@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+-->
+<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0">
+
+ <command-bundle xmlns="http://felix.apache.org/karaf/xmlns/gshell/v1.0.0">
+ <command name="config/cancel">
+ <action class="org.apache.felix.karaf.gshell.config.CancelCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ </action>
+ </command>
+ <command name="config/edit">
+ <action class="org.apache.felix.karaf.gshell.config.EditCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ </action>
+ <completers>
+ <ref component-id="configCompleter" />
+ <null/>
+ </completers>
+ </command>
+ <command name="config/list">
+ <action class="org.apache.felix.karaf.gshell.config.ListCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ </action>
+ </command>
+ <command name="config/propdel">
+ <action class="org.apache.felix.karaf.gshell.config.PropDelCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ </action>
+ <completers>
+ <ref component-id="configPropertyCompleter" />
+ <null/>
+ </completers>
+ </command>
+ <command name="config/proplist">
+ <action class="org.apache.felix.karaf.gshell.config.PropListCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ </action>
+ </command>
+ <command name="config/propset">
+ <action class="org.apache.felix.karaf.gshell.config.PropSetCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ </action>
+ <completers>
+ <ref component-id="configPropertyCompleter" />
+ <null/>
+ </completers>
+ </command>
+ <command name="config/update">
+ <action class="org.apache.felix.karaf.gshell.config.UpdateCommand">
+ <property name="bundleContext" ref="blueprintBundleContext"/>
+ </action>
+ </command>
+ </command-bundle>
+
+ <bean id="configCompleter" class="org.apache.felix.karaf.gshell.config.completers.ConfigurationCompleter" init-method="init">
+ <property name="admin" ref="configAdmin"/>
+ </bean>
+
+ <bean id="configPropertyCompleter" class="org.apache.felix.karaf.gshell.config.completers.ConfigurationPropertyCompleter" />
+
+ <reference id="configAdmin" interface="org.osgi.service.cm.ConfigurationAdmin" />
+
+ <service ref="configCompleter" interface="org.osgi.service.cm.ConfigurationListener" />
+
+</blueprint>
Modified: felix/trunk/karaf/gshell/gshell-core/pom.xml
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/gshell/gshell-core/pom.xml?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/gshell/gshell-core/pom.xml (original)
+++ felix/trunk/karaf/gshell/gshell-core/pom.xml Thu Jun 18 20:57:23 2009
@@ -99,14 +99,6 @@
</exclusions>
</dependency>
<dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring-context</artifactId>
- </dependency>
- <dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring-aop</artifactId>
- </dependency>
- <dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
@@ -173,6 +165,10 @@
<artifactId>org.osgi.compendium</artifactId>
<scope>provided</scope>
</dependency>
+ <dependency>
+ <groupId>org.apache.geronimo</groupId>
+ <artifactId>blueprint-bundle</artifactId>
+ </dependency>
</dependencies>
<build>
@@ -206,12 +202,6 @@
<instructions>
<Bundle-SymbolicName>${artifactId}</Bundle-SymbolicName>
<Import-Package>
- org.springframework.aop,
- org.springframework.aop.framework,
- org.springframework.beans.factory.annotation,
- org.springframework.context.annotation,
- org.springframework.osgi.service.importer,
- org.aopalliance.aop,
org.apache.commons.vfs.provider.temp,
org.apache.commons.vfs.provider.ram,
jline*,
@@ -220,6 +210,7 @@
org.apache.felix.karaf.main.spi;resolution:=optional;version="1.0.0",
org.apache.sshd.server.keyprovider,
org.apache.sshd.server.jaas,
+ !org.springframework*,
*
</Import-Package>
<Export-Package>
@@ -229,7 +220,6 @@
<Private-Package>
org.codehaus.plexus.interpolation*,
</Private-Package>
- <Spring-Context>*;publish-context:=false;create-asynchronously:=true</Spring-Context>
<_versionpolicy>${bnd.version.policy}</_versionpolicy>
</instructions>
<unpackBundle>true</unpackBundle>
Modified: felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/ApplicationManagerImpl.java
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/ApplicationManagerImpl.java?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/ApplicationManagerImpl.java (original)
+++ felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/ApplicationManagerImpl.java Thu Jun 18 20:57:23 2009
@@ -25,12 +25,9 @@
import org.apache.geronimo.gshell.wisdom.application.ShellCreatedEvent;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
-import org.springframework.beans.factory.DisposableBean;
-import org.springframework.beans.factory.InitializingBean;
-import org.springframework.context.ApplicationContext;
-import org.springframework.context.ApplicationContextAware;
+import org.osgi.service.blueprint.container.BlueprintContainer;
-public class ApplicationManagerImpl implements ApplicationManager, ApplicationContextAware {
+public class ApplicationManagerImpl implements ApplicationManager {
private final Logger log = LoggerFactory.getLogger(getClass());
@@ -38,11 +35,12 @@
private Application application;
- private ApplicationContext applicationContext;
+ private BlueprintContainer blueprintContainer;
- public ApplicationManagerImpl(EventPublisher eventPublisher, Application application) {
+ public ApplicationManagerImpl(EventPublisher eventPublisher, Application application, BlueprintContainer blueprintContainer) {
this.eventPublisher = eventPublisher;
this.application = application;
+ this.blueprintContainer = blueprintContainer;
}
public void init() throws Exception {
@@ -56,10 +54,6 @@
SystemOutputHijacker.uninstall();
}
- public void setApplicationContext(ApplicationContext applicationContext) {
- this.applicationContext = applicationContext;
- }
-
public void configure(ApplicationConfiguration applicationConfiguration) throws Exception {
throw new UnsupportedOperationException();
}
@@ -69,7 +63,7 @@
}
public Shell create() throws Exception {
- final Shell shell = (Shell) applicationContext.getBean("shell");
+ final Shell shell = (Shell) blueprintContainer.getComponentInstance("shell");
log.debug("Created shell instance: {}", shell);
Modified: felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/BeanContainerWrapper.java
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/BeanContainerWrapper.java?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/BeanContainerWrapper.java (original)
+++ felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/BeanContainerWrapper.java Thu Jun 18 20:57:23 2009
@@ -24,19 +24,21 @@
import java.util.Map;
import org.apache.geronimo.gshell.spring.BeanContainer;
+import org.apache.geronimo.gshell.wisdom.command.GroupCommand;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.NoSuchBeanDefinitionException;
import org.springframework.context.ApplicationContext;
+import org.osgi.service.blueprint.container.BlueprintContainer;
public class BeanContainerWrapper implements BeanContainer {
private final Logger log = LoggerFactory.getLogger(getClass());
- private ApplicationContext context;
+ private BlueprintContainer container;
- public BeanContainerWrapper(ApplicationContext context) {
- this.context = context;
+ public BeanContainerWrapper(BlueprintContainer container) {
+ this.container = container;
}
public BeanContainer getParent() {
@@ -44,7 +46,7 @@
}
public ClassLoader getClassLoader() {
- return context.getClassLoader();
+ return null;
}
public void loadBeans(String[] strings) throws Exception {
@@ -54,18 +56,10 @@
public <T> T getBean(Class<T> type) {
assert type != null;
- log.trace("Getting bean of type: {}", type);
-
- String[] names = context.getBeanNamesForType(type);
-
- if (names.length == 0) {
- throw new NoSuchBeanDefinitionException(type, "No bean defined for type: " + type);
- }
- if (names.length > 1) {
- throw new NoSuchBeanDefinitionException(type, "No unique bean defined for type: " + type + ", found matches: " + Arrays.asList(names));
+ if (GroupCommand.class.isAssignableFrom(type)) {
+ return type.cast(new GroupCommand());
}
-
- return getBean(names[0], type);
+ throw new UnsupportedOperationException();
}
public <T> T getBean(String name, Class<T> requiredType) {
@@ -74,29 +68,19 @@
log.trace("Getting bean named '{}' of type: {}", name, requiredType);
- return (T) context.getBean(name, requiredType);
+ return requiredType.cast(container.getComponentInstance(name));
}
public <T> Map<String, T> getBeans(Class<T> type) {
- assert type != null;
-
- log.trace("Getting beans of type: {}", type);
-
- return (Map<String,T>) context.getBeansOfType(type);
+ throw new UnsupportedOperationException();
}
public String[] getBeanNames() {
- log.trace("Getting bean names");
-
- return context.getBeanDefinitionNames();
+ throw new UnsupportedOperationException();
}
public String[] getBeanNames(Class type) {
- assert type != null;
-
- log.trace("Getting bean names of type: {}", type);
-
- return context.getBeanNamesForType(type);
+ throw new UnsupportedOperationException();
}
public BeanContainer createChild(Collection<URL> urls) {
Added: felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/CommandResolverImpl.java
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/CommandResolverImpl.java?rev=786262&view=auto
==============================================================================
--- felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/CommandResolverImpl.java (added)
+++ felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/CommandResolverImpl.java Thu Jun 18 20:57:23 2009
@@ -0,0 +1,353 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.felix.karaf.gshell.core;
+
+import org.apache.commons.vfs.FileContent;
+import org.apache.commons.vfs.FileObject;
+import org.apache.commons.vfs.FileSystemException;
+import org.apache.geronimo.gshell.command.Command;
+import org.apache.geronimo.gshell.command.CommandException;
+import org.apache.geronimo.gshell.command.Variables;
+import org.apache.geronimo.gshell.registry.CommandResolver;
+import org.apache.geronimo.gshell.registry.NoSuchCommandException;
+import org.apache.geronimo.gshell.spring.BeanContainer;
+import org.apache.geronimo.gshell.spring.BeanContainerAware;
+import org.apache.geronimo.gshell.vfs.FileSystemAccess;
+import org.apache.geronimo.gshell.wisdom.command.AliasCommand;
+import org.apache.geronimo.gshell.wisdom.command.GroupCommand;
+import org.apache.geronimo.gshell.wisdom.registry.GroupDirectoryResolver;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.List;
+
+/**
+ * {@link CommandResolver} component.
+ *
+ * @version $Rev: 741078 $ $Date: 2009-02-05 12:39:10 +0100 (Thu, 05 Feb 2009) $
+ */
+public class CommandResolverImpl
+ implements CommandResolver, BeanContainerAware
+{
+ private final Logger log = LoggerFactory.getLogger(getClass());
+
+ private final FileSystemAccess fileSystemAccess;
+
+ private final GroupDirectoryResolver groupDirResolver;
+
+ private FileObject commandsRoot;
+
+ private FileObject aliasesRoot;
+
+ private BeanContainer container;
+
+ private String aliasCommandBeanId;
+ private String groupCommandBeanId;
+
+ public CommandResolverImpl(final FileSystemAccess fileSystemAccess, final GroupDirectoryResolver groupDirResolver) {
+ assert fileSystemAccess != null;
+ this.fileSystemAccess = fileSystemAccess;
+
+ assert groupDirResolver != null;
+ this.groupDirResolver = groupDirResolver;
+ }
+
+ public void setBeanContainer(final BeanContainer container) {
+ assert container != null;
+
+ this.container = container;
+ }
+
+ public void setAliasCommandBeanId(String aliasCommandBeanId) {
+ this.aliasCommandBeanId = aliasCommandBeanId;
+ }
+
+ public void setGroupCommandBeanId(String groupCommandBeanId) {
+ this.groupCommandBeanId = groupCommandBeanId;
+ }
+
+ //
+ // TODO: Consider adding an undefined command handler to allow for even more customization of
+ // execution when no defined command is found? So one can say directly execute a
+ // *.gsh script, which under the covers will translate into 'source *.gsh' (or really
+ // should be 'shell *.gsh' once we have a sub-shell command.
+ //
+
+ public Command resolveCommand(final String name, final Variables variables) throws CommandException {
+ assert name != null;
+ assert variables != null;
+
+ log.debug("Resolving command name: {}", name);
+
+ // Always try to resolve aliases before we resolve commands
+ Command command = resolveAliasCommand(name, variables);
+
+ if (command == null) {
+ try {
+ FileObject file = resolveCommandFile(name, variables);
+
+ if (file != null) {
+ command = createCommand(file);
+ }
+ }
+ catch (FileSystemException e) {
+ log.warn("Unable to resolve command for name: " + name, e);
+ }
+ }
+
+ if (command == null) {
+ throw new NoSuchCommandException(name);
+ }
+
+ log.debug("Resolved command: {}", command);
+
+ return command;
+ }
+
+ private FileObject getAliasesRoot() throws FileSystemException {
+ if (aliasesRoot == null) {
+ aliasesRoot = fileSystemAccess.createVirtualFileSystem(ALIASES_ROOT);
+ }
+
+ return aliasesRoot;
+ }
+
+ private AliasCommand resolveAliasCommand(final String name, final Variables variables) {
+ assert name != null;
+ assert variables != null;
+
+ log.trace("Resolving alias for name: {}", name);
+
+ AliasCommand command = null;
+
+ try {
+ FileObject root = getAliasesRoot();
+ FileObject file = root.resolveFile(name);
+
+ if (file != null && file.exists()) {
+ log.trace("Resolved file: {}", file);
+
+ command = createAliasCommand(file);
+ }
+ }
+ catch (FileSystemException e) {
+ log.debug("Failed to resolve alias command for name: " + name, e);
+ }
+
+ return command;
+ }
+
+ private FileObject getCommandsRoot() throws FileSystemException {
+ if (commandsRoot == null) {
+ commandsRoot = fileSystemAccess.createVirtualFileSystem(COMMANDS_ROOT);
+ }
+
+ return commandsRoot;
+ }
+
+ private FileObject resolveCommandFile(final String name, final Variables variables) throws FileSystemException {
+ assert name != null;
+ assert variables != null;
+
+ log.trace("Resolving command file: {}", name);
+
+ FileObject root = getCommandsRoot();
+
+ // Special handling for root & group
+ if (name.equals("/")) {
+ return root;
+ }
+ else if (name.equals(".")) {
+ return groupDirResolver.getGroupDirectory(variables);
+ }
+
+ Collection<String> searchPath = getSearchPath(variables);
+
+ log.trace("Search path: {}", searchPath);
+
+ FileObject groupDir = groupDirResolver.getGroupDirectory(variables);
+
+ log.trace("Group dir: {}", groupDir);
+
+ FileObject file = null;
+
+ for (String pathElement : searchPath) {
+ log.trace("Resolving file; name={}, pathElement={}", name, pathElement);
+
+ FileObject dir;
+
+ if (pathElement.equals("/")) {
+ dir = root;
+ }
+ else if (pathElement.startsWith("/")) {
+ dir = fileSystemAccess.resolveFile(root, pathElement.substring(1, pathElement.length()));
+ }
+ else {
+ dir = fileSystemAccess.resolveFile(groupDir, pathElement);
+ }
+
+ log.trace("Dir: {}", dir);
+
+ FileObject tmp = fileSystemAccess.resolveFile(dir, name);
+
+ log.trace("File: {}", tmp);
+
+ if (tmp.exists()) {
+ file = tmp;
+ break;
+ }
+ }
+
+ if (file != null) {
+ log.trace("Resolved file: {}", file);
+ }
+
+ return file;
+ }
+
+ private Collection<String> getSearchPath(final Variables vars) {
+ assert vars != null;
+
+ Object tmp = vars.get(PATH);
+
+ if (tmp instanceof String) {
+ return Arrays.asList(((String)tmp).split(PATH_SEPARATOR));
+ }
+ else if (tmp != null) {
+ log.error("Invalid type for variable '" + PATH + "'; expected String; found: " + tmp.getClass());
+ }
+
+ // Return the default search path (group then root)
+ return Arrays.asList(".", "/");
+ }
+
+ public Collection<Command> resolveCommands(String name, Variables variables) throws CommandException {
+ // name may be null
+ assert variables != null;
+
+ if (name == null) {
+ name = "";
+ }
+
+ log.debug("Resolving commands for name: {}", name);
+
+ List<Command> commands = new ArrayList<Command>();
+
+ try {
+ FileObject file = resolveCommandFile(name, variables);
+
+ log.trace("Resolved (for commands): {}", file);
+
+ if (file != null && file.exists()) {
+ if (file.getType().hasChildren()) {
+ for (FileObject child : file.getChildren()) {
+ Command command = createCommand(child);
+ commands.add(command);
+ }
+ }
+ else {
+ Command command = createCommand(file);
+ commands.add(command);
+ }
+ }
+ }
+ catch (FileSystemException e) {
+ log.warn("Failed to resolve commands for name: " + name, e);
+ }
+
+ log.debug("Resolved {} commands", commands.size());
+ if (log.isTraceEnabled()) {
+ for (Command command : commands) {
+ log.trace(" {}", command);
+ }
+ }
+
+ return commands;
+ }
+
+ private Command createCommand(FileObject file) throws FileSystemException, CommandException {
+ assert file != null;
+
+ // HACK: Must dereference to avoid problems with the DelegateFileObject impl
+ file = fileSystemAccess.dereference(file);
+
+ log.trace("Creating command for file: {} ({})", file, file.getClass());
+
+ Command command = null;
+
+ if (file.exists()) {
+ FileContent content = file.getContent();
+ command = (Command)content.getAttribute("COMMAND");
+
+ if (command == null) {
+ if (file.getType().hasChildren()) {
+ command = createGroupCommand(file);
+ content.setAttribute("COMMAND", command);
+ }
+
+ // TODO: Try to construct AliasCommand?
+ }
+ }
+
+ if (command == null) {
+ throw new CommandException("Unable to create command for file: " + file.getName());
+ }
+
+ return command;
+ }
+
+ private AliasCommand createAliasCommand(final FileObject file) throws FileSystemException {
+ assert file != null;
+
+ String name = file.getName().getBaseName();
+
+ log.trace("Creating command for alias: {}", name);
+
+ AliasCommand command = container.getBean(aliasCommandBeanId, AliasCommand.class);
+
+ String alias = (String) file.getContent().getAttribute("ALIAS");
+ if (alias == null) {
+ throw new IllegalStateException("Alias meta-file does not contain 'ALIAS' attribute: " + file);
+ }
+
+ command.setName(name);
+ command.setAlias(alias);
+
+ return command;
+ }
+
+ private GroupCommand createGroupCommand(final FileObject file) throws FileSystemException {
+ assert file != null;
+
+ log.trace("Creating command for group: {}", file);
+
+ GroupCommand command = container.getBean(groupCommandBeanId, GroupCommand.class);
+ String path = fileSystemAccess.dereference(commandsRoot).getName().getRelativeName(file.getName());
+ if (".".equals(path)) {
+ path = "/";
+ }
+ command.setPath(path);
+
+ return command;
+ }
+}
Modified: felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/OsgiCommandRegistry.java
URL: http://svn.apache.org/viewvc/felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/OsgiCommandRegistry.java?rev=786262&r1=786261&r2=786262&view=diff
==============================================================================
--- felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/OsgiCommandRegistry.java (original)
+++ felix/trunk/karaf/gshell/gshell-core/src/main/java/org/apache/felix/karaf/gshell/core/OsgiCommandRegistry.java Thu Jun 18 20:57:23 2009
@@ -37,21 +37,21 @@
this.commandRegistry = commandRegistry;
}
- public synchronized void register(final Command command, Map<String, ?> properties) throws Exception {
+ public synchronized void register(final Command command, Map props) throws Exception {
commandRegistry.registerCommand(command);
}
- public synchronized void unregister(final Command command, Map<String, ?> properties) throws Exception {
+ public synchronized void unregister(final Command command, Map props) throws Exception {
commandRegistry.removeCommand(command);
}
- public synchronized void register(final Link link, Map<String, ?> properties) throws Exception {
+ public synchronized void register(final Link link, Map props) throws Exception {
LinkCommand cmd = new LinkCommand(commandRegistry, link.getTarget());
cmd.setLocation(new CommandLocationImpl(link.getName()));
commandRegistry.registerCommand(cmd);
}
- public synchronized void unregister(final Link link, Map<String, ?> properties) throws Exception {
+ public synchronized void unregister(final Link link, Map props) throws Exception {
commandRegistry.removeCommand(commandRegistry.getCommand(link.getName()));
}