You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@aries.apache.org by mn...@apache.org on 2010/08/10 15:01:32 UTC

svn commit: r983975 - in /incubator/aries/trunk/application/application-runtime/src/main: java/org/apache/aries/application/runtime/defaults/ resources/OSGI-INF/blueprint/

Author: mnuttall
Date: Tue Aug 10 13:01:31 2010
New Revision: 983975

URL: http://svn.apache.org/viewvc?rev=983975&view=rev
Log:
ARIES-359: Isolated application support. From a patch by Chris Wilkinson. 

Modified:
    incubator/aries/trunk/application/application-runtime/src/main/java/org/apache/aries/application/runtime/defaults/DefaultLocalPlatform.java
    incubator/aries/trunk/application/application-runtime/src/main/java/org/apache/aries/application/runtime/defaults/NoOpResolver.java
    incubator/aries/trunk/application/application-runtime/src/main/resources/OSGI-INF/blueprint/app-context-management.xml

Modified: incubator/aries/trunk/application/application-runtime/src/main/java/org/apache/aries/application/runtime/defaults/DefaultLocalPlatform.java
URL: http://svn.apache.org/viewvc/incubator/aries/trunk/application/application-runtime/src/main/java/org/apache/aries/application/runtime/defaults/DefaultLocalPlatform.java?rev=983975&r1=983974&r2=983975&view=diff
==============================================================================
--- incubator/aries/trunk/application/application-runtime/src/main/java/org/apache/aries/application/runtime/defaults/DefaultLocalPlatform.java (original)
+++ incubator/aries/trunk/application/application-runtime/src/main/java/org/apache/aries/application/runtime/defaults/DefaultLocalPlatform.java Tue Aug 10 13:01:31 2010
@@ -1,37 +0,0 @@
-/*
- * 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.aries.application.runtime.defaults;
-
-import java.io.File;
-import java.io.IOException;
-
-import org.apache.aries.application.management.LocalPlatform;
-
-public class DefaultLocalPlatform implements LocalPlatform {
-
-  public File getTemporaryDirectory() throws IOException {
-    File f = File.createTempFile("ebaTmp", null);
-    f.delete();
-    f.mkdir();
-    return f;
-  } 
-  public File getTemporaryFile () throws IOException { 
-    return File.createTempFile("ebaTmp", null);
-  }
-}

Modified: incubator/aries/trunk/application/application-runtime/src/main/java/org/apache/aries/application/runtime/defaults/NoOpResolver.java
URL: http://svn.apache.org/viewvc/incubator/aries/trunk/application/application-runtime/src/main/java/org/apache/aries/application/runtime/defaults/NoOpResolver.java?rev=983975&r1=983974&r2=983975&view=diff
==============================================================================
--- incubator/aries/trunk/application/application-runtime/src/main/java/org/apache/aries/application/runtime/defaults/NoOpResolver.java (original)
+++ incubator/aries/trunk/application/application-runtime/src/main/java/org/apache/aries/application/runtime/defaults/NoOpResolver.java Tue Aug 10 13:01:31 2010
@@ -1,45 +0,0 @@
-/*
- * 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.aries.application.runtime.defaults;
-
-import java.util.Set;
-
-import org.apache.aries.application.management.AriesApplication;
-import org.apache.aries.application.management.AriesApplicationResolver;
-import org.apache.aries.application.management.BundleInfo;
-import org.apache.aries.application.management.ResolveConstraint;
-import org.osgi.framework.Version;
-
-/** AriesApplicationManager requires that there be at least one 
- * AriesApplicationResolver service present. This class provides a null 
- * implementation: it simply returns the bundles that it was provided with - 
- * enough to permit the testing of Aries applications that have no external 
- * dependencies.   
- */
-public class NoOpResolver implements AriesApplicationResolver {
-
-  public Set<BundleInfo> resolve(AriesApplication app, ResolveConstraint... constraints) {
-    return app.getBundleInfo();
-  }
-
-  public BundleInfo getBundleInfo(String bundleSymbolicName, Version bundleVersion)
-  {
-    return null;
-  }
-}
\ No newline at end of file

Modified: incubator/aries/trunk/application/application-runtime/src/main/resources/OSGI-INF/blueprint/app-context-management.xml
URL: http://svn.apache.org/viewvc/incubator/aries/trunk/application/application-runtime/src/main/resources/OSGI-INF/blueprint/app-context-management.xml?rev=983975&r1=983974&r2=983975&view=diff
==============================================================================
--- incubator/aries/trunk/application/application-runtime/src/main/resources/OSGI-INF/blueprint/app-context-management.xml (original)
+++ incubator/aries/trunk/application/application-runtime/src/main/resources/OSGI-INF/blueprint/app-context-management.xml Tue Aug 10 13:01:31 2010
@@ -24,18 +24,5 @@
   </bean>
 
   <service interface="org.apache.aries.application.management.AriesApplicationContextManager" ref="app-context-manager" />
-  
-  <!-- Default implementations of services that must be implemented against a 
-       particular application server environment follow -->
-
-  <bean id="default-local-platform" class="org.apache.aries.application.runtime.defaults.DefaultLocalPlatform"/>
-  <bean id="no-op-resolver" class="org.apache.aries.application.runtime.defaults.NoOpResolver"/>
-  
-  <service interface="org.apache.aries.application.management.LocalPlatform" 
-            ref="default-local-platform"
-            ranking="-1"/>
-  <service interface="org.apache.aries.application.management.AriesApplicationResolver" 
-            ref="no-op-resolver"
-            ranking="-1"/>
-  
+    
 </blueprint>