How to tell EAR packager to use the exact names created by <addClasspath>true</addClasspath>?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

How to tell EAR packager to use the exact names created by <addClasspath>true</addClasspath>?

mkarg
I am using the ear and acr plugins to build an ear that contains an
app-client. It all works well but one thing is always wrong:

 

The car must use <addClasspath>true</addClasspath> so the client will
find the needed libraries. When those libraries are SNAPSHOTs, the
created manifest entry contains not "SNAPSHOT" but the latest date (as
usual with SNAPSHOTs). But the ear plugin doesn't care for this. It
always uses "SNAPSHOT" (the word, not the latest version). As a result,
at runtime the client will not find the needed libraries, as it looks
for it by date, but it actually is named "SNAPSHOT".

 

For me this looks like a bug in the conception of the EAR plugin: It
must not statically build the name from the version string, but it
certainly needs to use the actual name of the artifact (here: the date
of the snapshot).

 

Is that really a bug or am I too dumb to see the light? ;-)

 

Regards

Markus

Reply | Threaded
Open this post in threaded view
|

Re: How to tell EAR packager to use the exact names created by <addClasspath>true</addClasspath>?

Anders Hammar
Sounds like a bug when building a multi-module project. File a JIRA
ticket with a test project to recreate the issue.
Also, if you're not using Maven 3, try to build with that as well to
see if that solves the problem.

/Anders

On Mon, Mar 12, 2012 at 10:06, Markus Karg <[hidden email]> wrote:

> I am using the ear and acr plugins to build an ear that contains an
> app-client. It all works well but one thing is always wrong:
>
>
>
> The car must use <addClasspath>true</addClasspath> so the client will
> find the needed libraries. When those libraries are SNAPSHOTs, the
> created manifest entry contains not "SNAPSHOT" but the latest date (as
> usual with SNAPSHOTs). But the ear plugin doesn't care for this. It
> always uses "SNAPSHOT" (the word, not the latest version). As a result,
> at runtime the client will not find the needed libraries, as it looks
> for it by date, but it actually is named "SNAPSHOT".
>
>
>
> For me this looks like a bug in the conception of the EAR plugin: It
> must not statically build the name from the version string, but it
> certainly needs to use the actual name of the artifact (here: the date
> of the snapshot).
>
>
>
> Is that really a bug or am I too dumb to see the light? ;-)
>
>
>
> Regards
>
> Markus
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: How to tell EAR packager to use the exact names created by <addClasspath>true</addClasspath>?

Markus KARG-3
Maven is 3.0.4

What exactly do you think is "the bug": The fact that Class-Path is
replacing "-SNAPSHOT" by version, or the fact that EAR plugin is NOT doing
so?

Thanks!
Markus

> -----Original Message-----
> From: [hidden email] [mailto:[hidden email]] On
> Behalf Of Anders Hammar
> Sent: Montag, 12. März 2012 11:21
> To: Maven Users List
> Subject: Re: How to tell EAR packager to use the exact names created by
> <addClasspath>true</addClasspath>?
>
> Sounds like a bug when building a multi-module project. File a JIRA
> ticket with a test project to recreate the issue.
> Also, if you're not using Maven 3, try to build with that as well to
> see if that solves the problem.
>
> /Anders
>
> On Mon, Mar 12, 2012 at 10:06, Markus Karg <[hidden email]> wrote:
> > I am using the ear and acr plugins to build an ear that contains an
> > app-client. It all works well but one thing is always wrong:
> >
> >
> >
> > The car must use <addClasspath>true</addClasspath> so the client will
> > find the needed libraries. When those libraries are SNAPSHOTs, the
> > created manifest entry contains not "SNAPSHOT" but the latest date
> (as
> > usual with SNAPSHOTs). But the ear plugin doesn't care for this. It
> > always uses "SNAPSHOT" (the word, not the latest version). As a
> > result, at runtime the client will not find the needed libraries, as
> > it looks for it by date, but it actually is named "SNAPSHOT".
> >
> >
> >
> > For me this looks like a bug in the conception of the EAR plugin: It
> > must not statically build the name from the version string, but it
> > certainly needs to use the actual name of the artifact (here: the
> date
> > of the snapshot).
> >
> >
> >
> > Is that really a bug or am I too dumb to see the light? ;-)
> >
> >
> >
> > Regards
> >
> > Markus
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]



---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: How to tell EAR packager to use the exact names created by <addClasspath>true</addClasspath>?

Anders Hammar
Well, the bug is that the generated classpath does not match the
actual library file names.
I haven't looked at the code, but very possibly the bug might not be
in the plugin's code but some library used to calculate the classpath
(which expects unique snapshot file name). In any case, file the bug
report on the plugin and include a test project that will reproduce
the problem. Also clearly state what environment (exact Maven version
etc.) you're using.

/Anders

On Sat, Mar 17, 2012 at 15:35, Markus KARG <[hidden email]> wrote:

> Maven is 3.0.4
>
> What exactly do you think is "the bug": The fact that Class-Path is
> replacing "-SNAPSHOT" by version, or the fact that EAR plugin is NOT doing
> so?
>
> Thanks!
> Markus
>
>> -----Original Message-----
>> From: [hidden email] [mailto:[hidden email]] On
>> Behalf Of Anders Hammar
>> Sent: Montag, 12. März 2012 11:21
>> To: Maven Users List
>> Subject: Re: How to tell EAR packager to use the exact names created by
>> <addClasspath>true</addClasspath>?
>>
>> Sounds like a bug when building a multi-module project. File a JIRA
>> ticket with a test project to recreate the issue.
>> Also, if you're not using Maven 3, try to build with that as well to
>> see if that solves the problem.
>>
>> /Anders
>>
>> On Mon, Mar 12, 2012 at 10:06, Markus Karg <[hidden email]> wrote:
>> > I am using the ear and acr plugins to build an ear that contains an
>> > app-client. It all works well but one thing is always wrong:
>> >
>> >
>> >
>> > The car must use <addClasspath>true</addClasspath> so the client will
>> > find the needed libraries. When those libraries are SNAPSHOTs, the
>> > created manifest entry contains not "SNAPSHOT" but the latest date
>> (as
>> > usual with SNAPSHOTs). But the ear plugin doesn't care for this. It
>> > always uses "SNAPSHOT" (the word, not the latest version). As a
>> > result, at runtime the client will not find the needed libraries, as
>> > it looks for it by date, but it actually is named "SNAPSHOT".
>> >
>> >
>> >
>> > For me this looks like a bug in the conception of the EAR plugin: It
>> > must not statically build the name from the version string, but it
>> > certainly needs to use the actual name of the artifact (here: the
>> date
>> > of the snapshot).
>> >
>> >
>> >
>> > Is that really a bug or am I too dumb to see the light? ;-)
>> >
>> >
>> >
>> > Regards
>> >
>> > Markus
>> >
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [hidden email]
>> For additional commands, e-mail: [hidden email]
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]