Hi Dan, I'm just catching up with what you're doing here. Back in March we spent some time figuring out how to implement the OSGi Semantic Versioning policy in our Maven build and release process. Zoe documented it here:
http://aries.apache.org/development/versionpolicy.html based discussions on the list, with the last one being here: http://mail-archives.apache.org/mod_mbox/aries-dev/201103.mbox/%3C1300364661.27234.33.camel%40meschbix%3E There are some disparities with what you've change w.r.t what was decided back then. I've made a comment in-line to this commit. Cheers, Jeremy On 17 November 2011 17:59, <[email protected]> wrote: > Author: dkulp > Date: Thu Nov 17 17:59:48 2011 > New Revision: 1203307 > > URL: http://svn.apache.org/viewvc?rev=1203307&view=rev > Log: > Add a testcase for the Part1 fix for ARIES-626 > Update itests pom to use the versions of the blueprint stuff build in > the build. > > Added: > > aries/trunk/blueprint/blueprint-testbundlea/src/main/java/org/apache/aries/blueprint/testbundlea/NSHandlerFour.java > (with props) > > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfour.xsd > (with props) > > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfourimport.xsd > (with props) > Modified: > aries/trunk/blueprint/blueprint-bundle/pom.xml > aries/trunk/blueprint/blueprint-itests/pom.xml > > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/OSGI-INF/blueprint/config.xml > > aries/trunk/blueprint/blueprint-testbundleb/src/main/resources/OSGI-INF/blueprint/config.xml > > Modified: aries/trunk/blueprint/blueprint-bundle/pom.xml > URL: > http://svn.apache.org/viewvc/aries/trunk/blueprint/blueprint-bundle/pom.xml?rev=1203307&r1=1203306&r2=1203307&view=diff > ============================================================================== > --- aries/trunk/blueprint/blueprint-bundle/pom.xml (original) > +++ aries/trunk/blueprint/blueprint-bundle/pom.xml Thu Nov 17 17:59:48 2011 > @@ -111,25 +111,25 @@ > <dependency> > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint.api</artifactId> > - <version>0.3</version> > + <version>0.3.2-SNAPSHOT</version> This should stay at 0.3 as there is no difference between trunk and 0.3. blueprint 0.3.1 was released before we moved to the 'release by bundle' process so it ended up releasing blueprint-api 0.3.1 even there were no changes in it over 0.3. Can you describe how you have decided what versions to use here and below? They really should be depending on the released artifact. Thanks. > <scope>provided</scope> > </dependency> > <dependency> > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint.annotation.api</artifactId> > - <version>0.3</version> > + <version>0.3.3-SNAPSHOT</version> > <scope>provided</scope> > </dependency> > <dependency> > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint.core</artifactId> > - <version>0.4</version> > + <version>0.4.1-SNAPSHOT</version> > <scope>provided</scope> > </dependency> > <dependency> > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint.cm</artifactId> > - <version>0.3.2</version> > + <version>0.3.3-SNAPSHOT</version> > <scope>provided</scope> > </dependency> > <dependency> > > Modified: aries/trunk/blueprint/blueprint-itests/pom.xml > URL: > http://svn.apache.org/viewvc/aries/trunk/blueprint/blueprint-itests/pom.xml?rev=1203307&r1=1203306&r2=1203307&view=diff > ============================================================================== > --- aries/trunk/blueprint/blueprint-itests/pom.xml (original) > +++ aries/trunk/blueprint/blueprint-itests/pom.xml Thu Nov 17 17:59:48 2011 > @@ -60,13 +60,13 @@ > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint</artifactId> > <scope>test</scope> > - <version>0.4</version> > + <version>0.4.1-SNAPSHOT</version> > </dependency> > <dependency> > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint.jexl.evaluator</artifactId> > <scope>test</scope> > - <version>0.1.0</version> > + <version>0.1.1-SNAPSHOT</version> > </dependency> > <dependency> > <groupId>org.apache.aries</groupId> > @@ -78,19 +78,19 @@ > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint.sample</artifactId> > <scope>test</scope> > - <version>0.4</version> > + <version>0.3.3-SNAPSHOT</version> > </dependency> > <dependency> > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint.testbundlea</artifactId> > <scope>test</scope> > - <version>0.3.2</version> > + <version>0.3.3-SNAPSHOT</version> > </dependency> > <dependency> > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint.testbundleb</artifactId> > <scope>test</scope> > - <version>0.3.2</version> > + <version>0.3.3-SNAPSHOT</version> > </dependency> > <dependency> > <groupId>org.apache.aries.testsupport</groupId> > @@ -179,25 +179,37 @@ > <dependency> > <groupId>org.apache.aries.blueprint</groupId> > > <artifactId>org.apache.aries.blueprint.testquiescebundle</artifactId> > - <version>0.3.2</version> > + <version>0.3.3-SNAPSHOT</version> > <type>bundle</type> > <scope>compile</scope> > </dependency> > <dependency> > + <groupId>org.apache.aries.blueprint</groupId> > + <artifactId>org.apache.aries.blueprint.api</artifactId> > + <version>0.3.2-SNAPSHOT</version> > + <scope>compile</scope> > + </dependency> > + <dependency> > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint.core</artifactId> > - <version>0.4</version> > + <version>0.4.1-SNAPSHOT</version> > <type>bundle</type> > <scope>compile</scope> > </dependency> > <dependency> > <groupId>org.apache.aries.blueprint</groupId> > <artifactId>org.apache.aries.blueprint.cm</artifactId> > - <version>0.3.2</version> > + <version>0.3.3-SNAPSHOT</version> > <type>bundle</type> > <scope>compile</scope> > </dependency> > <dependency> > + <groupId>org.apache.aries.blueprint</groupId> > + <artifactId>blueprint-parser</artifactId> > + <scope>provided</scope> > + <version>0.4.1-SNAPSHOT</version> > + </dependency> > + <dependency> > <groupId>org.apache.commons</groupId> > <artifactId>commons-jexl</artifactId> > <version>2.0</version> > @@ -210,6 +222,9 @@ > <testResource> > > <directory>${project.build.directory}/test-resources</directory> > </testResource> > + <testResource> > + <directory>src/test/resources</directory> > + </testResource> > </testResources> > <plugins> > <plugin> > > Added: > aries/trunk/blueprint/blueprint-testbundlea/src/main/java/org/apache/aries/blueprint/testbundlea/NSHandlerFour.java > URL: > http://svn.apache.org/viewvc/aries/trunk/blueprint/blueprint-testbundlea/src/main/java/org/apache/aries/blueprint/testbundlea/NSHandlerFour.java?rev=1203307&view=auto > ============================================================================== > --- > aries/trunk/blueprint/blueprint-testbundlea/src/main/java/org/apache/aries/blueprint/testbundlea/NSHandlerFour.java > (added) > +++ > aries/trunk/blueprint/blueprint-testbundlea/src/main/java/org/apache/aries/blueprint/testbundlea/NSHandlerFour.java > Thu Nov 17 17:59:48 2011 > @@ -0,0 +1,76 @@ > +/** > + * 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.blueprint.testbundlea; > + > +import java.net.URL; > +import java.util.Collections; > +import java.util.List; > +import java.util.Set; > + > +import org.apache.aries.blueprint.NamespaceHandler; > +import org.apache.aries.blueprint.ParserContext; > +import org.apache.aries.blueprint.PassThroughMetadata; > +import org.apache.aries.blueprint.mutable.MutableBeanMetadata; > +import org.apache.aries.blueprint.mutable.MutableRefMetadata; > +import org.osgi.service.blueprint.reflect.BeanMetadata; > +import org.osgi.service.blueprint.reflect.ComponentMetadata; > +import org.osgi.service.blueprint.reflect.Metadata; > +import org.osgi.service.blueprint.reflect.RefMetadata; > + > +import org.w3c.dom.Attr; > +import org.w3c.dom.Element; > +import org.w3c.dom.Node; > + > +public class NSHandlerFour implements NamespaceHandler{ > + public static String NSURI = "http://ns.handler.four"; > + private static String ELT_NAME = "nshandlerfour"; > + private static String ATTRIB_ID = "id"; > + > + > + public static class Four { > + public Four() { > + } > + } > + //process elements > + public Metadata parse(Element element, ParserContext context) { > + Metadata retval = null; > + if( element.getLocalName().equals(ELT_NAME) ) { > + final String id = element.getAttributeNS(NSURI, ATTRIB_ID); > + MutableBeanMetadata bm = > context.createMetadata(MutableBeanMetadata.class); > + bm.setId(id); > + bm.setClassName(Four.class.getName()); > + retval = bm; > + } > + return retval; > + } > + > + //supply schema back to blueprint. > + public URL getSchemaLocation(String namespace) { > + return this.getClass().getResource("nshandlerfour.xsd"); > + } > + > + public Set<Class> getManagedClasses() { > + Class cls = Four.class; > + return Collections.singleton(cls); > + } > + > + public ComponentMetadata decorate(Node node, ComponentMetadata component, > + ParserContext context) { > + return component; > + } > + > +} > > Propchange: > aries/trunk/blueprint/blueprint-testbundlea/src/main/java/org/apache/aries/blueprint/testbundlea/NSHandlerFour.java > ------------------------------------------------------------------------------ > svn:eol-style = native > > Propchange: > aries/trunk/blueprint/blueprint-testbundlea/src/main/java/org/apache/aries/blueprint/testbundlea/NSHandlerFour.java > ------------------------------------------------------------------------------ > svn:keywords = Rev Date > > Modified: > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/OSGI-INF/blueprint/config.xml > URL: > http://svn.apache.org/viewvc/aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/OSGI-INF/blueprint/config.xml?rev=1203307&r1=1203306&r2=1203307&view=diff > ============================================================================== > --- > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/OSGI-INF/blueprint/config.xml > (original) > +++ > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/OSGI-INF/blueprint/config.xml > Thu Nov 17 17:59:48 2011 > @@ -27,6 +27,8 @@ > > <bean id="NSHandlerThree" > class="org.apache.aries.blueprint.testbundlea.NSHandlerThree"> > </bean> > + <bean id="NSHandlerFour" > class="org.apache.aries.blueprint.testbundlea.NSHandlerFour"> > + </bean> > > <service interface="org.apache.aries.blueprint.NamespaceHandler" > ref="NSHandlerOne"> > <service-properties> > @@ -45,6 +47,11 @@ > <entry key="osgi.service.blueprint.namespace" > value="http://ns.handler.three"/> > </service-properties> > </service> > + <service interface="org.apache.aries.blueprint.NamespaceHandler" > ref="NSHandlerFour"> > + <service-properties> > + <entry key="osgi.service.blueprint.namespace" > value="http://ns.handler.four"/> > + </service-properties> > + </service> > > </blueprint> > > > Added: > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfour.xsd > URL: > http://svn.apache.org/viewvc/aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfour.xsd?rev=1203307&view=auto > ============================================================================== > --- > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfour.xsd > (added) > +++ > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfour.xsd > Thu Nov 17 17:59:48 2011 > @@ -0,0 +1,35 @@ > +<?xml version="1.0" encoding="UTF-8"?> > +<!-- > + Licensed to the Apache Software Foundation (ASF) under one or more > + contributor license agreements. See the NOTICE file distributed with > + this work for additional information regarding copyright ownership. > + The ASF licenses this file to You under the Apache License, Version 2.0 > + (the "License"); you may not use this file except in compliance with > + the License. You may obtain a copy of the License at > + > + http://www.apache.org/licenses/LICENSE-2.0 > + > + Unless required by applicable law or agreed to in writing, software > + distributed under the License is distributed on an "AS IS" BASIS, > + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. > + See the License for the specific language governing permissions and > + limitations under the License. > +--> > +<schema xmlns="http://www.w3.org/2001/XMLSchema" > + targetNamespace="http://ns.handler.four" > + xmlns:tns="http://ns.handler.four" > + xmlns:imp="http://ns.handler.four.import" > + xmlns:xsd="http://www.w3.org/2001/XMLSchema" > + elementFormDefault="qualified" > + attributeFormDefault="qualified" > > + <import schemaLocation="nshandlerfourimport.xsd" > + namespace="http://ns.handler.four.import"/> > + <element name="nshandlerfour"> > + <complexType> > + <sequence> > + <element name="stuff" type="imp:Imported"/> > + </sequence> > + <attribute name="id" type="xsd:string"/> > + </complexType> > + </element> > +</schema> > \ No newline at end of file > > Propchange: > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfour.xsd > ------------------------------------------------------------------------------ > svn:eol-style = native > > Propchange: > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfour.xsd > ------------------------------------------------------------------------------ > svn:keywords = Rev Date > > Propchange: > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfour.xsd > ------------------------------------------------------------------------------ > svn:mime-type = text/xml > > Added: > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfourimport.xsd > URL: > http://svn.apache.org/viewvc/aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfourimport.xsd?rev=1203307&view=auto > ============================================================================== > --- > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfourimport.xsd > (added) > +++ > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfourimport.xsd > Thu Nov 17 17:59:48 2011 > @@ -0,0 +1,30 @@ > +<?xml version="1.0" encoding="UTF-8"?> > +<!-- > + Licensed to the Apache Software Foundation (ASF) under one or more > + contributor license agreements. See the NOTICE file distributed with > + this work for additional information regarding copyright ownership. > + The ASF licenses this file to You under the Apache License, Version 2.0 > + (the "License"); you may not use this file except in compliance with > + the License. You may obtain a copy of the License at > + > + http://www.apache.org/licenses/LICENSE-2.0 > + > + Unless required by applicable law or agreed to in writing, software > + distributed under the License is distributed on an "AS IS" BASIS, > + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. > + See the License for the specific language governing permissions and > + limitations under the License. > +--> > +<schema xmlns="http://www.w3.org/2001/XMLSchema" > + targetNamespace="http://ns.handler.four.import" > + xmlns:tns="http://ns.handler.four.import" > + xmlns:xsd="http://www.w3.org/2001/XMLSchema" > + elementFormDefault="unqualified" > + attributeFormDefault="unqualified" > > + > + <complexType name="Imported"> > + <sequence> > + <element name="stuff" type="xsd:string"/> > + </sequence> > + </complexType> > +</schema> > \ No newline at end of file > > Propchange: > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfourimport.xsd > ------------------------------------------------------------------------------ > svn:eol-style = native > > Propchange: > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfourimport.xsd > ------------------------------------------------------------------------------ > svn:keywords = Rev Date > > Propchange: > aries/trunk/blueprint/blueprint-testbundlea/src/main/resources/org/apache/aries/blueprint/testbundlea/nshandlerfourimport.xsd > ------------------------------------------------------------------------------ > svn:mime-type = text/xml > > Modified: > aries/trunk/blueprint/blueprint-testbundleb/src/main/resources/OSGI-INF/blueprint/config.xml > URL: > http://svn.apache.org/viewvc/aries/trunk/blueprint/blueprint-testbundleb/src/main/resources/OSGI-INF/blueprint/config.xml?rev=1203307&r1=1203306&r2=1203307&view=diff > ============================================================================== > --- > aries/trunk/blueprint/blueprint-testbundleb/src/main/resources/OSGI-INF/blueprint/config.xml > (original) > +++ > aries/trunk/blueprint/blueprint-testbundleb/src/main/resources/OSGI-INF/blueprint/config.xml > Thu Nov 17 17:59:48 2011 > @@ -21,6 +21,8 @@ > xmlns:one="http://ns.handler.one" > xmlns:two="http://ns.handler.two" > xmlns:three="http://ns.handler.three" > + xmlns:four="http://ns.handler.four" > + xmlns:fourim="http://ns.handler.four.import" > default-availability="optional"> > > <!-- Default test.. no other ns interaction. --> > @@ -62,5 +64,13 @@ > <reference activation="eager" > availability="optional" > > interface="org.apache.aries.blueprint.testbundlea.InterfaceWithDependency" /> > + > + <!-- NShandler four test, make sure the schema can be parsed - ARIES-626 > Part 1 --> > + <four:nshandlerfour four:id="FOUR"> > + <four:stuff> > + <stuff xmlns="">foo</stuff> > + </four:stuff> > + </four:nshandlerfour> > + > </blueprint> > > > >
