Skip to main content

Re: Downloading GF 4 via Maven fails

1 reply [Last post]
Romain Grecourt...
Offline
Joined: 2012-02-17
Points: 0

On 8/13/13 2:03 PM, Oliver B. Fischer wrote:
> Yes, I download it as Maven dependency.
We do this and don't face that particular problem.

The transitive dependencies should be avoided though, it would prevent
any such issue.
See https://java.net/jira/browse/GLASSFISH-20427.

Which maven version are you using ? Can you share a small pom that
reproduces the issue on your end ?

Thanks,
Romain
>
> Am 13.08.13 13:52, schrieb Romain Grecourt:
>> On 8/13/13 1:41 PM, Oliver B. Fischer wrote:
>>> Hi,
>>>
>>> I download the Zip distribution of GlassFish via Maven. Currently the
>>> download fails because of a missing dependency to
>>>
>>> org.glassfish.main.jdbc:templates:distribution-fragment:4.0
>>>
>>> I haven't found it at the main Maven repository =>
>>>
>>> http://bit.ly/13xaeYa
>>>
>>> Might it be possible that someone forgot to upload this artifact?
>> How do you download it ? Via a dependency [1] in a pom, with
>> dependency:get, or some other way ?
>>
>> Thanks,
>> Romain
>>
>> [1]
>>
>> org.glassfish.main.distributions
>> glassfish
>> 4.0
>> zip
>>
>>>
>>> Bye,
>>>
>>> Oliver
>>>
>>

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Romain Grecourt...
Offline
Joined: 2012-02-17
Points: 0

Hi Oliver,

You actually spotted a real issue.

As related in GLASSFISH-20427,
org.glassfish.main.distributions:glassfish:4.0:zip is exposes it
transitive dependencies to consumers.
Unfortunately it also exposes the inconsistencies in the GlassFish
dependencies:

"distribution-fragment" is a custom packaging type that specifies a
lifecycle for creating various ".zip" archives, it is part of
org.glassfish.build:glassfishbuild-maven-plugin.
When loaded as an extension [1], both "distribution-fragment" and "zip"
can be used as for the dependency.
If not, "distribution-fragment" is not mapped to "zip" and the
[transitive] dependency can't be resolved.

org.glassfish.main.jdbc:template can't be resolved because refered to by
[2] as "distribution-fragment" instead of "zip", tha't a bug.

Both (this one + GLASSFISH-20427) will be fixed as part of the next release.

Thanks,
Romain

[1]

org.glassfish.build
glassfishbuild-maven-plugin
3.2.3

[2]
https://svn.java.net/svn/glassfish~svn/tags/4.0-b89/appserver/jdbc/jdbc-...

On 8/13/13 4:14 PM, Oliver B. Fischer wrote:
> Hi Romain,
>
> can you try the attached POM (mvn -f gf4-download.xml)?
>
> Here is the output of mvn -v on my machine:
>
> plexus/labor$ mvn -v
> Apache Maven 3.0.3 (r1075438; 2011-02-28 18:31:09+0100)
> Maven home: /usr/share/maven
> Java version: 1.7.0_21, vendor: Oracle Corporation
> Java home:
> /Library/Java/JavaVirtualMachines/jdk1.7.0_21.jdk/Contents/Home/jre
> Default locale: de_DE, platform encoding: UTF-8
> OS name: "mac os x", version: "10.8.4", arch: "x86_64", family: "mac"
>
> Bye,
>
> Oliver
>
> Am 13.08.13 14:12, schrieb Romain Grecourt:
>> On 8/13/13 2:03 PM, Oliver B. Fischer wrote:
>>> Yes, I download it as Maven dependency.
>> We do this and don't face that particular problem.
>>
>> The transitive dependencies should be avoided though, it would prevent
>> any such issue.
>> See https://java.net/jira/browse/GLASSFISH-20427.
>>
>> Which maven version are you using ? Can you share a small pom that
>> reproduces the issue on your end ?
>>
>> Thanks,
>> Romain
>>>
>>> Am 13.08.13 13:52, schrieb Romain Grecourt:
>>>> On 8/13/13 1:41 PM, Oliver B. Fischer wrote:
>>>>> Hi,
>>>>>
>>>>> I download the Zip distribution of GlassFish via Maven. Currently the
>>>>> download fails because of a missing dependency to
>>>>>
>>>>> org.glassfish.main.jdbc:templates:distribution-fragment:4.0
>>>>>
>>>>> I haven't found it at the main Maven repository =>
>>>>>
>>>>> http://bit.ly/13xaeYa
>>>>>
>>>>> Might it be possible that someone forgot to upload this artifact?
>>>> How do you download it ? Via a dependency [1] in a pom, with
>>>> dependency:get, or some other way ?
>>>>
>>>> Thanks,
>>>> Romain
>>>>
>>>> [1]
>>>>
>>>> org.glassfish.main.distributions
>>>> glassfish
>>>> 4.0
>>>> zip
>>>>
>>>>>
>>>>> Bye,
>>>>>
>>>>> Oliver
>>>>>
>>>>
>>