sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cziege...@apache.org
Subject [sling-whiteboard] branch master updated: Move resolving to separate package
Date Tue, 17 Apr 2018 07:25:19 GMT
This is an automated email from the ASF dual-hosted git repository.

cziegeler pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-whiteboard.git


The following commit(s) were added to refs/heads/master by this push:
     new 798f899  Move resolving to separate package
798f899 is described below

commit 798f899d201ca116af5cc0a3d8fc6d1f2f9890af
Author: Carsten Ziegeler <cziegeler@apache.org>
AuthorDate: Tue Apr 17 09:25:12 2018 +0200

    Move resolving to separate package
---
 .../sling/feature/analyser/AnalyserTest.java       |  4 +--
 .../feature/analyser/TestBundleResourceImpl.java   |  2 +-
 .../feature/applicationbuilder/impl/Main.java      |  2 +-
 .../impl/ApplicationBuilderTest.java               |  2 +-
 .../feature/launcher/impl/FeatureProcessor.java    |  2 +-
 .../modelconverter/impl/FeatureToProvisioning.java |  2 +-
 .../sling/feature/resolver/FrameworkResolver.java  | 35 ++++++++++------------
 .../feature/resolver/impl/BundleResourceImpl.java  | 14 ++++-----
 .../feature/resolver/impl/FeatureResourceImpl.java | 14 ++++-----
 .../feature/resolver/FrameworkResolverTest.java    | 28 ++++++++---------
 .../resolver/impl/BundleResourceImplTest.java      | 30 +++++++++----------
 .../apache/sling/feature/support/FeatureUtil.java  |  2 +-
 .../support/process/ApplicationBuilder.java        |  2 ++
 .../{process => resolver}/FeatureResolver.java     |  2 +-
 .../{process => resolver}/FeatureResource.java     |  2 +-
 15 files changed, 70 insertions(+), 73 deletions(-)

diff --git a/featuremodel/feature-analyser/src/test/java/org/apache/sling/feature/analyser/AnalyserTest.java
b/featuremodel/feature-analyser/src/test/java/org/apache/sling/feature/analyser/AnalyserTest.java
index 213ac63..d6f65b7 100644
--- a/featuremodel/feature-analyser/src/test/java/org/apache/sling/feature/analyser/AnalyserTest.java
+++ b/featuremodel/feature-analyser/src/test/java/org/apache/sling/feature/analyser/AnalyserTest.java
@@ -27,8 +27,8 @@ import org.apache.sling.feature.support.ArtifactManagerConfig;
 import org.apache.sling.feature.support.FeatureUtil;
 import org.apache.sling.feature.support.json.FeatureJSONReader;
 import org.apache.sling.feature.support.json.FeatureJSONReader.SubstituteVariables;
-import org.apache.sling.feature.support.process.FeatureResolver;
-import org.apache.sling.feature.support.process.FeatureResource;
+import org.apache.sling.feature.support.resolver.FeatureResolver;
+import org.apache.sling.feature.support.resolver.FeatureResource;
 import org.junit.Test;
 
 import java.io.File;
diff --git a/featuremodel/feature-analyser/src/test/java/org/apache/sling/feature/analyser/TestBundleResourceImpl.java
b/featuremodel/feature-analyser/src/test/java/org/apache/sling/feature/analyser/TestBundleResourceImpl.java
index 2fd7962..11e7d5d 100644
--- a/featuremodel/feature-analyser/src/test/java/org/apache/sling/feature/analyser/TestBundleResourceImpl.java
+++ b/featuremodel/feature-analyser/src/test/java/org/apache/sling/feature/analyser/TestBundleResourceImpl.java
@@ -20,7 +20,7 @@ import org.apache.sling.feature.Artifact;
 import org.apache.sling.feature.Feature;
 import org.apache.sling.feature.OSGiCapability;
 import org.apache.sling.feature.OSGiRequirement;
-import org.apache.sling.feature.support.process.FeatureResource;
+import org.apache.sling.feature.support.resolver.FeatureResource;
 import org.apache.sling.feature.support.util.PackageInfo;
 import org.osgi.framework.Version;
 import org.osgi.framework.VersionRange;
diff --git a/featuremodel/feature-applicationbuilder/src/main/java/org/apache/sling/feature/applicationbuilder/impl/Main.java
b/featuremodel/feature-applicationbuilder/src/main/java/org/apache/sling/feature/applicationbuilder/impl/Main.java
index 57c08b2..fc9b591 100644
--- a/featuremodel/feature-applicationbuilder/src/main/java/org/apache/sling/feature/applicationbuilder/impl/Main.java
+++ b/featuremodel/feature-applicationbuilder/src/main/java/org/apache/sling/feature/applicationbuilder/impl/Main.java
@@ -29,7 +29,7 @@ import org.apache.sling.feature.support.ArtifactManager;
 import org.apache.sling.feature.support.ArtifactManagerConfig;
 import org.apache.sling.feature.support.FeatureUtil;
 import org.apache.sling.feature.support.json.ApplicationJSONWriter;
-import org.apache.sling.feature.support.process.FeatureResolver;
+import org.apache.sling.feature.support.resolver.FeatureResolver;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
diff --git a/featuremodel/feature-applicationbuilder/src/test/java/org/apache/sling/feature/applicationbuilder/impl/ApplicationBuilderTest.java
b/featuremodel/feature-applicationbuilder/src/test/java/org/apache/sling/feature/applicationbuilder/impl/ApplicationBuilderTest.java
index 4887eb7..07faad6 100644
--- a/featuremodel/feature-applicationbuilder/src/test/java/org/apache/sling/feature/applicationbuilder/impl/ApplicationBuilderTest.java
+++ b/featuremodel/feature-applicationbuilder/src/test/java/org/apache/sling/feature/applicationbuilder/impl/ApplicationBuilderTest.java
@@ -29,7 +29,7 @@ import org.apache.sling.feature.support.json.FeatureJSONReader.SubstituteVariabl
 import org.apache.sling.feature.support.process.ApplicationBuilder;
 import org.apache.sling.feature.support.process.BuilderContext;
 import org.apache.sling.feature.support.process.FeatureProvider;
-import org.apache.sling.feature.support.process.FeatureResolver;
+import org.apache.sling.feature.support.resolver.FeatureResolver;
 import org.junit.After;
 import org.junit.Before;
 import org.junit.Test;
diff --git a/featuremodel/feature-launcher/src/main/java/org/apache/sling/feature/launcher/impl/FeatureProcessor.java
b/featuremodel/feature-launcher/src/main/java/org/apache/sling/feature/launcher/impl/FeatureProcessor.java
index 8194698..99d3c47 100644
--- a/featuremodel/feature-launcher/src/main/java/org/apache/sling/feature/launcher/impl/FeatureProcessor.java
+++ b/featuremodel/feature-launcher/src/main/java/org/apache/sling/feature/launcher/impl/FeatureProcessor.java
@@ -36,7 +36,7 @@ import org.apache.sling.feature.support.ArtifactManager;
 import org.apache.sling.feature.support.FeatureUtil;
 import org.apache.sling.feature.support.json.ApplicationJSONReader;
 import org.apache.sling.feature.support.json.ApplicationJSONWriter;
-import org.apache.sling.feature.support.process.FeatureResolver;
+import org.apache.sling.feature.support.resolver.FeatureResolver;
 
 public class FeatureProcessor {
 
diff --git a/featuremodel/feature-modelconverter/src/main/java/org/apache/sling/feature/modelconverter/impl/FeatureToProvisioning.java
b/featuremodel/feature-modelconverter/src/main/java/org/apache/sling/feature/modelconverter/impl/FeatureToProvisioning.java
index 4c7089e..cf5a3a5 100644
--- a/featuremodel/feature-modelconverter/src/main/java/org/apache/sling/feature/modelconverter/impl/FeatureToProvisioning.java
+++ b/featuremodel/feature-modelconverter/src/main/java/org/apache/sling/feature/modelconverter/impl/FeatureToProvisioning.java
@@ -28,7 +28,7 @@ import org.apache.sling.feature.support.ArtifactManager;
 import org.apache.sling.feature.support.FeatureUtil;
 import org.apache.sling.feature.support.json.ApplicationJSONReader;
 import org.apache.sling.feature.support.json.FeatureJSONReader.SubstituteVariables;
-import org.apache.sling.feature.support.process.FeatureResolver;
+import org.apache.sling.feature.support.resolver.FeatureResolver;
 import org.apache.sling.provisioning.model.Artifact;
 import org.apache.sling.provisioning.model.Configuration;
 import org.apache.sling.provisioning.model.Feature;
diff --git a/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/FrameworkResolver.java
b/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/FrameworkResolver.java
index 83767b2..1081429 100644
--- a/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/FrameworkResolver.java
+++ b/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/FrameworkResolver.java
@@ -16,6 +16,19 @@
  */
 package org.apache.sling.feature.resolver;
 
+import java.io.File;
+import java.io.IOException;
+import java.nio.file.Files;
+import java.nio.file.Path;
+import java.nio.file.Paths;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.HashMap;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Map;
+import java.util.ServiceLoader;
+
 import org.apache.sling.feature.Artifact;
 import org.apache.sling.feature.ArtifactId;
 import org.apache.sling.feature.Feature;
@@ -25,8 +38,8 @@ import org.apache.sling.feature.resolver.impl.BundleResourceImpl;
 import org.apache.sling.feature.resolver.impl.FeatureResourceImpl;
 import org.apache.sling.feature.resolver.impl.ResolveContextImpl;
 import org.apache.sling.feature.support.ArtifactManager;
-import org.apache.sling.feature.support.process.FeatureResolver;
-import org.apache.sling.feature.support.process.FeatureResource;
+import org.apache.sling.feature.support.resolver.FeatureResolver;
+import org.apache.sling.feature.support.resolver.FeatureResource;
 import org.osgi.framework.BundleContext;
 import org.osgi.framework.BundleException;
 import org.osgi.framework.Constants;
@@ -45,24 +58,6 @@ import org.osgi.resource.Wire;
 import org.osgi.service.resolver.ResolutionException;
 import org.osgi.service.resolver.Resolver;
 
-import java.io.File;
-import java.io.IOException;
-import java.util.Collections;
-import java.util.HashMap;
-import java.nio.file.Files;
-import java.nio.file.Path;
-import java.nio.file.Paths;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.Map;
-import java.util.ServiceLoader;
-import java.util.Set;
-
 public class FrameworkResolver implements FeatureResolver {
     private final ArtifactManager artifactManager;
     private final Resolver resolver;
diff --git a/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/impl/BundleResourceImpl.java
b/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/impl/BundleResourceImpl.java
index e6e061a..8a110cf 100644
--- a/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/impl/BundleResourceImpl.java
+++ b/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/impl/BundleResourceImpl.java
@@ -16,12 +16,18 @@
  */
 package org.apache.sling.feature.resolver.impl;
 
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
 import org.apache.sling.feature.Artifact;
 import org.apache.sling.feature.Feature;
 import org.apache.sling.feature.OSGiCapability;
 import org.apache.sling.feature.OSGiRequirement;
 import org.apache.sling.feature.analyser.BundleDescriptor;
-import org.apache.sling.feature.support.process.FeatureResource;
+import org.apache.sling.feature.support.resolver.FeatureResource;
 import org.apache.sling.feature.support.util.PackageInfo;
 import org.osgi.framework.Version;
 import org.osgi.framework.VersionRange;
@@ -32,12 +38,6 @@ import org.osgi.framework.namespace.PackageNamespace;
 import org.osgi.resource.Capability;
 import org.osgi.resource.Requirement;
 
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
 /**
  * Implementation of the OSGi Resource interface.
  */
diff --git a/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/impl/FeatureResourceImpl.java
b/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/impl/FeatureResourceImpl.java
index 4b0c145..093ab3f 100644
--- a/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/impl/FeatureResourceImpl.java
+++ b/featuremodel/feature-resolver/src/main/java/org/apache/sling/feature/resolver/impl/FeatureResourceImpl.java
@@ -16,22 +16,22 @@
  */
 package org.apache.sling.feature.resolver.impl;
 
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
 import org.apache.sling.feature.Artifact;
 import org.apache.sling.feature.Feature;
 import org.apache.sling.feature.OSGiCapability;
 import org.apache.sling.feature.OSGiRequirement;
-import org.apache.sling.feature.support.process.FeatureResource;
+import org.apache.sling.feature.support.resolver.FeatureResource;
 import org.osgi.framework.Version;
 import org.osgi.framework.namespace.IdentityNamespace;
 import org.osgi.resource.Capability;
 import org.osgi.resource.Requirement;
 
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
 public class FeatureResourceImpl extends AbstractResourceImpl implements FeatureResource
{
     private final Artifact artifact;
     private final Feature feature;
diff --git a/featuremodel/feature-resolver/src/test/java/org/apache/sling/feature/resolver/FrameworkResolverTest.java
b/featuremodel/feature-resolver/src/test/java/org/apache/sling/feature/resolver/FrameworkResolverTest.java
index 093b873..47c7dc6 100644
--- a/featuremodel/feature-resolver/src/test/java/org/apache/sling/feature/resolver/FrameworkResolverTest.java
+++ b/featuremodel/feature-resolver/src/test/java/org/apache/sling/feature/resolver/FrameworkResolverTest.java
@@ -16,19 +16,7 @@
  */
 package org.apache.sling.feature.resolver;
 
-import org.apache.sling.feature.Feature;
-import org.apache.sling.feature.support.ArtifactHandler;
-import org.apache.sling.feature.support.ArtifactManager;
-import org.apache.sling.feature.support.ArtifactManagerConfig;
-import org.apache.sling.feature.support.json.FeatureJSONReader;
-import org.apache.sling.feature.support.json.FeatureJSONReader.SubstituteVariables;
-import org.apache.sling.feature.support.process.FeatureResolver;
-import org.apache.sling.feature.support.process.FeatureResource;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.Constants;
-import org.osgi.framework.namespace.IdentityNamespace;
+import static org.junit.Assert.assertEquals;
 
 import java.io.File;
 import java.io.FileReader;
@@ -40,7 +28,19 @@ import java.util.Collections;
 import java.util.Comparator;
 import java.util.Map;
 
-import static org.junit.Assert.assertEquals;
+import org.apache.sling.feature.Feature;
+import org.apache.sling.feature.support.ArtifactHandler;
+import org.apache.sling.feature.support.ArtifactManager;
+import org.apache.sling.feature.support.ArtifactManagerConfig;
+import org.apache.sling.feature.support.json.FeatureJSONReader;
+import org.apache.sling.feature.support.json.FeatureJSONReader.SubstituteVariables;
+import org.apache.sling.feature.support.resolver.FeatureResolver;
+import org.apache.sling.feature.support.resolver.FeatureResource;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.Constants;
+import org.osgi.framework.namespace.IdentityNamespace;
 
 public class FrameworkResolverTest {
     private Path tempDir;
diff --git a/featuremodel/feature-resolver/src/test/java/org/apache/sling/feature/resolver/impl/BundleResourceImplTest.java
b/featuremodel/feature-resolver/src/test/java/org/apache/sling/feature/resolver/impl/BundleResourceImplTest.java
index cbc9ff1..b56719d 100644
--- a/featuremodel/feature-resolver/src/test/java/org/apache/sling/feature/resolver/impl/BundleResourceImplTest.java
+++ b/featuremodel/feature-resolver/src/test/java/org/apache/sling/feature/resolver/impl/BundleResourceImplTest.java
@@ -16,6 +16,20 @@
  */
 package org.apache.sling.feature.resolver.impl;
 
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertSame;
+import static org.junit.Assert.assertTrue;
+
+import java.lang.reflect.Field;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
 import org.apache.sling.feature.Artifact;
 import org.apache.sling.feature.ArtifactId;
 import org.apache.sling.feature.Feature;
@@ -24,7 +38,7 @@ import org.apache.sling.feature.OSGiRequirement;
 import org.apache.sling.feature.analyser.BundleDescriptor;
 import org.apache.sling.feature.analyser.Descriptor;
 import org.apache.sling.feature.analyser.impl.BundleDescriptorImpl;
-import org.apache.sling.feature.support.process.FeatureResource;
+import org.apache.sling.feature.support.resolver.FeatureResource;
 import org.apache.sling.feature.support.util.PackageInfo;
 import org.junit.Test;
 import org.mockito.Mockito;
@@ -35,20 +49,6 @@ import org.osgi.resource.Capability;
 import org.osgi.resource.Requirement;
 import org.osgi.resource.Resource;
 
-import java.lang.reflect.Field;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertSame;
-import static org.junit.Assert.assertTrue;
-
 public class BundleResourceImplTest {
     @Test
     public void testResource() {
diff --git a/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/FeatureUtil.java
b/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/FeatureUtil.java
index 6cbdf69..5b7f30b 100644
--- a/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/FeatureUtil.java
+++ b/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/FeatureUtil.java
@@ -24,7 +24,7 @@ import org.apache.sling.feature.support.json.FeatureJSONReader.SubstituteVariabl
 import org.apache.sling.feature.support.process.ApplicationBuilder;
 import org.apache.sling.feature.support.process.BuilderContext;
 import org.apache.sling.feature.support.process.FeatureProvider;
-import org.apache.sling.feature.support.process.FeatureResolver;
+import org.apache.sling.feature.support.resolver.FeatureResolver;
 
 import java.io.File;
 import java.io.FileReader;
diff --git a/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/process/ApplicationBuilder.java
b/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/process/ApplicationBuilder.java
index c3907d8..1fc2325 100644
--- a/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/process/ApplicationBuilder.java
+++ b/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/process/ApplicationBuilder.java
@@ -20,6 +20,8 @@ import org.apache.sling.feature.Application;
 import org.apache.sling.feature.Artifact;
 import org.apache.sling.feature.ArtifactId;
 import org.apache.sling.feature.Feature;
+import org.apache.sling.feature.support.resolver.FeatureResolver;
+import org.apache.sling.feature.support.resolver.FeatureResource;
 
 import java.util.ArrayList;
 import java.util.Collections;
diff --git a/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/process/FeatureResolver.java
b/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/resolver/FeatureResolver.java
similarity index 96%
rename from featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/process/FeatureResolver.java
rename to featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/resolver/FeatureResolver.java
index dead887..e5073ee 100644
--- a/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/process/FeatureResolver.java
+++ b/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/resolver/FeatureResolver.java
@@ -14,7 +14,7 @@
  * License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.sling.feature.support.process;
+package org.apache.sling.feature.support.resolver;
 
 import java.util.List;
 
diff --git a/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/process/FeatureResource.java
b/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/resolver/FeatureResource.java
similarity index 97%
rename from featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/process/FeatureResource.java
rename to featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/resolver/FeatureResource.java
index 17594ca..4b327d2 100644
--- a/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/process/FeatureResource.java
+++ b/featuremodel/feature-support/src/main/java/org/apache/sling/feature/support/resolver/FeatureResource.java
@@ -14,7 +14,7 @@
  * License for the specific language governing permissions and limitations under
  * the License.
  */
-package org.apache.sling.feature.support.process;
+package org.apache.sling.feature.support.resolver;
 
 import org.apache.sling.feature.Artifact;
 import org.apache.sling.feature.Feature;

-- 
To stop receiving notification emails like this one, please contact
cziegeler@apache.org.

Mime
View raw message