Maven from source - version 2.x or 3.x ?

classic Classic list List threaded Threaded
19 messages Options
Reply | Threaded
Open this post in threaded view
|

Maven from source - version 2.x or 3.x ?

Kasun Gajasinghe
Hi all,
I'm working on getting Apache Maven in to work by building from
source. Currently, in main tree, Maven is installed using the binary
(dev-java/maven-bin), which is against the Gentoo Java Packaging
Policy.

Getting Maven in to work by building-from-source is a lengthy process.
We have two main versions to go ahead. The 2.x range with the latest
being v2.2.1, and the 3.x range with the latest being v3.0.3. The
compatibility notes for 2.x and 3.x are at [1]. There's only few
compatibility issues as I've seen. I was thinking to go with 2.x since
in my experience and the area where I was involved in, haven't had any
plans to migrate to Maven 3.x soon. But the overall picture may vary.

So, I'm asking from the Gentoo's Java community, what's the suitable
version to go with? 2.x or 3.x?

[1] https://cwiki.apache.org/MAVEN/maven-3x-compatibility-notes.html

PS: Development will be carried out at the gsoc-maven-overlay which is
based on the java-overlay.
http://overlays.gentoo.org/proj/java/browser/gsoc-maven-overlay

Thanks,
--Kasun

--
~~~*******'''''''''''''*******~~~
Kasun Gajasinghe,
University of Moratuwa,
Sri Lanka.
Blog: http://kasunbg.blogspot.com
Twitter: http://twitter.com/kasunbg

Reply | Threaded
Open this post in threaded view
|

Re: Maven from source - version 2.x or 3.x ?

kiorky
+1 for 2.X

--
Cordialement,
KiOrKY
GPG Key FingerPrint: 0x1A1194B7681112AF
Pensez à l’environnement.
N’imprimez ce courriel que si vous en avez vraiment besoin.


signature.asc (269 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Maven from source - version 2.x or 3.x ?

Eric Chatellier
In reply to this post by Kasun Gajasinghe
Le 22/05/2011 07:38, Kasun Gajasinghe a écrit :

> Hi all,
> I'm working on getting Apache Maven in to work by building from
> source. Currently, in main tree, Maven is installed using the binary
> (dev-java/maven-bin), which is against the Gentoo Java Packaging
> Policy.
>
> Getting Maven in to work by building-from-source is a lengthy process.
> We have two main versions to go ahead. The 2.x range with the latest
> being v2.2.1, and the 3.x range with the latest being v3.0.3. The
> compatibility notes for 2.x and 3.x are at [1]. There's only few
> compatibility issues as I've seen. I was thinking to go with 2.x since
> in my experience and the area where I was involved in, haven't had any
> plans to migrate to Maven 3.x soon. But the overall picture may vary.
>
> So, I'm asking from the Gentoo's Java community, what's the suitable
> version to go with? 2.x or 3.x
Hi, i'm a gentoo user and java developper using maven for
years. I also known the maven gentoo problem ;)
So i'll be happy to help you or test your work.

For maven 2/3, 3.x is a new achitecture intended to
be maven 2 complaint. So, i vote for 3.x.
But maybe 3.x is too young...

--
Éric Chatellier <[hidden email]>
Tel: 02.40.50.29.28
http://www.codelutin.com

Reply | Threaded
Open this post in threaded view
|

Re: Maven from source - version 2.x or 3.x ?

Petteri Räty-2
On 05/22/2011 05:54 PM, Eric Chatellier wrote:

> Le 22/05/2011 07:38, Kasun Gajasinghe a écrit :
>> Hi all,
>> I'm working on getting Apache Maven in to work by building from
>> source. Currently, in main tree, Maven is installed using the binary
>> (dev-java/maven-bin), which is against the Gentoo Java Packaging
>> Policy.
>>
>> Getting Maven in to work by building-from-source is a lengthy process.
>> We have two main versions to go ahead. The 2.x range with the latest
>> being v2.2.1, and the 3.x range with the latest being v3.0.3. The
>> compatibility notes for 2.x and 3.x are at [1]. There's only few
>> compatibility issues as I've seen. I was thinking to go with 2.x since
>> in my experience and the area where I was involved in, haven't had any
>> plans to migrate to Maven 3.x soon. But the overall picture may vary.
>>
>> So, I'm asking from the Gentoo's Java community, what's the suitable
>> version to go with? 2.x or 3.x
> Hi, i'm a gentoo user and java developper using maven for
> years. I also known the maven gentoo problem ;)
> So i'll be happy to help you or test your work.
>
> For maven 2/3, 3.x is a new achitecture intended to
> be maven 2 complaint. So, i vote for 3.x.
> But maybe 3.x is too young...
>
Eventually 2.x will die while 3.x continues to be supported and so on. I
would target 3.x and then do 2.x also if it's relative easy to backport.
If they are largely compatible as you say then targeting 3.x shouldn't
be a problem knowledge wise.

Regards,
Petteri


signature.asc (918 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Maven from source - version 2.x or 3.x ?

Kasun Gajasinghe
On Mon, May 23, 2011 at 3:24 AM, Petteri Räty <[hidden email]> wrote:

> On 05/22/2011 05:54 PM, Eric Chatellier wrote:
>> Le 22/05/2011 07:38, Kasun Gajasinghe a écrit :
>>> Hi all,
>>> I'm working on getting Apache Maven in to work by building from
>>> source. Currently, in main tree, Maven is installed using the binary
>>> (dev-java/maven-bin), which is against the Gentoo Java Packaging
>>> Policy.
>>>
>>> Getting Maven in to work by building-from-source is a lengthy process.
>>> We have two main versions to go ahead. The 2.x range with the latest
>>> being v2.2.1, and the 3.x range with the latest being v3.0.3. The
>>> compatibility notes for 2.x and 3.x are at [1]. There's only few
>>> compatibility issues as I've seen. I was thinking to go with 2.x since
>>> in my experience and the area where I was involved in, haven't had any
>>> plans to migrate to Maven 3.x soon. But the overall picture may vary.
>>>
>>> So, I'm asking from the Gentoo's Java community, what's the suitable
>>> version to go with? 2.x or 3.x
>> Hi, i'm a gentoo user and java developper using maven for
>> years. I also known the maven gentoo problem ;)
>> So i'll be happy to help you or test your work.

Thanks Eric. Much appreciate your help. I'm starting out now, and my
objective first goal is to bump all the maven modules. As you probably
know, maven-from-source is implemented in java-overlay though it's not
in a working state. So, have to fix all the bugs in there! :)
I could possibly use help on knowing the issues the current
implementation have for now only if you like that kind of thing!


>>
>> For maven 2/3, 3.x is a new achitecture intended to
>> be maven 2 complaint. So, i vote for 3.x.
>> But maybe 3.x is too young...
>>

Thanks... let's see what others say. See my comment below.

>
> Eventually 2.x will die while 3.x continues to be supported and so on. I
> would target 3.x and then do 2.x also if it's relative easy to backport.
> If they are largely compatible as you say then targeting 3.x shouldn't
> be a problem knowledge wise.

True. As they say, the *major* objective of Maven 3 was to decouple
maven core from reporting tools (such as site plugin). So, yes, Maven
3.x is compatible with 2.x except for the site plugin and few other
plugins mentioned at [2]. We can back-port, but _most_ of the projects
still depend on 2.x because there isn't any major issue with 2.x
except for the slightly slower performance afaik. So, I was afraid
whether going ahead with 3.x makes the real projects can't use
maven-from-source thing effectively.

So, I was in the mind supporting 2.x and then upgrade to 3.x when the
time comes. Does the site-plugin is actually useful when packaging?
Only packagers will know. If that's not matter much, then I'm OK to go
with 3.x.

[2] https://cwiki.apache.org/MAVEN/maven-3x-plugin-compatibility-matrix.html

Thanks,
--Kasun

--
~~~*******'''''''''''''*******~~~
Kasun Gajasinghe,
University of Moratuwa,
Sri Lanka.
Blog: http://kasunbg.blogspot.com
Twitter: http://twitter.com/kasunbg

Reply | Threaded
Open this post in threaded view
|

Re: Maven from source - version 2.x or 3.x ?

Petteri Räty-2
On 05/23/2011 09:15 AM, Kasun Gajasinghe wrote:

> On Mon, May 23, 2011 at 3:24 AM, Petteri Räty <[hidden email]> wrote:
>> On 05/22/2011 05:54 PM, Eric Chatellier wrote:
>>> Le 22/05/2011 07:38, Kasun Gajasinghe a écrit :
>>>> Hi all,
>>>> I'm working on getting Apache Maven in to work by building from
>>>> source. Currently, in main tree, Maven is installed using the binary
>>>> (dev-java/maven-bin), which is against the Gentoo Java Packaging
>>>> Policy.
>>>>
>>>> Getting Maven in to work by building-from-source is a lengthy process.
>>>> We have two main versions to go ahead. The 2.x range with the latest
>>>> being v2.2.1, and the 3.x range with the latest being v3.0.3. The
>>>> compatibility notes for 2.x and 3.x are at [1]. There's only few
>>>> compatibility issues as I've seen. I was thinking to go with 2.x since
>>>> in my experience and the area where I was involved in, haven't had any
>>>> plans to migrate to Maven 3.x soon. But the overall picture may vary.
>>>>
>>>> So, I'm asking from the Gentoo's Java community, what's the suitable
>>>> version to go with? 2.x or 3.x
>>> Hi, i'm a gentoo user and java developper using maven for
>>> years. I also known the maven gentoo problem ;)
>>> So i'll be happy to help you or test your work.
>
> Thanks Eric. Much appreciate your help. I'm starting out now, and my
> objective first goal is to bump all the maven modules. As you probably
> know, maven-from-source is implemented in java-overlay though it's not
> in a working state. So, have to fix all the bugs in there! :)
> I could possibly use help on knowing the issues the current
> implementation have for now only if you like that kind of thing!
>
>
>>>
>>> For maven 2/3, 3.x is a new achitecture intended to
>>> be maven 2 complaint. So, i vote for 3.x.
>>> But maybe 3.x is too young...
>>>
>
> Thanks... let's see what others say. See my comment below.
>
>>
>> Eventually 2.x will die while 3.x continues to be supported and so on. I
>> would target 3.x and then do 2.x also if it's relative easy to backport.
>> If they are largely compatible as you say then targeting 3.x shouldn't
>> be a problem knowledge wise.
>
> True. As they say, the *major* objective of Maven 3 was to decouple
> maven core from reporting tools (such as site plugin). So, yes, Maven
> 3.x is compatible with 2.x except for the site plugin and few other
> plugins mentioned at [2]. We can back-port, but _most_ of the projects
> still depend on 2.x because there isn't any major issue with 2.x
> except for the slightly slower performance afaik. So, I was afraid
> whether going ahead with 3.x makes the real projects can't use
> maven-from-source thing effectively.
>
maven-bin 2.x support continues to work through the binary package?

Regards,
Petteri


signature.asc (918 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Maven from source - version 2.x or 3.x ?

Kasun Gajasinghe
On Mon, May 23, 2011 at 12:08 PM, Petteri Räty <[hidden email]> wrote:

> On 05/23/2011 09:15 AM, Kasun Gajasinghe wrote:
>> On Mon, May 23, 2011 at 3:24 AM, Petteri Räty <[hidden email]> wrote:
>>> On 05/22/2011 05:54 PM, Eric Chatellier wrote:
>>>> Le 22/05/2011 07:38, Kasun Gajasinghe a écrit :
>>>>> Hi all,
>>>>> I'm working on getting Apache Maven in to work by building from
>>>>> source. Currently, in main tree, Maven is installed using the binary
>>>>> (dev-java/maven-bin), which is against the Gentoo Java Packaging
>>>>> Policy.
>>>>>
>>>>> Getting Maven in to work by building-from-source is a lengthy process.
>>>>> We have two main versions to go ahead. The 2.x range with the latest
>>>>> being v2.2.1, and the 3.x range with the latest being v3.0.3. The
>>>>> compatibility notes for 2.x and 3.x are at [1]. There's only few
>>>>> compatibility issues as I've seen. I was thinking to go with 2.x since
>>>>> in my experience and the area where I was involved in, haven't had any
>>>>> plans to migrate to Maven 3.x soon. But the overall picture may vary.
>>>>>
>>>>> So, I'm asking from the Gentoo's Java community, what's the suitable
>>>>> version to go with? 2.x or 3.x
>>>> Hi, i'm a gentoo user and java developper using maven for
>>>> years. I also known the maven gentoo problem ;)
>>>> So i'll be happy to help you or test your work.
>>
>> Thanks Eric. Much appreciate your help. I'm starting out now, and my
>> objective first goal is to bump all the maven modules. As you probably
>> know, maven-from-source is implemented in java-overlay though it's not
>> in a working state. So, have to fix all the bugs in there! :)
>> I could possibly use help on knowing the issues the current
>> implementation have for now only if you like that kind of thing!
>>
>>
>>>>
>>>> For maven 2/3, 3.x is a new achitecture intended to
>>>> be maven 2 complaint. So, i vote for 3.x.
>>>> But maybe 3.x is too young...
>>>>
>>
>> Thanks... let's see what others say. See my comment below.
>>
>>>
>>> Eventually 2.x will die while 3.x continues to be supported and so on. I
>>> would target 3.x and then do 2.x also if it's relative easy to backport.
>>> If they are largely compatible as you say then targeting 3.x shouldn't
>>> be a problem knowledge wise.
>>
>> True. As they say, the *major* objective of Maven 3 was to decouple
>> maven core from reporting tools (such as site plugin). So, yes, Maven
>> 3.x is compatible with 2.x except for the site plugin and few other
>> plugins mentioned at [2]. We can back-port, but _most_ of the projects
>> still depend on 2.x because there isn't any major issue with 2.x
>> except for the slightly slower performance afaik. So, I was afraid
>> whether going ahead with 3.x makes the real projects can't use
>> maven-from-source thing effectively.
>>
>
> maven-bin 2.x support continues to work through the binary package?

Yes, we can keep supporting maven-bin 2.x for maven users. Though the
packagers of projects based on maven won't be able to use the support
for maven 2.x if we start with 3.x.This project's focus is more
towards packagers, right?  I think Serkan or people who are more
familiar with this can give an exact answer.

--
~~~*******'''''''''''''*******~~~
Kasun Gajasinghe,
University of Moratuwa,
Sri Lanka.
Blog: http://kasunbg.blogspot.com
Twitter: http://twitter.com/kasunbg

Reply | Threaded
Open this post in threaded view
|

Re: Maven from source - version 2.x or 3.x ?

Petteri Räty-2
On 05/23/2011 07:52 PM, Kasun Gajasinghe wrote:

>>
>> maven-bin 2.x support continues to work through the binary package?
>
> Yes, we can keep supporting maven-bin 2.x for maven users. Though the
> packagers of projects based on maven won't be able to use the support
> for maven 2.x if we start with 3.x.This project's focus is more
> towards packagers, right?  I think Serkan or people who are more
> familiar with this can give an exact answer.
>

So are you discussing which version of Maven to build from source or
which version to target ebuild infrastructure for? Those two don't
necessarily need to be the same and your topic implied the former but
the above talks about the latter. The ebuild infrastructure for Maven
based projects should work just the same regardless of whether the maven
package itself is built from source or not. Our target is of course to
get rid of all binary packages but I consider this thread about asking
about priorities. For ebuild infrastructure targeting 2.x is fine if the
large majority of projects that will start using the work are using 2.x.
Otherwise I think my earlier logic still applies.

Regards,
Petteri


signature.asc (918 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Maven from source - version 2.x or 3.x ?

Kasun Gajasinghe
On 24 May 2011, at 14:37, Petteri Räty <[hidden email]> wrote:

> On 05/23/2011 07:52 PM, Kasun Gajasinghe wrote:
>
>>>
>>> maven-bin 2.x support continues to work through the binary package?
>>
>> Yes, we can keep supporting maven-bin 2.x for maven users. Though the
>> packagers of projects based on maven won't be able to use the support
>> for maven 2.x if we start with 3.x.This project's focus is more
>> towards packagers, right?  I think Serkan or people who are more
>> familiar with this can give an exact answer.
>>
>
> So are you discussing which version of Maven to build from source or
> which version to target ebuild infrastructure for? Those two don't
> necessarily need to be the same and your topic implied the former but
> the above talks about the latter.

Well, mainly this project is inclined towards packagers.
But of course the users are targeted too. Currently, users have the
maven-bin too
which means they have a choice in hand. The problem with Maven 3 is
that some important plugins for users are not
supported yet.

> The ebuild infrastructure for Maven
> based projects should work just the same regardless of whether the
> maven
> package itself is built from source or not. Our target is of course to
> get rid of all binary packages but I consider this thread about asking
> about priorities. For ebuild infrastructure targeting 2.x is fine if
> the
> large majority of projects that will start using the work are using
> 2.x.
> Otherwise I think my earlier logic still applies.

Indeed the large majority of the projects are using 2.x AFAIK. May be all? ;)

IMHO, it's better if we start with 2.x. Bumping to 3.x from there
isn't a big deal. And, by that time maven 3 would be much matured too.

Personally, I'm not switching my projects to 3.x because there's actually no
mind blowing reason. Only difference is the speed and the better error
reporting. These features doesn't deserve such a version increment anyway.

I think Petteri is OK with 2.x based on your comments? If there's no
further arguments from others, I'd like to go ahead with 2.x.

Thanks,
--Kasun


>

Reply | Threaded
Open this post in threaded view
|

Re: Maven from source - version 2.x or 3.x ?

robert burrell donkin-2
On Tue, May 24, 2011 at 12:52 PM, Kasun Gajasinghe <[hidden email]> wrote:

> On 24 May 2011, at 14:37, Petteri Räty <[hidden email]> wrote:
>> On 05/23/2011 07:52 PM, Kasun Gajasinghe wrote:
>>
>>>>
>>>> maven-bin 2.x support continues to work through the binary package?
>>>
>>> Yes, we can keep supporting maven-bin 2.x for maven users. Though the
>>> packagers of projects based on maven won't be able to use the support
>>> for maven 2.x if we start with 3.x.This project's focus is more
>>> towards packagers, right?  I think Serkan or people who are more
>>> familiar with this can give an exact answer.
>>>
>>
>> So are you discussing which version of Maven to build from source or
>> which version to target ebuild infrastructure for? Those two don't
>> necessarily need to be the same and your topic implied the former but
>> the above talks about the latter.
>
> Well, mainly this project is inclined towards packagers.
> But of course the users are targeted too. Currently, users have the
> maven-bin too
> which means they have a choice in hand. The problem with Maven 3 is
> that some important plugins for users are not
> supported yet.

AIUI the situation is more complex than that

maven seems to be moving towards requiring specific core versions for
builds. some  projects i develop require maven 2, some maven 3. i
manage this situation with a set of custom scripts and installations
independent of gentoo. i expect other developers now work in a similar
way. (same goes for jdks.) the gentoo java stuff just gets in my way
now for development.

FWIW one unresolved challenge for linux distributions with the rise of
bytecode languages (such as Java) is that compressed bytecodes are not
binaries in the usual sense (platform dependent machine executable
machine code). i know that it's a hard thing for the linux community
to hear but it's about time that the community acknowledged that these
languages are now mainstream and stop trying to force them into a
inappropriate provisioning model.

Robert

Reply | Threaded
Open this post in threaded view
|

Re: Maven from source - version 2.x or 3.x ?

Jörg Schaible-2
Hi Robert,

Robert Burrell Donkin wrote:

> On Tue, May 24, 2011 at 12:52 PM, Kasun Gajasinghe
> <[hidden email]> wrote:
>> On 24 May 2011, at 14:37, Petteri Räty
>> <[hidden email]> wrote:
>>> On 05/23/2011 07:52 PM, Kasun Gajasinghe wrote:
>>>
>>>>>
>>>>> maven-bin 2.x support continues to work through the binary package?
>>>>
>>>> Yes, we can keep supporting maven-bin 2.x for maven users. Though the
>>>> packagers of projects based on maven won't be able to use the support
>>>> for maven 2.x if we start with 3.x.This project's focus is more
>>>> towards packagers, right?  I think Serkan or people who are more
>>>> familiar with this can give an exact answer.
>>>>
>>>
>>> So are you discussing which version of Maven to build from source or
>>> which version to target ebuild infrastructure for? Those two don't
>>> necessarily need to be the same and your topic implied the former but
>>> the above talks about the latter.
>>
>> Well, mainly this project is inclined towards packagers.
>> But of course the users are targeted too. Currently, users have the
>> maven-bin too
>> which means they have a choice in hand. The problem with Maven 3 is
>> that some important plugins for users are not
>> supported yet.
>
> AIUI the situation is more complex than that
>
> maven seems to be moving towards requiring specific core versions for
> builds. some  projects i develop require maven 2, some maven 3. i
> manage this situation with a set of custom scripts and installations
> independent of gentoo. i expect other developers now work in a similar
> way. (same goes for jdks.) the gentoo java stuff just gets in my way
> now for development.

Why? I have emerged maven:1.0, maven:1.1, maven:2.0, maven:2.2 and
maven:3.0. I've selected my default version with eselect. However, I can use
any of those versions at the same time:

/usr/bin $ ls -lGgo m*v*n*
lrwxrwxrwx 1    34 Jan 22 14:07 maven-1.0 -> /usr/share/maven-
bin-1.0/bin/maven
lrwxrwxrwx 1    34 Jan 22 14:07 maven-1.1 -> /usr/share/maven-
bin-1.1/bin/maven
lrwxrwxrwx 1     7 Jul 19  2010 mvn -> mvn-3.0
lrwxrwxrwx 1    32 Apr 30  2010 mvn-2.0 -> /usr/share/maven-bin-2.0/bin/mvn
lrwxrwxrwx 1    32 Apr 30  2010 mvn-2.2 -> /usr/share/maven-bin-2.2/bin/mvn
lrwxrwxrwx 1    32 Mar 10 18:17 mvn-3.0 -> /usr/share/maven-bin-3.0/bin/mvn

All that eselect effectively does is to switch the unversioned link. You may
call any of those scripts (well, you should not have set MAVEN_HOME at all,
the Maven start script will do this for you anyway).

> FWIW one unresolved challenge for linux distributions with the rise of
> bytecode languages (such as Java) is that compressed bytecodes are not
> binaries in the usual sense (platform dependent machine executable
> machine code). i know that it's a hard thing for the linux community
> to hear but it's about time that the community acknowledged that these
> languages are now mainstream and stop trying to force them into a
> inappropriate provisioning model.

To build Maven from source in Gentoo I wonder about the hen-and-egg problem.

Cheers,
Jörg



Reply | Threaded
Open this post in threaded view
|

Re: Re: Maven from source - version 2.x or 3.x ?

robert burrell donkin-2
On Wed, May 25, 2011 at 5:09 PM, Jörg Schaible <[hidden email]> wrote:
> Hi Robert,

Hi Jörg :-)

> Robert Burrell Donkin wrote:
>
>> On Tue, May 24, 2011 at 12:52 PM, Kasun Gajasinghe
>> <[hidden email]> wrote:
>>> On 24 May 2011, at 14:37, Petteri Räty
>>> <[hidden email]> wrote:
>>>> On 05/23/2011 07:52 PM, Kasun Gajasinghe wrote:
>>>>
>>>>>>
>>>>>> maven-bin 2.x support continues to work through the binary package?
>>>>>
>>>>> Yes, we can keep supporting maven-bin 2.x for maven users. Though the
>>>>> packagers of projects based on maven won't be able to use the support
>>>>> for maven 2.x if we start with 3.x.This project's focus is more
>>>>> towards packagers, right?  I think Serkan or people who are more
>>>>> familiar with this can give an exact answer.
>>>>>
>>>>
>>>> So are you discussing which version of Maven to build from source or
>>>> which version to target ebuild infrastructure for? Those two don't
>>>> necessarily need to be the same and your topic implied the former but
>>>> the above talks about the latter.
>>>
>>> Well, mainly this project is inclined towards packagers.
>>> But of course the users are targeted too. Currently, users have the
>>> maven-bin too
>>> which means they have a choice in hand. The problem with Maven 3 is
>>> that some important plugins for users are not
>>> supported yet.
>>
>> AIUI the situation is more complex than that
>>
>> maven seems to be moving towards requiring specific core versions for
>> builds. some  projects i develop require maven 2, some maven 3. i
>> manage this situation with a set of custom scripts and installations
>> independent of gentoo. i expect other developers now work in a similar
>> way. (same goes for jdks.) the gentoo java stuff just gets in my way
>> now for development.
>
> Why? I have emerged maven:1.0, maven:1.1, maven:2.0, maven:2.2 and
> maven:3.0. I've selected my default version with eselect. However, I can use
> any of those versions at the same time:
>
> /usr/bin $ ls -lGgo m*v*n*
> lrwxrwxrwx 1    34 Jan 22 14:07 maven-1.0 -> /usr/share/maven-
> bin-1.0/bin/maven
> lrwxrwxrwx 1    34 Jan 22 14:07 maven-1.1 -> /usr/share/maven-
> bin-1.1/bin/maven
> lrwxrwxrwx 1     7 Jul 19  2010 mvn -> mvn-3.0
> lrwxrwxrwx 1    32 Apr 30  2010 mvn-2.0 -> /usr/share/maven-bin-2.0/bin/mvn
> lrwxrwxrwx 1    32 Apr 30  2010 mvn-2.2 -> /usr/share/maven-bin-2.2/bin/mvn
> lrwxrwxrwx 1    32 Mar 10 18:17 mvn-3.0 -> /usr/share/maven-bin-3.0/bin/mvn
>
> All that eselect effectively does is to switch the unversioned link. You may
> call any of those scripts (well, you should not have set MAVEN_HOME at all,
> the Maven start script will do this for you anyway).

Cool. Thanks :-)

Apache James builds now insists on particular minor versions (mostly
3.0.3 ATM). This matches the current version for maven-bin-3.0 but I
suppose it should be easy enough to create an overlay or something to
handle minor versions when needed...)

>> FWIW one unresolved challenge for linux distributions with the rise of
>> bytecode languages (such as Java) is that compressed bytecodes are not
>> binaries in the usual sense (platform dependent machine executable
>> machine code). i know that it's a hard thing for the linux community
>> to hear but it's about time that the community acknowledged that these
>> languages are now mainstream and stop trying to force them into a
>> inappropriate provisioning model.
>
> To build Maven from source in Gentoo I wonder about the hen-and-egg problem.

+1

The scale scares me as well. Loosely coupled systems assembled from
lots of components are becoming the dominant paradigm for bytecode
languages (such as java and ruby). The amount of effort required to
create independent builds for all those libraries is huge for no gain
I know.

I still believe that there are significant advantages to building
every application from source, and most applications built from
bytecode can be optimised for a platform. But IMHO the bytecode
repository approach is the best way to manage libraries for these
languages.

Robert

Reply | Threaded
Open this post in threaded view
|

Re: Re: Maven from source - version 2.x or 3.x ?

Kasun Gajasinghe
In reply to this post by Jörg Schaible-2
Hi Jörg, and Robert,

>> FWIW one unresolved challenge for linux distributions with the rise of
>> bytecode languages (such as Java) is that compressed bytecodes are not
>> binaries in the usual sense (platform dependent machine executable
>> machine code). i know that it's a hard thing for the linux community
>> to hear but it's about time that the community acknowledged that these
>> languages are now mainstream and stop trying to force them into a
>> inappropriate provisioning model.

So... what exactly are you suggesting? Switch in to using binaries
instead of building from source paradigm?

>
> To build Maven from source in Gentoo I wonder about the hen-and-egg problem.

Yes. To Bootstrap maven, the work around for this is by: first
generate ANT build.xml via `mvn ant:ant`. maven-bin will provide the
mvn command in this case. Then patch that build.xml to the source.
After that, ANT will take care of the building from source.

If any of you is interested, you are welcome to have a look at the
proposal for Maven from source for Gentoo [1]. Feedback is much
appreciated.

[1] http://socghop.appspot.com/gsoc/proposal/review/google/gsoc2011/kasun_gajasinghe/1

Thanks,
--Kasun

PS: Glad to see that "reply-to" now defaults to gentoo-java list. :-)

--
~~~*******'''''''''''''*******~~~
Kasun Gajasinghe,
University of Moratuwa,
Sri Lanka.
Blog: http://kasunbg.blogspot.com
Twitter: http://twitter.com/kasunbg

Reply | Threaded
Open this post in threaded view
|

Re: Re: Maven from source - version 2.x or 3.x ?

robert burrell donkin-2
On Thu, May 26, 2011 at 10:06 AM, Kasun Gajasinghe <[hidden email]> wrote:

> Hi Jörg, and Robert,
>
>>> FWIW one unresolved challenge for linux distributions with the rise of
>>> bytecode languages (such as Java) is that compressed bytecodes are not
>>> binaries in the usual sense (platform dependent machine executable
>>> machine code). i know that it's a hard thing for the linux community
>>> to hear but it's about time that the community acknowledged that these
>>> languages are now mainstream and stop trying to force them into a
>>> inappropriate provisioning model.
>
> So... what exactly are you suggesting? Switch in to using binaries
> instead of building from source paradigm?

i love the "build-from-source" paradigm but dependencies for languages
such as Java are distributed as compressed intermediate bytecode
source not binaries. bytecode dependencies work quite differently from
the libraries used by directly compiled languages. building
applications in a reliable and reproducable way for bytecode languages
requires provisioning libraries in native source form (ie. bytecode).

it's time to start working with these new languages rather than try to
fight them by forcing them to fit into inappropriate structures.

>> To build Maven from source in Gentoo I wonder about the hen-and-egg problem.
>
> Yes. To Bootstrap maven, the work around for this is by: first
> generate ANT build.xml via `mvn ant:ant`. maven-bin will provide the
> mvn command in this case. Then patch that build.xml to the source.
> After that, ANT will take care of the building from source.

not very reliable :-/

- robert

Reply | Threaded
Open this post in threaded view
|

Re: Re: Maven from source - version 2.x or 3.x ?

robert burrell donkin-2
In reply to this post by Jörg Schaible-2
On Wed, May 25, 2011 at 5:09 PM, Jörg Schaible <[hidden email]> wrote:
> Hi Robert,

Hi Jörg

> Robert Burrell Donkin wrote:

<snip>

>> maven seems to be moving towards requiring specific core versions for
>> builds. some  projects i develop require maven 2, some maven 3. i
>> manage this situation with a set of custom scripts and installations
>> independent of gentoo. i expect other developers now work in a similar
>> way. (same goes for jdks.) the gentoo java stuff just gets in my way
>> now for development.
>
> Why? I have emerged maven:1.0, maven:1.1, maven:2.0, maven:2.2 and
> maven:3.0. I've selected my default version with eselect. However, I can use
> any of those versions at the same time:
>
> /usr/bin $ ls -lGgo m*v*n*
> lrwxrwxrwx 1    34 Jan 22 14:07 maven-1.0 -> /usr/share/maven-
> bin-1.0/bin/maven
> lrwxrwxrwx 1    34 Jan 22 14:07 maven-1.1 -> /usr/share/maven-
> bin-1.1/bin/maven
> lrwxrwxrwx 1     7 Jul 19  2010 mvn -> mvn-3.0
> lrwxrwxrwx 1    32 Apr 30  2010 mvn-2.0 -> /usr/share/maven-bin-2.0/bin/mvn
> lrwxrwxrwx 1    32 Apr 30  2010 mvn-2.2 -> /usr/share/maven-bin-2.2/bin/mvn
> lrwxrwxrwx 1    32 Mar 10 18:17 mvn-3.0 -> /usr/share/maven-bin-3.0/bin/mvn
>
> All that eselect effectively does is to switch the unversioned link. You may
> call any of those scripts (well, you should not have set MAVEN_HOME at all,
> the Maven start script will do this for you anyway).

eselect edits the symlinks. this switches the maven version for the
entire system. i want to be able to switch maven (and ant and java)
versions for just a terminal. is there some way to make this work with
eselect?

- robert

Reply | Threaded
Open this post in threaded view
|

Re: Re: Maven from source - version 2.x or 3.x ?

Jörg Schaible-2
In reply to this post by robert burrell donkin-2
Hi Robert,

Robert Burrell Donkin wrote:

> On Wed, May 25, 2011 at 5:09 PM, Jörg Schaible
> <[hidden email]> wrote:
>> Hi Robert,
>
> Hi Jörg :-)
>
[snip]

>>>
>>> AIUI the situation is more complex than that
>>>
>>> maven seems to be moving towards requiring specific core versions for
>>> builds. some  projects i develop require maven 2, some maven 3. i
>>> manage this situation with a set of custom scripts and installations
>>> independent of gentoo. i expect other developers now work in a similar
>>> way. (same goes for jdks.) the gentoo java stuff just gets in my way
>>> now for development.
>>
>> Why? I have emerged maven:1.0, maven:1.1, maven:2.0, maven:2.2 and
>> maven:3.0. I've selected my default version with eselect. However, I can
>> use any of those versions at the same time:
>>
>> /usr/bin $ ls -lGgo m*v*n*
>> lrwxrwxrwx 1    34 Jan 22 14:07 maven-1.0 -> /usr/share/maven-
>> bin-1.0/bin/maven
>> lrwxrwxrwx 1    34 Jan 22 14:07 maven-1.1 -> /usr/share/maven-
>> bin-1.1/bin/maven
>> lrwxrwxrwx 1     7 Jul 19  2010 mvn -> mvn-3.0
>> lrwxrwxrwx 1    32 Apr 30  2010 mvn-2.0 ->
>> /usr/share/maven-bin-2.0/bin/mvn lrwxrwxrwx 1    32 Apr 30  2010 mvn-2.2
>> -> /usr/share/maven-bin-2.2/bin/mvn lrwxrwxrwx 1    32 Mar 10 18:17
>> mvn-3.0 -> /usr/share/maven-bin-3.0/bin/mvn
>>
>> All that eselect effectively does is to switch the unversioned link. You
>> may call any of those scripts (well, you should not have set MAVEN_HOME
>> at all, the Maven start script will do this for you anyway).
>
> Cool. Thanks :-)
>
> Apache James builds now insists on particular minor versions (mostly
> 3.0.3 ATM). This matches the current version for maven-bin-3.0 but I
> suppose it should be easy enough to create an overlay or something to
> handle minor versions when needed...)

I have typically always the latest installed for a specific slot. Never had
real problems with this. Apart from that I create my own ebuilds for Maven
RCs and the like. Actually I don't expect projects that require Maven 2.0 to
be really buildable with Maven 2.0.0 ;-)

>>> FWIW one unresolved challenge for linux distributions with the rise of
>>> bytecode languages (such as Java) is that compressed bytecodes are not
>>> binaries in the usual sense (platform dependent machine executable
>>> machine code). i know that it's a hard thing for the linux community
>>> to hear but it's about time that the community acknowledged that these
>>> languages are now mainstream and stop trying to force them into a
>>> inappropriate provisioning model.
>>
>> To build Maven from source in Gentoo I wonder about the hen-and-egg
>> problem.
>
> +1
>
> The scale scares me as well. Loosely coupled systems assembled from
> lots of components are becoming the dominant paradigm for bytecode
> languages (such as java and ruby). The amount of effort required to
> create independent builds for all those libraries is huge for no gain
> I know.
>
> I still believe that there are significant advantages to building
> every application from source, and most applications built from
> bytecode can be optimised for a platform. But IMHO the bytecode
> repository approach is the best way to manage libraries for these
> languages.

Maven simply does not fit to Gentoo's package philosophy. When you try to
build a complex project from source (like Maven itself), I am quite sure
that the build will require e.g. five different versions of commons-lang. So
what to do with it in Gentoo? Create slots for all of these versions? Create
a symlink in a system local Maven repo for all those versions to the one
that is actually installed? Who updates these symlinks if the real package
is updated? Not to speak that all of this already require a hook into
Gentoo's download processing ... and might possibly require calling emerge
for missing deps that are available as Gentoo package?

Luckily this is not *my* can of worms :D

Cheers,
Jörg


Reply | Threaded
Open this post in threaded view
|

Re: Re: Maven from source - version 2.x or 3.x ?

Jörg Schaible-2
In reply to this post by robert burrell donkin-2
Robert Burrell Donkin wrote:

> On Wed, May 25, 2011 at 5:09 PM, Jörg Schaible
> <[hidden email]> wrote:
>> Hi Robert,
>
> Hi Jörg
>
>> Robert Burrell Donkin wrote:
>
> <snip>
>
>>> maven seems to be moving towards requiring specific core versions for
>>> builds. some  projects i develop require maven 2, some maven 3. i
>>> manage this situation with a set of custom scripts and installations
>>> independent of gentoo. i expect other developers now work in a similar
>>> way. (same goes for jdks.) the gentoo java stuff just gets in my way
>>> now for development.
>>
>> Why? I have emerged maven:1.0, maven:1.1, maven:2.0, maven:2.2 and
>> maven:3.0. I've selected my default version with eselect. However, I can
>> use any of those versions at the same time:
>>
>> /usr/bin $ ls -lGgo m*v*n*
>> lrwxrwxrwx 1    34 Jan 22 14:07 maven-1.0 -> /usr/share/maven-
>> bin-1.0/bin/maven
>> lrwxrwxrwx 1    34 Jan 22 14:07 maven-1.1 -> /usr/share/maven-
>> bin-1.1/bin/maven
>> lrwxrwxrwx 1     7 Jul 19  2010 mvn -> mvn-3.0
>> lrwxrwxrwx 1    32 Apr 30  2010 mvn-2.0 ->
>> /usr/share/maven-bin-2.0/bin/mvn lrwxrwxrwx 1    32 Apr 30  2010 mvn-2.2
>> -> /usr/share/maven-bin-2.2/bin/mvn lrwxrwxrwx 1    32 Mar 10 18:17
>> mvn-3.0 -> /usr/share/maven-bin-3.0/bin/mvn
>>
>> All that eselect effectively does is to switch the unversioned link. You
>> may call any of those scripts (well, you should not have set MAVEN_HOME
>> at all, the Maven start script will do this for you anyway).
>
> eselect edits the symlinks. this switches the maven version for the
> entire system. i want to be able to switch maven (and ant and java)
> versions for just a terminal. is there some way to make this work with
> eselect?

Defining aliases? Or use prepend a terminal specific directory to the path
where you define your own symlinks.

export PATH=~/tmp/term-1:$PATH
ls ~/tmp/term-1
mvn -> /usr/bin/mvn-2.2
jar -> /usr/lib/jvm/sun-jdk-1.6/bin/jar
java -> /usr/lib/jvm/sun-jdk-1.6/bin/java
javac -> /usr/lib/jvm/sun-jdk-1.6/bin/javac
javah -> /usr/lib/jvm/sun-jdk-1.6/bin/javah

For Ant you might create your own slotted ebuilds (maybe as ant-bin to
separate from the one provided with Gentoo) and use symlinks again.

I am quite sure you can create a little helper script that sets up such
links for the current terminal when you provide the version for those
packages as argument.

Cheers,
Jörg


Reply | Threaded
Open this post in threaded view
|

Re: Re: Maven from source - version 2.x or 3.x ?

Jörg Schaible-2
In reply to this post by Kasun Gajasinghe
Kasun Gajasinghe wrote:

> Hi Jörg, and Robert,
>
>>> FWIW one unresolved challenge for linux distributions with the rise of
>>> bytecode languages (such as Java) is that compressed bytecodes are not
>>> binaries in the usual sense (platform dependent machine executable
>>> machine code). i know that it's a hard thing for the linux community
>>> to hear but it's about time that the community acknowledged that these
>>> languages are now mainstream and stop trying to force them into a
>>> inappropriate provisioning model.
>
> So... what exactly are you suggesting? Switch in to using binaries
> instead of building from source paradigm?

For Java: Yes. Use flags are still useful for dropping optional deps. I
recommended that already years ago.

>> To build Maven from source in Gentoo I wonder about the hen-and-egg
>> problem.
>
> Yes. To Bootstrap maven, the work around for this is by: first
> generate ANT build.xml via `mvn ant:ant`. maven-bin will provide the
> mvn command in this case. Then patch that build.xml to the source.
> After that, ANT will take care of the building from source.
>
> If any of you is interested, you are welcome to have a look at the
> proposal for Maven from source for Gentoo [1]. Feedback is much
> appreciated.
>
> [1]
>
[http://socghop.appspot.com/gsoc/proposal/review/google/gsoc2011/kasun_gajasinghe/1

One hint only: You might take a closer look at Tycho. That one replaces the
default dependency mechanism with a DependencyResolver that reads the
dependencies from the OSGi entries in the manifest and uses a complete
different repo layout (more or less what you see, when you look into
Eclipse's plugins directory). It might be possible to develop a solution
that uses similar hooks into the Maven core - to resolve deps and to support
a different repo layout. However, that requires a Gentoo-version of Maven
...

- Jörg


Reply | Threaded
Open this post in threaded view
|

Re: Re: Maven from source - version 2.x or 3.x ?

Jörg Schaible-2
Jörg Schaible wrote:

> Kasun Gajasinghe wrote:
>
>> Hi Jörg, and Robert,
>>
>>>> FWIW one unresolved challenge for linux distributions with the rise of
>>>> bytecode languages (such as Java) is that compressed bytecodes are not
>>>> binaries in the usual sense (platform dependent machine executable
>>>> machine code). i know that it's a hard thing for the linux community
>>>> to hear but it's about time that the community acknowledged that these
>>>> languages are now mainstream and stop trying to force them into a
>>>> inappropriate provisioning model.
>>
>> So... what exactly are you suggesting? Switch in to using binaries
>> instead of building from source paradigm?
>
> For Java: Yes. Use flags are still useful for dropping optional deps. I
> recommended that already years ago.

I really meant years ...
http://thread.gmane.org/gmane.linux.gentoo.java/43

 - Jörg