You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Reinhard Pötz <re...@apache.org> on 2008/08/06 09:43:25 UTC
Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Grzegorz Kossakowski wrote:
> reinhard@apache.org pisze:
>> Author: reinhard
>> Date: Tue Aug 5 12:42:45 2008
>> New Revision: 682901
>>
>> URL: http://svn.apache.org/viewvc?rev=682901&view=rev
>> Log:
>> back in snapshot mode
>>
>> Modified:
>> cocoon/trunk/tools/pom.xml
>>
>> Modified: cocoon/trunk/tools/pom.xml
>> URL:
>> http://svn.apache.org/viewvc/cocoon/trunk/tools/pom.xml?rev=682901&r1=682900&r2=682901&view=diff
>>
>> ==============================================================================
>>
>> --- cocoon/trunk/tools/pom.xml (original)
>> +++ cocoon/trunk/tools/pom.xml Tue Aug 5 12:42:45 2008
>> @@ -26,7 +26,7 @@
>> <parent>
>> <groupId>org.apache.cocoon</groupId>
>> <artifactId>cocoon</artifactId>
>> - <version>7</version>
>> + <version>5-SNAPSHOT</version>
>> <relativePath>../parent</relativePath>
>
> Development version is lower than released one. Is it intended?
yes, I was too lazy to touch nearly every POM file in our repository
just to increase the version number of our parent POMs. I haven't done
this for the last release either and AFAICT, no problem occurred.
Does anybody know if it can cause problems if the development version
number isn't increased after a release?
--
Reinhard Pötz Managing Director, {Indoqa} GmbH
http://www.indoqa.com/en/people/reinhard.poetz/
Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member reinhard@apache.org
________________________________________________________________________
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Reinhard Pötz <re...@apache.org>.
Grzegorz Kossakowski wrote:
> Reinhard Pötz pisze:
>>
>> yes, I was too lazy to touch nearly every POM file in our repository
>> just to increase the version number of our parent POMs. I haven't done
>> this for the last release either and AFAICT, no problem occurred.
>
> Hmmm, find, xargs and sed should do this work within one minute. :-)
it's a bit more difficult but in general yes.
Actually we already have such a script (tools/pom-updater) but still I
always managed to break the build.
>> Does anybody know if it can cause problems if the development version
>> number isn't increased after a release?
>
> I would say that it's at least confusing. So how does this work now? We
> have a new version of parent pom but we reference to the old one. Which
> version is chosen finally?
All our POMs in snapshot mode refer to the (not-changing) cocoon-parent POM.
After writing this I see the potential problem: If we want to use some
of our own modules in their released versions, they would pull in the
released cocoon-parent POM. This could lead to some unwanted side-effects.
This means that if we want to use released versions of our own modules,
we have to increase the version number of cocoon-parent and should
follow Carsten's proposal and remove all intermediary POMs
(tools-modules, blocks-modules) except core-modules.
--
Reinhard Pötz Managing Director, {Indoqa} GmbH
http://www.indoqa.com/en/people/reinhard.poetz/
Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member reinhard@apache.org
________________________________________________________________________
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Grzegorz Kossakowski <gr...@tuffmail.com>.
Reinhard Pötz pisze:
>
> yes, I was too lazy to touch nearly every POM file in our repository
> just to increase the version number of our parent POMs. I haven't done
> this for the last release either and AFAICT, no problem occurred.
Hmmm, find, xargs and sed should do this work within one minute. :-)
> Does anybody know if it can cause problems if the development version
> number isn't increased after a release?
I would say that it's at least confusing. So how does this work now? We have a new version of parent
pom but we reference to the old one. Which version is chosen finally?
--
Grzegorz Kossakowski
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Felix Knecht <fe...@apache.org>.
Reinhard Pötz schrieb:
> Grzegorz Kossakowski wrote:
>> reinhard@apache.org pisze:
>>> Author: reinhard
>>> Date: Tue Aug 5 12:42:45 2008
>>> New Revision: 682901
>>>
>>> URL: http://svn.apache.org/viewvc?rev=682901&view=rev
>>> Log:
>>> back in snapshot mode
>>>
>>> Modified:
>>> cocoon/trunk/tools/pom.xml
>>>
>>> Modified: cocoon/trunk/tools/pom.xml
>>> URL:
>>> http://svn.apache.org/viewvc/cocoon/trunk/tools/pom.xml?rev=682901&r1=682900&r2=682901&view=diff
>>>
>>> ==============================================================================
>>>
>>> --- cocoon/trunk/tools/pom.xml (original)
>>> +++ cocoon/trunk/tools/pom.xml Tue Aug 5 12:42:45 2008
>>> @@ -26,7 +26,7 @@
>>> <parent>
>>> <groupId>org.apache.cocoon</groupId>
>>> <artifactId>cocoon</artifactId>
>>> - <version>7</version>
>>> + <version>5-SNAPSHOT</version>
>>> <relativePath>../parent</relativePath>
>>
>> Development version is lower than released one. Is it intended?
>
> yes, I was too lazy to touch nearly every POM file in our repository
> just to increase the version number of our parent POMs. I haven't done
> this for the last release either and AFAICT, no problem occurred.
>
> Does anybody know if it can cause problems if the development version
> number isn't increased after a release?
>
At least I find it intuitive for the one releasing the next version when
he can rely on the snapshot version than doing a search in the maven
remote repository to find the next version number for a release.
Just my 0.02 CHF
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Carsten Ziegeler <cz...@apache.org>.
Ralph Goers wrote:
> I thought about this some more. How about if a) to enable this feature
> you put a variable as the version, b) the variable is replaced by its
> definition c) if it isn't defined then go to the relativePath and get
> the version from there, c) if this fails throw an exception.
>
> I believe this won't cause any problems since variables aren't currently
> supported. It is also what people have asked for in the Jira issue.
Sounds like too much magic for me - but as we're talking about maven,
well, adding more magic to "too much magic" shouldn't hurt... :)
Carsten
--
Carsten Ziegeler
cziegeler@apache.org
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Ralph Goers <Ra...@dslextreme.com>.
Ralph Goers wrote:
>
>
> Carsten Ziegeler wrote:
>> Ralph Goers wrote:
>>>
>>>
>>> Carsten Ziegeler wrote:
>>>> Ralph Goers wrote:
>>>>> It uses the relative path so you will need the parent also.
>>>>>
>>>> Hmm, I'm not sure if this is a good idea :) as it permits building
>>>> a module standalone.
>>>> For Cocoon we have the dream (tm) to have separate
>>>> buildable/deployable modules one day.
>>>>
>>>> Carsten
>>>
>>> If you can think of a way to have it both ways let me know.
>>>
>> You could look into the local repo and use the latest version from there
>> or you can even go to a remote repo and use the latest version from
>> there.
>> I think/hope that the maven api allows you to do this.
> I'm not sure if there is an existing way of doing that. Even if there
> is, I'm not sure if that is a great idea. What if what is in your
> local repo is really old?
I thought about this some more. How about if a) to enable this feature
you put a variable as the version, b) the variable is replaced by its
definition c) if it isn't defined then go to the relativePath and get
the version from there, c) if this fails throw an exception.
I believe this won't cause any problems since variables aren't currently
supported. It is also what people have asked for in the Jira issue.
Ralph
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Ralph Goers <Ra...@dslextreme.com>.
Carsten Ziegeler wrote:
> Ralph Goers wrote:
>>
>>
>> Carsten Ziegeler wrote:
>>> Ralph Goers wrote:
>>>> It uses the relative path so you will need the parent also.
>>>>
>>> Hmm, I'm not sure if this is a good idea :) as it permits building a
>>> module standalone.
>>> For Cocoon we have the dream (tm) to have separate
>>> buildable/deployable modules one day.
>>>
>>> Carsten
>>
>> If you can think of a way to have it both ways let me know.
>>
> You could look into the local repo and use the latest version from there
> or you can even go to a remote repo and use the latest version from
> there.
> I think/hope that the maven api allows you to do this.
I'm not sure if there is an existing way of doing that. Even if there
is, I'm not sure if that is a great idea. What if what is in your local
repo is really old?
Ralph
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Carsten Ziegeler <cz...@apache.org>.
Ralph Goers wrote:
>
>
> Carsten Ziegeler wrote:
>> Ralph Goers wrote:
>>> It uses the relative path so you will need the parent also.
>>>
>> Hmm, I'm not sure if this is a good idea :) as it permits building a
>> module standalone.
>> For Cocoon we have the dream (tm) to have separate
>> buildable/deployable modules one day.
>>
>> Carsten
>
> If you can think of a way to have it both ways let me know.
>
You could look into the local repo and use the latest version from there
or you can even go to a remote repo and use the latest version from there.
I think/hope that the maven api allows you to do this.
Carsten
--
Carsten Ziegeler
cziegeler@apache.org
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Ralph Goers <Ra...@dslextreme.com>.
Carsten Ziegeler wrote:
> Ralph Goers wrote:
>> It uses the relative path so you will need the parent also.
>>
> Hmm, I'm not sure if this is a good idea :) as it permits building a
> module standalone.
> For Cocoon we have the dream (tm) to have separate
> buildable/deployable modules one day.
>
> Carsten
If you can think of a way to have it both ways let me know.
In the Maven issue (http://jira.codehaus.org/browse/MNG-624) the
suggestion was made to use a variable. I'm not a big fan of that if it
requires the variable always be set via -D or in the users settings.xml.
Too much room to get it wrong. Using the version in the pom at the
relative path you are sure to always get it right.
The way my patch is right now if you specified MavenParentVersion as the
version and it couldn't find the parent pom an exception would get
thrown more or less as if a version wasn't specified. I suppose instead
of throwing the exception it could try to find the pom some other way,
but what?
I have a feeling that if the way Cocoon's blocks parent pom was changed
than what I'm suggesting would be easy. If the parent pom was in
cocoon-blocks-parent instead of being the aggregation pom this would be
a lot easier to deal with as you would only need the Cocoon parent
project and the block parent project to create your block.
Ralph
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Carsten Ziegeler <cz...@apache.org>.
Ralph Goers wrote:
> It uses the relative path so you will need the parent also.
>
Hmm, I'm not sure if this is a good idea :) as it permits building a
module standalone.
For Cocoon we have the dream (tm) to have separate buildable/deployable
modules one day.
Carsten
--
Carsten Ziegeler
cziegeler@apache.org
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Ralph Goers <Ra...@dslextreme.com>.
It uses the relative path so you will need the parent also.
Carsten Ziegeler wrote:
> Ralph Goers wrote
>> I'm actually working on a fix to maven for this at the moment. It
>> would allow you to put <version>MAVEN_PARENT_VERSION</version> in the
>> pom instead of an actual version number. Don't get your hopes up
>> though. I've been working on this for the last few weeks in the
>> precious little available time I have right now. The thing that makes
>> it difficult is that when your pom gets installed or deployed it has
>> to have a real version number in it.
> And how does this work, if you just check out a single module instead
> of the whole tree?
>
> Carsten
>
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Carsten Ziegeler <cz...@apache.org>.
Ralph Goers wrote
> I'm actually working on a fix to maven for this at the moment. It would
> allow you to put <version>MAVEN_PARENT_VERSION</version> in the pom
> instead of an actual version number. Don't get your hopes up though.
> I've been working on this for the last few weeks in the precious little
> available time I have right now. The thing that makes it difficult is
> that when your pom gets installed or deployed it has to have a real
> version number in it.
And how does this work, if you just check out a single module instead of
the whole tree?
Carsten
--
Carsten Ziegeler
cziegeler@apache.org
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Ralph Goers <Ra...@dslextreme.com>.
Reinhard Pötz wrote:
> Grzegorz Kossakowski wrote:
>> reinhard@apache.org pisze:
>>> Author: reinhard
>>> Date: Tue Aug 5 12:42:45 2008
>>> New Revision: 682901
>>>
>>> URL: http://svn.apache.org/viewvc?rev=682901&view=rev
>>> Log:
>>> back in snapshot mode
>>>
>>> Modified:
>>> cocoon/trunk/tools/pom.xml
>>>
>>> Modified: cocoon/trunk/tools/pom.xml
>>> URL:
>>> http://svn.apache.org/viewvc/cocoon/trunk/tools/pom.xml?rev=682901&r1=682900&r2=682901&view=diff
>>>
>>> ==============================================================================
>>>
>>> --- cocoon/trunk/tools/pom.xml (original)
>>> +++ cocoon/trunk/tools/pom.xml Tue Aug 5 12:42:45 2008
>>> @@ -26,7 +26,7 @@
>>> <parent>
>>> <groupId>org.apache.cocoon</groupId>
>>> <artifactId>cocoon</artifactId>
>>> - <version>7</version>
>>> + <version>5-SNAPSHOT</version>
>>> <relativePath>../parent</relativePath>
>>
>> Development version is lower than released one. Is it intended?
>
> yes, I was too lazy to touch nearly every POM file in our repository
> just to increase the version number of our parent POMs. I haven't done
> this for the last release either and AFAICT, no problem occurred.
>
> Does anybody know if it can cause problems if the development version
> number isn't increased after a release?
I'm actually working on a fix to maven for this at the moment. It would
allow you to put <version>MAVEN_PARENT_VERSION</version> in the pom
instead of an actual version number. Don't get your hopes up though.
I've been working on this for the last few weeks in the precious little
available time I have right now. The thing that makes it difficult is
that when your pom gets installed or deployed it has to have a real
version number in it.
Ralph
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Carsten Ziegeler <cz...@apache.org>.
Reinhard Pötz wrote:
>
> I was releasing cocoon-parent because I wanted to use the latest
> versions of some plugins and some dependencies (e.g. Spring).
>
Ah yes, ok - Personally I would not change the references of all modules
to the latest snapshot of the parent pom after a release. The modules
should be indepedent.
Now comes the problematic part: As soon as you end up with two modules
referencing different parent pom with a dependency management, and let's
say the older parent pom references a lib or plugin in version X while
the newer parent pom references the same lib or plugin in a different
version Y, all modules are build with one or the other version in a
multi project build. Which version is used for the whole build depends
on the order how maven reads the poms (and it seems that this order is
not deterministic as we had problems on some machines while it worked on
others because of a different order). And obviously if just one version
is used for the whole build this might cause build problems - which look
very strange as all your poms are correct!
Ok, long story, because of this maven bug (or is it by design?) it's
much safer to make a search/replace after releasing the parent pom and
update *all* modules to the new trunk version. Or, which is the slightly
better but more difficult option, do this after you apply the first
change to the parent pom after a release.
Carsten
--
Carsten Ziegeler
cziegeler@apache.org
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Reinhard Pötz <re...@apache.org>.
Carsten Ziegeler wrote:
> Reinhard Pötz wrote:
>>
>> yes, I was too lazy to touch nearly every POM file in our repository
>> just to increase the version number of our parent POMs. I haven't done
>> this for the last release either and AFAICT, no problem occurred.
>>
>> Does anybody know if it can cause problems if the development version
>> number isn't increased after a release?
>
> I think we shouldn't change the version number just for the sake of
> changing it.
I was releasing cocoon-parent because I wanted to use the latest
versions of some plugins and some dependencies (e.g. Spring).
> If the pom doesn't change why should we increase the version number?
sure, in that case there is no need
> I think we should simply drop the parent relationship from all modules
> and use the current parent poms just as reactor poms. Every real module
> pom directly has our root pom as the parent. This makes releasing imho
> much easier as there is no release of any intermediate pom required
> anymore. We're using this approach for a very long time now and it has
> made things much easier.
+1, exept for cocoon-core-modules because this allows a release of all
of our core modules in one go (multi-module release).
--
Reinhard Pötz Managing Director, {Indoqa} GmbH
http://www.indoqa.com/en/people/reinhard.poetz/
Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member reinhard@apache.org
________________________________________________________________________
Re: Is it necessary to increase the development version number (SNAPSHOT)
after a release?
Posted by Carsten Ziegeler <cz...@apache.org>.
Reinhard Pötz wrote:
>
> yes, I was too lazy to touch nearly every POM file in our repository
> just to increase the version number of our parent POMs. I haven't done
> this for the last release either and AFAICT, no problem occurred.
>
> Does anybody know if it can cause problems if the development version
> number isn't increased after a release?
I think we shouldn't change the version number just for the sake of
changing it.
If the pom doesn't change why should we increase the version number?
I think we should simply drop the parent relationship from all modules
and use the current parent poms just as reactor poms. Every real module
pom directly has our root pom as the parent. This makes releasing imho
much easier as there is no release of any intermediate pom required
anymore. We're using this approach for a very long time now and it has
made things much easier.
Carsten
--
Carsten Ziegeler
cziegeler@apache.org