You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by sebb <se...@gmail.com> on 2017/04/21 13:12:39 UTC

[ALL] explicit Maven groupId in component POMs

Commons components use two different styles of groupId:

commons-<component> - used by some original components (e.g. IO, NET)
org.apache.commons - newer style, used by most components

Since Commons Parent uses the latter, and the groupId is inherited, in
theory a component using the new groupId does not need to specify it.

However, I think that is unwise, as it's not clear whether the
omission is deliberate or accidental.
Also the parent could potentially be changed to one with a different groupId.

Far better to specify the groupId explicitly rather than relying on an
inherited default.

Agreed?

S.
P.S. Note that changing the groupId can only be done if the package
name is also changed, see
https://wiki.apache.org/commons/MavenAndClasspath

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [ALL] explicit Maven groupId in component POMs

Posted by Gary Gregory <ga...@gmail.com>.
K

On Apr 21, 2017 6:21 AM, "Emmanuel Bourg" <eb...@apache.org> wrote:

Le 21/04/2017 à 15:12, sebb a écrit :

> Agreed?

I don't mind, but IntelliJ will highlight the groupId and suggest to
remove it :)



Same in Eclipse. POMs are big enough as it is, I prefer to keep the config
by exception going, but that's just me.

Gary


Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org

Re: [ALL] explicit Maven groupId in component POMs

Posted by Pascal Schumacher <pa...@gmx.net>.
Am 21.04.2017 um 15:21 schrieb Emmanuel Bourg:
> I don't mind, but IntelliJ will highlight the groupId and suggest to
> remove it :)
Eclipse also warns that the groupId duplicates the parent groupId.

I prefer not to duplicate the parent groupId.

Cheers,
Pascal

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [ALL] explicit Maven groupId in component POMs

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 21/04/2017 � 15:12, sebb a �crit :

> Agreed?

I don't mind, but IntelliJ will highlight the groupId and suggest to
remove it :)

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [ALL] explicit Maven groupId in component POMs

Posted by Emmanuel Bourg <eb...@apache.org>.
Le 21/04/2017 � 18:39, sebb a �crit :

> But the problem is that it would be very easy to change the parent gid
> and assume that everything is still OK.

But why would we change the parent groupId? It hasn't changed since its
first release 10 years ago and I don't see the need for a new name.

Emmanuel Bourg


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [ALL] explicit Maven groupId in component POMs

Posted by sebb <se...@gmail.com>.
On 21 April 2017 at 16:54, Benedikt Ritter <br...@apache.org> wrote:
>
>> Am 21.04.2017 um 15:12 schrieb sebb <se...@gmail.com>:
>>
>> Commons components use two different styles of groupId:
>>
>> commons-<component> - used by some original components (e.g. IO, NET)
>> org.apache.commons - newer style, used by most components
>>
>> Since Commons Parent uses the latter, and the groupId is inherited, in
>> theory a component using the new groupId does not need to specify it.
>>
>> However, I think that is unwise, as it's not clear whether the
>> omission is deliberate or accidental.
>> Also the parent could potentially be changed to one with a different groupId.
>>
>> Far better to specify the groupId explicitly rather than relying on an
>> inherited default.
>>
>> Agreed?
>
> -1: it’s redundant and unnecessary.

Strictly speaking, yes.

But the problem is that it would be very easy to change the parent gid
and assume that everything is still OK.

Especially with Commons which has a mixture of groupIds, I think it's
important to explicitly state the intended groupId for each component.

>>
>> S.
>> P.S. Note that changing the groupId can only be done if the package
>> name is also changed, see
>> https://wiki.apache.org/commons/MavenAndClasspath
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
>> For additional commands, e-mail: dev-help@commons.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [ALL] explicit Maven groupId in component POMs

Posted by Benedikt Ritter <br...@apache.org>.
> Am 21.04.2017 um 15:12 schrieb sebb <se...@gmail.com>:
> 
> Commons components use two different styles of groupId:
> 
> commons-<component> - used by some original components (e.g. IO, NET)
> org.apache.commons - newer style, used by most components
> 
> Since Commons Parent uses the latter, and the groupId is inherited, in
> theory a component using the new groupId does not need to specify it.
> 
> However, I think that is unwise, as it's not clear whether the
> omission is deliberate or accidental.
> Also the parent could potentially be changed to one with a different groupId.
> 
> Far better to specify the groupId explicitly rather than relying on an
> inherited default.
> 
> Agreed?

-1: it’s redundant and unnecessary.

> 
> S.
> P.S. Note that changing the groupId can only be done if the package
> name is also changed, see
> https://wiki.apache.org/commons/MavenAndClasspath
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org