Added: sling/whiteboard/cziegeler/feature-support/src/main/java/org/apache/sling/feature/support/util/ManifestUtil.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/feature-support/src/main/java/org/apache/sling/feature/support/util/ManifestUtil.java?rev=1803557&view=auto ============================================================================== --- sling/whiteboard/cziegeler/feature-support/src/main/java/org/apache/sling/feature/support/util/ManifestUtil.java (added) +++ sling/whiteboard/cziegeler/feature-support/src/main/java/org/apache/sling/feature/support/util/ManifestUtil.java Mon Jul 31 17:22:58 2017 @@ -0,0 +1,124 @@ +/* + * 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.sling.feature.support.util; + +import java.io.File; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Collections; +import java.util.List; +import java.util.Map; +import java.util.function.BiConsumer; +import java.util.function.BiFunction; +import java.util.function.Function; +import java.util.jar.JarFile; +import java.util.jar.Manifest; + +import org.apache.sling.commons.osgi.ManifestHeader; +import org.apache.sling.feature.Capability; +import org.apache.sling.feature.Requirement; +import org.osgi.framework.Constants; + +public class ManifestUtil { + + /** + * Get the manifest from the artifact. + * @param artifact The file + * @throws IOException If the manifest can't be read + */ + public static Manifest getManifest(final File artifact) throws IOException { + try (final JarFile file = new JarFile(artifact) ) { + return file.getManifest(); + } + } + + public static List<PackageInfo> extractPackages(final Manifest m, + final String headerName, + final String defaultVersion, + final boolean checkOptional) { + final String pckInfo = m.getMainAttributes().getValue(headerName); + if (pckInfo != null) { + final ManifestHeader header = ManifestHeader.parse(pckInfo); + + final List<PackageInfo> pcks = new ArrayList<>(); + for(final ManifestHeader.Entry entry : header.getEntries()) { + String version = entry.getAttributeValue("version"); + if ( version == null ) { + version = defaultVersion; + } + boolean optional = false; + if ( checkOptional ) { + final String resolution = entry.getDirectiveValue("resolution"); + optional = "optional".equalsIgnoreCase(resolution); + } + final PackageInfo pck = new PackageInfo(entry.getValue(), + version, + optional); + pcks.add(pck); + } + + return pcks; + } + return Collections.emptyList(); + } + + public static List<PackageInfo> extractExportedPackages(final Manifest m) { + return extractPackages(m, Constants.EXPORT_PACKAGE, "0.0.0", false); + } + + public static List<PackageInfo> extractImportedPackages(final Manifest m) { + return extractPackages(m, Constants.IMPORT_PACKAGE, null, true); + } + + public static List<PackageInfo> extractDynamicImportedPackages(final Manifest m) { + return extractPackages(m, Constants.DYNAMICIMPORT_PACKAGE, null, false); + } + + public static List<Capability> extractCapabilities(ManifestParser parser) { + return parser.getCapabilities(); + } + + public static List<Requirement> extractRequirements(ManifestParser parser) { + return parser.getRequirements(); + } + + public static void unmarshallAttribute(String key, Object value, BiConsumer<String, Object> sink) { + unmarshallAttributeOrDirective(key, value, sink); + } + + public static void unmarshallDirective(String key, Object value, BiConsumer<String, Object> sink) { + unmarshallAttributeOrDirective(key, value, sink); + } + + private static void unmarshallAttributeOrDirective(String key, Object value, BiConsumer<String, Object> sink) { + // TODO: parse Attribute Or Directive correctly + sink.accept(key, value.toString()); + } + + public static void marshallAttribute(String key, Object value, BiConsumer<String, String> sink) { + marshallAttributeOrDirective(key, value, sink); + } + + public static void marshallDirective(String key, Object value, BiConsumer<String, String> sink) { + marshallAttributeOrDirective(key, value, sink); + } + + private static void marshallAttributeOrDirective(String key, Object value, BiConsumer<String, String> sink) { + // TODO: encode Attribute Or Directive correctly + sink.accept(key, value.toString()); + } +}
Added: sling/whiteboard/cziegeler/feature-support/src/main/java/org/apache/sling/feature/support/util/PackageInfo.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/feature-support/src/main/java/org/apache/sling/feature/support/util/PackageInfo.java?rev=1803557&view=auto ============================================================================== --- sling/whiteboard/cziegeler/feature-support/src/main/java/org/apache/sling/feature/support/util/PackageInfo.java (added) +++ sling/whiteboard/cziegeler/feature-support/src/main/java/org/apache/sling/feature/support/util/PackageInfo.java Mon Jul 31 17:22:58 2017 @@ -0,0 +1,93 @@ +/* + * 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.sling.feature.support.util; + +import org.osgi.framework.Version; +import org.osgi.framework.VersionRange; + +public class PackageInfo { + + private final boolean optional; + private final String name; + private final String version; + + public PackageInfo(final String name, final String version, final boolean optional) { + this.name = name; + this.version = version; + this.optional = optional; + } + + public String getName() { + return name; + } + + public String getVersion() { + return version; + } + + public boolean isOptional() { + return optional; + } + + public Version getPackageVersion() { + return new Version(this.version); + } + + public VersionRange getPackageVersionRange() { + return new VersionRange(this.version); + } + + @Override + public String toString() { + return "Package " + name + ";version=" + version; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((name == null) ? 0 : name.hashCode()); + result = prime * result + (optional ? 1231 : 1237); + result = prime * result + ((version == null) ? 0 : version.hashCode()); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + PackageInfo other = (PackageInfo) obj; + if (name == null) { + if (other.name != null) + return false; + } else if (!name.equals(other.name)) + return false; + if (optional != other.optional) + return false; + if (version == null) { + if (other.version != null) + return false; + } else if (!version.equals(other.version)) + return false; + return true; + } + +} Added: sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/FeatureJSONReaderTest.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/FeatureJSONReaderTest.java?rev=1803557&view=auto ============================================================================== --- sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/FeatureJSONReaderTest.java (added) +++ sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/FeatureJSONReaderTest.java Mon Jul 31 17:22:58 2017 @@ -0,0 +1,68 @@ +/* + * 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.sling.feature.support.json; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotNull; +import static org.junit.Assert.assertNull; +import static org.junit.Assert.fail; + +import java.util.List; + +import org.apache.sling.feature.Configuration; +import org.apache.sling.feature.Feature; +import org.junit.Test; + +public class FeatureJSONReaderTest { + + @Test public void testRead() throws Exception { + final Feature feature = U.readFeature("test"); + assertNotNull(feature); + assertNotNull(feature.getId()); + assertEquals("org.apache.sling", feature.getId().getGroupId()); + assertEquals("test-feature", feature.getId().getArtifactId()); + assertEquals("1.1", feature.getId().getVersion()); + assertEquals("jar", feature.getId().getType()); + assertNull(feature.getId().getClassifier()); + + assertEquals(2, feature.getConfigurations().size()); + final Configuration cfg1 = findConfiguration(feature.getConfigurations(), "my.pid"); + assertEquals(7, cfg1.getProperties().get("number")); + final Configuration cfg2 = findFactoryConfiguration(feature.getConfigurations(), "my.factory.pid", "name"); + assertEquals("yeah", cfg2.getProperties().get("a.value")); + } + + private Configuration findConfiguration(final List<Configuration> cfgs, final String pid) { + for(final Configuration c : cfgs) { + if ( !c.isFactoryConfiguration() && pid.equals(c.getPid()) ) { + return c; + } + } + fail("Configuration not found " + pid); + return null; + } + + private Configuration findFactoryConfiguration(final List<Configuration> cfgs, final String factoryid, final String name) { + for(final Configuration c : cfgs) { + if ( c.isFactoryConfiguration() && factoryid.equals(c.getFactoryPid()) && name.equals(c.getName())) { + return c; + } + } + fail("Factory Configuration not found " + factoryid + "~" + name); + return null; + } +} Added: sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/FeatureJSONWriterTest.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/FeatureJSONWriterTest.java?rev=1803557&view=auto ============================================================================== --- sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/FeatureJSONWriterTest.java (added) +++ sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/FeatureJSONWriterTest.java Mon Jul 31 17:22:58 2017 @@ -0,0 +1,41 @@ +/* + * 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.sling.feature.support.json; + +import static org.junit.Assert.assertEquals; + +import java.io.StringReader; +import java.io.StringWriter; + +import org.apache.sling.feature.Feature; +import org.junit.Test; + +public class FeatureJSONWriterTest { + + @Test public void testRead() throws Exception { + final Feature feature = U.readFeature("test"); + final Feature readFeature; + try ( final StringWriter writer = new StringWriter() ) { + FeatureJSONWriter.write(writer, feature); + try ( final StringReader reader = new StringReader(writer.toString()) ) { + readFeature = FeatureJSONReader.read(reader, null); + } + } + assertEquals(feature.getId(), readFeature.getId()); + } + +} Added: sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/U.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/U.java?rev=1803557&view=auto ============================================================================== --- sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/U.java (added) +++ sling/whiteboard/cziegeler/feature-support/src/test/java/org/apache/sling/feature/support/json/U.java Mon Jul 31 17:22:58 2017 @@ -0,0 +1,35 @@ +/* + * 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.sling.feature.support.json; + +import java.io.InputStreamReader; +import java.io.Reader; + +import org.apache.sling.feature.Feature; +import org.apache.sling.feature.support.json.FeatureJSONReader; + +/** Test utilities */ +public class U { + + /** Read the feature from the provided resource */ + public static Feature readFeature(final String name) throws Exception { + try ( final Reader reader = new InputStreamReader(U.class.getResourceAsStream("/features/" + name + ".json"), + "UTF-8") ) { + return FeatureJSONReader.read(reader, name); + } + } +} Added: sling/whiteboard/cziegeler/feature-support/src/test/resources/features/test.json URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/feature-support/src/test/resources/features/test.json?rev=1803557&view=auto ============================================================================== --- sling/whiteboard/cziegeler/feature-support/src/test/resources/features/test.json (added) +++ sling/whiteboard/cziegeler/feature-support/src/test/resources/features/test.json Mon Jul 31 17:22:58 2017 @@ -0,0 +1,74 @@ +{ + "id" : "org.apache.sling/test-feature/1.1", + + "includes" : [ + { + "id" : "org.apache.sling/sling/9", + "removals" : { + "configurations" : [ + ], + "bundles" : [ + ], + "framework-properties" : [ + ] + } + } + ], + "requirements" : [ + { + "namespace" : "osgi.contract", + "directives" : { + "filter" : "(&(osgi.contract=JavaServlet)(version=3.1))" + } + } + ], + "capabilities" : [ + { + "namespace" : "osgi.implementation", + "attributes" : { + "osgi.implementation" : "osgi.http", + "version:Version" : "1.1" + }, + "directives" : { + "uses" : "javax.servlet,javax.servlet.http,org.osgi.service.http.context,org.osgi.service.http.whiteboard" + } + }, + { + "namespace" : "osgi.service", + "attributes" : { + "objectClass:List<String>" : "org.osgi.service.http.runtime.HttpServiceRuntime" + }, + "directives" : { + "uses" : "org.osgi.service.http.runtime,org.osgi.service.http.runtime.dto" + } + } + ], + "framework-properties" : { + "foo" : 1, + "brave" : "something", + "org.apache.felix.scr.directory" : "launchpad/scr" + }, + "bundles" : { + "1" : [ + { + "id" : "org.apache.sling/oak-server/1.0.0", + "hash" : "4632463464363646436" + }, + "org.apache.sling/application-bundle/2.0.0", + "org.apache.sling/another-bundle/2.1.0" + ], + "2" : [ + "org.apache.sling/foo-xyz/1.2.3" + ] + }, + "configurations" : { + "my.pid" : { + "foo" : 5, + "bar" : "test", + "number:Integer" : 7 + }, + "my.factory.pid~name" : { + "a.value" : "yeah" + } + } +} \ No newline at end of file Modified: sling/whiteboard/cziegeler/feature/pom.xml URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/feature/pom.xml?rev=1803557&r1=1803556&r2=1803557&view=diff ============================================================================== --- sling/whiteboard/cziegeler/feature/pom.xml (original) +++ sling/whiteboard/cziegeler/feature/pom.xml Mon Jul 31 17:22:58 2017 @@ -73,28 +73,13 @@ <version>1.0-alpha-1</version> <scope>provided</scope> </dependency> - <dependency> - <groupId>org.apache.felix</groupId> - <artifactId>org.apache.felix.converter</artifactId> - <version>0.1.0-SNAPSHOT</version> - <scope>provided</scope> - </dependency> - <dependency> - <groupId>org.apache.felix</groupId> - <artifactId>org.apache.felix.configurator</artifactId> - <version>0.0.1-SNAPSHOT</version> - <scope>provided</scope> - </dependency> + <!-- Testing --> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> </dependency> - <dependency> - <groupId>org.osgi</groupId> - <artifactId>osgi.core</artifactId> - <scope>test</scope> - </dependency> + <dependency> <groupId>org.apache.johnzon</groupId> <artifactId>johnzon-core</artifactId> Modified: sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/Capability.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/Capability.java?rev=1803557&r1=1803556&r2=1803557&view=diff ============================================================================== --- sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/Capability.java (original) +++ sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/Capability.java Mon Jul 31 17:22:58 2017 @@ -16,6 +16,9 @@ */ package org.apache.sling.feature; +import java.util.*; +import java.util.concurrent.ConcurrentHashMap; + /** * A capability of a feature. * The capability is modeled after an OSGi capability: it @@ -28,10 +31,10 @@ public class Capability { private final String namespace; /** Map of attributes. */ - private final KeyValueMap attributes = new KeyValueMap(); + private final Map<String, Object> attributes = new ConcurrentHashMap<>(); /** Map of directives. */ - private final KeyValueMap directives = new KeyValueMap(); + private final Map<String, Object> directives = new ConcurrentHashMap<>(); /** * Create a new Capability. @@ -58,7 +61,7 @@ public class Capability { * The map is modifiable. * @return The map of attributes. */ - public KeyValueMap getAttributes() { + public Map<String, Object> getAttributes() { return attributes; } @@ -67,10 +70,11 @@ public class Capability { * The map is modifiable. * @return The map of directives. */ - public KeyValueMap getDirectives() { + public Map<String, Object> getDirectives() { return directives; } + @Override public int hashCode() { final int prime = 31; Modified: sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/Requirement.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/Requirement.java?rev=1803557&r1=1803556&r2=1803557&view=diff ============================================================================== --- sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/Requirement.java (original) +++ sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/Requirement.java Mon Jul 31 17:22:58 2017 @@ -16,6 +16,9 @@ */ package org.apache.sling.feature; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; + /** * A requirement for a feature. * The requirement is modeled after an OSGi requirement: it @@ -24,14 +27,18 @@ package org.apache.sling.feature; */ public class Requirement { + /*public static final String RESOLUTION_OPTIONAL = "optional"; + + public static final String RESOLUTION_DIRECTIVE = "resolution";*/ + /** The namspace. */ private final String namespace; /** Map of attributes. */ - private final KeyValueMap attributes = new KeyValueMap(); + private final Map<String, Object> attributes = new ConcurrentHashMap<>(); /** Map of directives. */ - private final KeyValueMap directives = new KeyValueMap(); + private final Map<String, Object> directives = new ConcurrentHashMap<>(); /** * Create a new Requirement. @@ -58,7 +65,7 @@ public class Requirement { * The map is modifiable. * @return The map of attributes. */ - public KeyValueMap getAttributes() { + public Map<String,Object> getAttributes() { return attributes; } @@ -67,10 +74,11 @@ public class Requirement { * The map is modifiable. * @return The map of directives. */ - public KeyValueMap getDirectives() { + public Map<String,Object> getDirectives() { return directives; } + @Override public int hashCode() { final int prime = 31; Modified: sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/process/ApplicationBuilder.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/process/ApplicationBuilder.java?rev=1803557&r1=1803556&r2=1803557&view=diff ============================================================================== --- sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/process/ApplicationBuilder.java (original) +++ sling/whiteboard/cziegeler/feature/src/main/java/org/apache/sling/feature/process/ApplicationBuilder.java Mon Jul 31 17:22:58 2017 @@ -47,7 +47,7 @@ public class ApplicationBuilder { */ public static Application assemble(final Application app, final FeatureProvider provider, - final String...featureIds) { + final String... featureIds) { if ( featureIds == null || provider == null ) { throw new IllegalArgumentException("Features and/or provider must not be null"); } @@ -81,7 +81,7 @@ public class ApplicationBuilder { public static Application assemble( Application app, final FeatureProvider provider, - final Feature...features) { + final Feature... features) { if ( features == null || provider == null ) { throw new IllegalArgumentException("Features and/or provider must not be null"); } Modified: sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/Preprocessor.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/Preprocessor.java?rev=1803557&r1=1803556&r2=1803557&view=diff ============================================================================== --- sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/Preprocessor.java (original) +++ sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/Preprocessor.java Mon Jul 31 17:22:58 2017 @@ -33,7 +33,7 @@ import org.apache.sling.feature.Artifact import org.apache.sling.feature.Extension; import org.apache.sling.feature.ExtensionType; import org.apache.sling.feature.Feature; -import org.apache.sling.feature.json.FeatureJSONReader; +import org.apache.sling.feature.support.json.FeatureJSONReader; import org.apache.sling.feature.process.FeatureBuilder; import org.apache.sling.feature.process.FeatureProvider; import org.apache.sling.feature.support.FeatureUtil; Modified: sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/ProjectHelper.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/ProjectHelper.java?rev=1803557&r1=1803556&r2=1803557&view=diff ============================================================================== --- sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/ProjectHelper.java (original) +++ sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/ProjectHelper.java Mon Jul 31 17:22:58 2017 @@ -38,8 +38,8 @@ import org.apache.maven.model.PluginExec import org.apache.maven.project.MavenProject; import org.apache.sling.feature.ArtifactId; import org.apache.sling.feature.Feature; -import org.apache.sling.feature.json.FeatureJSONReader; -import org.apache.sling.feature.json.FeatureJSONWriter; +import org.apache.sling.feature.support.json.FeatureJSONReader; +import org.apache.sling.feature.support.json.FeatureJSONWriter; import org.codehaus.plexus.util.xml.Xpp3Dom; public abstract class ProjectHelper { Modified: sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/mojos/AttachFeature.java URL: http://svn.apache.org/viewvc/sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/mojos/AttachFeature.java?rev=1803557&r1=1803556&r2=1803557&view=diff ============================================================================== --- sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/mojos/AttachFeature.java (original) +++ sling/whiteboard/cziegeler/osgifeature-maven-plugin/src/main/java/org/apache/sling/feature/maven/mojos/AttachFeature.java Mon Jul 31 17:22:58 2017 @@ -27,7 +27,7 @@ import org.apache.maven.plugins.annotati import org.apache.maven.plugins.annotations.Mojo; import org.apache.maven.plugins.annotations.ResolutionScope; import org.apache.sling.feature.Feature; -import org.apache.sling.feature.json.FeatureJSONWriter; +import org.apache.sling.feature.support.json.FeatureJSONWriter; import org.apache.sling.feature.maven.FeatureConstants; import org.apache.sling.feature.maven.ProjectHelper;