Re: [mvn] bad artifacs returned

2012-07-04 Thread Ron Wheeler

I am not sure I understand the reluctance to test that POMs are well-formed.
A POM that is not well-formed is worthy of a note at least.
Compared to the cost of a download, the test for well-formed XML should 
be pretty small for a file the size of a POM.



It should be possible to recognize the HTML returned by the "big-three" 
repos in the case of an error and display the HTML body or part of it in 
the error message.
Perhaps a standard could be agreed upon by the "big-three" to make it 
easier for Maven to detect the fact that an error message has been 
returned and have all three put out similar messages.


Ron


On 04/07/2012 6:24 PM, Wayne Fay wrote:

Ideally there would be some Maven magic which checks the contents of
the file and ensures it seems like a reasonable pom, jar, war, etc
before saving it to the local repo cache but that does not currently
exist beyond a feature request in JIRA.

I  think that the suggestion to validate items returned is a good one
that we should raise with, I think, Aether.

I don't disagree. I'm not sure that we can guarantee much beyond "this
seems to be XML" (I'm not sure that we should test for it being
well-formed etc) or "this seems to be a zip file" (for jars, wars and
ears) but just a basic check of "this is not garbage HTML" would be
sufficient (and a big enhancement) for most users.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org





--
Ron Wheeler
President
Artifact Software Inc
email: rwhee...@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: [mvn] bad artifacs returned

2012-07-04 Thread Ron Wheeler


Am I mistaken to think that a


  
  nexus
  *
http://myRepoURL:8081/nexus/content/groups/public

  

in my settings.xml will stop Maven from reaching a repo that someone 
defined in a jar that I include as a dependency?
I believe that this setting sucks up any attempt by Maven on the 
developers workstation to reach any repo and forces it to mine.


I will defer to your superior knowledge of Maven and repos but this was 
the belief that triggered my comments about the benefit of a properly 
configured Maven and repo preventing the problem in this case.


Am I wrong in thinking that I am safe from third party libraries 
interfering with my master plan of library reference?



Ron


On 04/07/2012 4:36 PM, Wayne Fay wrote:

This whole problem would not even be in the forum if a repo had been
installed.

Well, Josef did say in another post:

we have a corporate repository acting as a proxy to central !

...

But bad luck, our repository is really just a mirror of central and
contains the same rubbish for xalan-2.7.1.pom and jar

So it seems he does have some kind of a corporate repository which is
acting as a proxy. I don't know any more details though (what MRM he
is running, what version, how it is configured, etc) which might be
helpful to know.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org





--
Ron Wheeler
President
Artifact Software Inc
email: rwhee...@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: [mvn] bad artifacs returned

2012-07-04 Thread Wayne Fay
>>> Ideally there would be some Maven magic which checks the contents of
>>> the file and ensures it seems like a reasonable pom, jar, war, etc
>>> before saving it to the local repo cache but that does not currently
>>> exist beyond a feature request in JIRA.

> I  think that the suggestion to validate items returned is a good one
> that we should raise with, I think, Aether.

I don't disagree. I'm not sure that we can guarantee much beyond "this
seems to be XML" (I'm not sure that we should test for it being
well-formed etc) or "this seems to be a zip file" (for jars, wars and
ears) but just a basic check of "this is not garbage HTML" would be
sufficient (and a big enhancement) for most users.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: [mvn] bad artifacs returned

2012-07-04 Thread Benson Margulies
I  think that the suggestion to validate items returned is a good one
that we should raise with, I think, Aether.

On Wed, Jul 4, 2012 at 2:38 PM, Ron Wheeler
 wrote:
> There should be a BIG note on the Maven front page and on the download page.
>
> "Do NOT even think about using Maven until you have your Maven repo running!
> This means you!!! When applied without a repo, Maven is hazardous and may
> cause rage, intense loathing of your vocation and a desire to kick an
> innocent person, animal or inanimate object or to write ill-tempered e-mail
> to forums.
> Seriously, you will not like the experience and you may get hurt and waste
> days.
> If anything does not work and you do not have a repo, you are on your own
> and will have to depend on the pity of strangers!"
>
>
> This whole problem would not even be in the forum if a repo had been
> installed.
>
> Ron
>
>
> On 04/07/2012 12:42 PM, Wayne Fay wrote:
>>>
>>> in fact content of any jar or pom or sha downloaded is the html page
>>> explaining the user that
>>>
>>> *** Internet2 Shibboleth Project has moved ***
>>>
>>> what is wrong ?
>>>
>>> who has to act ?
>>
>> This is the result of a poorly configured Maven repository. This is
>> not Maven's fault.
>>
>> The shibboleth repository should not return http 200 status code when
>> it is unable to serve the proper file, which is what it is doing.
>> Maven interprets the http 200 status code as "everything is OK" and
>> saves the resulting HTML as the pom or jar file you requested.
>>
>> Ideally there would be some Maven magic which checks the contents of
>> the file and ensures it seems like a reasonable pom, jar, war, etc
>> before saving it to the local repo cache but that does not currently
>> exist beyond a feature request in JIRA.
>>
>> Problems like this hopefully teach people to be aware of what Maven
>> repositories they are linking to for dependencies and become a little
>> bit more cautious about them. Also if you were running a proper MRM
>> like Nexus, this problem would be dealt with in the MRM. For the best
>> Maven-experience, you really need to be running an MRM.
>>
>> Wayne
>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
>> For additional commands, e-mail: users-h...@maven.apache.org
>>
>>
>
>
> --
> Ron Wheeler
> President
> Artifact Software Inc
> email: rwhee...@artifact-software.com
> skype: ronaldmwheeler
> phone: 866-970-2435, ext 102
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: [mvn] bad artifacs returned

2012-07-04 Thread Wayne Fay
> This whole problem would not even be in the forum if a repo had been
> installed.

Well, Josef did say in another post:
>> we have a corporate repository acting as a proxy to central !
...
>> But bad luck, our repository is really just a mirror of central and
>> contains the same rubbish for xalan-2.7.1.pom and jar

So it seems he does have some kind of a corporate repository which is
acting as a proxy. I don't know any more details though (what MRM he
is running, what version, how it is configured, etc) which might be
helpful to know.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: [mvn] bad artifacs returned

2012-07-04 Thread Ron Wheeler

There should be a BIG note on the Maven front page and on the download page.

"Do NOT even think about using Maven until you have your Maven repo running!
This means you!!! When applied without a repo, Maven is hazardous and 
may cause rage, intense loathing of your vocation and a desire to kick 
an innocent person, animal or inanimate object or to write ill-tempered 
e-mail to forums.
Seriously, you will not like the experience and you may get hurt and 
waste days.
If anything does not work and you do not have a repo, you are on your 
own and will have to depend on the pity of strangers!"



This whole problem would not even be in the forum if a repo had been 
installed.


Ron


On 04/07/2012 12:42 PM, Wayne Fay wrote:

in fact content of any jar or pom or sha downloaded is the html page explaining 
the user that

*** Internet2 Shibboleth Project has moved ***

what is wrong ?

who has to act ?

This is the result of a poorly configured Maven repository. This is
not Maven's fault.

The shibboleth repository should not return http 200 status code when
it is unable to serve the proper file, which is what it is doing.
Maven interprets the http 200 status code as "everything is OK" and
saves the resulting HTML as the pom or jar file you requested.

Ideally there would be some Maven magic which checks the contents of
the file and ensures it seems like a reasonable pom, jar, war, etc
before saving it to the local repo cache but that does not currently
exist beyond a feature request in JIRA.

Problems like this hopefully teach people to be aware of what Maven
repositories they are linking to for dependencies and become a little
bit more cautious about them. Also if you were running a proper MRM
like Nexus, this problem would be dealt with in the MRM. For the best
Maven-experience, you really need to be running an MRM.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org





--
Ron Wheeler
President
Artifact Software Inc
email: rwhee...@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: [mvn-3] jar files causing problems

2012-07-04 Thread Wayne Fay
> 100%-nail-hit! how did you know that
> xalan-2.7.1.jar & xalan-2.7.1.pom
> and other stuff . . .
> when downloaded as maven-artifact
> from the repository, comes down with
> such a bunch of HTML rubbish in it?

This is not entirely uncommon. I have seen it happen myself (from old
java.net repo, don't get me started). Since then, I am much more
careful about what mirrors I leverage in my builds and what repos we
connect to.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: [mvn] bad artifacs returned

2012-07-04 Thread Wayne Fay
> in fact content of any jar or pom or sha downloaded is the html page 
> explaining the user that
>
> *** Internet2 Shibboleth Project has moved ***
>
> what is wrong ?
>
> who has to act ?

This is the result of a poorly configured Maven repository. This is
not Maven's fault.

The shibboleth repository should not return http 200 status code when
it is unable to serve the proper file, which is what it is doing.
Maven interprets the http 200 status code as "everything is OK" and
saves the resulting HTML as the pom or jar file you requested.

Ideally there would be some Maven magic which checks the contents of
the file and ensures it seems like a reasonable pom, jar, war, etc
before saving it to the local repo cache but that does not currently
exist beyond a feature request in JIRA.

Problems like this hopefully teach people to be aware of what Maven
repositories they are linking to for dependencies and become a little
bit more cautious about them. Also if you were running a proper MRM
like Nexus, this problem would be dealt with in the MRM. For the best
Maven-experience, you really need to be running an MRM.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: AW: AW: [mvn] bad artifacs returned

2012-07-04 Thread Ron Wheeler

That is why one should not put repo definitions in poms.
The people at fault are the opensaml authors.

It is also why you mirror ALL references to repos that Maven makes so 
that they all go to your repo manager and then your repo manager will 
decide what external repos should be consulted.

That is your fault in this case.

BTW:

shibboleth.internet2.edu has no way to notify others who will be impacted by 
their shutdown.
Perhaps they did notify you when they did it years ago but you did not 
understand how that would affect you until this week.


OTOH: I sure hope Sonatype never shuts down Maven Central without sending me an 
e-mail.
Sonantype guys, just to let you know... I really depend on Maven Central being 
up.


Was I wrong about the dependency definition being incorrect?

Ron



On 04/07/2012 12:09 PM, Stadelmann Josef wrote:

And opensaml-2.2.3.pom has a reference as well


 
 shibboleth.internet2.edu
 Internet2
 default
 http://shibboleth.internet2.edu/downloads/maven2
 
 false
 
 
 

Just to become aware that this url is outdated and leads to troubles with maven 
when used in a download.
Don't ask me about the mystery when this will happen.

Josef




-Ursprüngliche Nachricht-
Von: Ron Wheeler [mailto:rwhee...@artifact-software.com]
Gesendet: Mittwoch, 4. Juli 2012 17:36
An: users@maven.apache.org
Betreff: Re: AW: [mvn] bad artifacs returned

It appears you have a bad dependency definition.

Only you can fix it.

The right one is

 xalan
 xalan
 2.7.1


It appears that you have


 org.apache.xalan
 xalan
 2.7.1


No one knows how you got this included in your effective POM but it is
wrong.

Excluding all the repos in the world will not fix your problem.

Ron

On 04/07/2012 10:46 AM, Stadelmann Josef wrote:

that is what I want to tell you that you will not find any artifacy at

-Ursprüngliche Nachricht-
Von: Olivier Lamy [mailto:ol...@apache.org]
Gesendet: Mittwoch, 4. Juli 2012 16:37
An: Maven Users List
Betreff: Re: [mvn] bad artifacs returned

AFAIK xalan has the groupId:artifactId xalan:xalan see
http://repo.maven.apache.org/maven2/xalan/xalan/

Maybe you declare the repository
http://shibboleth.internet2.edu/downloads/maven2 in your pom (or in a
project you are using)

2012/7/4 Stadelmann Josef :

what is returned to an depencey invoked artifact download
if the link to the artifact does not hit a .pom or the .jar wanted
but is redirected by the receiving repository server to a basic
html page explaing the user that artifacts have been moved?

i.e. currently for
/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.jar
/org/opensaml/openws/1.2.2/openws-1.2.2.jar;
jargs/jargs/1.0/jargs-1.0.jar

i.e. beeing requested to download from
Downloading:
http://repo1.maven.org/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.p
om
but is then redirected to
Downloading:
http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/
2.7.1/xalan-2.7.1.pom
where it ends in the nirvana as this EP is redirected
http://shibboleth.internet2.edu/ explaing that stuuf has been moved.

Josef







--
Ron Wheeler
President
Artifact Software Inc
email: rwhee...@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



AW: AW: [mvn] bad artifacs returned

2012-07-04 Thread Stadelmann Josef
And opensaml-2.2.3.pom has a reference as well

   

shibboleth.internet2.edu
Internet2
default
http://shibboleth.internet2.edu/downloads/maven2

false




Just to become aware that this url is outdated and leads to troubles with maven 
when used in a download.
Don't ask me about the mystery when this will happen.

Josef




-Ursprüngliche Nachricht-
Von: Ron Wheeler [mailto:rwhee...@artifact-software.com] 
Gesendet: Mittwoch, 4. Juli 2012 17:36
An: users@maven.apache.org
Betreff: Re: AW: [mvn] bad artifacs returned

It appears you have a bad dependency definition.

Only you can fix it.

The right one is

xalan
xalan
2.7.1


It appears that you have


org.apache.xalan
xalan
2.7.1


No one knows how you got this included in your effective POM but it is 
wrong.

Excluding all the repos in the world will not fix your problem.

Ron

On 04/07/2012 10:46 AM, Stadelmann Josef wrote:
> that is what I want to tell you that you will not find any artifacy at
>
> -Ursprüngliche Nachricht-
> Von: Olivier Lamy [mailto:ol...@apache.org]
> Gesendet: Mittwoch, 4. Juli 2012 16:37
> An: Maven Users List
> Betreff: Re: [mvn] bad artifacs returned
>
> AFAIK xalan has the groupId:artifactId xalan:xalan see
> http://repo.maven.apache.org/maven2/xalan/xalan/
>
> Maybe you declare the repository
> http://shibboleth.internet2.edu/downloads/maven2 in your pom (or in a
> project you are using)
>
> 2012/7/4 Stadelmann Josef :
>> what is returned to an depencey invoked artifact download
>> if the link to the artifact does not hit a .pom or the .jar wanted
>> but is redirected by the receiving repository server to a basic
>> html page explaing the user that artifacts have been moved?
>>
>> i.e. currently for
>> /org/apache/xalan/xalan/2.7.1/xalan-2.7.1.jar
>> /org/opensaml/openws/1.2.2/openws-1.2.2.jar;
>> jargs/jargs/1.0/jargs-1.0.jar
>>
>> i.e. beeing requested to download from
>> Downloading:
>> http://repo1.maven.org/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.p
>> om
>> but is then redirected to
>> Downloading:
>> http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/
>> 2.7.1/xalan-2.7.1.pom
>> where it ends in the nirvana as this EP is redirected
>> http://shibboleth.internet2.edu/ explaing that stuuf has been moved.
>>
>> Josef
>
>


-- 
Ron Wheeler
President
Artifact Software Inc
email: rwhee...@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



AW: AW: [mvn] bad artifacs returned

2012-07-04 Thread Stadelmann Josef
Ron

I would not say that - because I just found out that the artifact
org/apache/rampart/rampart-project/1.6.2/rampart-project-1.6.1.pom 
has the following snippet in it. AND
My project so far depends on this artifact and it comes from apache !

Now I will check if I can make it without this artifact.
rampart-project-1.6.1.pom

and rampart-1.6.2 as well





true
always
warn


true
never
warn

open-saml
OpenSAML
http://shibboleth.internet2.edu/downloads/maven2/





But the trouble makers are not at apache ! 
they are at EDU shibboleth which moved the artifact repository 
potentially without telling axis2/rampart folk what they did.

what can maven do when a request for an artifact is re-directed into nirvana?

Josef





-Ursprüngliche Nachricht-
Von: Ron Wheeler [mailto:rwhee...@artifact-software.com] 
Gesendet: Mittwoch, 4. Juli 2012 17:36
An: users@maven.apache.org
Betreff: Re: AW: [mvn] bad artifacs returned

It appears you have a bad dependency definition.

Only you can fix it.

The right one is

xalan
xalan
2.7.1


It appears that you have


org.apache.xalan
xalan
2.7.1


No one knows how you got this included in your effective POM but it is 
wrong.

Excluding all the repos in the world will not fix your problem.

Ron

On 04/07/2012 10:46 AM, Stadelmann Josef wrote:
> that is what I want to tell you that you will not find any artifacy at
>
> -Ursprüngliche Nachricht-
> Von: Olivier Lamy [mailto:ol...@apache.org]
> Gesendet: Mittwoch, 4. Juli 2012 16:37
> An: Maven Users List
> Betreff: Re: [mvn] bad artifacs returned
>
> AFAIK xalan has the groupId:artifactId xalan:xalan see
> http://repo.maven.apache.org/maven2/xalan/xalan/
>
> Maybe you declare the repository
> http://shibboleth.internet2.edu/downloads/maven2 in your pom (or in a
> project you are using)
>
> 2012/7/4 Stadelmann Josef :
>> what is returned to an depencey invoked artifact download
>> if the link to the artifact does not hit a .pom or the .jar wanted
>> but is redirected by the receiving repository server to a basic
>> html page explaing the user that artifacts have been moved?
>>
>> i.e. currently for
>> /org/apache/xalan/xalan/2.7.1/xalan-2.7.1.jar
>> /org/opensaml/openws/1.2.2/openws-1.2.2.jar;
>> jargs/jargs/1.0/jargs-1.0.jar
>>
>> i.e. beeing requested to download from
>> Downloading:
>> http://repo1.maven.org/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.p
>> om
>> but is then redirected to
>> Downloading:
>> http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/
>> 2.7.1/xalan-2.7.1.pom
>> where it ends in the nirvana as this EP is redirected
>> http://shibboleth.internet2.edu/ explaing that stuuf has been moved.
>>
>> Josef
>
>


-- 
Ron Wheeler
President
Artifact Software Inc
email: rwhee...@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: AW: [mvn] bad artifacs returned

2012-07-04 Thread Ron Wheeler

It appears you have a bad dependency definition.

Only you can fix it.

The right one is

   xalan
   xalan
   2.7.1


It appears that you have


   org.apache.xalan
   xalan
   2.7.1


No one knows how you got this included in your effective POM but it is 
wrong.


Excluding all the repos in the world will not fix your problem.

Ron

On 04/07/2012 10:46 AM, Stadelmann Josef wrote:

that is what I want to tell you that you will not find any artifacy at

-Ursprüngliche Nachricht-
Von: Olivier Lamy [mailto:ol...@apache.org]
Gesendet: Mittwoch, 4. Juli 2012 16:37
An: Maven Users List
Betreff: Re: [mvn] bad artifacs returned

AFAIK xalan has the groupId:artifactId xalan:xalan see
http://repo.maven.apache.org/maven2/xalan/xalan/

Maybe you declare the repository
http://shibboleth.internet2.edu/downloads/maven2 in your pom (or in a
project you are using)

2012/7/4 Stadelmann Josef :

what is returned to an depencey invoked artifact download
if the link to the artifact does not hit a .pom or the .jar wanted
but is redirected by the receiving repository server to a basic
html page explaing the user that artifacts have been moved?

i.e. currently for
/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.jar
/org/opensaml/openws/1.2.2/openws-1.2.2.jar;
jargs/jargs/1.0/jargs-1.0.jar

i.e. beeing requested to download from
Downloading:
http://repo1.maven.org/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.p
om
but is then redirected to
Downloading:
http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/
2.7.1/xalan-2.7.1.pom
where it ends in the nirvana as this EP is redirected
http://shibboleth.internet2.edu/ explaing that stuuf has been moved.

Josef






--
Ron Wheeler
President
Artifact Software Inc
email: rwhee...@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: Help me to understand this unpack-dependencies?

2012-07-04 Thread hujirong
Thank you for the help, here is the result:

C:\Sandbox\MDM\WESB>mvn dependency:tree
[INFO] Scanning for projects...
[INFO]
[INFO]

[INFO] Building WESB Deployment R2-0.0.1-SNAPSHOT
[INFO]

[INFO]
[INFO] --- maven-dependency-plugin:2.4:tree (default-cli) @ MDM-WESB ---
[INFO] com.nbfg.mdm.environments:MDM-WESB:pom:R2-0.0.1-SNAPSHOT
[INFO] \- com.nbfg.fw.wsadmin:dpllib:zip:1.0.0-SNAPSHOT:compile
[INFO]

[INFO] BUILD SUCCESS
[INFO]

[INFO] Total time: 0.823s
[INFO] Finished at: Wed Jul 04 11:19:09 EDT 2012
[INFO] Final Memory: 12M/512M
[INFO]

C:\Sandbox\MDM\WESB>

--
View this message in context: 
http://maven.40175.n5.nabble.com/Help-me-to-understand-this-unpack-dependencies-tp5712889p5712989.html
Sent from the Maven - Users mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: reactor build && changes in module && recompilation of dependent modules

2012-07-04 Thread Stephen Connolly
Keep in mind that the reactor in general resolves the jar within the
multi-module project... so you don't know which source files changed as
easily and therefore you don't know which .class files to remove

If you run with -DskipTests most builds are very fast anyway (hey I
regularly rebuild all of Jenkins clean every day) and any decent unix guy
worth their crusties should be able to fork maven in the background to
build for them ;-)

On 4 July 2012 15:30, Dmitry Trunikov  wrote:

>
>  The way I do this is to use my IDE's dependency analysis to have my IDE
> do a "Make" (which rebuilds all the downstream changes)... then before I
> commit I will do a "mvn clean verify" to make sure that my changes are good
>
>
> Yes my IDE does the analysis too.
> The problem is in my colleague.
> He is unix geek and orthodox and use Emacs as java IDE. At the start of
> the project we had a long discussion what use as build tool.
> He insisted on Ant because he knew exactly how it works and can easily
> adjust build process.
> I proposed to use Maven as it has perfect support of multi-module projects
> (at least I thought so at that time).
> I frustrated a lot because in my opinion recompilation of dependent
> modules when dependency was changed is a main goal of any matured build
> tool.
> And I was convinced that Maven reactor mechanism does it perfectly.
> Actually I can't believe in absence of such functionality in Maven.
>


Re: [mvn] bad artifacs returned

2012-07-04 Thread Olivier Lamy
so in such case a solution is to exclude org.apache.xalan:xalan from
the shibboleth artifact.
and add a dependency to xalan:xalan.
And contact those folks who publish bad poms.

2012/7/4 Stadelmann Josef :
> that is what I want to tell you that you will not find any artifacy at
>
> -Ursprüngliche Nachricht-
> Von: Olivier Lamy [mailto:ol...@apache.org]
> Gesendet: Mittwoch, 4. Juli 2012 16:37
> An: Maven Users List
> Betreff: Re: [mvn] bad artifacs returned
>
> AFAIK xalan has the groupId:artifactId xalan:xalan see
> http://repo.maven.apache.org/maven2/xalan/xalan/
>
> Maybe you declare the repository
> http://shibboleth.internet2.edu/downloads/maven2 in your pom (or in a
> project you are using)
>
> 2012/7/4 Stadelmann Josef :
>> what is returned to an depencey invoked artifact download
>> if the link to the artifact does not hit a .pom or the .jar wanted
>> but is redirected by the receiving repository server to a basic
>> html page explaing the user that artifacts have been moved?
>>
>> i.e. currently for
>> /org/apache/xalan/xalan/2.7.1/xalan-2.7.1.jar
>> /org/opensaml/openws/1.2.2/openws-1.2.2.jar;
>> jargs/jargs/1.0/jargs-1.0.jar
>>
>> i.e. beeing requested to download from
>> Downloading:
>> http://repo1.maven.org/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.p
>> om
>> but is then redirected to
>> Downloading:
>> http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/
>> 2.7.1/xalan-2.7.1.pom
>> where it ends in the nirvana as this EP is redirected
>> http://shibboleth.internet2.edu/ explaing that stuuf has been moved.
>>
>> Josef
>
>
>
> --
> Olivier Lamy
> Talend: http://coders.talend.com
> http://twitter.com/olamy | http://linkedin.com/in/olamy
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>



-- 
Olivier Lamy
Talend: http://coders.talend.com
http://twitter.com/olamy | http://linkedin.com/in/olamy

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



AW: [mvn] bad artifacs returned

2012-07-04 Thread Stadelmann Josef
that is what I want to tell you that you will not find any artifacy at 

-Ursprüngliche Nachricht-
Von: Olivier Lamy [mailto:ol...@apache.org] 
Gesendet: Mittwoch, 4. Juli 2012 16:37
An: Maven Users List
Betreff: Re: [mvn] bad artifacs returned

AFAIK xalan has the groupId:artifactId xalan:xalan see
http://repo.maven.apache.org/maven2/xalan/xalan/

Maybe you declare the repository
http://shibboleth.internet2.edu/downloads/maven2 in your pom (or in a
project you are using)

2012/7/4 Stadelmann Josef :
> what is returned to an depencey invoked artifact download
> if the link to the artifact does not hit a .pom or the .jar wanted
> but is redirected by the receiving repository server to a basic
> html page explaing the user that artifacts have been moved?
>
> i.e. currently for
> /org/apache/xalan/xalan/2.7.1/xalan-2.7.1.jar
> /org/opensaml/openws/1.2.2/openws-1.2.2.jar;
> jargs/jargs/1.0/jargs-1.0.jar
>
> i.e. beeing requested to download from
> Downloading:
> http://repo1.maven.org/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.p
> om
> but is then redirected to
> Downloading:
> http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/
> 2.7.1/xalan-2.7.1.pom
> where it ends in the nirvana as this EP is redirected
> http://shibboleth.internet2.edu/ explaing that stuuf has been moved.
>
> Josef



-- 
Olivier Lamy
Talend: http://coders.talend.com
http://twitter.com/olamy | http://linkedin.com/in/olamy

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: AW: [mvn-3] jar files causing problems

2012-07-04 Thread Jörg Schaible
Hi Josef,

Stadelmann Josef wrote:

> Ok Wayne
> or anybody else

[snip]

> What I do not understand is, why xalan-* and a few other artifacts must
> come down from
> http://shibboleth.internet2.edu/downloads/maven2/org/apache/
> 
> Where can I prevent this? can I? can I black-list proactively the
> http://shibboleth.internet2.edu/downloads/maven2 ?
> 
> can someone more fluent with that confirm or explain me what happens?

M2 has the unfortunate habbit to take repositories into account that are 
somewhere declared in one of the POMs that are part of your build (i.e. also 
those in transitive 3rd party POMs). That's the reason why it is discouraged 
to declare repositories in POMs. Therefore your mirror declaration should 
have a * entry to mask all those additional "injected" 
repos. IIRC M3 behaves better, but uses such repos under some circumstances 
also.

Regards,
Jörg


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



AW: [mvn] bad artifacs returned

2012-07-04 Thread Stadelmann Josef
To answer part of my question:

if a project has a dependency on xalan, and somehow maven-magic the artifact is 
said to be at 
http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.pom

however, there, a redirect happens, and the pom or the jar just ends in the 
following content/page


http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";>
http://www.w3.org/1999/xhtml";>


Internet2 Shibboleth Project has moved

Re: [mvn] bad artifacs returned

2012-07-04 Thread Olivier Lamy
AFAIK xalan has the groupId:artifactId xalan:xalan see
http://repo.maven.apache.org/maven2/xalan/xalan/

Maybe you declare the repository
http://shibboleth.internet2.edu/downloads/maven2 in your pom (or in a
project you are using)

2012/7/4 Stadelmann Josef :
> what is returned to an depencey invoked artifact download
> if the link to the artifact does not hit a .pom or the .jar wanted
> but is redirected by the receiving repository server to a basic
> html page explaing the user that artifacts have been moved?
>
> i.e. currently for
> /org/apache/xalan/xalan/2.7.1/xalan-2.7.1.jar
> /org/opensaml/openws/1.2.2/openws-1.2.2.jar;
> jargs/jargs/1.0/jargs-1.0.jar
>
> i.e. beeing requested to download from
> Downloading:
> http://repo1.maven.org/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.p
> om
> but is then redirected to
> Downloading:
> http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/
> 2.7.1/xalan-2.7.1.pom
> where it ends in the nirvana as this EP is redirected
> http://shibboleth.internet2.edu/ explaing that stuuf has been moved.
>
> Josef



-- 
Olivier Lamy
Talend: http://coders.talend.com
http://twitter.com/olamy | http://linkedin.com/in/olamy

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: reactor build && changes in module && recompilation of dependent modules

2012-07-04 Thread Dmitry Trunikov


The way I do this is to use my IDE's dependency analysis to have my 
IDE do a "Make" (which rebuilds all the downstream changes)... then 
before I commit I will do a "mvn clean verify" to make sure that my 
changes are good




Yes my IDE does the analysis too.
The problem is in my colleague.
He is unix geek and orthodox and use Emacs as java IDE. At the start of 
the project we had a long discussion what use as build tool.
He insisted on Ant because he knew exactly how it works and can easily 
adjust build process.
I proposed to use Maven as it has perfect support of multi-module 
projects (at least I thought so at that time).
I frustrated a lot because in my opinion recompilation of dependent 
modules when dependency was changed is a main goal of any matured build 
tool.

And I was convinced that Maven reactor mechanism does it perfectly.
Actually I can't believe in absence of such functionality in Maven.


[mvn] bad artifacs returned

2012-07-04 Thread Stadelmann Josef
what is returned to an depencey invoked artifact download
if the link to the artifact does not hit a .pom or the .jar wanted
but is redirected by the receiving repository server to a basic
html page explaing the user that artifacts have been moved?

i.e. currently for
/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.jar
/org/opensaml/openws/1.2.2/openws-1.2.2.jar;
jargs/jargs/1.0/jargs-1.0.jar

i.e. beeing requested to download from 
Downloading:
http://repo1.maven.org/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.p
om
but is then redirected to
Downloading:
http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/
2.7.1/xalan-2.7.1.pom
where it ends in the nirvana as this EP is redirected
http://shibboleth.internet2.edu/ explaing that stuuf has been moved.

Josef


AW: [mvn-3] jar files causing problems

2012-07-04 Thread Stadelmann Josef
Ok Wayne
or anybody else

we have a corporate repository acting as a proxy to central !
fine - this safes you a lot bandwidth and us time.

But what shall I do if I get same rubbish from our repository as well as from 
central when I ask for pom / jar? for an artifact?

I just cleared out my m2/repository and have all downloaded for a small axis2 
project from our repository at axa-winterthur.

As xalan jars and pom's and others are in error, just rubbish HTML in it, I 
expected our axa-winterthur repository is bad;
Hence I took out from settings.xml the  to our repository. Sso I work 
without any mirror at the moment. 

But bad luck, our repository is really just a mirror of central and contains 
the same rubbish for xalan-2.7.1.pom and jar 

- HTML in a POM and in the jar's 

while my $ mvn install 
takes place I observer the following

[INFO] 
[INFO] Building SpezplaService 1.6.1
[INFO] 
Downloading: 
http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-deploy-plugin/maven-metadata.xml
Downloaded: 
http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-deploy-plugin/maven-metadata.xml
 (614 B at 2.2 KB/sec)
Downloading: 
http://repo1.maven.org/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.pom
Downloading: 
http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.pom
[WARNING] Checksum validation failed, expected http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.pom
[WARNING] Checksum validation failed, expected http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.pom


let's take 1 by 1
Downloading: 
http://shibboleth.internet2.edu/downloads/maven2/org/apache/xalan/xalan/2.7.1/xalan-2.7.1.pom

taking this URL into the browser brings you to the shibboleth site and it seems 
that the expected repository has been relocated to somewhere else. I think, 
maven cannot handle this bad redirection but sucks up the HTML rubbish instead 
from this site for the artifacts wanted.

What I do not understand is, why xalan-* and a few other artifacts must come 
down from http://shibboleth.internet2.edu/downloads/maven2/org/apache/

Where can I prevent this? can I? can I black-list proactively the 
http://shibboleth.internet2.edu/downloads/maven2 ?

can someone more fluent with that confirm or explain me what happens?

any help welcome

Josef
 


-Ursprüngliche Nachricht-
Von: Wayne Fay [mailto:wayne...@gmail.com] 
Gesendet: Dienstag, 3. Juli 2012 18:28
An: Maven Users List
Betreff: Re: [mvn-3] jar files causing problems

> [WARNING] The POM for org.apache.xalan:xalan:jar:2.7.1 is invalid,
> transitive dependencies (if any) will not be available, enable debug logging
> for more details

Cat the jar file or open it in vi etc. I bet you see an HTTP 503 or a
404 or something other HTML in there instead of the proper binary jar
bits.

Most likely you have a problem in your settings.xml. Ideally you
should set up a proper local Maven Repository Manager (Nexus, Archiva,
Artifactory, etc) and leverage it for your jar access.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: reactor build && changes in module && recompilation of dependent modules

2012-07-04 Thread Stephen Connolly
On 4 July 2012 09:46, Dmitry Trunikov  wrote:

>
>  javac will only recompile classes that have changed. it does not do
>> dependency analysis, so a breaking change will only cause a compile failure
>> until you do clean
>>
>>
> Thank you for clarification.
> Is there any way (except explicit 'clean') to turn on dependency analysis
> during compilation.
> The project consists of tens of modules so approach with 'clean' is not
> good enough because full re-biuld requires relative significant amount of
> time.
>
>
The way I do this is to use my IDE's dependency analysis to have my IDE do
a "Make" (which rebuilds all the downstream changes)... then before I
commit I will do a "mvn clean verify" to make sure that my changes are good


>
> Thanks for your help,
> Dmitry
>


AW: [mvn-3] jar files causing problems

2012-07-04 Thread Stadelmann Josef
Wayne

100%-nail-hit! how did you know that 
xalan-2.7.1.jar & xalan-2.7.1.pom
and other stuff . . .
when downloaded as maven-artifact 
from the repository, comes down with 
such a bunch of HTML rubbish in it?

Who deposits xalan-2.7.1.jar é all?

Before I deleted the mirrors in my 
settings.xml, there was local company
repository mirror defined. This mirror
acts as proxy. And it provided me the
same rubbish. So I removed this mirror.

So the rubbish is located somehow central 
and I wonder if I am the only one having 
this types of troubles. 

Below my settings.xml

Josef



  /dka3/stadelma/.m2/repository
  
   
   true
   http
   proxyserver.ch
   8080
   C770817
   orbxorbx
   *.wgrintra.net
   default
   
  
  
  


I am going to move now, from my local PC m2/repository,
the failing artifacts into the OpenVMS m2/repository. 





-Ursprüngliche Nachricht-
Von: Wayne Fay [mailto:wayne...@gmail.com] 
Gesendet: Dienstag, 3. Juli 2012 18:28
An: Maven Users List
Betreff: Re: [mvn-3] jar files causing problems

> [WARNING] The POM for org.apache.xalan:xalan:jar:2.7.1 is invalid,
> transitive dependencies (if any) will not be available, enable debug logging
> for more details

Cat the jar file or open it in vi etc. I bet you see an HTTP 503 or a
404 or something other HTML in there instead of the proper binary jar
bits.

Most likely you have a problem in your settings.xml. Ideally you
should set up a proper local Maven Repository Manager (Nexus, Archiva,
Artifactory, etc) and leverage it for your jar access.

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: reactor build && changes in module && recompilation of dependent modules

2012-07-04 Thread Dmitry Trunikov


javac will only recompile classes that have changed. it does not do 
dependency analysis, so a breaking change will only cause a compile 
failure until you do clean




Thank you for clarification.
Is there any way (except explicit 'clean') to turn on dependency 
analysis during compilation.
The project consists of tens of modules so approach with 'clean' is not 
good enough because full re-biuld requires relative significant amount 
of time.


Thanks for your help,
Dmitry

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: reactor build && changes in module && recompilation of dependent modules

2012-07-04 Thread Stephen Connolly
On 3 July 2012 15:55, Dmitry Trunikov  wrote:

> Hi All,
>
> It seems that my question has an obvious answer. Unfortunately googling
> didn't give me a good one.
>
> Prerequisites:
>
> I have a classical multi-module project. The root POM declares two
> modules: 'api' and 'impl'.
> These modules have references to the parent.
> The module 'api' contains definition of an interface.
> The module 'impl' has dependency on 'api' and a class which implements the
> interface.
>
> Issue:
>
> In the top directory I run a reactor build:
>
> [First build]
> $ mvn clean compile
>
> The build finished with success.
> Then I made changes in the interface declaration in the module 'api'
> (added a new method) and run build again:
>
> [Second build]
> $ mvn compile
>
>
javac will only recompile classes that have changed. it does not do
dependency analysis, so a breaking change will only cause a compile failure
until you do clean


> The build finished with success again. It is strange because I expected
> that build finished with failure because class in the module 'impl' had no
> implementation of the method just added to the interface.
> When I run build with command:
>
> [Third build]
> $ mvn clean compile
>
> It finished, as I expected, with failure.
>
> Question:
>
> Why Maven didn't complain on second build?
>
>
> Thanks for your help,
>
> Dmitry
>


Re: Help me to understand this unpack-dependencies?

2012-07-04 Thread Jörg Schaible
Hi Jirong,

hujirong wrote:

> I found CDIPubSubMgmtMed-0.0.1-SNAPSHOT-scripts.zip in Nexus in this
> folder:
> local:8080/nexus/content/groups/mdm-
public/com/nbfg/max/wesb/CDIPubSubMgmtMed/0.0.1-SNAPSHOT/
> 
> So I guess because the project is depending on the following:
> 
>   
>  com.nbfg.max.wesb
> CDIPubSubMgmtMed
> 0.0.1-SNAPSHOT
> ear
>   App
> 
> 
> The classifier makes it look for *scripts.zip in that folder.

Well, no.

> However, the
> Maven doc doesn't tell exactly how it works:
> http://maven.apache.org/plugins/maven-dependency-plugin/unpack-
dependencies-mojo.html#classifier

It works on the declared (or inherited) dependencies. You can implement a 
Mojo to look for artifacts of a different classifier, but I'd be really 
surprised if the assembly plugin does something like that. I'd bet that the 
script artifact is part of your dependency tree.

- Jörg


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: reactor build && changes in module && recompilation of dependent modules

2012-07-04 Thread Dmitry Trunikov

Hi Wayne,

The app version is '1.0-SNAPSHOT'.
The Maven is:

$ mvn --version
Apache Maven 3.0.3 (r1075438; 2011-02-28 19:31:09+0200)
Maven home: /opt/maven
Java version: 1.6.0_29, vendor: Sun Microsystems Inc.
Java home: /opt/jdk1.6.0_29/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "3.2.0-25-generic", arch: "amd64", family: "unix"

Below are the POMs which I use to reproduce the issue.
Directory structure:

pom.xml  [root pom, the builds were run in this dir]
|
+-api   [module of an interface]
|   |
|   +pom.xml
|
+-impl [module of an implementation]
|
+pom.xml


The root POM:


http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/xsd/maven-4.0.0.xsd";>


4.0.0

a.b.c
foo
pom
1.0-SNAPSHOT


api
impl






maven-clean-plugin
2.4.1


maven-resources-plugin
2.5


org.apache.maven.plugins
maven-compiler-plugin
2.4

1.6
1.6








The POM for 'api' module:


http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/xsd/maven-4.0.0.xsd";>


4.0.0


a.b.c
foo
1.0-SNAPSHOT
..


foo-api
1.0-SNAPSHOT
jar


foo-api
src/main/java




The POM for 'impl' module:


http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/xsd/maven-4.0.0.xsd";>


4.0.0


a.b.c
foo
1.0-SNAPSHOT
..


a.b.c
foo-impl
1.0-SNAPSHOT
jar



a.b.c
foo-api
1.0-SNAPSHOT




foo-impl
src/main/java





Thanks for your help,

Dmitry



On 07/04/2012 12:15 AM, Wayne Fay wrote:

Question:

Why Maven didn't complain on second build?

What are the versions of the various projects in your build?

Wayne




-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org