aries-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jwr...@apache.org
Subject svn commit: r1245173 - in /aries/trunk/subsystem/subsystem-core/src/main/java/org/apache: aries/subsystem/core/ aries/subsystem/core/archive/ aries/subsystem/core/internal/ aries/subsystem/core/obr/ felix/resolver/ felix/resolver/impl/
Date Thu, 16 Feb 2012 20:50:00 GMT
Author: jwross
Date: Thu Feb 16 20:49:59 2012
New Revision: 1245173

URL: http://svn.apache.org/viewvc?rev=1245173&view=rev
Log:
ARIES-825: Update subsystems to latest Subsystem, Resolver, and Repository APIs.

After much thought, I decided to make the Felix resolver an internal implementation detail
of Aries Subsystems for now.

(1) The Felix resolver is the only known implementation of RFC 112 in any shape or form.
(2) The Felix resolver is a work in progress and doesn't reflect the very latest API changes,
which are used in the CT. Consequently, it is not possible to run against the CT and import
the API without updating the Felix resolver. The task of updating the Felix resolver code
to the latest API is not trivial and would be throw away work as Felix is in the process of
updating it themselves.
(3) The Felix resolver is in an SCM sandbox and not currently published to a maven repository.

Once Felix has updated their implementation and made it available in a maven repository, I
will back this out and switch to it.

Added:
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/Environment.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/ResolutionException.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/Resolver.java
Modified:
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/archive/DeploymentManifest.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/Activator.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/obr/SubsystemEnvironment.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/obr/SubsystemResolver.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/FelixEnvironment.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/FelixResolver.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/Candidates.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/EnvironmentAdaptor.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostResource.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostedCapability.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostedRequirement.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/ResolverImpl.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/Util.java
    aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/WireImpl.java

Added: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/Environment.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/Environment.java?rev=1245173&view=auto
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/Environment.java
(added)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/Environment.java
Thu Feb 16 20:49:59 2012
@@ -0,0 +1,128 @@
+/*
+ * Copyright (c) OSGi Alliance (2011). All Rights Reserved.
+ *
+ * Licensed 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.subsystem.core;
+
+import java.util.Collection;
+import java.util.Map;
+import java.util.SortedSet;
+
+import org.osgi.framework.resource.Capability;
+import org.osgi.framework.resource.Requirement;
+import org.osgi.framework.resource.Resource;
+import org.osgi.framework.resource.Wiring;
+
+/**
+ * An environment provides options and constraints to the potential solution of
+ * a {@link Resolver#resolve(Environment, Collection, Collection)} operation.
+ *
+ * <p>
+ * Environments:
+ * <ul>
+ * <li>Provide {@link Capability capabilities} that the Resolver can use
+ * to satisfy {@link Requirement requirements} via the
+ * {@link #findProviders(Requirement)} method</li>
+ *
+ * <li>Constrain solutions via the {@link #getWirings()} method. This provides
+ * a map to link existing resolved {@link Resource resources} to their {@link Wiring
+ * wirings}.
+ *
+ * <li>Filter transitive requirements that are brought in as part of a resolve
+ * operation via the {@link #isEffective(Requirement)}.
+ * </ul>
+ *
+ * <p>
+ * An environment may be used to provide capabilities via local {@link Resource
+ * resources} and/or remote {@link org.osgi.service.repository.Repository repositories}.
+ *
+ * <p>
+ * A resolver may call the {@link #findProviders(Requirement)},
+ * {@link #isEffective(Requirement)} and {@link #getWirings()} method any number of
+ * times during a resolve using any thread. Environments may also be shared
+ * between several resolvers. As such implementors should ensure that this class
+ * is properly synchronized.
+ *
+ * @ThreadSafe
+ */
+public interface Environment {
+  /**
+   * Find any capabilities that {@link Requirement#matches(Capability) match}
+   * the supplied requirement.
+   *
+   * <p>
+   * A resolver should use the iteration order or the returned capability
+   * collection to infer preference in the case where multiple capabilities
+   * match a requirement. Capabilities at the start of the iteration are implied
+   * to be preferred over capabilities at the end.
+   *
+   * @param requirement
+   *          the requirement that a resolver is attempting to satisfy
+   *
+   * @return an collection of capabilities that match the supplied
+   *         requirement
+   *
+   * @throws NullPointerException if the requirement is null
+   */
+  SortedSet<Capability> findProviders(Requirement requirement);
+  
+  /**
+	 * Find any capabilities that match the supplied requirement.
+	 * 
+	 * <p>
+	 * The set returned by this call should be mutable to support ordering of
+	 * {@link Synthesized} resources created by the resolution process.
+	 * 
+	 * <p>
+	 * See {@link #findProviders} for a discussion on matching.
+	 * 
+	 * @param requirements the requirements that should be matched
+	 * 
+	 * @return A map of requirements to capabilities that match the supplied
+	 *         requirements
+	 * 
+	 * @throws NullPointerException if requirements is null
+	 * 
+	 * 
+	 * @see #findProviders
+	 */
+	Map<Requirement, SortedSet<Capability>> findProviders(Collection<? extends
Requirement> requirements);
+
+  /**
+   * Test if a given requirement should be wired in a given resolve
+   * operation. If this method returns false then the resolver should ignore
+   * this requirement during this resolve operation.
+   *
+   * <p>
+   * The primary use case for this is to test the <code>effective</code> directive
+   * on the requirement, though implementations are free to use this for any other
+   * purposes.
+   *
+   * @param requirement the Requirement to test
+   *
+   * @return true if the requirement should be considered as part of this resolve operation
+   *
+   * @throws NullPointerException if requirement is null
+   */
+  boolean isEffective(Requirement requirement);
+
+  	/**
+	 * An immutable map of wirings for resources. Multiple calls to this method
+	 * for the same environment object must result in the same set of wirings.
+	 *
+	 * @return the wirings already defined in this environment
+	 */
+	Map<Resource, Wiring> getWirings();
+}

Added: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/ResolutionException.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/ResolutionException.java?rev=1245173&view=auto
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/ResolutionException.java
(added)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/ResolutionException.java
Thu Feb 16 20:49:59 2012
@@ -0,0 +1,128 @@
+/*
+ * Copyright (c) OSGi Alliance (2011). All Rights Reserved.
+ * 
+ * Licensed 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.subsystem.core;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+
+import org.osgi.framework.resource.Requirement;
+
+/**
+ * Indicates failure to resolve a set of requirements.
+ * 
+ * <p>
+ * If a resolution failure is caused by a missing mandatory dependency a
+ * resolver may include any requirements it has considered in the resolution
+ * exception. Clients may access this set of dependencies via the
+ * {@link #getUnresolvedRequirements()} method.
+ * 
+ * <p>
+ * Resolver implementations may subclass this class to provide extra state
+ * information about the reason for the resolution failure.
+ * 
+ * @ThreadSafe
+ * @Immutable
+ */
+public class ResolutionException extends RuntimeException {
+
+  private static final long serialVersionUID = 1L;
+
+  // NOTE used requirement[] not collection to avoid accidental serialization
+  // issues
+  private Requirement[] unresolvedRequirements;
+
+  /**
+   * Creates an exception of type {@code ResolutionException}.
+   * 
+   * <p>
+   * This method creates an {@code ResolutionException} object with the
+   * specified message, cause and unresolvedRequirements.
+   * 
+   * @param message
+   *          The message.
+   * @param cause
+   *          The cause of this exception.
+   * @param unresolvedRequirements
+   *          the requirements that are unresolved or null if no unresolved requirements
+   *          information is provided.
+   */
+  public ResolutionException(String message, Throwable cause,
+      Collection<Requirement> unresolvedRequirements) {
+    super(message, cause);
+    if (unresolvedRequirements != null) {
+      // copy array both fixes serialization issues and
+      // ensures exception is immutable
+      this.unresolvedRequirements = unresolvedRequirements
+          .toArray(new Requirement[unresolvedRequirements.size()]);
+    }
+  }
+
+  /**
+   * Creates an exception of type {@code ResolutionException}.
+   * 
+   * <p>
+   * This method creates an {@code ResolutionException} object with the
+   * specified message.
+   * 
+   * @param message
+   *          The message.
+   */
+  public ResolutionException(String message) {
+    super(message);
+  }
+
+  /**
+   * Creates an exception of type {@code ResolutionException}.
+   * 
+   * <p>
+   * This method creates an {@code ResolutionException} object with the
+   * specified cause.
+   * 
+   * @param cause
+   *          The cause of this exception.
+   */
+  public ResolutionException(Throwable cause) {
+    super(cause);
+  }
+
+  /**
+   * May contain one or more unresolved mandatory requirements from mandatory
+   * resources.
+   * 
+   * <p>
+   * This exception is provided for informational purposes and the specific set
+   * of requirements that are returned after a resolve failure is not defined.
+   * 
+   * @return a collection of requirements that are unsatisfied
+   */
+  public Collection<Requirement> getUnresolvedRequirements() {
+    // creating at each call ensures internal data is immutable
+    // TODO could use a transient field to reduce CPU cost at expense of RAM -
+    // both trivial compared to code complexity
+    if (unresolvedRequirements == null) {
+      return Collections.EMPTY_LIST;
+    } else {
+      ArrayList<Requirement> requirements = new ArrayList<Requirement>(
+          unresolvedRequirements.length);
+      for (Requirement r : unresolvedRequirements) {
+        requirements.add(r);
+      }
+      return requirements;
+    }
+  }
+}

Added: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/Resolver.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/Resolver.java?rev=1245173&view=auto
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/Resolver.java
(added)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/Resolver.java
Thu Feb 16 20:49:59 2012
@@ -0,0 +1,111 @@
+/*
+ * Copyright (c) OSGi Alliance (2006, 2010). All Rights Reserved.
+ *
+ * Licensed 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.
+ */
+
+// This document is an experimental draft to enable interoperability
+// between bundle repositories. There is currently no commitment to
+// turn this draft into an official specification.
+
+package org.apache.aries.subsystem.core;
+
+import java.util.Collection;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.felix.resolver.FelixEnvironment;
+import org.osgi.framework.resource.Resource;
+import org.osgi.framework.resource.Wire;
+
+/**
+ * A resolver is a service interface that can be used to find resolutions for
+ * specified {@link Resource resources} based on a supplied {@link Environment}.
+ *
+ * @ThreadSafe
+ * @version $Id: 5735a30be6494040afe5a05cadf353cf0ce943a0 $
+ */
+public interface Resolver {
+  /**
+   * Attempt to resolve the resources based on the specified environment and
+   * return any new resources and wires to the caller.
+   *
+   * <p>
+   * The resolver considers two groups of resources:
+   * <ul>
+   * <li>Mandatory - any resource in the mandatory group must be resolved, a
+   * failure to satisfy any mandatory requirement for these resources will
+   * result in a {@link ResolutionException}</li>
+   * <li>Optional - any resource in the optional group may be resolved, a
+   * failure to satisfy a mandatory requirement for a resource in this group
+   * will not fail the overall resolution but no resources or wires will be
+   * returned for this resource.</li>
+   * </ul>
+   *
+   * <h3>Delta</h3>
+   * <p>
+   * The resolve method returns the delta between the start state defined by
+   * {@link Environment#getWiring()} and the end resolved state, i.e. only new
+   * resources and wires are included. To get the complete resolution the caller
+   * can merge the start state and the delta using something like the following:
+   *
+   * <pre>
+   * Map&lt;Resource, List&lt;Wire&gt;&gt; delta = resolver.resolve(env,
resources, null);
+   * Map&lt;Resource, List&lt;Wire&gt;&gt; wiring = env.getWiring();
+   *
+   * for (Map.Entry&lt;Resource, List&lt;Wire&gt;&gt; e : delta.entrySet())
{
+   *   Resource res = e.getKey();
+   *   List&lt;Wire&gt; newWires = e.getValue();
+   *
+   *   List&lt;Wire&gt; currentWires = wiring.get(res);
+   *   if (currentWires != null) {
+   *     newWires.addAll(currentWires);
+   *   }
+   *
+   *   wiring.put(res, newWires);
+   * }
+   * </pre>
+   *
+   * <h3>Consistency</h3>
+   * <p>
+   * For a given resolve operation the parameters to the resolve method should be
+   * considered immutable. This means that resources should have constant
+   * capabilities and requirements and an environment should return a consistent
+   * set of capabilities, wires and effective requirements.
+   *
+   * <p>
+   * The behavior of the resolver is not defined if resources or the environment
+   * supply inconsistent information.
+   *
+   * @param environment
+   *          the environment into which to resolve the requirements
+   * @param mandatoryResources
+   *          The resources that must be resolved during this resolution step or
+   *          null if no resources must be resolved
+   * @param optionalResources
+   *          Any resources which the resolver should attempt to resolve but
+   *          that will not cause an exception if resolution is impossible or
+   *          null if no resources are optional.
+   *
+   * @return the new resources and wires required to satisfy the requirements
+   *
+   * @throws ResolutionException
+   *           if the resolution cannot be satisfied for any reason
+   * @throws NullPointerException
+   *           if environment is null
+   */
+	Map<Resource, List<Wire>> resolve(Environment environment,
+			Collection<? extends Resource> mandatoryResources,
+			Collection<? extends Resource> optionalResources)
+			throws ResolutionException;
+}

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/archive/DeploymentManifest.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/archive/DeploymentManifest.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/archive/DeploymentManifest.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/archive/DeploymentManifest.java
Thu Feb 16 20:49:59 2012
@@ -16,6 +16,7 @@ import java.util.Map.Entry;
 import java.util.jar.Attributes;
 import java.util.jar.Manifest;
 
+import org.apache.aries.subsystem.core.Resolver;
 import org.apache.aries.subsystem.core.internal.Activator;
 import org.apache.aries.subsystem.core.internal.OsgiIdentityRequirement;
 import org.apache.aries.subsystem.core.obr.SubsystemEnvironment;
@@ -23,7 +24,6 @@ import org.apache.aries.util.manifest.Ma
 import org.osgi.framework.Constants;
 import org.osgi.framework.resource.Resource;
 import org.osgi.framework.resource.Wire;
-import org.osgi.service.resolver.Resolver;
 import org.osgi.service.subsystem.SubsystemConstants;
 import org.osgi.service.subsystem.SubsystemException;
 
@@ -85,7 +85,7 @@ public class DeploymentManifest {
 					resources.add(resource);
 				}
 				// TODO This does not validate that all content bundles were found.
-				Map<Resource, List<Wire>> resolution = Activator.getInstance().getServiceProvider().getService(Resolver.class).resolve(environment,
new ArrayList<Resource>(resources), Collections.EMPTY_LIST);
+				Map<Resource, List<Wire>> resolution = Activator.getInstance().getResolver().resolve(environment,
new ArrayList<Resource>(resources), Collections.EMPTY_LIST);
 				// TODO Once we have a resolver that actually returns lists of wires, we can use them
to compute other manifest headers such as Import-Package.
 				Collection<Resource> deployedContent = new HashSet<Resource>();
 				Collection<Resource> provisionResource = new HashSet<Resource>();

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/Activator.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/Activator.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/Activator.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/internal/Activator.java
Thu Feb 16 20:49:59 2012
@@ -19,14 +19,13 @@ import static org.apache.aries.applicati
 import java.util.ArrayList;
 import java.util.List;
 
+import org.apache.aries.subsystem.core.Resolver;
 import org.apache.felix.resolver.impl.ResolverImpl;
 import org.osgi.framework.BundleActivator;
 import org.osgi.framework.BundleContext;
 import org.osgi.framework.BundleListener;
 import org.osgi.framework.ServiceRegistration;
 import org.osgi.framework.hooks.resolver.ResolverHookFactory;
-import org.osgi.service.resolver.Resolver;
-import org.osgi.service.subsystem.Subsystem;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -68,6 +67,10 @@ public class Activator implements Bundle
 		return result;
 	}
 	
+	public Resolver getResolver() {
+		return new ResolverImpl(null);
+	}
+	
 	public synchronized ServiceProvider getServiceProvider() {
 		logger.debug(LOG_ENTRY, "getServiceProvider");
 		ServiceProvider result = serviceProvider;

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/obr/SubsystemEnvironment.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/obr/SubsystemEnvironment.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/obr/SubsystemEnvironment.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/obr/SubsystemEnvironment.java
Thu Feb 16 20:49:59 2012
@@ -27,6 +27,7 @@ import java.util.Set;
 import java.util.SortedSet;
 import java.util.TreeSet;
 
+import org.apache.aries.subsystem.core.Environment;
 import org.apache.aries.subsystem.core.ResourceHelper;
 import org.apache.aries.subsystem.core.internal.Activator;
 import org.apache.aries.subsystem.core.internal.AriesSubsystem;
@@ -39,7 +40,6 @@ import org.osgi.framework.resource.Resou
 import org.osgi.framework.resource.Wiring;
 import org.osgi.framework.wiring.BundleRevision;
 import org.osgi.service.repository.Repository;
-import org.osgi.service.resolver.Environment;
 import org.osgi.service.subsystem.Subsystem;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/obr/SubsystemResolver.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/obr/SubsystemResolver.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/obr/SubsystemResolver.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/aries/subsystem/core/obr/SubsystemResolver.java
Thu Feb 16 20:49:59 2012
@@ -23,6 +23,9 @@ import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 
+import org.apache.aries.subsystem.core.Environment;
+import org.apache.aries.subsystem.core.ResolutionException;
+import org.apache.aries.subsystem.core.Resolver;
 import org.apache.aries.subsystem.core.internal.Activator;
 import org.apache.aries.subsystem.core.obr.felix.OsgiResourceAdapter;
 import org.apache.felix.bundlerepository.Reason;
@@ -31,10 +34,6 @@ import org.osgi.framework.resource.Capab
 import org.osgi.framework.resource.Requirement;
 import org.osgi.framework.resource.Resource;
 import org.osgi.framework.resource.Wire;
-import org.osgi.framework.resource.Wiring;
-import org.osgi.service.resolver.Environment;
-import org.osgi.service.resolver.ResolutionException;
-import org.osgi.service.resolver.Resolver;
 import org.osgi.service.subsystem.SubsystemException;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/FelixEnvironment.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/FelixEnvironment.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/FelixEnvironment.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/FelixEnvironment.java
Thu Feb 16 20:49:59 2012
@@ -18,9 +18,9 @@
  */
 package org.apache.felix.resolver;
 
+import org.apache.aries.subsystem.core.Environment;
+import org.apache.aries.subsystem.core.ResolutionException;
 import org.osgi.framework.resource.Resource;
-import org.osgi.service.resolver.Environment;
-import org.osgi.service.resolver.ResolutionException;
 
 public interface FelixEnvironment extends Environment
 {

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/FelixResolver.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/FelixResolver.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/FelixResolver.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/FelixResolver.java
Thu Feb 16 20:49:59 2012
@@ -22,11 +22,12 @@ import java.util.Collection;
 import java.util.List;
 import java.util.Map;
 import java.util.SortedSet;
+
+import org.apache.aries.subsystem.core.Resolver;
 import org.osgi.framework.resource.Capability;
 import org.osgi.framework.resource.Requirement;
 import org.osgi.framework.resource.Resource;
 import org.osgi.framework.resource.Wire;
-import org.osgi.service.resolver.Resolver;
 
 public interface FelixResolver extends Resolver
 {

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/Candidates.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/Candidates.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/Candidates.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/Candidates.java
Thu Feb 16 20:49:59 2012
@@ -30,6 +30,9 @@ import java.util.Set;
 import java.util.SortedSet;
 import java.util.TreeMap;
 import java.util.TreeSet;
+
+import org.apache.aries.subsystem.core.Environment;
+import org.apache.aries.subsystem.core.ResolutionException;
 import org.apache.felix.resolver.FelixEnvironment;
 import org.osgi.framework.Constants;
 import org.osgi.framework.Version;
@@ -38,8 +41,6 @@ import org.osgi.framework.resource.Requi
 import org.osgi.framework.resource.Resource;
 import org.osgi.framework.resource.ResourceConstants;
 import org.osgi.framework.resource.Wire;
-import org.osgi.service.resolver.Environment;
-import org.osgi.service.resolver.ResolutionException;
 import org.osgi.framework.resource.Wiring;
 
 class Candidates

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/EnvironmentAdaptor.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/EnvironmentAdaptor.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/EnvironmentAdaptor.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/EnvironmentAdaptor.java
Thu Feb 16 20:49:59 2012
@@ -4,13 +4,13 @@ import java.util.Collection;
 import java.util.Map;
 import java.util.SortedSet;
 
+import org.apache.aries.subsystem.core.Environment;
+import org.apache.aries.subsystem.core.ResolutionException;
 import org.apache.felix.resolver.FelixEnvironment;
 import org.osgi.framework.resource.Capability;
 import org.osgi.framework.resource.Requirement;
 import org.osgi.framework.resource.Resource;
 import org.osgi.framework.resource.Wiring;
-import org.osgi.service.resolver.Environment;
-import org.osgi.service.resolver.ResolutionException;
 
 public class EnvironmentAdaptor implements FelixEnvironment {
 	private final Environment environment;

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostResource.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostResource.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostResource.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostResource.java
Thu Feb 16 20:49:59 2012
@@ -21,6 +21,7 @@ package org.apache.felix.resolver.impl;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
+
 import org.osgi.framework.resource.Capability;
 import org.osgi.framework.resource.Requirement;
 import org.osgi.framework.resource.Resource;

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostedCapability.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostedCapability.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostedCapability.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostedCapability.java
Thu Feb 16 20:49:59 2012
@@ -19,6 +19,7 @@
 package org.apache.felix.resolver.impl;
 
 import java.util.Map;
+
 import org.osgi.framework.resource.Capability;
 import org.osgi.framework.resource.Resource;
 import org.osgi.framework.resource.ResourceConstants;

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostedRequirement.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostedRequirement.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostedRequirement.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/HostedRequirement.java
Thu Feb 16 20:49:59 2012
@@ -19,6 +19,7 @@
 package org.apache.felix.resolver.impl;
 
 import java.util.Map;
+
 import org.osgi.framework.resource.Capability;
 import org.osgi.framework.resource.Requirement;
 import org.osgi.framework.resource.Resource;

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/ResolverImpl.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/ResolverImpl.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/ResolverImpl.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/ResolverImpl.java
Thu Feb 16 20:49:59 2012
@@ -30,6 +30,9 @@ import java.util.Map.Entry;
 import java.util.Set;
 import java.util.SortedSet;
 import java.util.StringTokenizer;
+
+import org.apache.aries.subsystem.core.Environment;
+import org.apache.aries.subsystem.core.ResolutionException;
 import org.apache.felix.resolver.FelixCapability;
 import org.apache.felix.resolver.FelixEnvironment;
 import org.apache.felix.resolver.FelixResolver;
@@ -40,8 +43,6 @@ import org.osgi.framework.resource.Requi
 import org.osgi.framework.resource.Resource;
 import org.osgi.framework.resource.ResourceConstants;
 import org.osgi.framework.resource.Wire;
-import org.osgi.service.resolver.Environment;
-import org.osgi.service.resolver.ResolutionException;
 import org.osgi.framework.resource.Wiring;
 
 public class ResolverImpl implements FelixResolver

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/Util.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/Util.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/Util.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/Util.java
Thu Feb 16 20:49:59 2012
@@ -21,6 +21,7 @@ package org.apache.felix.resolver.impl;
 import java.util.ArrayList;
 import java.util.List;
 
+import org.apache.aries.subsystem.core.Environment;
 import org.apache.aries.subsystem.core.ResourceHelper;
 import org.osgi.framework.Constants;
 import org.osgi.framework.Version;
@@ -28,7 +29,6 @@ import org.osgi.framework.resource.Capab
 import org.osgi.framework.resource.Requirement;
 import org.osgi.framework.resource.Resource;
 import org.osgi.framework.resource.ResourceConstants;
-import org.osgi.service.resolver.Environment;
 import org.osgi.framework.resource.Wiring;
 
 public class Util

Modified: aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/WireImpl.java
URL: http://svn.apache.org/viewvc/aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/WireImpl.java?rev=1245173&r1=1245172&r2=1245173&view=diff
==============================================================================
--- aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/WireImpl.java
(original)
+++ aries/trunk/subsystem/subsystem-core/src/main/java/org/apache/felix/resolver/impl/WireImpl.java
Thu Feb 16 20:49:59 2012
@@ -18,12 +18,10 @@
  */
 package org.apache.felix.resolver.impl;
 
-import java.util.List;
 import org.osgi.framework.resource.Capability;
 import org.osgi.framework.resource.Requirement;
 import org.osgi.framework.resource.Resource;
 import org.osgi.framework.resource.Wire;
-import org.osgi.framework.resource.Wiring;
 
 class WireImpl implements Wire
 {



Mime
View raw message