users@glassfish.java.net

Re: Downloading GF 4 via Maven fails

From: Oliver Fischer <mailsink_at_swe-blog.net>
Date: Sun, 18 Aug 2013 00:44:49 +0200

Hi Romain,

Thank you for the detailed explanation of this issue. In the meantime I
am able to handle this issue by adding an exclusion to the dependency
declaration.

Is there a planed release date for GF 4.0.1?

Bye,

Oliver

Am 13.08.2013 18:57, schrieb Romain Grecourt:
> 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 <type> 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]
> <extensions>
> <extension>
> <groupId>org.glassfish.build</groupId>
> <artifactId>glassfishbuild-maven-plugin</artifactId>
> <version>3.2.3</version>
> </extension>
> </extensions>
>
> [2]
> https://svn.java.net/svn/glassfish~svn/tags/4.0-b89/appserver/jdbc/jdbc-ra/jdbc-ra-distribution/pom.xml
>
>
> 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]
>>>>> <dependency>
>>>>> <groupId>org.glassfish.main.distributions</groupId>
>>>>> <artifactId>glassfish</artifactId>
>>>>> <version>4.0</version>
>>>>> <type>zip</type>
>>>>> </dependency>
>>>>>>
>>>>>> Bye,
>>>>>>
>>>>>> Oliver
>>>>>>
>>>>>
>>>
>