[M2] Repository Problem trying to override central and maintain local corporate repository

2007-03-14 Thread Peter Anning
Hi,
 
We need to override the Maven Central Repository and maintain a local
network repository. This has worked fine, up until now, with a mirror
setting in the maven settings.xml
 
settings
  ...
  mirrors
mirror
  idmirror-maven-central/id
  mirrorOfcentral/mirrorOf
  nameLocal Override for The Maven Central Repository/name
  urlfile:///\\AUBNVRAT03\repository\/url !-- Yes this works
it's how you define a file based repo --
/mirror
  /mirrors
  ...
/settings
 
When building a project I noticed that mysteriously Maven was
downloading jibx jars from http://jibx.sf.net/maven Despite the fact
that our network does not allow outbound http traffic and the local
settings.xml file not defining any proxies!
 
On further investigation and debugging I found that the
xfire-jibx-1.2.4.pom in my corporate repository defines a repository
with an id of jibx.sf.net and the rouge url of http://jibx.sf.net/maven
as a workaround I have created another mirror definition that overrides
this repo id and points at my corporate repository.
 
mirror
  idmirror-jibx.sf.net/id
  mirrorOfjibx.sf.net/mirrorOf
  nameLocal Override for Jibx/name
  urlfile:///\\AUBNVRAT03\repository\/url
/mirror
 
This stops it downloading from a remote source in this case.
 
The questions are: How on earth Maven is picking up proxy settings from
the underlying system is still a mystery. I certainly can't browse to
this repository when I use a Browser with no proxy configured?!
 
Surely this is not desired behaviour, how can I be sure that Maven won't
go sucking jars off the Internet when I don't want it to?
 
 

 

Peter Anning

Sr Software Engineer

 

Dialect Payment Technologies Pty Ltd

 

[EMAIL PROTECTED]

www.dialectpayments.com

 

 

 

 

IMPORTANT NOTICE

---

Confidentiality Note: The information contained in this email and any
attachments is confidential and/or privileged. This email and any
attachments are intended to be read only by the person named above. If
the reader of this email and any attachments is not the intended
recipient, or a representative of the intended recipient, you are hereby
notified that any review, dissemination or copying of this email and any
attachments is prohibited. If you have received this email and any
attachments in error, please notify the sender by email, telephone or
fax and return it to the sender at the email address above. 

 

 


RE: How to Use custom central repository completely instead of the default central repository?

2007-03-14 Thread Peter Anning
You need to define it in your settings.xml as a mirror in your
settings.xml and place  a repository in an active profile as per the
example below (note the three slashes in the file url:

settings
  ...
  mirrors
mirror
  idmirror-maven-central/id
  mirrorOfcentral/mirrorOf
  nameLocal Override for The Maven Central Repository/name
  urlfile:///E:\repository1\/url !-- Yes this works it's how
you define a file based repo --
/mirror
  /mirrors
  ...

profile
idmyProfile/id
repositories  
repository
releases
enabledtrue/enabled
updatePolicy/

checksumPolicyignore/checksumPolicy
/releases
snapshots
enabledtrue/enabled
updatePolicy/

checksumPolicyignore/checksumPolicy
/snapshots
idmy-central/id
nameMaven Repository
Switchboard/name
urlfile:///E:\repository1\/url
layoutdefault/layout
/repository
/repositories
pluginRepositories
  pluginRepository
releases
  updatePolicynever/updatePolicy
/releases
snapshots
  enabledtrue/enabled
/snapshots
idmy-central/id
nameMaven Plugin Repository/name
urlfile:///E:\repository1\/url
  /pluginRepository
/pluginRepositories   
/profile
  /profiles

  activeProfiles
activeProfilemyProfile/activeProfile
  /activeProfiles

/settings

 -Original Message-
 From: JesseLiu [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, 15 March 2007 11:56 AM
 To: Maven Users List
 Subject: How to Use custom central repository completely 
 instead of the default central repository?
 
 
 I want to build a file repository in my computer which can't 
 access Internet. so, I create the repository in  
 file://e:\repository1 which contains all the required 
 artifacts hierarchy. and config pom.xml like below: project
   modelVersion4.0.0/modelVersion
   groupIdcom.mycompany.dolly/groupId
   artifactIdsample/artifactId
   version1.0.1/version
   dependencies/
   repositories
 repository
   idcentral/id
   nameMaven Repository Switchboard/name
   layoutdefault/layout
   url file://e:\repository1 /url
 /repository
/repositories
 /project
 
 The localRepository of Maven2 is default to ~/.m2/ which has 
 no artifacts at the beginning. The mvn result is : 
 E:\mvndemo\my-appmvn -o compile [ERROR] BUILD ERROR [INFO] 
 --
 --
 [INFO] The plugin 
 'org.apache.maven.plugins:maven-resources-plugin' does not 
 exist or no valid version could be found [INFO] 
 --
 --
 
 According log, mvn2 try to access 
 http://repo1.maven.org/maven2 ( not file://e:\repository1 ) 
 to download the maven-resources-plugin. 
 How can my own repository completely replace the dafault 
 repository  http://repo1.maven.org/maven2.
 
 Thanks for any suggestion?
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [M2] Repository Problem trying to override central and maintain local corporate repository

2007-03-14 Thread Peter Anning
Thanks Wayne,

When you say 'new' feature does this work with 2.0.4

Cheers

Peter

 -Original Message-
 From: Wayne Fay [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, 15 March 2007 2:02 PM
 To: Maven Users List
 Subject: Re: [M2] Repository Problem trying to override 
 central and maintain local corporate repository
 
 
 Use the new mirrorOf*/mirrorOf feature to declare that 
 all repos are mirror'ed by your local override.
 
 Wayne
 
 On 3/14/07, Peter Anning [EMAIL PROTECTED] wrote:
  Hi,
 
  We need to override the Maven Central Repository and 
 maintain a local 
  network repository. This has worked fine, up until now, with a 
  mirror setting in the maven settings.xml
 
  settings
...
mirrors
  mirror
idmirror-maven-central/id
mirrorOfcentral/mirrorOf
nameLocal Override for The Maven Central Repository/name
urlfile:///\\AUBNVRAT03\repository\/url !-- Yes 
 this works 
  it's how you define a file based repo --
  /mirror
/mirrors
...
  /settings
 
  When building a project I noticed that mysteriously Maven was 
  downloading jibx jars from http://jibx.sf.net/maven Despite 
 the fact 
  that our network does not allow outbound http traffic and the local 
  settings.xml file not defining any proxies!
 
  On further investigation and debugging I found that the 
  xfire-jibx-1.2.4.pom in my corporate repository defines a 
 repository 
  with an id of jibx.sf.net and the rouge url of 
  http://jibx.sf.net/maven as a workaround I have created 
 another mirror 
  definition that overrides this repo id and points at my corporate 
  repository.
 
  mirror
idmirror-jibx.sf.net/id
mirrorOfjibx.sf.net/mirrorOf
nameLocal Override for Jibx/name
urlfile:///\\AUBNVRAT03\repository\/url
  /mirror
 
  This stops it downloading from a remote source in this case.
 
  The questions are: How on earth Maven is picking up proxy settings 
  from the underlying system is still a mystery. I certainly can't 
  browse to this repository when I use a Browser with no proxy 
  configured?!
 
  Surely this is not desired behaviour, how can I be sure that Maven 
  won't go sucking jars off the Internet when I don't want it to?
 
 
 
 
 
  Peter Anning
 
  Sr Software Engineer
 
 
 
  Dialect Payment Technologies Pty Ltd
 
 
 
  [EMAIL PROTECTED]
 
  www.dialectpayments.com
 
 
 
 
 
 
 
 
 
  IMPORTANT NOTICE
 
  ---
 
  Confidentiality Note: The information contained in this 
 email and any 
  attachments is confidential and/or privileged. This email and any 
  attachments are intended to be read only by the person 
 named above. If 
  the reader of this email and any attachments is not the intended 
  recipient, or a representative of the intended recipient, you are 
  hereby notified that any review, dissemination or copying of this 
  email and any attachments is prohibited. If you have received this 
  email and any attachments in error, please notify the 
 sender by email, 
  telephone or fax and return it to the sender at the email address 
  above.
 
 
 
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Maven2 Plugin Ant or Java

2006-10-20 Thread Peter Anning
Hi All,

Ejaz has made available some code that wraps webtest as a Maven 2 Ant
Plugin. Whilst I am very grateful to Ejaz for his code I had expected it
to be a native Maven 2 Java Plugin. All the Maven Plugins that I have
written have been in Java. So my question is does anybody have any
opinions; ant or java?

Java would involve plugging into the webtest api behind the Ant layer.
Is this a good or bad thing to do or is webtest bound tightly to Ant. I
guess if it is bound tightly to Ant Ejaz's Maven Ant plugin may be the
way to go. If it has been designed to be loosely coupled then maybe I
should look at writing Java version.


Best Regards

Peter Anning

Sr. Developer

www.dialectsolutions.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: How to unpack a zip file into a source directory

2006-10-16 Thread Peter Anning
Just to add to this thread check out
http://jira.codehaus.org/browse/MNG-1683 this gave me my solution for
packaging stuff in a zip deploying as an artifact then unpacking in a
war.

Peter

 -Original Message-
 From: Naresh Bhatia [mailto:[EMAIL PROTECTED] 
 Sent: Sunday, 15 October 2006 1:01 PM
 To: Maven Users List
 Subject: RE: How to unpack a zip file into a source directory
 
 
 Perfect! That worked like a charm. Thanks again Wendy.
 
 Naresh
 
 -Original Message-
 From: Wendy Smoak [mailto:[EMAIL PROTECTED] 
 Sent: Saturday, October 14, 2006 10:32 PM
 To: Maven Users List
 Subject: Re: How to unpack a zip file into a source directory
 
 On 10/14/06, Naresh Bhatia [EMAIL PROTECTED] wrote:
  Wendy,
 
  Quick question. It seems that the dependency-maven-plugin does not 
  recognize the .zip extension. I had to change the extension 
 to .jar to 
  make the plugin work. Is my understanding correct?
 
 You can use the type element to tell the dependency plugin 
 what to look for.
 
 Take a look at this old revision of one of my wiki pages, 
 when I was still installing the Selenium distribution .zip 
 file in my local
 repository:
 
 http://wiki.wsmoak.net/cgi-bin/wiki.pl?action=browseid=Maven/
Seleniumr
evision=5

artifactItem
   groupIdorg.openqa/groupId
   artifactIdselenium-core/artifactId
   version0.7.0/version
   typezip/type   ---
/artifactItem

HTH,
-- 
Wendy

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[m2]Properties List

2006-10-11 Thread Peter Anning
Hi,

I know this has been posted to death, but anyway here goes.

I am looking for a list of non obvious properties that maven2 has access
to. For example ${java.home}, ${m2.home}, ${maven.repo.local} etc. 

I know a lot can be derived from the pom structure but this is not what
I am after.

I am sure I saw the beginings of a wiki page somewhere but no amount of
Googling has lead me to re-discover this holly grail of properties.

Anyone know where I can find it.

 
Peter Anning
Sr Software Engineer

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[m2]Is there a dedicated Maven2 Wiki

2006-10-11 Thread Peter Anning
Is there a Wiki decicated to Maven2 where the masses can contribut any
little snippets they may have. I have followed a number of links on
Codehaus and apache.org but they are eith imuttable or unreachable.

Cheers

 
Peter Anning
Sr Software Engineer
 
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [m2]Is there a dedicated Maven2 Wiki

2006-10-11 Thread Peter Anning
Thanks Wendy

You quite right it is not that well advertised, who could make it more
obvious?

Cheers

Peter

 -Original Message-
 From: Wendy Smoak [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, 12 October 2006 12:10 PM
 To: Maven Users List
 Subject: Re: [m2]Is there a dedicated Maven2 Wiki
 
 
 On 10/11/06, Peter Anning [EMAIL PROTECTED] wrote:
 
  Is there a Wiki decicated to Maven2 where the masses can 
 contribut any 
  little snippets they may have.
 
 Yes!  It's not obvious, but the 'User Contributed' link under 
 Documentation (on the Maven home page) takes you to a part of 
 the MAVENUSER space on the Codehaus Confluence instance.
 
 Start here:  http://docs.codehaus.org/display/MAVENUSER/
 
 I usually put things under Examples or Mini Guides, depending 
 on what it is.
 
 HTH,
 Wendy
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [m2]Properties List

2006-10-11 Thread Peter Anning
Wendy Smoak also answereed this one :o)

http://docs.codehaus.org/display/MAVENUSER/MavenPropertiesGuide


 -Original Message-
 From: Peter Anning [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, 12 October 2006 9:56 AM
 To: users@maven.apache.org
 Subject: [m2]Properties List
 
 
 Hi,
 
 I know this has been posted to death, but anyway here goes.
 
 I am looking for a list of non obvious properties that maven2 
 has access to. For example ${java.home}, ${m2.home}, 
 ${maven.repo.local} etc. 
 
 I know a lot can be derived from the pom structure but this 
 is not what I am after.
 
 I am sure I saw the beginings of a wiki page somewhere but no 
 amount of Googling has lead me to re-discover this holly 
 grail of properties.
 
 Anyone know where I can find it.
 
  
 Peter Anning
 Sr Software Engineer
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [M2] Overriding the Central Repository not working

2006-10-08 Thread Peter Anning
No not the Windows Resigstry. The local Maven Repository, by default located at 
~/.m2/repository

 -Original Message-
 From: Marilyn Sander -X (marilysa - Digital-X, Inc. at Cisco) 
 [mailto:[EMAIL PROTECTED] 
 Sent: Saturday, 7 October 2006 8:10 AM
 To: 'Maven Users List'
 Subject: RE: [M2] Overriding the Central Repository not working
 
 
 Peter, what local registry do you speak of?  Do you mean 
 the Windows registry?  The reason I ask is I'm about to try 
 the same thing, but I'm using Linux.
 
 Thanks,
 --Marilyn 
 
 -Original Message-
 From: Peter Anning [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, October 05, 2006 11:34 PM
 To: Maven Users List
 Subject: RE: [M2] Overriding the Central Repository not working
 
 Anyway Arnaud Bailly was right I have solved my problem by 
 creating a Bash script moving all the 
 maven-metadata-central.xml to maven-metdata.xml regenerating 
 the sha1 files and delete al unwanted maven-metadata-*.xml 
 files in the copy of the local registry. Also my plugins that 
 were Snapshots have been released and deployed to the local 
 newtwork repository.
 
 Now running a mirror of Central as the override on the local 
 network and all is happy
 
 Cheers
 
 Peter
 
 Talking to yourself may be the first sign of maddnes, but it 
 is the only way to get sensible answers
  
   -Original Message-
   From: Arnaud Bailly [mailto:[EMAIL PROTECTED]
   Sent: Wednesday, 4 October 2006 5:43 PM
   To: Maven Users List
   Subject: Re: [M2] Overriding the Central Repository not working
   
   
   Peter Anning [EMAIL PROTECTED] writes:
   
Hi,
   
   
   Hello,
   
I do a build with a vanilla settings.xml add any stuff I
  need to my
local repository by hand. Then make a network copy of the local
repository delete my local repository and then my 
 troubles start.
   
   
   This won't work, AFAIK. There is metadata information 
 stored in the
   repository which identifies it (the information) as local 
 or tied to 
   a specific remote repo. This means, I think, that you 
 cannot simply 
   copy
   (local) repositories around and hope it will work. You need to 
   deploy files or use a proxy as Wayne Fay advised you.
   
   I have been bitten in the past by this in relation with custom
   plugins.
   
   HTH
   --
   OQube  software engineering \ génie logiciel  Arnaud 
 Bailly, Dr. 
   \web http://www.oqube.com
   
   
   
  
 -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
   
   
  
  
 -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [M2] Overriding the Central Repository not working

2006-10-06 Thread Peter Anning
Anyway Arnaud Bailly was right I have solved my problem by creating a Bash 
script moving all the maven-metadata-central.xml to maven-metdata.xml 
regenerating the sha1 files and delete al unwanted maven-metadata-*.xml files 
in the copy of the local registry. Also my plugins that were Snapshots have 
been released and deployed to the local newtwork repository.

Now running a mirror of Central as the override on the local network and all is 
happy

Cheers

Peter

Talking to yourself may be the first sign of maddnes, but it is the only way 
to get sensible answers
 
  -Original Message-
  From: Arnaud Bailly [mailto:[EMAIL PROTECTED]
  Sent: Wednesday, 4 October 2006 5:43 PM
  To: Maven Users List
  Subject: Re: [M2] Overriding the Central Repository not working
  
  
  Peter Anning [EMAIL PROTECTED] writes:
  
   Hi,
  
  
  Hello,
  
   I do a build with a vanilla settings.xml add any stuff I 
 need to my
   local repository by hand. Then make a network copy of the local 
   repository delete my local repository and then my troubles start.
  
  
  This won't work, AFAIK. There is metadata information stored
  in the repository which identifies it (the information) as 
  local or tied to a specific remote repo. This means, I think, 
  that you cannot simply copy
  (local) repositories around and hope it will work. You need 
  to deploy files or use a proxy as Wayne Fay advised you.
  
  I have been bitten in the past by this in relation with
  custom plugins. 
  
  HTH
  --
  OQube  software engineering \ génie logiciel 
  Arnaud Bailly, Dr.
  \web http://www.oqube.com
  
  
  
 -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [M2] Overriding the Central Repository not working

2006-10-05 Thread Peter Anning
Thanks for this. Are there any tools to deploy a local repository to a 
Corportate style network based repository?

I have been workig inisolation setting up a build system and it is now time to 
share the artifacts in my local repository.

Thanks
Peter

 -Original Message-
 From: Arnaud Bailly [mailto:[EMAIL PROTECTED] 
 Sent: Wednesday, 4 October 2006 5:43 PM
 To: Maven Users List
 Subject: Re: [M2] Overriding the Central Repository not working
 
 
 Peter Anning [EMAIL PROTECTED] writes:
 
  Hi,
 
 
 Hello,
 
  I do a build with a vanilla settings.xml add any stuff I need to my 
  local repository by hand. Then make a network copy of the local 
  repository delete my local repository and then my troubles start.
 
 
 This won't work, AFAIK. There is metadata information stored 
 in the repository which identifies it (the information) as 
 local or tied to a specific remote repo. This means, I think, 
 that you cannot simply copy
 (local) repositories around and hope it will work. You need 
 to deploy files or use a proxy as Wayne Fay advised you.
 
 I have been bitten in the past by this in relation with 
 custom plugins. 
 
 HTH
 -- 
 OQube  software engineering \ génie logiciel 
 Arnaud Bailly, Dr.
 \web http://www.oqube.com
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[M2] Overriding the Central Repository not working

2006-10-03 Thread Peter Anning
Hi,

 

Maven 2.0.4

 

We are trying to prevent any users from accessing the central repository
by providing a controlled internal corporate repository.

 

I do a build with a vanilla settings.xml add any stuff I need to my
local repository by hand. Then make a network copy of the local
repository delete my local repository and then my troubles start.

 

Reading a number of posts this should be as simple as creating a
definition in the settings.xml (or in the POM) for repositories

 

project

. . .

repositories

repository

releases

enabledtrue/enabled

updatePolicy/

checksumPolicy/

/releases

snapshots

enabledfalse/enabled

 
updatePolicynever/updatePolicy

 
checksumPolicyfail/checksumPolicy

/snapshots

idtest/id

nameDialect Central/name

urlfile:///\\
fileServer01/repository/url

layout/

/repository

/repositories

pluginRepositories

pluginRepository

releases

enabledfalse/enabled

updatePolicy/

checksumPolicy/

/releases

snapshots

enabledfalse/enabled

 
updatePolicynever/updatePolicy

 
checksumPolicyfail/checksumPolicy

/snapshots

idcentral/id

nameDialect Central/name

 
urlfile:///\\fileServer01/repository/url

layout/

/pluginRepository

/pluginRepositories

. . . 

/project

 

However this does not work Maven seems to get quite confused if it does
not find a real central Repository.

 

I have tried to get it working by defining a mirror of central

 

settings

. . . 

  mirrors

mirror

  idmirror-maven-central/id

  mirrorOfcentral/mirrorOf

  nameLocal Override For Maven Central Repository/name

  urlfile:///\\fileServer01\repository\/url

/mirror

 

  /mirrors

. . . 

/settings

 

This seems to have problems not finding maven-resources-plugin but it is
there in the network repository (which is just a copy of local) before I
tear all my hair out has anyone else had any similar problems.

 

 

Peter Anning

Sr Software Engineer



RE: [M2] Overriding the Central Repository not working

2006-10-03 Thread Peter Anning
Afaid not this URL works fine once I have seeded the local repository
with org.apache.maven artifacts. That is to say other non maven plugins
and artifact are successfully downloaded from this respository
configured with this URL.

I have also tried a http: based repository with the exact same effect.

Peter

-Original Message-
From: Wayne Fay [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, 4 October 2006 2:49 PM
To: Maven Users List
Subject: Re: [M2] Overriding the Central Repository not working

At first glance, those urls look completely wrong:
 urlfile:///\\fileServer01/repository/url

Rather than playing with file:// until you make it work, can you
perhaps set up a simple Apache (or IIS) instance on top of the network
repo and use the standard HTTP:// reference to the repo? I'd suspect
this is the source of your problem(s) right now.

Also, I'd recommend you look into a Maven Proxy like Proximity rather
than continuing with your current approach. In the long term I think
you'll be much happier and work less with a solution like Promixity.

Wayne

On 10/3/06, Peter Anning [EMAIL PROTECTED] wrote:
 Hi,



 Maven 2.0.4



 We are trying to prevent any users from accessing the central
repository
 by providing a controlled internal corporate repository.



 I do a build with a vanilla settings.xml add any stuff I need to my
 local repository by hand. Then make a network copy of the local
 repository delete my local repository and then my troubles start.



 Reading a number of posts this should be as simple as creating a
 definition in the settings.xml (or in the POM) for repositories



 project

 . . .

repositories

repository

releases

enabledtrue/enabled

updatePolicy/

checksumPolicy/

/releases

snapshots


enabledfalse/enabled


 updatePolicynever/updatePolicy


 checksumPolicyfail/checksumPolicy

/snapshots

idtest/id

nameDialect Central/name

urlfile:///\\
 fileServer01/repository/url

layout/

/repository

/repositories

pluginRepositories

pluginRepository

releases


enabledfalse/enabled

updatePolicy/

checksumPolicy/

/releases

snapshots


enabledfalse/enabled


 updatePolicynever/updatePolicy


 checksumPolicyfail/checksumPolicy

/snapshots

idcentral/id

nameDialect Central/name


 urlfile:///\\fileServer01/repository/url

layout/

/pluginRepository

/pluginRepositories

 . . .

 /project



 However this does not work Maven seems to get quite confused if it
does
 not find a real central Repository.



 I have tried to get it working by defining a mirror of central



 settings

 . . .

  mirrors

mirror

  idmirror-maven-central/id

  mirrorOfcentral/mirrorOf

  nameLocal Override For Maven Central Repository/name

  urlfile:///\\fileServer01\repository\/url

/mirror



  /mirrors

 . . .

 /settings



 This seems to have problems not finding maven-resources-plugin but it
is
 there in the network repository (which is just a copy of local) before
I
 tear all my hair out has anyone else had any similar problems.





 Peter Anning

 Sr Software Engineer




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[M2] Anyone know of a Canoo Webtest Plugin

2006-10-03 Thread Peter Anning
Hi,

 

Does anyone know of any work being done to develop a Canoo Webtest
plugin for Maven 2

 

Cheers

 

Peter Anning

Sr Software Engineer

 



RE: antrun plugin, junit classpath

2006-09-18 Thread Peter Anning
Yes the secret is in using the task definition and seeting the dependency on 
ant-junit _at the pom level_ if you do it at the plugin level then it can't be 
seen:


project
  ...
  dependencies
!-- callout to ant for integration tests --   
dependency
groupIdant/groupId
artifactIdant-junit/artifactId
version1.6.5/version
scopetest/scope
/dependency   
  /dependencies   
  build
plugins   
  plugin
groupIdorg.apache.maven.plugins/groupId
artifactIdmaven-antrun-plugin/artifactId
executions
  execution
idrun-itests/id
phaseintegration-test/phase
configuration
  tasks
taskdef name=junit 
  
classname=org.apache.tools.ant.taskdefs.optional.junit.JUnitTask
  classpath
  path refid=maven.test.classpath/
  /classpath
/taskdef  
mkdir dir=${project.build.directory}/test-classes/
junit
  ...
/junit
  /tasks
/configuration
goals
  goalrun/goal
/goals
  /execution  
/executions
dependencies
  dependency
groupIdcom.sun/groupId
artifactIdtools/artifactId
scopesystem/scope
version1.5/version
systemPath${java.home}/../lib/tools.jar/systemPath
  /dependency 

/dependencies 
  /plugin
/plugins
  /build
/project



-Original Message-
From: news on behalf of Paul Galbraith
Sent: Mon 9/18/2006 4:51 PM
To: users@maven.apache.org
Subject:  antrun plugin, junit classpath
 
I want to use M2's antrun plugin to execute a junit task, but I keep 
getting errors indicating that ant can't find junit in the classpath.

My POM has:

plugin
   groupIdorg.apache.maven.plugins/groupId
   artifactIdmaven-antrun-plugin/artifactId
   executions
 execution
   idjunit/id
   phasetest/phase
   goals
 goalrun/goal
   /goals
   configuration
 tasks
   junit
 ...
   /junit
 /tasks
   /configuration
 /execution
   /executions
   dependencies
 dependency
   groupIdjunit/groupId
   artifactIdjunit/artifactId
   version3.8.1/version
   scopetest/scope
 /dependency
   /dependencies
/plugin

I get the following output:



[DEBUG] Configuring mojo 
'org.apache.maven.plugins:maven-antrun-plugin:1.1:run'
--
[DEBUG]   (f) artifacts = [junit:junit:jar:3.8.1:test, 
ant:ant:jar:1.6.5:runtime
, ant:ant-launcher:jar:1.6.5:runtime, 
org.apache.maven:maven-project:jar:2.0.1:r
untime, org.apache.maven:maven-plugin-api:jar:2.0.1:runtime]
[DEBUG]   (f) project = [EMAIL PROTECTED]
[DEBUG]   (f) tasks =
[DEBUG] -- end configuration --
[INFO] [antrun:run {execution: junit}]
[INFO] Executing tasks
[DEBUG] getProperty(ns=null, name=ant.reuse.loader, user=false)
[INFO] 

[ERROR] BUILD ERROR
[INFO] 

[INFO] Error executing ant tasks

Embedded error: Could not create task or type of type: junit.

Ant could not find the task or a class this task relies upon.



If I remember correctly, this is typical when running ant standalone, if 
junit is not on ant's classpath.

Is there any way to get this to work in M2?

Paul


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

RE: inplace

2006-08-29 Thread Peter Anning
Have you tried using war:exploded to refresh the target/YourWebApp Then
using the Context.xml in tomcat to point to the
AbosolutePath/target/YourWebApp and get tomcat to hot reload

Context path=/ YourWebApp docBase= AbosolutePath/target/YourWebApp
reloadable=true
  WatchedResourceWEB-INF/web.xml/WatchedResource
  WatchedResourceMETA-INF/context.xml/WatchedResource
/Context

This works fine for me.

Peter

-Original Message-
From: Douglas Ferguson [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, 29 August 2006 11:27 PM
To: users
Subject: war:inplace

I found this task when looking into ways to just deploy static file
changes to tomcat rather than building a war and having tomcat rebuild
the context, etc. 

 

The only problem I have is that it generates files (WEB-INF  META-INF)
in my src directory. Is there a way to avoid this? 

Anybody using this feature or doing something different?

 

D-



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



maven-script-ant path id problem in the ant build file

2006-08-28 Thread Peter Anning
Hi,

I am trying to build an Ant plugin for Maven 2. Having followed the Hello World 
example on the maven site and got everything working I now have the following 
problem in the real world. A path defined in the build.xml is not being created 
properly when calling from maven but works from Ant.

Maven 2.0.4
maven-script-ant 2.0.1

in my projectName.build.xml I define a path
project

path id=dbmstools-jython-classpath
pathelement location=${library.jython-task.jar} /
pathelement location=${library.jython.jar} /
/path
 ...

target name=print-build-properties
echo message=Jython Task Jar: ${library.jython-task.jar}/
echo message=Main Jython Lib Jar: ${library.jython.jar}/
property name=my-dbmstools-jython-classpath 
refid=dbmstools-jython-classpath/
echo message=Jython Classpath: ${my-dbmstools-jython-classpath}/
/target
/project

In my projectName.mojos.xml I define the parameters
pluginMetadata
  mojos
mojo

...
parameter
  namelibrary.jython.jar/name 
  propertylibrary.jython.jar/property 
  requiredtrue/required 
  expression${library.jython.jar}/expression
  typejava.lang.String/type
  descriptionThe Jython Jar/description
/parameter
parameter
  namelibrary.jython-task.jar/name 
  propertylibrary.jython-task.jar/property 
  requiredtrue/required 
  expression${library.jython-task.jar}/expression
  typejava.lang.String/type
  descriptionThe Jython Task Jar/description
/parameter

The output from running the plugin is:

[echo] Jython Task Jar: E:\path\to\jython-task-0.3.8.jar
[echo] Main Jython Lib Jar: E:\path\to\jython-2.1.jar
[echo] Jython Classpath: 
E:\path\to\project\${library.jython-task.jar};E:\path\to\project\{library.jython.jar}

So its not picking up the correct path as input via the properties.

Running it from from ant works fine:

[echo] Jython Task Jar: E:\path\to\jython-task-0.3.8.jar
[echo] Main Jython Lib Jar: E:\path\to\jython-2.1.jar
[echo] Jython Classpath: 
E:\path\to\jython-task-0.3.8.jar;E:\path\to\jython-2.1.jar

I have searched and searched for help with this plugin but have found next to 
nothing. Anybody know what I can try or the best source of info.

Thanks and Regards
Peter Anning
Sr. Software Engineer


Re: file:// protocol not working for remote repsoitory in 1.0

2004-07-29 Thread Peter Anning
Fixed now. Bizarrely I completely re-installed Java and upgraded from 1.4.1 
to 1.4.2 and it now works.

Have re-upgraded to 1.0 and all seems cool.

Thanks for the posts
Peter

On Thu, 29 Jul 2004 01:30:03 +1000, Dion Gillard wrote
 It's because it's a malformed URL and the 'host' is assumed to be C:
 
 On Wed, 28 Jul 2004 16:18:16 +0200, Maczka Michal 
 [EMAIL PROTECTED] wrote:
  
  
   -Original Message-
   From: Peter Anning [mailto:[EMAIL PROTECTED]
   Sent: Wednesday, July 28, 2004 8:32 AM
   To: [EMAIL PROTECTED]
   Subject: file:// protocol not working for remote repsoitory in 1.0
  
  
   Hi all,
  
   We have a remote repository located on a Windows file server.
  
   The repository could be accessed using the file: protocol in
   maven rc2
   upgrading to 1.0 seems to have broken this. I have tested it
   by putting the
   jar in question behind a local http server and it works.
  
   build.properties are set as:
   maven.repo.remote=file:lonfs02/EBJAVA/repository,http://ww
   w.ibiblio.org/ma
   ven,http://dist.codehaus.org,http://www.codeczar.com/maven
   maven.repo.remote.enabled=true
  
   Has anyone else seen this?
  
   Below is the stack trace.
  
  I have seen anything like that but what's strange is the fact that maven 
is
  trying to use ftp protocol
  for downloading your artifacts from that location.
  
  In addition JDK URL handler for FTP is used... and this is highly bizzare!
  
  
  Michal
  
  
  
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
  
 
 
 -- 
 http://www.multitask.com.au/people/dion/
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



file:// protocol not working for remote repsoitory in 1.0

2004-07-28 Thread Peter Anning
Hi all,

We have a remote repository located on a Windows file server.

The repository could be accessed using the file: protocol in maven rc2 
upgrading to 1.0 seems to have broken this. I have tested it by putting the 
jar in question behind a local http server and it works.

build.properties are set as:
maven.repo.remote=file:lonfs02/EBJAVA/repository,http://www.ibiblio.org/ma
ven,http://dist.codehaus.org,http://www.codeczar.com/maven
maven.repo.remote.enabled=true

Has anyone else seen this?

Below is the stack trace.

cheers
Peter 

Attempting to download commons-discovery.jar.
Getting URL: file://lonfs02/EBJAVA/repository/commons-discovery/jars/commons-
dis
covery.jar
Error retrieving artifact from [file://lonfs02/EBJAVA/repository/commons-
discove
ry/jars/commons-discovery.jar]: java.net.ConnectException: Connection 
refused: c
onnect
Error details
java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:305)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:171)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:158)
at java.net.Socket.connect(Socket.java:434)
at java.net.Socket.connect(Socket.java:384)
at sun.net.NetworkClient.doConnect(NetworkClient.java:139)
at sun.net.NetworkClient.openServer(NetworkClient.java:118)
at sun.net.ftp.FtpClient.openServer(FtpClient.java:423)
at sun.net.ftp.FtpClient.init(FtpClient.java:687)
at sun.net.www.protocol.ftp.FtpURLConnection.connect
(FtpURLConnection.ja
va:175)
at org.apache.maven.util.HttpUtils.getFile(HttpUtils.java:421)
at org.apache.maven.util.HttpUtils.getFile(HttpUtils.java:287)
at org.apache.maven.util.HttpUtils.getFile(HttpUtils.java:181)
at org.apache.maven.verifier.DependencyVerifier.getRemoteArtifact
(Depend
encyVerifier.java:326)
at org.apache.maven.verifier.DependencyVerifier.getDependencies
(Dependen
cyVerifier.java:255)
at org.apache.maven.verifier.DependencyVerifier.satisfyDependencies
(Depe
ndencyVerifier.java:171)
at org.apache.maven.verifier.DependencyVerifier.verify
(DependencyVerifie
r.java:97)
at org.apache.maven.project.Project.verifyDependencies
(Project.java:1365
)
at org.apache.maven.plugin.PluginManager.attainGoals
(PluginManager.java:
510)
at org.apache.maven.MavenSession.attainGoals(MavenSession.java:266)
at org.apache.maven.cli.App.doMain(App.java:486)
at org.apache.maven.cli.App.main(App.java:1215)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke
(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke
(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at com.werken.forehead.Forehead.run(Forehead.java:551)
at com.werken.forehead.Forehead.main(Forehead.java:581)

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: file:// protocol not working for remote repsoitory in 1.0

2004-07-28 Thread Peter Anning
On Wed, 28 Jul 2004 13:16:03 +0300, Arto Pastinen wrote
 Hi!
 
 Have you tried to put url something like this: file:lonfs02...
 
 Artsi
 
 On Wed, 2004-07-28 at 09:31, Peter Anning wrote:
  Hi all,
  
  We have a remote repository located on a Windows file server.
  
  The repository could be accessed using the file: protocol in maven rc2 
  upgrading to 1.0 seems to have broken this. I have tested it by putting 
the 
  jar in question behind a local http server and it works.
  
  build.properties are set as:
  
maven.repo.remote=file:lonfs02/EBJAVA/repository,http://www.ibiblio.org/ma
  ven,http://dist.codehaus.org,http://www.codeczar.com/maven
  maven.repo.remote.enabled=true
  
  Has anyone else seen this?
  
  Below is the stack trace.
  
  cheers
  Peter 
  
  Attempting to download commons-discovery.jar.
  Getting URL: file://lonfs02/EBJAVA/repository/commons-
discovery/jars/commons-
  dis
  covery.jar
  Error retrieving artifact from [file://lonfs02/EBJAVA/repository/commons-
  discove
  ry/jars/commons-discovery.jar]: java.net.ConnectException: Connection 
  refused: c
  onnect
  Error details
  java.net.ConnectException: Connection refused: connect
  at java.net.PlainSocketImpl.socketConnect(Native Method)
  at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:305)
  at java.net.PlainSocketImpl.connectToAddress
(PlainSocketImpl.java:171)
  at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:158)
  at java.net.Socket.connect(Socket.java:434)
  at java.net.Socket.connect(Socket.java:384)
  at sun.net.NetworkClient.doConnect(NetworkClient.java:139)
  at sun.net.NetworkClient.openServer(NetworkClient.java:118)
  at sun.net.ftp.FtpClient.openServer(FtpClient.java:423)
  at sun.net.ftp.FtpClient.init(FtpClient.java:687)
  at sun.net.www.protocol.ftp.FtpURLConnection.connect
  (FtpURLConnection.ja
  va:175)
  at org.apache.maven.util.HttpUtils.getFile(HttpUtils.java:421)
  at org.apache.maven.util.HttpUtils.getFile(HttpUtils.java:287)
  at org.apache.maven.util.HttpUtils.getFile(HttpUtils.java:181)
  at org.apache.maven.verifier.DependencyVerifier.getRemoteArtifact
  (Depend
  encyVerifier.java:326)
  at org.apache.maven.verifier.DependencyVerifier.getDependencies
  (Dependen
  cyVerifier.java:255)
  at 
org.apache.maven.verifier.DependencyVerifier.satisfyDependencies
  (Depe
  ndencyVerifier.java:171)
  at org.apache.maven.verifier.DependencyVerifier.verify
  (DependencyVerifie
  r.java:97)
  at org.apache.maven.project.Project.verifyDependencies
  (Project.java:1365
  )
  at org.apache.maven.plugin.PluginManager.attainGoals
  (PluginManager.java:
  510)
  at org.apache.maven.MavenSession.attainGoals
(MavenSession.java:266)
  at org.apache.maven.cli.App.doMain(App.java:486)
  at org.apache.maven.cli.App.main(App.java:1215)
  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  at sun.reflect.NativeMethodAccessorImpl.invoke
  (NativeMethodAccessorImpl.
  java:39)
  at sun.reflect.DelegatingMethodAccessorImpl.invoke
  (DelegatingMethodAcces
  sorImpl.java:25)
  at java.lang.reflect.Method.invoke(Method.java:324)
  at com.werken.forehead.Forehead.run(Forehead.java:551)
  at com.werken.forehead.Forehead.main(Forehead.java:581)
  
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: file:// protocol not working for remote repsoitory in 1.0

2004-07-28 Thread Peter Anning

Yes.

Going back to rc2 fixes this.


On Wed, 28 Jul 2004 13:16:03 +0300, Arto Pastinen wrote
 Hi!
 
 Have you tried to put url something like this: file:lonfs02...
 
 Artsi
 
 On Wed, 2004-07-28 at 09:31, Peter Anning wrote:
  Hi all,
  
  We have a remote repository located on a Windows file server.
  
  The repository could be accessed using the file: protocol in maven rc2 
  upgrading to 1.0 seems to have broken this. I have tested it by putting 
the 
  jar in question behind a local http server and it works.
  
  build.properties are set as:
  
maven.repo.remote=file:lonfs02/EBJAVA/repository,http://www.ibiblio.org/ma
  ven,http://dist.codehaus.org,http://www.codeczar.com/maven
  maven.repo.remote.enabled=true
  
  Has anyone else seen this?
  
  Below is the stack trace.
  
  cheers
  Peter 
  
  Attempting to download commons-discovery.jar.
  Getting URL: file://lonfs02/EBJAVA/repository/commons-
discovery/jars/commons-
  dis
  covery.jar
  Error retrieving artifact from [file://lonfs02/EBJAVA/repository/commons-
  discove
  ry/jars/commons-discovery.jar]: java.net.ConnectException: Connection 
  refused: c
  onnect
  Error details
  java.net.ConnectException: Connection refused: connect
  at java.net.PlainSocketImpl.socketConnect(Native Method)
  at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:305)
  at java.net.PlainSocketImpl.connectToAddress
(PlainSocketImpl.java:171)
  at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:158)
  at java.net.Socket.connect(Socket.java:434)
  at java.net.Socket.connect(Socket.java:384)
  at sun.net.NetworkClient.doConnect(NetworkClient.java:139)
  at sun.net.NetworkClient.openServer(NetworkClient.java:118)
  at sun.net.ftp.FtpClient.openServer(FtpClient.java:423)
  at sun.net.ftp.FtpClient.init(FtpClient.java:687)
  at sun.net.www.protocol.ftp.FtpURLConnection.connect
  (FtpURLConnection.ja
  va:175)
  at org.apache.maven.util.HttpUtils.getFile(HttpUtils.java:421)
  at org.apache.maven.util.HttpUtils.getFile(HttpUtils.java:287)
  at org.apache.maven.util.HttpUtils.getFile(HttpUtils.java:181)
  at org.apache.maven.verifier.DependencyVerifier.getRemoteArtifact
  (Depend
  encyVerifier.java:326)
  at org.apache.maven.verifier.DependencyVerifier.getDependencies
  (Dependen
  cyVerifier.java:255)
  at 
org.apache.maven.verifier.DependencyVerifier.satisfyDependencies
  (Depe
  ndencyVerifier.java:171)
  at org.apache.maven.verifier.DependencyVerifier.verify
  (DependencyVerifie
  r.java:97)
  at org.apache.maven.project.Project.verifyDependencies
  (Project.java:1365
  )
  at org.apache.maven.plugin.PluginManager.attainGoals
  (PluginManager.java:
  510)
  at org.apache.maven.MavenSession.attainGoals
(MavenSession.java:266)
  at org.apache.maven.cli.App.doMain(App.java:486)
  at org.apache.maven.cli.App.main(App.java:1215)
  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  at sun.reflect.NativeMethodAccessorImpl.invoke
  (NativeMethodAccessorImpl.
  java:39)
  at sun.reflect.DelegatingMethodAccessorImpl.invoke
  (DelegatingMethodAcces
  sorImpl.java:25)
  at java.lang.reflect.Method.invoke(Method.java:324)
  at com.werken.forehead.Forehead.run(Forehead.java:551)
  at com.werken.forehead.Forehead.main(Forehead.java:581)
  
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]