repositories ids

2012-11-15 Thread Davis, Chad
I'm wondering what the scope of the id's are in the various elements where you 
can reference a repository.  To be specific, if I have definitions of my repos 
in , ,  are the id's 
supposed to be unique?

What happens if they aren't?  In some cases, it seems that they are the same 
repos.  For instance, my repository and pluginRepository both point to the same 
repo, so it seems to make sense to have the same id.






RE: Maven site can not find parent

2012-11-13 Thread Davis, Chad

> > Concerning the empty "relativePath" element, this will typically be
> > empty when you can't guarantee that the parent is in the parent
> > directory.  it's a common practice to separate the responsibilities of
> > the aggregator pom from the parent pom.  When that is the case, if you
> > don't have the empty "relativePath" element, it will fail.
> >
> 
> To make this a bit clearer: if you use a *released* parent pom, it won't have 
> a
> relative path. If this is true in a module, you need an empty element. And the
> site plugin may become disoriented.
> 

It seems that lots of things in the maven world make the assumption that the 
aggregator pom and the parent pom are one and the same.  I've been having 
trouble with this parent pom resolution issue in the Hudson/Jenkins environment 
for some time.  In these cases, it's the build server's own pom processing that 
can't seem to be able to resolve where the parent pom is.  I think this has 
improved on newer versions of the build servers though.  


RE: how to proxy a one nexus instance via another local one

2012-11-12 Thread Davis, Chad

> > 1)  set up local nexus to have a proxy repo that proxies the release
> > nexus's "public" group, if this even works technically
> >
> 
> I've been told on this list this is a no-no, because you have to pick an 
> artifact
> type when you proxy (release or snapshot; what if the proxied group
> contains both?).  Others on this list have said pshaw, just proxy it twice.  I
> chose to heed the first camp and I always proxy repositories, never groups.
> 

I can see their point.  In my case, however, I don't want the snapshots to come 
from the proxied repo, so this should be a bonus feature for me.

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


RE: deploying WAR from maven with different configurations

2012-10-29 Thread Davis, Chad

> > Do I need to restructure the way I do my whole build, externalizing
> > the config to another artifact?
> 
> This is one (good) way to do it.
> 

What then are the options for handling this externalized configuration at build 
time?  At first glance, I'm thinking it requires a whole extra build project 
for doing the testing deployment, complete with src that includes a copy of the 
test configuration.

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


deploying WAR from maven with different configurations

2012-10-29 Thread Davis, Chad
I'm using Cargo to deploy my WAR to a testing server.  The idea is that the CI 
build will push the app over to a testing server.  When deployed to this 
testing environment, my Spring configuration wires mock business objects into 
the app.  The spring config resides inside my WAR.  It's unclear to me how I 
should handle the creation of this testing version of the spring config . . . 

I think I understand that it's very bad have my build produce an alternative 
version of the WAR artifact for testing.  I know that I could use a maven 
profile, triggered in the build job I use to deploy the war to the testing 
server, to filter the spring config for the testing settings.  The obvious 
drawback here seems to be the fact that the same maven artifact, my war, would 
sometimes have testing config  inside it and sometimes the real config.  How do 
I get around this?  Do I need to restructure the way I do my whole build, 
externalizing the config to another artifact?  Is there someway to just 
safeguard against the testing artifact escaping into the real world ( i.e. a 
maven repo ) where it could be confused with the real one?  Should I make two 
versions of the WAR from my build?  

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



Re: maven-compiler-plugin woes

2012-10-04 Thread Davis Ford
Appending this as well:

$ mvn -version
Apache Maven 3.0.4 (r1232337; 2012-01-17 08:44:56+)
Maven home: /home/ubuntu/apache-maven-3.0.4
Java version: 1.7.0_07, vendor: Oracle Corporation
Java home: /usr/lib/jvm/jdk1.7.0/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "3.0.0-23-virtual", arch: "i386", family: "unix"

On Thu, Oct 4, 2012 at 2:22 PM, Davis Ford  wrote:

> This doesn't make a whole lot of sense to me.  Any idea what the problem
> is here?
>
> [INFO] BUILD FAILURE
> [INFO]
> 
> [INFO] Total time: 2.944s
> [INFO] Finished at: Thu Oct 04 17:54:16 UTC 2012
> [INFO] Final Memory: 9M/23M
> [INFO]
> 
> [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-compiler-plugin:2.5.1:compile
> (default-compile) on project example-server: Compilation failure:
> Compilation failure:
> [ERROR]
> /home/ubuntu/git/example-server/src/main/java/com/example/m2m/service/DeviceService.java:[17,25]
> error: package com.sun.jersey.api does not exist
> [ERROR]
> /home/ubuntu/git/my-server/src/main/java/com/example/m2m/service/DeviceService.java:[33,11]
> error: cannot find symbol
> [ERROR] symbol:   class JResponse
> [ERROR] location: class DeviceService
>
> The class I wrote DeviceService.java has this import:
>
> import com.sun.jersey.api.JResponse;
>
> pom.xml snipped:
>
> 
>
> com.sun.jersey
> jersey-server
> ${jersey.version}
> runtime
>   
>etc...
> 
>
> Ok, the compiler can't find it -- works fine in Eclipse - I built the
> eclipse project with mvn eclipse:eclipse, it resolves to the
> jersey-server-1.14.jar - in Eclipse, I expand the jar, and see the class
> is indeed in there.  dependency:tree shows it is in the classpath, and
> scope is runtime =>
>
> ubuntu@$ mvn dependency:tree
> [INFO] Scanning for projects...
> [INFO]
>
> [INFO]
> 
> [INFO] Building Example Webapp 1.0-SNAPSHOT
> [INFO]
> 
> [INFO]
> [INFO] --- maven-dependency-plugin:2.1:tree (default-cli) @ example-server
> ---
> [INFO] com.example:example-server:war:1.0-SNAPSHOT
> [INFO] +- org.zeromq:jzmq:jar:1.0:compile
>  [INFO] +- com.google.protobuf:protobuf-java:jar:LATEST:compile
> [INFO] +- javax.ws.rs:jsr311-api:jar:1.1.1:compile
> [INFO] +- com.sun.jersey:jersey-server:jar:1.14:runtime
> [INFO] |  +- asm:asm:jar:3.1:runtime
> [INFO] |  \- com.sun.jersey:jersey-core:jar:1.14:runtime
> [INFO] +- com.sun.jersey:jersey-json:jar:1.14:runtime
> [INFO] |  +- org.codehaus.jettison:jettison:jar:1.1:runtime
> [INFO] |  |  \- stax:stax-api:jar:1.0.1:runtime
> [INFO] |  +- com.sun.xml.bind:jaxb-impl:jar:2.2.3-1:runtime
> [INFO] |  |  \- javax.xml.bind:jaxb-api:jar:2.2.2:runtime
> [INFO] |  | +- javax.xml.stream:stax-api:jar:1.0-2:runtime
> [INFO] |  | \- javax.activation:activation:jar:1.1:runtime
> [INFO] |  +- org.codehaus.jackson:jackson-core-asl:jar:1.9.2:runtime
> [INFO] |  +- org.codehaus.jackson:jackson-mapper-asl:jar:1.9.2:runtime
> [INFO] |  +- org.codehaus.jackson:jackson-jaxrs:jar:1.9.2:runtime
> [INFO] |  \- org.codehaus.jackson:jackson-xc:jar:1.9.2:runtime
> [INFO] +- com.sun.jersey.contribs:jersey-spring:jar:1.14:runtime
> [INFO] |  +- com.sun.jersey:jersey-servlet:jar:1.14:runtime
> [INFO] |  +- org.springframework:spring-core:jar:3.0.0.RC3:runtime
> [INFO] |  |  \- org.springframework:spring-asm:jar:3.0.0.RC3:runtime
> [INFO] |  +- org.springframework:spring-beans:jar:3.0.0.RC3:runtime
> [INFO] |  +- org.springframework:spring-context:jar:3.0.0.RC3:runtime
> [INFO] |  |  +- aopalliance:aopalliance:jar:1.0:runtime
> [INFO] |  |  \- org.springframework:spring-expression:jar:3.0.0.RC3:runtime
> [INFO] |  +- org.springframework:spring-web:jar:3.0.0.RC3:runtime
> [INFO] |  \- org.springframework:spring-aop:jar:3.0.0.RC3:runtime
> [INFO] +- org.slf4j:jcl-over-slf4j:jar:1.5.8:compile
> [INFO] +- org.slf4j:slf4j-api:jar:1.5.8:compile
> [INFO] +- org.slf4j:slf4j-log4j12:jar:1.5.8:compile
> [INFO] +- log4j:log4j:jar:1.2.14:compile
> [INFO] \- junit:junit:jar:4.8.2:test
>
> Let's validate that the class does indeed exist in that jarfile...and it
> does =>
>
> ubuntu@$ jar tf
> ~/.m2/repository/com/sun/jersey/jersey-server/1.14/jersey-server-1.14.jar
> META-INF/MANIFEST.MF
> META-INF/
> META-INF/jersey-module-version
> META-INF/maven/
> META-INF/maven/com.sun.jersey/
> META-INF/maven/com.sun.jersey/j

RE: deploying ad hoc jars from build

2012-09-24 Thread Davis, Chad


> 
> In your repo, can you not upload the jars as maven-like artifacts?
> 

I can, or at least I can have someone, who is authorized, do that for me.  I 
was hoping to automate the process of converting the distribution zip into 
useable maven pieces . . . perhaps that's just not  very normal thing to do.

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



deploying ad hoc jars from build

2012-09-24 Thread Davis, Chad
We have a 3rd party dependency whose distribution consists of a zip file with a 
set of jars and native libraries.  Our repository person has deployed this zip 
for us.  We are trying to process the zip into more consumable pieces.  We'd 
like to create another zip, containing only the native libraries,  and deploy 
that as a artifact.  Then we'd like to deploy each of the jars as artifacts.  
Can this second part, deploying the jars, be done from within a build? 

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



RE: adding timestamp to locally built snapshots

2012-09-18 Thread Davis, Chad


> If you want to basically override the deployed x.y-SNAPSHOT version with the
> last deployed one, then you might want to have a look at buildnumber-
> maven-plugin. This is going to create a variable (say
> buildnumber) in your context. Then you can use that variable in a generated
> manifest.
> 

The buildnumber-maven-plugin sounds good.  One thing is that I'm not building a 
jar file; it's a binary executable installer.  But I can use the 
buildnumber-maven-plugin to pump a value in for my names.  Thanks!

> But in the end, I feel you're doing something wrong. Instead of (or
> complementary to) doing what u describe. I would advice you set up
> continuous integration that will deploy continuously (!) artifacts to a
> repository manager. Then you're just left with either manually deploying the
> last or the version you want (standardly timestamped) to your appserver, or
> even setting up a dedicating job to deploy the last version continuously :).

This is for an individual developer prior to checking in their code . . . we 
have a CI server but that's after you've already checked in your code.



adding timestamp to locally built snapshots

2012-09-18 Thread Davis, Chad
I frequently deploy artifacts that I build locally to some of my dev 
environment servers.  Later I have trouble figuring out which one of my local 
dev builds I'm looking at in a given dev environment; this is because they are 
all named "blahblah-SNAPSHOT.run"  

So, I'd like to add a timestamp to that, just like what occurs when during the 
deploy of that same artifact to nexus, but:

1) I don't know how

2) I don't know if it would cause other troubles



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



Re: resources-plugin, testResources, relative path, eclipse plugin

2010-06-03 Thread Davis Ford
I don't have the luxury -- product is preparing to ship, build
refactorings won't be allowed.  Not under my control right now.
Believe me there are a lot of things I'd like to fix the right way.

Any other options?

On Thu, Jun 3, 2010 at 12:39 PM, Wayne Fay  wrote:
>> I have a multi-module project.  I have some test resources that a
>> project needs at runtime that are defined in another project.  I know
>> the correct would be to move shared resources into their own project,
>> but I don't have that luxury right now.  So, I do this:
>
> You know what you should do -- just spend the time and fix it right.
> Surely that will take less time than constantly fighting with Eclipse,
> sending emails to this list, etc right??
>
> Wayne
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



resources-plugin, testResources, relative path, eclipse plugin

2010-06-03 Thread Davis Ford
Hi,

I have a multi-module project.  I have some test resources that a
project needs at runtime that are defined in another project.  I know
the correct would be to move shared resources into their own project,
but I don't have that luxury right now.  So, I do this:



${basedir}/../other-project/src/test/resources/

some-file.xml




Then run:

mvn process-test-resources

This puts some-file.xml under target/test-classes/some-file.xml, which
is great b/c I need it there on the test classpath.  So far so
good...until I create the eclipse project and the eclipse plugin adds
this line to the .classpath file:



The problem is the windows path-name
[C:/path/other-project/src/test/resources]...apparently, eclipse can't
deal with it.  Under the problems tab in eclipse, it notes that the
resource can't be found, and the project can't be built.  I have to
manually go into Eclipse and delete the link, and link it back in
manually.

I've tried a number of different ways to get around this looking at
the various options for maven-eclipse-plugin and
maven-resources-plugin, but I'm coming up short.  Any ideas??

Thanks in advance,
Davis

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



Re: A maven/nexus repos manager/missing dependency question

2009-10-19 Thread Sean Davis
On Mon, Oct 19, 2009 at 6:46 AM, Quintin Beukes wrote:

> You should add it to the plugin's dependencies.
>
> Here is an example extract from one of my POMs (the irrelevant bits
> removed):
>
>  
>.
>
>  
>org.apache.maven.surefire
>surefire-api
>2.4.3
>  
>
>  
>
>
Thanks, Quentin.  Here is the extract from my pom.




org.apache.maven.plugins
maven-javadoc-plugin





That is the only plugin specified in my pom.  The plugin that looks to be
causing the problem is a maven plugin (the maven-project-info-reports-plugin)
that is being used by the site build phase, but I could be wrong in my
interpretation of the error trace in my original message.  Is there a place
(or even a reason) that I should be placing a dependency for such a plugin
for the site build phase?

Sean



> On Mon, Oct 19, 2009 at 12:43 PM, Sean Davis  wrote:
> > On Mon, Oct 19, 2009 at 5:15 AM, Quintin Beukes  >wrote:
> >
> >> Try adding the commons-lang dependency.
> >>
> >>
> > Thanks, Quintin.  However, it appears that this dependency is arising in
> a
> > maven plugin, if I understand things correctly?  So, adding the
> dependency
> > to my own pom won't have an effect on the build process, will it?
> >
> > Sean
> >
> >
> >
> >> On Sun, Oct 18, 2009 at 10:34 PM, Sean Davis 
> wrote:
> >> > I have been using maven pretty successfully for low-end java
> >> > programming--I'm not much of a developer.  I have finally convinced a
> few
> >> > folks to potentially work with me on some projects at work and thought
> >> > setting up a repository manager would be a good idea.  The nexus setup
> >> > pretty simple and I changed my settings.xml to include a mirror to the
> >> local
> >> > nexus installation (version 1.3.6, open source).  I can see artifacts
> >> moving
> >> > into the cache just fine as they are used in builds.
> >> >
> >> > I have a project that I have been building fine until the above
> process
> >> was
> >> > completed.  Now, during site building under m2eclipse, I get the error
> >> > below.  Any suggestions on what needs to change?  It appears that
> >> > commons-lang is not being picked up as a dependency?
> >> >
> >> > Thanks,
> >> > Sean
> >> >
> >> >
> >> >
> >> > [ERROR]
> >> >
> org.apache.maven.report.projectinfo.DependencyConvergenceReport#execute()
> >> > caused a linkage error (java.lang.NoClassDefFoundError). Check the
> >> realms:
> >> >
> >> > NOTE:
> >> > Plugin realm is:
> >> >
> >>
> /plugins/org.apache.maven.plugins:maven-project-info-reports-plugin:2@48
> >> > /thread:main
> >> > Container realm is: plexus.core
> >> >
> >> > Realm ID:
> >> >
> >>
> /plugins/org.apache.maven.plugins:maven-project-info-reports-plugin:2@48
> >> > /thread:main
> >> >  CUT 
> >> > java.lang.NoClassDefFoundError: org/apache/commons/lang/StringUtils
> >> >at
> >> >
> >>
> org.apache.velocity.runtime.resource.ResourceManagerImpl.initialize(ResourceManagerImpl.java:165)
> >> >at
> >> >
> >>
> org.apache.velocity.runtime.RuntimeInstance.initializeResourceManager(RuntimeInstance.java:594)
> >> >at
> >> >
> >>
> org.apache.velocity.runtime.RuntimeInstance.init(RuntimeInstance.java:241)
> >> >at
> >> org.apache.velocity.app.VelocityEngine.init(VelocityEngine.java:116)
> >> >at
> >> >
> >>
> org.codehaus.plexus.velocity.DefaultVelocityComponent.initialize(DefaultVelocityComponent.java:95)
> >> >at
> >> >
> >>
> org.codehaus.plexus.personality.plexus.lifecycle.phase.InitializePhase.execute(InitializePhase.java:33)
> >> >at
> >> >
> >>
> org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:97)
> >> >at
> >> >
> >>
> org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:139)
> >> >at
> >> >
> >>
> org.code

Re: A maven/nexus repos manager/missing dependency question

2009-10-19 Thread Sean Davis
On Mon, Oct 19, 2009 at 5:15 AM, Quintin Beukes wrote:

> Try adding the commons-lang dependency.
>
>
Thanks, Quintin.  However, it appears that this dependency is arising in a
maven plugin, if I understand things correctly?  So, adding the dependency
to my own pom won't have an effect on the build process, will it?

Sean



> On Sun, Oct 18, 2009 at 10:34 PM, Sean Davis  wrote:
> > I have been using maven pretty successfully for low-end java
> > programming--I'm not much of a developer.  I have finally convinced a few
> > folks to potentially work with me on some projects at work and thought
> > setting up a repository manager would be a good idea.  The nexus setup
> > pretty simple and I changed my settings.xml to include a mirror to the
> local
> > nexus installation (version 1.3.6, open source).  I can see artifacts
> moving
> > into the cache just fine as they are used in builds.
> >
> > I have a project that I have been building fine until the above process
> was
> > completed.  Now, during site building under m2eclipse, I get the error
> > below.  Any suggestions on what needs to change?  It appears that
> > commons-lang is not being picked up as a dependency?
> >
> > Thanks,
> > Sean
> >
> >
> >
> > [ERROR]
> > org.apache.maven.report.projectinfo.DependencyConvergenceReport#execute()
> > caused a linkage error (java.lang.NoClassDefFoundError). Check the
> realms:
> >
> > NOTE:
> > Plugin realm is:
> >
> /plugins/org.apache.maven.plugins:maven-project-info-reports-plugin:2@48
> > /thread:main
> > Container realm is: plexus.core
> >
> > Realm ID:
> >
> /plugins/org.apache.maven.plugins:maven-project-info-reports-plugin:2@48
> > /thread:main
> >  CUT 
> > java.lang.NoClassDefFoundError: org/apache/commons/lang/StringUtils
> >at
> >
> org.apache.velocity.runtime.resource.ResourceManagerImpl.initialize(ResourceManagerImpl.java:165)
> >at
> >
> org.apache.velocity.runtime.RuntimeInstance.initializeResourceManager(RuntimeInstance.java:594)
> >at
> >
> org.apache.velocity.runtime.RuntimeInstance.init(RuntimeInstance.java:241)
> >at
> org.apache.velocity.app.VelocityEngine.init(VelocityEngine.java:116)
> >at
> >
> org.codehaus.plexus.velocity.DefaultVelocityComponent.initialize(DefaultVelocityComponent.java:95)
> >at
> >
> org.codehaus.plexus.personality.plexus.lifecycle.phase.InitializePhase.execute(InitializePhase.java:33)
> >at
> >
> org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:97)
> >at
> >
> org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:139)
> >at
> >
> org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:129)
> >at
> >
> org.codehaus.plexus.component.manager.ClassicSingletonComponentManager.getComponent(ClassicSingletonComponentManager.java:96)
> >at
> >
> org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:147)
> >at
> >
> org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:491)
> >at
> >
> org.codehaus.plexus.component.composition.AbstractComponentComposer.findRequirement(AbstractComponentComposer.java:214)
> >at
> >
> org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirementToField(FieldComponentComposer.java:72)
> >at
> >
> org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirement(FieldComponentComposer.java:62)
> >at
> >
> org.codehaus.plexus.component.composition.AbstractComponentComposer.assembleComponent(AbstractComponentComposer.java:99)
> >at
> >
> org.codehaus.plexus.component.composition.DefaultComponentComposerManager.assembleComponent(DefaultComponentComposerManager.java:76)
> >at
> >
> org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:46)
> >at
> >
> org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:97)
> >at
> >
> org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:139)
> >at
> >
> org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:129)
> >at
> >
> org.codehaus.plexus.component.manager.ClassicSingletonCompo

A maven/nexus repos manager/missing dependency question

2009-10-18 Thread Sean Davis
I have been using maven pretty successfully for low-end java
programming--I'm not much of a developer.  I have finally convinced a few
folks to potentially work with me on some projects at work and thought
setting up a repository manager would be a good idea.  The nexus setup
pretty simple and I changed my settings.xml to include a mirror to the local
nexus installation (version 1.3.6, open source).  I can see artifacts moving
into the cache just fine as they are used in builds.

I have a project that I have been building fine until the above process was
completed.  Now, during site building under m2eclipse, I get the error
below.  Any suggestions on what needs to change?  It appears that
commons-lang is not being picked up as a dependency?

Thanks,
Sean



[ERROR]
org.apache.maven.report.projectinfo.DependencyConvergenceReport#execute()
caused a linkage error (java.lang.NoClassDefFoundError). Check the realms:

NOTE:
Plugin realm is:
/plugins/org.apache.maven.plugins:maven-project-info-reports-plugin:2@48
/thread:main
Container realm is: plexus.core

Realm ID:
/plugins/org.apache.maven.plugins:maven-project-info-reports-plugin:2@48
/thread:main
 CUT 
java.lang.NoClassDefFoundError: org/apache/commons/lang/StringUtils
at
org.apache.velocity.runtime.resource.ResourceManagerImpl.initialize(ResourceManagerImpl.java:165)
at
org.apache.velocity.runtime.RuntimeInstance.initializeResourceManager(RuntimeInstance.java:594)
at
org.apache.velocity.runtime.RuntimeInstance.init(RuntimeInstance.java:241)
at org.apache.velocity.app.VelocityEngine.init(VelocityEngine.java:116)
at
org.codehaus.plexus.velocity.DefaultVelocityComponent.initialize(DefaultVelocityComponent.java:95)
at
org.codehaus.plexus.personality.plexus.lifecycle.phase.InitializePhase.execute(InitializePhase.java:33)
at
org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:97)
at
org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:139)
at
org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:129)
at
org.codehaus.plexus.component.manager.ClassicSingletonComponentManager.getComponent(ClassicSingletonComponentManager.java:96)
at
org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:147)
at
org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:491)
at
org.codehaus.plexus.component.composition.AbstractComponentComposer.findRequirement(AbstractComponentComposer.java:214)
at
org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirementToField(FieldComponentComposer.java:72)
at
org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirement(FieldComponentComposer.java:62)
at
org.codehaus.plexus.component.composition.AbstractComponentComposer.assembleComponent(AbstractComponentComposer.java:99)
at
org.codehaus.plexus.component.composition.DefaultComponentComposerManager.assembleComponent(DefaultComponentComposerManager.java:76)
at
org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:46)
at
org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:97)
at
org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:139)
at
org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:129)
at
org.codehaus.plexus.component.manager.ClassicSingletonComponentManager.getComponent(ClassicSingletonComponentManager.java:96)
at
org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:147)
at
org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:491)
at
org.codehaus.plexus.component.composition.AbstractComponentComposer.findRequirement(AbstractComponentComposer.java:214)
at
org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirementToField(FieldComponentComposer.java:72)
at
org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirement(FieldComponentComposer.java:62)
at
org.codehaus.plexus.component.composition.AbstractComponentComposer.assembleComponent(AbstractComponentComposer.java:99)
at
org.codehaus.plexus.component.composition.DefaultComponentComposerManager.assembleComponent(DefaultComponentComposerManager.java:76)
at
org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:46)
at
org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:97)
at
org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:139)
at
org.codehaus.plexus.component.ma

Building a project that includes scripts

2009-10-15 Thread Sean Davis
Sorry for the naive question.  I'm using maven2 in eclipse and now have a
project that includes a script folder that has shell scripts for common java
-cp . command-line interactions.  I would like to build a project that
has a lib folder, a scripts folder (with scripts that refer to the lib
folder), and potentially other top-level directories or documents in it.
One way to do this would be to use an ant build script for everything, but I
wanted to see if that was the "maven" way of doing things.

Thanks,
Sean


Re: installing src or javadoc into local repository

2009-10-03 Thread Sean Davis
On Fri, Oct 2, 2009 at 8:35 PM, Roland Asmann  wrote:
> Check the install-mojo for this:
> http://maven.apache.org/plugins/maven-install-plugin/install-file-mojo.html
>
> Reinstall the jar into your repository and add the 'javadoc' and 'sources'
> switches or install them separately with the 'classifier' switch.

Thanks, Roland.  That is exactly what I needed.

>> I apologize for the naive question in advance.  I have installed an
>> external jar file into my local repository--very easy.  The jar file
>> was built using ant as part of a third-party project.  I would now
>> like to add the source and/or the javadocs to my local repository,
>> also.  I have the source (in src/java/) and can generate the
>> javadoc.  How can I install these files into my local repository (so
>> that I have the equivalent of the "download sources and javadocs")?
>>
>> Thanks,
>> Sean
>>
>> -
>> 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
>
>

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



installing src or javadoc into local repository

2009-10-02 Thread Sean Davis
I apologize for the naive question in advance.  I have installed an
external jar file into my local repository--very easy.  The jar file
was built using ant as part of a third-party project.  I would now
like to add the source and/or the javadocs to my local repository,
also.  I have the source (in src/java/) and can generate the
javadoc.  How can I install these files into my local repository (so
that I have the equivalent of the "download sources and javadocs")?

Thanks,
Sean

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



mvn classpath weirdness with eclipse plugin

2009-05-05 Thread Davis Ford
Hi, I've been using mvn for a lot of years now, but I've just
encountered a bizarre issue that I have no explanation for.

I am having trouble with the following dependencies


aspectj
aspectjrt
1.5.3


aspectj
aspectjweaver
1.5.3


We are using Archiva -- and these are cached.  If I run:

$ mvn -X eclipse:eclipse

I can see the following in the output:
[DEBUG] Adding managed dependencies for com.example:drm
[DEBUG]   aspectj:aspectjrt:jar:1.5.3
[DEBUG]   aspectj:aspectjweaver:jar:1.5.3

The jars are in my local repo.  However, these jars are not added to
the .classpath file, nor do they show up in Reference Libraries under
eclipse.

I have verified that this happens on multiple developer machines, so
it isn't localized to a single environment.

What is even stranger is that if you run the same project with mvn
idea:idea, the aspectj jars show up in the classpath for Intellij.

I am at a loss.  We have no  in the pom.  Where should I look next?

Thanks in advance,
Davis

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



Re: How to share resources across projects in Maven

2009-04-23 Thread Davis Ford
I think it had something to do with my recent plugin snapshot issues.
I wiped out my local repo.  Turned off plugin snapshots on my
settings.xml, and rebuilt -- and now it is working.  Very nice tip,
btw!

On Thu, Apr 23, 2009 at 11:08 PM, Brian Fox  wrote:
> I don't see anything obvious. Can you attach some build logs? The dep plugin
> is pretty verbose about what it's doing so it should hopefully be obvious.
>
> On 4/23/2009 10:54 PM, Davis Ford wrote:
>>
>> Hi Brian -- I'm trying to emulate your blog:
>>
>> http://www.sonatype.com/people/2008/04/how-to-share-resources-across-projects-in-maven/
>>
>> for sharing resources across a multi-module project.  It is a grand
>> trick, but one that doesn't seem to be working for me.
>>
>> I have the config project setup just fine.  It generates a .zip
>> archive.  I have done mvn install on it.
>>
>> So, another project depends on it:
>>
>> 
>>                
>>                        ${project.groupId}
>>                        elibrary-config
>>                        ${project.version}
>>                        resources
>>                        zip
>>                        provided
>>                
>>
>> And I have set this up:
>>
>> 
>>                
>>                        
>>
>>  ${basedir}/src/main/resources
>>                        
>>                        
>>
>>  ${project.build.directory}/generated-resources
>>                                true
>>                        
>>                
>>                
>>                        
>>
>>  maven-dependency-plugin
>>                                
>>                                        
>>                                                unpack-config
>>                                                
>>
>>  unpack-dependencies
>>                                                
>>
>>  generate-resources
>>                                                
>>
>>  ${project.build.directory}/generated-resources
>>
>>  ${project.groupId}
>>
>>  elibrary-config
>>
>>  zip
>>                                                
>>                                        
>>                                
>>                        
>>
>> If I run mvn package or mvn process-resources or mvn
>> process-test-resources, it never creates the  and
>> copies the files inside that zip there.  What am I missing?
>>
>> Regards,
>> Davis
>>
>>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



Re: org.apache.maven.plugins:maven-eclipse-plugin:2.7-SNAPSHOT ignores maven-compiler-plugin

2009-04-23 Thread Davis Ford
My apologies Barrie...this is the con entry:



User error.  Somehow my eclipse default JDK/JRE setting got switched
back to JDK 5.  When I refreshed using mvn eclipse:eclipse it resets
the JDK back to default JRE_CONTAINER -- whereas only the project was
set previously on 6.  Its the IDE setting that changed for me, and
this was the root of my problem.  I reset this globally in Eclipse and
all is well.

--davis

On Thu, Apr 23, 2009 at 10:56 PM, Barrie Treloar  wrote:
> On Fri, Apr 24, 2009 at 11:41 AM, Davis Ford
>  wrote:
>> Hi, I just enabled all snapshots for plugins, and a side effect of
>> this was to pull down
>> org.apache.maven.plugins:maven-eclipse-plugin:2.7-SNAPSHOT version of
>> eclipse plugin.
>>
>> Now, my project breaks in eclipse b/c it sets the JDK to be (I think)
>> the system default (which is JDK 1.5), but my maven-compiler-plugin
>> settings in the pom specify 1.6.  So maven compiles the sources, and
>> when I launch the project in eclipse, it throws an error saying the
>> class version is wrong.
>>
>> Nothing very interesting in the config below.  This problem did not
>> exist for me until I just opened up plugin snapshots -- which I think
>> I'll turn off.  This is on:
>> $ mvn -version
>> Maven version: 2.0.9
>> Java version: 1.6.0_07
>
> It should be setting it to 1.6.
>
> Can you check the .classpath file that gets created and look at what
> kind="con" is defined? (It should be the last entry)
>
> It should either be
>  
> which takes the default JRE defined in eclipse.
> Check what version that is in the eclipse preferences Java > Installed JREs.
>
> or
>  path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
>
> Which will use the Execution Environment bound to JavaSE-1.6 in your
> eclipse preferences Java > Installed JREs > Execution Environment.
>
> I can't find any integration tests for 1.6 specifically but we have
> ones for J2SE-1.4.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



How to share resources across projects in Maven

2009-04-23 Thread Davis Ford
Hi Brian -- I'm trying to emulate your blog:
http://www.sonatype.com/people/2008/04/how-to-share-resources-across-projects-in-maven/

for sharing resources across a multi-module project.  It is a grand
trick, but one that doesn't seem to be working for me.

I have the config project setup just fine.  It generates a .zip
archive.  I have done mvn install on it.

So, another project depends on it:



${project.groupId}
elibrary-config
${project.version}
resources
zip
provided


And I have set this up:





${basedir}/src/main/resources



${project.build.directory}/generated-resources
true




maven-dependency-plugin


unpack-config


unpack-dependencies


generate-resources


${project.build.directory}/generated-resources

${project.groupId}

elibrary-config

zip





If I run mvn package or mvn process-resources or mvn
process-test-resources, it never creates the  and
copies the files inside that zip there.  What am I missing?

Regards,
Davis

-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



org.apache.maven.plugins:maven-eclipse-plugin:2.7-SNAPSHOT ignores maven-compiler-plugin

2009-04-23 Thread Davis Ford
Hi, I just enabled all snapshots for plugins, and a side effect of
this was to pull down
org.apache.maven.plugins:maven-eclipse-plugin:2.7-SNAPSHOT version of
eclipse plugin.

Now, my project breaks in eclipse b/c it sets the JDK to be (I think)
the system default (which is JDK 1.5), but my maven-compiler-plugin
settings in the pom specify 1.6.  So maven compiles the sources, and
when I launch the project in eclipse, it throws an error saying the
class version is wrong.

Nothing very interesting in the config below.  This problem did not
exist for me until I just opened up plugin snapshots -- which I think
I'll turn off.  This is on:
$ mvn -version
Maven version: 2.0.9
Java version: 1.6.0_07
OS name: "mac os x" version: "10.5.6" arch: "x86_64" Family: "mac"




org.apache.maven.plugins
maven-eclipse-plugin

true

true




maven-compiler-plugin

1.6
1.6



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



Re: scm:add question

2009-04-22 Thread Sean Davis
On Wed, Apr 22, 2009 at 8:40 AM, Ryan Connolly  wrote:

> It looks as though you are trying to add everything in the src dir but
> the plugin is complaining that it does not know what it is you want to
> add... I would try passing the optional includes property to the
> plugin configuration to see if that changes things.


Thanks, Ryan, for the suggestion.

 mvn scm:add -Dmaven.scm.basedir=./src -Dmaven.scm.src.includes=*

produces the same result.

Sean


>
> On Wed, Apr 22, 2009 at 8:27 AM, Sean Davis  wrote:
> > I am pretty new to maven and I am trying to use the maven scm plugin to
> add
> > files and then commit to a bare git repository (located on the file
> system).
> >
> > In my pom, I have:
> >
> >
> >scm:git:file://localhost/tmp/stuff.git
> >
> >
> scm:git:file://localhost/tmp/stuff.git
> >
> >
> > Then, I am executing from the command line and in the base directory of
> the
> > project (directory contains pom.xml):
> >
> > sdavis$ mvn scm:add -Dmaven.scm.basedir=./src
> > [INFO] Scanning for projects...
> > [INFO] Searching repository for plugin with prefix: 'scm'.
> > [INFO]
> > 
> > [INFO] Building SeqWrench
> > [INFO]task-segment: [scm:add] (aggregator-style)
> > [INFO]
> > 
> > [INFO] [scm:add]
> > [INFO]
> > 
> > [ERROR] BUILD ERROR
> > [INFO]
> > 
> > [INFO] Cannot run add command :
> >
> > Embedded error: Exception while executing SCM command.
> > You must provide at least one file/directory to add
> >
> > Any suggestions on what I am missing?
> >
> > Thanks,
> > Sean
> >
>
>
>
> --
> �...@n
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>


scm:add question

2009-04-22 Thread Sean Davis
I am pretty new to maven and I am trying to use the maven scm plugin to add
files and then commit to a bare git repository (located on the file system).

In my pom, I have:


scm:git:file://localhost/tmp/stuff.git

scm:git:file://localhost/tmp/stuff.git


Then, I am executing from the command line and in the base directory of the
project (directory contains pom.xml):

sdavis$ mvn scm:add -Dmaven.scm.basedir=./src
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'scm'.
[INFO]

[INFO] Building SeqWrench
[INFO]task-segment: [scm:add] (aggregator-style)
[INFO]

[INFO] [scm:add]
[INFO]

[ERROR] BUILD ERROR
[INFO]

[INFO] Cannot run add command :

Embedded error: Exception while executing SCM command.
You must provide at least one file/directory to add

Any suggestions on what I am missing?

Thanks,
Sean


Re: m2eclipse and crashing on any access to pom.xml

2009-04-09 Thread Sean Davis
On Wed, Apr 8, 2009 at 4:06 PM, Brian E. Fox wrote:

> The m2eclipse user list is more appropriate for this, but Igor found these
> links:
> http://www.mail-archive.com/ubuntu-b...@lists.ubuntu.com/msg728168.html
> http://dev.eclipse.org/newslists/news.eclipse.newcomer/msg21845.html
> so it doesn't seem specific to M2e.
>

Updating to a more recent jre did the trick.  Thanks for the pointers.

Sean


>
>
> -Original Message-
> From: seand...@gmail.com [mailto:seand...@gmail.com] On Behalf Of Sean
> Davis
> Sent: Wednesday, April 08, 2009 3:09 PM
> To: users@maven.apache.org
> Subject: m2eclipse and crashing on any access to pom.xml
>
> I am running eclipse under:
>
> > java -version
> java version "1.6.0_04"
> Java(TM) SE Runtime Environment (build 1.6.0_04-b12)
> Java HotSpot(TM) 64-Bit Server VM (build 10.0-b19, mixed mode)
>
> When I do anything to add a dependency, I get a crash of the VM:
>
> #
> # An unexpected error has been detected by Java Runtime Environment:
> #
> #  SIGSEGV (0xb) at pc=0x2adcdb63522a, pid=18211, tid=1085491536
> #
> # Java VM: Java HotSpot(TM) 64-Bit Server VM (10.0-b19 mixed mode
> linux-amd64)
> # Problematic frame:
> # V  [libjvm.so+0x1f122a]
> #
> # An error report file with more information is saved as:
> # /home/sdavis/eclipse/hs_err_pid18211.log
> #
> # If you would like to submit a bug report, please visit:
> #   http://java.sun.com/webapps/bugreport/crash.jsp
> # The crash happened outside the Java Virtual Machine in native code.
> # See problematic frame for where to report the bug.
> #
>
> Any suggestions as to how to alleviate the problem?  Do I really need to
> back up to java 1.5 to use m2eclipse as some sites suggest?
>
> Thanks,
> Sean
>


m2eclipse and crashing on any access to pom.xml

2009-04-08 Thread Sean Davis
I am running eclipse under:

> java -version
java version "1.6.0_04"
Java(TM) SE Runtime Environment (build 1.6.0_04-b12)
Java HotSpot(TM) 64-Bit Server VM (build 10.0-b19, mixed mode)

When I do anything to add a dependency, I get a crash of the VM:

#
# An unexpected error has been detected by Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x2adcdb63522a, pid=18211, tid=1085491536
#
# Java VM: Java HotSpot(TM) 64-Bit Server VM (10.0-b19 mixed mode
linux-amd64)
# Problematic frame:
# V  [libjvm.so+0x1f122a]
#
# An error report file with more information is saved as:
# /home/sdavis/eclipse/hs_err_pid18211.log
#
# If you would like to submit a bug report, please visit:
#   http://java.sun.com/webapps/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#

Any suggestions as to how to alleviate the problem?  Do I really need to
back up to java 1.5 to use m2eclipse as some sites suggest?

Thanks,
Sean


maven-war-plugin: War Manifest Customization

2009-03-11 Thread Davis Ford
Hi, the war plugin explains how to customize the manifest here:

http://maven.apache.org/plugins/maven-war-plugin/examples/war-manifest-guide.html

I can't seem to repeat this.  I'm wondering what I'm doing wrong.
Here's a quick example with two projects: one jar project (foo-bar),
and one webapp project.  The foo-bar project depends on commons-cli,
and the webapp project depends on foo-bar.  If I configure the pom.xml
as follows, and run 'mvn package' on the webapp project, it includes
commons-cli in the WEB-INF/lib folder.  I don't want this. I want it
to include it in the META-INF/Manifest classpath, but not in
WEB-INF/lib -- any ideas?

Thanks in advance!

$ mvn archetype:create -DgroupId=com.example -DartifactId=foo-bar

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/maven-v4_0_0.xsd";>
 4.0.0
 com.example
 foo-bar
 jar
 1.0-SNAPSHOT
 foo-bar
 http://maven.apache.org
 
   
 commons-cli
 commons-cli
 1.0
   
 


$ mvn archetype:create -DgroupId=com.example -DartifactId=webapp
-DarchetypeArtifactId=maven-archetype-webapp

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/maven-v4_0_0.xsd";>
 4.0.0
 com.example
 webapp
 war
 1.0-SNAPSHOT
 webapp Maven Webapp
 http://maven.apache.org
 
   
 com.example
 foo-bar
 1.0-SNAPSHOT
 true
   
 
 
   webapp
   
 
  org.apache.maven.plugins
  maven-war-plugin
  2.0
  

  
true
  

  

   
 


-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



Re: mvn package exclude transitive deps from war archive

2009-03-05 Thread Davis Ford
Hi Wayne, here's a more concrete example.  I'm sure I'm just doing
something stupid, but I hope this makes it easier to see the
stupid-ness.

Create a new jar project:

mvn archetype:create -DgroupId=com.example -DartifactId=foo-bar

Make the pom.xml look like this:

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/maven-v4_0_0.xsd";>
  4.0.0
  com.example
  foo-bar
  jar
  1.0-SNAPSHOT
  foo-bar
  http://maven.apache.org
  

  commons-cli
  commons-cli
  1.0

  


Create a new war project:

mvn archetype:create -DgroupId=com.example -DartifactId=webapp
-DarchetypeArtifactId=maven-archetype-webapp

Make the pom.xml look like this:

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/maven-v4_0_0.xsd";>
  4.0.0
  com.example
  webapp
  war
  1.0-SNAPSHOT
  webapp Maven Webapp
  http://maven.apache.org
  

  com.example
  foo-bar
  1.0-SNAPSHOT
  true

  
  
webapp

  
   org.apache.maven.plugins
   maven-war-plugin
   2.0
   
 
   
 true
   
 
   
 

  


Do mvn install on the foo-bar project.
Do mvn package on the webapp project.  See that all the commons-cli
dependencies are included inside the war WEB-INF/lib directory?  How
to only add this to the manifest classpath and not include in
WEB-INF/lib ?

Regards,
Davis

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



Re: mvn package exclude transitive deps from war archive

2009-03-05 Thread Davis Ford
Hi Wayne, thanks for the reply -- no luck on the clean.  I still get
all the jars.  See my reply to my post.  I configured the war plugin
as per the webpage, but still no luck.

On Thu, Mar 5, 2009 at 8:58 PM, Wayne Fay  wrote:
>> $ mvn package
>>
>> It still creates a war file with all the deps and transitive deps
>> under WEB-INF/lib/ - what am I doing wrong?  Do I need to use the
>> maven war plugin?
>
> Try "mvn clean package". The jars are still sitting in /target, and
> therefore landing in your war.
>
> Wayne
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



Re: mvn package exclude transitive deps from war archive

2009-03-05 Thread Davis Ford
I managed to exclude direct dependencies and add them to the manifest
classpath as per
http://maven.apache.org/plugins/maven-war-plugin/examples/war-manifest-guide.html

--but it still puts all transitive dependencies in WEB-INF/lib.

For example. Project A is jar

Project A artifact is jar, and it has a bunch of dependencies.

Project B is war and depends on project A like this:


   blah
   A
   blah
   true


Then I configure maven war plugin like this:


org.apache.maven.plugins
maven-war-plugin
2.0

  

  true

  

  

What I want is that project A and all its transitive dependencies end
up in the Manifest classpath, but are not included in WEB-INF/lib.
What ends up happening with this configuration is that project-A.jar
is excluded from WEB-INF/lib, but it is in the Manifest classpath.
However, all project A's transitive dependencies are included in
WEB-INF/lib and they are in the Manifest classpath.  I want the latter
but not the former.  What am I missing?

Thanks in advance,
Davis

On Thu, Mar 5, 2009 at 7:27 PM, Davis Ford  wrote:
> Hi, so I have a war project, with some
> dependencies, and I made all the deps be provided, but
> when I run:
>
> $ mvn package
>
> It still creates a war file with all the deps and transitive deps
> under WEB-INF/lib/ - what am I doing wrong?  Do I need to use the
> maven war plugin?
>
> Thanks in advance,
> Davis
>
> --
> Zeno Consulting, Inc.
> home: http://www.zenoconsulting.biz
> blog: http://zenoconsulting.wikidot.com
> p: 248.894.4922
> f: 313.884.2977
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



mvn package exclude transitive deps from war archive

2009-03-05 Thread Davis Ford
Hi, so I have a war project, with some
dependencies, and I made all the deps be provided, but
when I run:

$ mvn package

It still creates a war file with all the deps and transitive deps
under WEB-INF/lib/ - what am I doing wrong?  Do I need to use the
maven war plugin?

Thanks in advance,
Davis

-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



Re: how to stop pom downloads

2009-03-04 Thread Davis Ford
Bruce -- thanks a lot for this.  I am just trying to use the plugin
with 9.2, but I am hitting this issue:

http://www.mail-archive.com/u...@mojo.codehaus.org/msg00503.html

Is this issue one that you encountered also when trying the plugin
with 10.x?  I wouldn't mind having 10.x working, also.

On Wed, Mar 4, 2009 at 8:58 PM, Barrie Treloar  wrote:
> On Thu, Mar 5, 2009 at 12:09 PM, Davis Ford
>  wrote:
>> True - although that would take me a long time.  In any event, I ended
>> up getting the 53MB weblogic.jar deployed to archiva - yay!
>
> BEWARE
>
> If you are using Weblogic 10 then you need to "chase the dragons tail".
> As the jar defines a Class-Path in its Manifest using relative file 
> definitions.
>
> You need to add EACH one of these files into your maven repository AND
> then define each artifact as a dependency in your pom.
>
> We ended up creating an internal dependency project just for weblogic
> so you can depend upon that instead of having to cut-and-paste for
> every project.  However all the scopes are compile when some should be
> runtime)
>
> On my todo list is to extend the deploy plugin to also deploy
> artifacts defined in the Manfiest Class-Path...
>
> Here is the dependency pom (it may be useful to others)
>
> 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/maven-v4_0_0.xsd";>
>  4.0.0
>  weblogic
>  weblogic-dependencies
>  pom
>  10.0.0
>  
>    
>      weblogic
>      weblogic
>      10.0.0
>    
>    
>      weblogic
>      javax.jms_1.1
>      10.0.0
>      false
>    
>    
>      weblogic
>      javax.servlet_2.5
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.repackaged.asm_1.5.2
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.diagnostics.instrumentor_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      xbean
>      9.2.1
>      false
>    
>    
>      weblogic
>      wljmsclient
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.descriptor_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.utils_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.utils.classloaders_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.weblogic.workmanager_1.0.0.0
>      10.0.0
>      true
>    
>    
>      weblogic
>      com.bea.core.weblogic.rmi.client_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.transaction_2.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.weblogic.security.wls_2.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.weblogic.security_2.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.logging_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.management.core_1.0.0.0
>      10.0.0
>      true
>    
>    
>      weblogic
>      com.bea.core.utils.full_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      javax.transaction_1.1
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.store_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.workarea_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.utils.wrapper_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.datasource_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.diagnostics.core_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      com.bea.core.resourcepool_1.0.0.0
>      10.0.0
>      false
>    
>    
>      weblogic
>      javax.annotation_1.0
>      10.0.0
>    
>  
> 
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



Re: how to stop pom downloads

2009-03-04 Thread Davis Ford
True - although that would take me a long time.  In any event, I ended
up getting the 53MB weblogic.jar deployed to archiva - yay!

On Wed, Mar 4, 2009 at 7:50 PM, Wayne Fay  wrote:
>> The only annoying thing is that weblogic.jar is 53MB.  I tried
>> deploying that to archiva and it just times out.
>
> There's no rule that says you can't break up a massive jar file like
> this into a series of jar files, and use  to pull them
> all down and use them as needed...
>
> Wayne
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



Re: how to stop pom downloads

2009-03-04 Thread Davis Ford
Yes, archiva has a way to deploy through the web interface with
generate pom option.

I'm trying to use the weblogic-maven-plugin which requires all these
silly jars from the weblogic install.  I just did a manual
install:install-file to my local repo to try to get it working.
However, whenever I run a command like:

mvn weblogic:deploy

I have to wait a couple minutes while it hits the server to check for
pom files.  I know how to fix it now.  I will deploy the jars to
archiva, or else use the generatePom option for installing locally.

The only annoying thing is that weblogic.jar is 53MB.  I tried
deploying that to archiva and it just times out.

I did not pick weblogic

On Wed, Mar 4, 2009 at 6:02 PM, David C. Hicks  wrote:
>
>
> Wendy Smoak wrote:
>>
>> On Wed, Mar 4, 2009 at 3:56 PM, Davis Ford 
>> wrote:
>>
>>>
>>>   -- I did mvn install:install-file -- can you make
>>> the install command generate a pom.xml?
>>>
>>
>> Install is for your _local_ repo.  You need deploy:deploy-file, and
>> yes, there's a parameter -DgeneratePom=true (if that's not the default
>> already...)
>>
>
> Does Archiva not have some kind of web interface from which you can do an
> install?  I know Nexus does.  It handles building the POM for you.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



Re: how to stop pom downloads

2009-03-04 Thread Davis Ford
  -- I did mvn install:install-file -- can you make
the install command generate a pom.xml?

On Wed, Mar 4, 2009 at 5:51 PM, Wendy Smoak  wrote:
> On Wed, Mar 4, 2009 at 3:48 PM, Davis Ford  
> wrote:
>> Hi, we have an internal repo here (using Archiva), and I manually
>> deployed some jars to it.  However, whenever I run a maven command it
>> is constantly trying to check the pom against the server version.
>> Example:
>>
>> Downloading: 
>> http://internal-maven-repo:8080/archiva/repository/internal//weblogic/webservices/9.2/webservices-9.2.pom
>
> Does that file exist?
>
>> This keeps repeating and it is really slow.  I noticed that jars that
>> I pulled from the Internet and cached in Archiva it does not do this
>> for.  Is there some way to stop it from doing this?  Why does it
>> appear to do it only for the jars I manually deployed?
>
>  My guess is that when you deployed the artifacts, you did not deploy
> a pom or have one generated.  Exactly how did you deploy the jars?
>
> --
> Wendy
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



how to stop pom downloads

2009-03-04 Thread Davis Ford
Hi, we have an internal repo here (using Archiva), and I manually
deployed some jars to it.  However, whenever I run a maven command it
is constantly trying to check the pom against the server version.
Example:


Downloading: 
http://internal-maven-repo:8080/archiva/repository/internal//weblogic/webservices/9.2/webservices-9.2.pom

This keeps repeating and it is really slow.  I noticed that jars that
I pulled from the Internet and cached in Archiva it does not do this
for.  Is there some way to stop it from doing this?  Why does it
appear to do it only for the jars I manually deployed?

Thanks in advance,
Davis

-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



Re: resource filtering in pom.xml

2009-03-04 Thread Davis Ford
Awesome -- exactly what I was looking for Thomas.  Thank you.

On Wed, Mar 4, 2009 at 11:53 AM, Thomas Marti  wrote:
> Hello Davis
>
> You can use the Maven Properties Plugin
> => http://haroon.sis.utoronto.ca/zarar/properties-maven-plugin/
>
>
> Greetings, Thomas
>
> Davis Ford wrote:
>>
>> Is it possible to have maven do resource filtering on the fly inside
>> the pom.xml -- albeit without writing to the file (i.e. in-memory
>> only)
>>
>> For example, I might be using maven-sql-plugin:
>>
>> 
>>          ${db.driver}
>>          ${db.url}
>>          ${db.username}
>>          ${db.password}
>> 
>>
>> I don't want to hard-code these values in the pom.xml.  I want them to
>> be read from an external properties file.  Is this possible?
>>
>> Thanks in advance,
>> Davis
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



resource filtering in pom.xml

2009-03-04 Thread Davis Ford
Is it possible to have maven do resource filtering on the fly inside
the pom.xml -- albeit without writing to the file (i.e. in-memory
only)

For example, I might be using maven-sql-plugin:


  ${db.driver}
  ${db.url}
  ${db.username}
  ${db.password}


I don't want to hard-code these values in the pom.xml.  I want them to
be read from an external properties file.  Is this possible?

Thanks in advance,
Davis
-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



Re: how to get eclipse plugin to process-test-resources?

2009-03-02 Thread Davis Ford
Yea, I know I can do that.  It would just be nice to not force
developers to have to remember both commands -- which is why I wanted
to configure the plugin to also run process-test-resources.  I looked
at the solution at the very bottom of the comments on this blog:
http://cmaki.blogspot.com/2007/10/getting-maven-and-eclipse-to-work.html
but that doesn't work for me.

We don't use the m2eclipse plugin for eclipse -- just the maven
command line eclipse plugin.

On Mon, Mar 2, 2009 at 2:56 PM, Carlos Sanchez  wrote:
> mvn process-test-resources eclipse:eclipse
>
> or in your first example just do
> mvn process-test-resources
>
>
> On Mon, Mar 2, 2009 at 11:48 AM, Davis Ford
>  wrote:
>> Hi, when I run the eclipse goal like this: mvn eclipse:eclipse I also
>> want it to execute resources:testResources.
>>
>> I tried something like this:
>>
>> 
>>                
>>                        
>>                                org.apache.maven.plugins
>>                                maven-eclipse-plugin
>>                                
>>                                        
>>                                                eclipse
>>                                                
>> process-test-resources
>>                                                
>>                                                        eclipse
>>                                                
>>                                        
>>                                
>>                        
>>
>> But it doesn't work.  If I put it in a profile like this, it does
>> work, but I don't want to have to have a profile for it.  Is there a
>> way to accomplish this?
>>
>>        
>>                
>>                        eclipse
>>                        
>>                                
>> process-test-resources
>>                                
>>                                        
>>                                                
>> maven-eclipse-plugin
>>                                                
>>                                                        
>>                                                                
>> eclipse
>>                                                                
>> process-test-resources
>>                                                                
>>                                                                        
>> eclipse
>>                                                                
>>                                                        
>>                                                
>>                                        
>>                                
>>                        
>>                
>>
>>
>>
>> --
>> Zeno Consulting, Inc.
>> home: http://www.zenoconsulting.biz
>> blog: http://zenoconsulting.wikidot.com
>> p: 248.894.4922
>> f: 313.884.2977
>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
>> For additional commands, e-mail: users-h...@maven.apache.org
>>
>>
>



-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977


how to get eclipse plugin to process-test-resources?

2009-03-02 Thread Davis Ford
Hi, when I run the eclipse goal like this: mvn eclipse:eclipse I also
want it to execute resources:testResources.

I tried something like this:




org.apache.maven.plugins
maven-eclipse-plugin


eclipse

process-test-resources

eclipse





But it doesn't work.  If I put it in a profile like this, it does
work, but I don't want to have to have a profile for it.  Is there a
way to accomplish this?



eclipse


process-test-resources



maven-eclipse-plugin


eclipse

process-test-resources


eclipse










-- 
Zeno Consulting, Inc.
home: http://www.zenoconsulting.biz
blog: http://zenoconsulting.wikidot.com
p: 248.894.4922
f: 313.884.2977

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



I get an Cannot create virtual machine error when trying to Install maven

2008-06-29 Thread James Davis
Hello,
 
I have follow the step for installation word for word and I still can install 
mavem. When I run the test "mvn --version" in the command prompt I get the 
following error:
 
Unrecognized option: -
Could not create the Java virtual machine.
 
Does anyone know what this means? I have copied and pasted my JAVA_HOME 
variable striaght from the address bar of my browser where I installed java. I 
must have went thorught the instructions a hundred times can someone please 
help.


  

Re: Building for different environments - how do _you_ do it?

2008-06-03 Thread Paul Davis
The best thing is to NOT create a different build for different
environments.

When environment specific stuff is needed (EARs and WARs) look up the info
from JNDI and put that configuration on the server.
Then if something needs to change, you don't need to create a new build.

If you have to do it, you could probably create a profile for each
environment setting a variable.
Then the files specific to that environment could be "filtered" based on the
value of that variable.
You'd just specify the profile to use when creating the build.

On Tue, Jun 3, 2008 at 11:14 AM, EJ Ciramella <[EMAIL PROTECTED]>
wrote:

> So how are other people building for both dev and other environments?
>
>
>
> For example, how does one support multiple environments like the
> following:
>
>
>
> 1 - Dev integration
>
> 2 - QA stack 1
>
> 3 - QA stack 2
>
> 4 - QA stack 3
>
> 5 - Staging
>
> 6 - Prod
>
> 7 - local developer builds
>
>
>
> How do other people support variables that can be the same from local
> builds through production but support the option to change them at the
> last minute?  Are people building multiple version of say an ear
> deployment to support all the different environments?
>
>


Re: generate link css on maven reports

2008-06-02 Thread Paul Davis
actually, it's so you can add your own css at:
src/site/resources/css/
in your project and have it used in the site

On Mon, Jun 2, 2008 at 2:03 AM, ggalou08 <[EMAIL PROTECTED]> wrote:

>
> hi !
>
> I generate a site with maven reports and in the code source I see a link on
> a css file : print.css.
>
> This file doesn't exist, and i wonder if I can force Maven not to generate
> this link or if it's just a bug ?!?
>
> this is the source :
>
>
>  @import url("./css/maven-base.css");
>  @import url("./css/maven-theme.css");
>  @import url("./css/site.css");
>
>
> Thank you for your help !
> --
> View this message in context:
> http://www.nabble.com/generate-link-css-on-maven-reports-tp17596897p17596897.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: integration-test practices

2008-05-30 Thread Paul Davis
It looks like my original problem has been solved, it's an issue (bug?) with
the latest version of the surefire plugin.

http://www.nabble.com/Re%3A-Integration-testing-via-profile-fails-in-2.0.9-p17532410.html

Maybe the plugin could use a little automated testing too  ;-)

On Tue, May 27, 2008 at 10:19 PM, Jerome Lacoste <[EMAIL PROTECTED]>
wrote:

> On Tue, May 27, 2008 at 11:34 PM, Wendy Smoak <[EMAIL PROTECTED]> wrote:
> > On Tue, May 27, 2008 at 1:57 PM, Jerome Lacoste
> > <[EMAIL PROTECTED]> wrote:
> >> On Mon, May 26, 2008 at 1:41 AM, Kaizer H. Sogiawala <[EMAIL PROTECTED]>
> wrote:
> >>> A while back I came across a note about integration test - From a
> >>> single project POM you can only choose to execute either unit or the
> >>> integration test, not both. Could that be a factor in the outcome you
> >>> see?
> >>
> >> Are you sure of that ? Maven doesn't limit you. You can attach your
> >> mojos to the phase you want.
> >>
> >> I have a project under my eyes that binds surefire to the test phase,
> >> and easyb tests to the integration-test one.
> >
> > The limitation is that there is only one testSourceDirectory in the
> > pom.  If you use Surefire in both the test and integration-test
> > phases, you have to configure includes and excludes to get it to use
> > the right code for each set of tests.
>
> You're right: there's at least one big limitation is the compiler
> plugin. testCompile only uses the test source directory defined in the
> POM:
>
>/**
> * The source directories containing the test-source to be compiled.
> *
> * @parameter expression="${project.testCompileSourceRoots}"
> * @required
> * @readonly
> */
>private List compileSourceRoots;
>
> > My guess is that 'easyb' is using a different default or configuration
> > for its test source directory.
>
> yep. And all tools I've used for integration-tests had their own source
> dirs.
>
> So the problem is probably not that you can chose to execute it or
> unit test, it's that you can only compile one of them easily.
>
> Cheers,
>
> Jerome
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: [m2] Cargo, Tomcat on CentOS/Linux?

2008-05-29 Thread Paul Davis
I'm using file:// in my settings.xml and http:// in for the default in the
pom.xml

On Thu, May 29, 2008 at 1:04 PM, Mick Knutson <[EMAIL PROTECTED]> wrote:

> What is the setting for your settings.xml? http:// or file://
>
>
>
> On Thu, May 29, 2008 at 11:55 AM, Paul Davis <[EMAIL PROTECTED]> wrote:
>
> > I use it on Linux and noticed intermittent timeouts (I use continuum for
> > continuous integration).
> > The solution was to store the tomcat zip file locally.
> > I use a variable for the tomcat location (defaults to the remote
> location).
> > Then in my settings.xml, I have a profile that sets the variable to the
> > local location.
> >
> > This allows anyone to use tomcat (because of the default) and anyone, in
> > the
> > know, or my build system, to pull it off the local file system.
> >
> > This has eliminated timeouts for me
> >
> > On Thu, May 29, 2008 at 11:34 AM, Mick Knutson <[EMAIL PROTECTED]>
> > wrote:
> >
> > > do you use the zip for both, or the tar.gz?
> > >
> > >
> > > On Thu, May 29, 2008 at 11:15 AM, Geoffrey Wiseman <
> > > [EMAIL PROTECTED]> wrote:
> > >
> > > > On Thu, May 29, 2008 at 1:25 PM, Mick Knutson <[EMAIL PROTECTED]
> >
> > > > wrote:
> > > >
> > > > > Just wondering if anyone is using tomcat/cargo on Linux. I have the
> > > > > following CFG on windows, but am now getting time-outs on Linux.
> Just
> > > > >
> > > >
> > > > We're using Tomcat 5.5 / Cargo / M2 on Windows and Linux.  We do
> > > > occasionally get a build failure on the build server (Linux) due to
> > > failure
> > > > deploying the artifact before the timeout, but for the most part,
> it's
> > > been
> > > > fairly problem-free for us.
> > > >
> > > >  - Geoffrey
> > > > --
> > > > Geoffrey Wiseman
> > > >
> > >
> > >
> > >
> > > --
> > > ---
> > > Thank You…
> > >
> > > Mick Knutson
> > > BASE Logic, inc.
> > >
> > > Website: http://baselogic.com
> > > Blog: http://baselogic.com/blog
> > > BLiNC Magazine: http://blincmagazine.com
> > > Linked IN: http://linkedin.com/in/mickknutson
> > > DJ Mick: http://djmick.com
> > > MySpace: http://myspace.com/mickknutson
> > > Tahoe: http://tahoe.baselogic.com
> > >
> >
>
>
>
> --
> ---
> Thank You…
>
> Mick Knutson
> BASE Logic, inc.
>
> Website: http://baselogic.com
> Blog: http://baselogic.com/blog
> BLiNC Magazine: http://blincmagazine.com
> Linked IN: http://linkedin.com/in/mickknutson
> DJ Mick: http://djmick.com
> MySpace: http://myspace.com/mickknutson
> Tahoe: http://tahoe.baselogic.com
>



-- 
Paul E. Davis
[EMAIL PROTECTED]
253-861-7769


Re: [m2] Cargo, Tomcat on CentOS/Linux?

2008-05-29 Thread Paul Davis
I use it on Linux and noticed intermittent timeouts (I use continuum for
continuous integration).
The solution was to store the tomcat zip file locally.
I use a variable for the tomcat location (defaults to the remote location).
Then in my settings.xml, I have a profile that sets the variable to the
local location.

This allows anyone to use tomcat (because of the default) and anyone, in the
know, or my build system, to pull it off the local file system.

This has eliminated timeouts for me

On Thu, May 29, 2008 at 11:34 AM, Mick Knutson <[EMAIL PROTECTED]>
wrote:

> do you use the zip for both, or the tar.gz?
>
>
> On Thu, May 29, 2008 at 11:15 AM, Geoffrey Wiseman <
> [EMAIL PROTECTED]> wrote:
>
> > On Thu, May 29, 2008 at 1:25 PM, Mick Knutson <[EMAIL PROTECTED]>
> > wrote:
> >
> > > Just wondering if anyone is using tomcat/cargo on Linux. I have the
> > > following CFG on windows, but am now getting time-outs on Linux. Just
> > >
> >
> > We're using Tomcat 5.5 / Cargo / M2 on Windows and Linux.  We do
> > occasionally get a build failure on the build server (Linux) due to
> failure
> > deploying the artifact before the timeout, but for the most part, it's
> been
> > fairly problem-free for us.
> >
> >  - Geoffrey
> > --
> > Geoffrey Wiseman
> >
>
>
>
> --
> ---
> Thank You…
>
> Mick Knutson
> BASE Logic, inc.
>
> Website: http://baselogic.com
> Blog: http://baselogic.com/blog
> BLiNC Magazine: http://blincmagazine.com
> Linked IN: http://linkedin.com/in/mickknutson
> DJ Mick: http://djmick.com
> MySpace: http://myspace.com/mickknutson
> Tahoe: http://tahoe.baselogic.com
>


Re: how to separate Unit Tests from Integration-Tests with JUnit 4.x?

2008-05-29 Thread Paul Davis
Another option is to place the integration tests into a separate module.

On Thu, May 29, 2008 at 8:12 AM, Kalle Korhonen <[EMAIL PROTECTED]>
wrote:

> Standard answer is with naming convention, see
> http://www.mail-archive.com/users@maven.apache.org/msg81355.html.
>
> Kalle
>
> On Thu, May 29, 2008 at 7:54 AM, <[EMAIL PROTECTED]> wrote:
>
> > Hi,
> >
> > Actually, we have mixed JUnit Testcases in our modules - some of them can
> > be run "standalone" with no database connection or any other environment,
> > others need environment.
> >
> > I now want to separate those tests into different categories, but I don´t
> > want to
> > - manually create a DatabaseTestSuite where I need to add all
> > database-testcases
> > - create a new Maven Module to separate the testcases
> >
> > Can I use JUnit 4.x with its annotations like @RunWith @Ignore and so on
> > to do so ?
> >
> > For example the "simple testcases" should be bound to the "test" phase,
> > the "database-testcases" should be bound to the "integration-test" phase.
> >
> > Any ideas, links, cookbooks?
> >
> > Thanx, Torsten
> >
> >
>


Re: integration-test practices

2008-05-22 Thread Paul Davis
Before my response, I just want to say, I really appreciate you taking the
time to help me with this.

Yes, I am defining the src to look in "src/it/java".
I heard a rumor that maven 2.1 would support that for integration tests so,
I wanted to start using the location.

I also have the integration tests in a separate module.

My project structure looks like:
/pom.xml
/my-data-api/pom.xml
/my-data-impl/pom.xml
/my-web-module/pom.xml
/functest/pom.xml

The functest module contains the integration tests
from the functest pom:


src/it/java


false
src/it/resources




There is a profile defined in that module to use the surefire plugin to run
the tests in the integration test phase. The profile also uses the cargo
plugin to start tomcat, deploy the web app for "pre-integration-test", and
undeploy/shutdown tomcat for "post-integration-test".

Everything is working fine for the integration tests to execute on the
"integration-test" part of the project life-cycle except getting the
resources to load up (unless they are in both places, mentioned before).

The app is designed so that the "my-data-impl" module uses REST to
communicate with an external server. It is instrumented with JMX so the
integration test can tell it to use mock data, injected via JMX, instead of
hitting the external server. This ensures tests that are repeatable.

The thing is, the tests need to load up the mock data in order to be
injected. Thus, my issue getting the files loaded from the classpath.

I could have the files duplicated but, it's going to cause maintenance
problems down the road

On Thu, May 22, 2008 at 11:55 AM, Wendy Smoak <[EMAIL PROTECTED]> wrote:

> On Thu, May 22, 2008 at 8:39 AM, Paul Davis <[EMAIL PROTECTED]> wrote:
>
> > I have found that if I place the resource (xml file) in both places, it
> > works
> > src/it/java
> > src/test/resources
> > However, if I only have one copy (in either location) it does not work.
>
> I wouldn't expect src/it/* to work, unless you are configuring a
> plugin to look there.  AFAIK, nothing looks there by default.  Neither
> are any plugins bound to the integration test phases in the default
> lifecycle, so if you want to use those phases you need to do the
> bindings yourself.
>
> I still don't have a good idea of what you're trying to do.  Can you
> include some of the pom config and explain the project structure?  Are
> the integration tests in a separate module?
>
> --
> Wendy
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: integration-test practices

2008-05-22 Thread Paul Davis
I actually meant
src/test/resources

I have found that if I place the resource (xml file) in both places, it
works
src/it/java
src/test/resources
However, if I only have one copy (in either location) it does not work.

I didn't try "src/main/resources" because it's an integration test.
Should I put it there?

Maybe my confusion is a result of the integration-test phase doesn't have a
similar life-cycle as the test phase?


On Wed, May 21, 2008 at 8:57 PM, Wendy Smoak <[EMAIL PROTECTED]> wrote:

> On Wed, May 21, 2008 at 3:35 PM, Paul Davis <[EMAIL PROTECTED]> wrote:
>
> > It seems the documentation for the integration-test phase is pretty thin
> (as
> > in, where is it?).
>
> There are some notes on the wiki:
> http://docs.codehaus.org/display/MAVENUSER/Maven+and+Integration+Testing
>
> > I can't seem to get "resources" accessible by the test code.
>
> We'll need more info in order to help.  Do you mean files in
> src/main/resources?
>
> --
> Wendy
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


integration-test practices

2008-05-21 Thread Paul Davis
It seems the documentation for the integration-test phase is pretty thin (as
in, where is it?).

I can't seem to get "resources" accessible by the test code.

Is there some undocumented "convention" I should be following?


Re: maven-dependency-plugin

2008-03-25 Thread Davis Ford
It is slightly more complex.

The assembly jar's purpose loads geodata from a database, and then
does quality checks on that data, and stores any violations it found
in a separate repository.

Every time I run the jar, I want to store with the list of violations
the list of all versions of jars it usedfor analysis (if number of
violations changes, I want to understand why...perhaps a new jar was
released that caused it).

I could scan this info at runtime by looking in the lib dir inside the
assembly jar, true.  This doesn't help me, though when I'm developing
/ testing, since I run tests either via mvn or w/in eclipse, and I
want to know the same info during that phase.

So, I guess what I'm looking for is a universal solution to always
being able to obtain this information at runtime despite what phase
I'm in (as a deployed assembly jar, or running in eclipse).  I'm
coming to the conclusion that the best way to do this is probably to
just get the classpath system property, and parse that.

Regards,
Davis

On Tue, Mar 25, 2008 at 11:25 AM, Brian E. Fox <[EMAIL PROTECTED]> wrote:
> So it sounds like you might be trying to do a form of code coverage for
>  your dependencies?
>
>  To answer your question, yes I would dump the file when you are making
>  the assembly and then use that at runtime. Just curious though, if the
>  dependencies are in the assembly, why do you need a list of them?
>  Couldn't you just enumerate the lib folder?
>
>
>  -Original Message-
>  From: Davis Ford [mailto:[EMAIL PROTECTED]
>
>
> Sent: Tuesday, March 25, 2008 11:17 AM
>  To: Maven Users List
>  Subject: Re: maven-dependency-plugin
>
>  Quick follow-up.  Consider if I have this use case:
>
>  For project A, do mvn assembly:assembly to make uber-jar, and deploy
>  it so someone can use it.  For each execution that they run it, I want
>  it to log programmatically the list of jars it used for that
>  execution.  If I developed a plugin to get this info, then it would
>  also require maven being installed where the assembly jar is
>  installed, since the plugin would try to resolve each jar.  I'm
>  assuming that it does not resolve from the classpath but only from the
>  mvn remote or local repos.
>
>  Thus, perhaps it is better to use the dependency plugin to dump a text
>  file list of dependencies that gets deployed with the assembly jar,
>  since this won't require any other maven dependencies to get at the
>  same information?
>
>  Any thoughts?
>
>  Thanks in advance,
>  Davis
>
>  On Tue, Mar 25, 2008 at 10:40 AM, Brian E. Fox
>  <[EMAIL PROTECTED]> wrote:
>  > Generally bad things happen when you use plugins as dependencies. The
>  >  project.getArtifacts() is part of the plugin api, not just the
>  >  dependency plugin. If you use the M2Eclipse plugin for eclipse, you
>  can
>  >  quickly create a plugin by using the maven-archetype-mojo archetype.
>  >
>  >
>  >  -Original Message-
>  >  From: Davis Ford [mailto:[EMAIL PROTECTED]
>  >
>  >
>  > Sent: Tuesday, March 25, 2008 10:31 AM
>  >  To: Maven Users List
>  >  Subject: Re: maven-dependency-plugin
>  >
>  >  Brian,
>  >
>  >  Maybe a dumb question, but is there a way I can just use the
>  >  maven-dependency-plugin programatically to accomplish what I'm trying
>  >  to do?
>  >
>  >  Can I just pull the plugin jar in so it is on the classpath like any
>  >  other dependency and use its API to get project.getArtifacts() ?
>  >
>  >  On Wed, Mar 19, 2008 at 6:02 PM, Brian E. Fox
>  <[EMAIL PROTECTED]>
>  >  wrote:
>  >  > Actually getting the list via a plugin is trivial. Just set a
>  >  parameter
>  >  >  like this:
>  >  >
>  >  > /**
>  >  >  * POM
>  >  >  *
>  >  >  * @parameter expression="${project}"
>  >  >  * @readonly
>  >  >  * @required
>  >  >  */
>  >  > protected MavenProject project;
>  >  >
>  >  >  And then project.getArtifacts() will be all (including transitive)
>  >  >  dependencies. You'll also need to specify
>  >  @requiresDependencyResolution
>  >  >  [scope] in the mojo annotations.
>  >  >
>  >  >  There is also a tree component that you could use to get the
>  output
>  >  used
>  >  >  to generate dependency:tree
>  >  >
>  >  >
>  >  >  -Original Message-
>  >  >  From: Davis Ford [mailto:[EMAIL PROTECTED]
>  >  >
>  >  > Sent: Wednesday, March 19, 2008 5:57 PM
>  >  >  To: Mave

Re: maven-dependency-plugin

2008-03-25 Thread Davis Ford
Quick follow-up.  Consider if I have this use case:

For project A, do mvn assembly:assembly to make uber-jar, and deploy
it so someone can use it.  For each execution that they run it, I want
it to log programmatically the list of jars it used for that
execution.  If I developed a plugin to get this info, then it would
also require maven being installed where the assembly jar is
installed, since the plugin would try to resolve each jar.  I'm
assuming that it does not resolve from the classpath but only from the
mvn remote or local repos.

Thus, perhaps it is better to use the dependency plugin to dump a text
file list of dependencies that gets deployed with the assembly jar,
since this won't require any other maven dependencies to get at the
same information?

Any thoughts?

Thanks in advance,
Davis

On Tue, Mar 25, 2008 at 10:40 AM, Brian E. Fox <[EMAIL PROTECTED]> wrote:
> Generally bad things happen when you use plugins as dependencies. The
>  project.getArtifacts() is part of the plugin api, not just the
>  dependency plugin. If you use the M2Eclipse plugin for eclipse, you can
>  quickly create a plugin by using the maven-archetype-mojo archetype.
>
>
>  -Original Message-
>  From: Davis Ford [mailto:[EMAIL PROTECTED]
>
>
> Sent: Tuesday, March 25, 2008 10:31 AM
>  To: Maven Users List
>  Subject: Re: maven-dependency-plugin
>
>  Brian,
>
>  Maybe a dumb question, but is there a way I can just use the
>  maven-dependency-plugin programatically to accomplish what I'm trying
>  to do?
>
>  Can I just pull the plugin jar in so it is on the classpath like any
>  other dependency and use its API to get project.getArtifacts() ?
>
>  On Wed, Mar 19, 2008 at 6:02 PM, Brian E. Fox <[EMAIL PROTECTED]>
>  wrote:
>  > Actually getting the list via a plugin is trivial. Just set a
>  parameter
>  >  like this:
>  >
>  > /**
>  >  * POM
>  >  *
>  >  * @parameter expression="${project}"
>  >  * @readonly
>  >  * @required
>  >  */
>  > protected MavenProject project;
>  >
>  >  And then project.getArtifacts() will be all (including transitive)
>  >  dependencies. You'll also need to specify
>  @requiresDependencyResolution
>  >  [scope] in the mojo annotations.
>  >
>  >  There is also a tree component that you could use to get the output
>  used
>  >  to generate dependency:tree
>  >
>  >
>  >  -Original Message-
>  >  From: Davis Ford [mailto:[EMAIL PROTECTED]
>  >
>  > Sent: Wednesday, March 19, 2008 5:57 PM
>  >  To: Maven Users List
>  >
>  >
>  > Subject: Re: maven-dependency-plugin
>  >
>  >  Hi Brian,
>  >
>  >  Indeed -- total goof-up on my part.  I had multiple project pom.xml
>  >  files and was editing the wrong one.  It works like a charm.
>  >
>  >  Quick related question...the whole purpose of me dumping this to a
>  >  text file was because I could not see an easy way to programmatically
>  >  get a list of all project dependenciesso I figured I'd create the
>  >  .txt file and parse it myself.
>  >
>  >  The reason I want this list is as part of reporting framework we
>  have.
>  >   We run a long-running set of quality checks on some data, and I need
>  >  to be able to store with the final report the list of all things like
>  >  .jar versions, database versions, etc., etc.
>  >
>  >  Is there somewhere an API that would let me retrieve this same
>  >  information in the code?
>  >
>  >  Regards,
>  >  Davis
>  >
>  >  On Wed, Mar 19, 2008 at 4:50 PM, Brian E. Fox
>  <[EMAIL PROTECTED]>
>  >  wrote:
>  >  > I just double checked the code and this should work. Is it
>  displaying
>  >  >  the list to the output? If not, then it's going to a file
>  somewhere.
>  >  It
>  >  >  would be better to use ${project.build.directory}/output.txt
>  instead
>  >  so
>  >  >  it goes to /target/output.txt
>  >  >
>  >  >
>  >  >
>  >  >  -Original Message-
>  >  >  From: Davis Ford [mailto:[EMAIL PROTECTED]
>  >  >  Sent: Wednesday, March 19, 2008 4:46 PM
>  >  >  To: Maven Users List
>  >  >  Subject: maven-dependency-plugin
>  >  >
>  >  >  Hi, I'm trying to use the maven-dependency-plugin to dump a list
>  of
>  >  >  the project's dependencies out to a text file, but I can 

Re: maven-dependency-plugin

2008-03-25 Thread Davis Ford
Brian,

Maybe a dumb question, but is there a way I can just use the
maven-dependency-plugin programatically to accomplish what I'm trying
to do?

Can I just pull the plugin jar in so it is on the classpath like any
other dependency and use its API to get project.getArtifacts() ?

On Wed, Mar 19, 2008 at 6:02 PM, Brian E. Fox <[EMAIL PROTECTED]> wrote:
> Actually getting the list via a plugin is trivial. Just set a parameter
>  like this:
>
> /**
>  * POM
>  *
>  * @parameter expression="${project}"
>  * @readonly
>  * @required
>  */
> protected MavenProject project;
>
>  And then project.getArtifacts() will be all (including transitive)
>  dependencies. You'll also need to specify @requiresDependencyResolution
>  [scope] in the mojo annotations.
>
>  There is also a tree component that you could use to get the output used
>  to generate dependency:tree
>
>
>  -Original Message-
>  From: Davis Ford [mailto:[EMAIL PROTECTED]
>
> Sent: Wednesday, March 19, 2008 5:57 PM
>  To: Maven Users List
>
>
> Subject: Re: maven-dependency-plugin
>
>  Hi Brian,
>
>  Indeed -- total goof-up on my part.  I had multiple project pom.xml
>  files and was editing the wrong one.  It works like a charm.
>
>  Quick related question...the whole purpose of me dumping this to a
>  text file was because I could not see an easy way to programmatically
>  get a list of all project dependenciesso I figured I'd create the
>  .txt file and parse it myself.
>
>  The reason I want this list is as part of reporting framework we have.
>   We run a long-running set of quality checks on some data, and I need
>  to be able to store with the final report the list of all things like
>  .jar versions, database versions, etc., etc.
>
>  Is there somewhere an API that would let me retrieve this same
>  information in the code?
>
>  Regards,
>  Davis
>
>  On Wed, Mar 19, 2008 at 4:50 PM, Brian E. Fox <[EMAIL PROTECTED]>
>  wrote:
>  > I just double checked the code and this should work. Is it displaying
>  >  the list to the output? If not, then it's going to a file somewhere.
>  It
>  >  would be better to use ${project.build.directory}/output.txt instead
>  so
>  >  it goes to /target/output.txt
>  >
>  >
>  >
>  >  -Original Message-
>  >  From: Davis Ford [mailto:[EMAIL PROTECTED]
>  >  Sent: Wednesday, March 19, 2008 4:46 PM
>  >  To: Maven Users List
>  >  Subject: maven-dependency-plugin
>  >
>  >  Hi, I'm trying to use the maven-dependency-plugin to dump a list of
>  >  the project's dependencies out to a text file, but I can not seem to
>  >  get it to do anything.
>  >
>  >  relevant configuration:
>  >
>  >   
>  >
>  >  org.apache.maven.plugins
>  >
>  >  maven-dependency-plugin
>  > 2.0
>  > 
>  > 
>  >
>  >  write-dependencies
>  > compile
>  > 
>  >
>  >  list
>  > 
>  > 
>  >
>  >  dependencies.txt
>  > 
>  > 
>  > 
>  > 
>  > 
>  > 
>  >
>  >  I would expect that if I do "mvn compile" it would create
>  >  dependencies.txt but it does not.  Anyone have an idea what I'm doing
>  >  wrong here?
>  >
>  >  Thanks in advance,
>  >  Davis
>  >
>  >  -
>  >  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: maven-dependency-plugin

2008-03-19 Thread Davis Ford
Hi Brian,

Indeed -- total goof-up on my part.  I had multiple project pom.xml
files and was editing the wrong one.  It works like a charm.

Quick related question...the whole purpose of me dumping this to a
text file was because I could not see an easy way to programmatically
get a list of all project dependenciesso I figured I'd create the
.txt file and parse it myself.

The reason I want this list is as part of reporting framework we have.
 We run a long-running set of quality checks on some data, and I need
to be able to store with the final report the list of all things like
.jar versions, database versions, etc., etc.

Is there somewhere an API that would let me retrieve this same
information in the code?

Regards,
Davis

On Wed, Mar 19, 2008 at 4:50 PM, Brian E. Fox <[EMAIL PROTECTED]> wrote:
> I just double checked the code and this should work. Is it displaying
>  the list to the output? If not, then it's going to a file somewhere. It
>  would be better to use ${project.build.directory}/output.txt instead so
>  it goes to /target/output.txt
>
>
>
>  -Original Message-
>  From: Davis Ford [mailto:[EMAIL PROTECTED]
>  Sent: Wednesday, March 19, 2008 4:46 PM
>  To: Maven Users List
>  Subject: maven-dependency-plugin
>
>  Hi, I'm trying to use the maven-dependency-plugin to dump a list of
>  the project's dependencies out to a text file, but I can not seem to
>  get it to do anything.
>
>  relevant configuration:
>
>   
>
>  org.apache.maven.plugins
>
>  maven-dependency-plugin
> 2.0
> 
> 
>
>  write-dependencies
> compile
> 
>
>  list
> 
> 
>
>  dependencies.txt
> 
> 
> 
> 
> 
> 
>
>  I would expect that if I do "mvn compile" it would create
>  dependencies.txt but it does not.  Anyone have an idea what I'm doing
>  wrong here?
>
>  Thanks in advance,
>  Davis
>
>  -
>  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]
>
>



-- 
Zeno Consulting, Inc.
http://www.zenoconsulting.biz
248.894.4922 phone
313.884.2977 fax

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



maven-dependency-plugin

2008-03-19 Thread Davis Ford
Hi, I'm trying to use the maven-dependency-plugin to dump a list of
the project's dependencies out to a text file, but I can not seem to
get it to do anything.

relevant configuration:

  
org.apache.maven.plugins
maven-dependency-plugin
2.0


write-dependencies
compile

list



dependencies.txt


   




I would expect that if I do "mvn compile" it would create
dependencies.txt but it does not.  Anyone have an idea what I'm doing
wrong here?

Thanks in advance,
Davis

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



Trouble deploying Archiva 1.0 to JBoss 4.2.2.GA

2008-01-21 Thread Leon Davis
Hi I have been trying to deploy the latest version of
the Archiva war to JBoss version 4.2.2 without
success. Has anyone else been successful in deploying
the latest version of Archiva to JBoss?

I would really like to get this working and appreciate
any help anyone can offer!

I have seen the following wiki page that contains
instructions:

http://docs.codehaus.org/display/MAVENUSER/Archiva+on+JBoss

In addition to this I have looked at:
http://docs.codehaus.org/display/MAVENUSER/Archiva+on+Tomcat

What I have done:
1. I have added the following context.xml to the
META-INF directory of the Archiva war file:


  

  

  


2. I have added a jboss-web.xml file to the WEB-INF
directory of the war: (as instructed on the wiki:
Although it feels as though there should be more
entries in this file as there are more resource-ref
entries made in the web.xml file?)


 
   jdbc/users
   java:/users
 


3. I made sure that the following entry appears in the
web.xml file: 

 jdbc/users
 javax.sql.DataSource
 Container


This entry was already in web.xml along with the
following two other entries:
  
 jdbc/archiva
 javax.sql.DataSource
 Container
 Shareable
  
  
 mail/Session
 javax.mail.Session
 Container
 Shareable
  

4. I have coppied derby-10.1.3.1.jar,
derby-tools-10.1.3.1.jar and mail-1.4.jar in to
JBoss's default server's lib directory

5. I have added the following derby-ds.xml file to
JBoss's default server's deploy directory.


  
 
 
 users
 

jdbc:derby:database/archiva;create=true
 

org.apache.derby.jdbc.EmbeddedDriver
 
 sa
 
 
 5
 
 20
 
 5
 
 
  


The wiki says to include settings for appserver.base
and appserver.home using the CATALINA_OPTS environment
variable but I am not sure where I should be
specifying this within the JBoss configuration? As a
result I do see exceptions when the \log\logfiles can
not be found.

So What happens when loading JBoss?:
On loading JBoss: I see the following:
org.jboss.deployment.DeploymentException: Error during
deploy; - nested throwable:
(javax.naming.NamingException: resource-ref:
mail/Session has no valid JNDI binding. Check the
jboss-web/resource-ref.)

Followed by a very long stack trace.

The message mentions the resource-ref's in
jboss-web.xml and I have tried adding JNDI bindings
for both jdbc/archiva and mail/Session: (I am guessing
what these are supposed to be)


 
   jdbc/users
   java:/users
 

   jdbc/archiva
   java:/archiva
 
 
   mail/Session
   java:/mail
 


On doing so I get:
20:00:19,531 INFO  [STDOUT] 2008-01-21 20:00:19,515
[main] ERROR
org.apache.commons.configuration.JNDIConfiguration  -
Could not dereference
objectjavax.naming.NamingException: Could not
dereference object [Root exception is
javax.naming.NameNotFoundException: mail not bound]

Once again many thanks for any help you might be able
to give me.

Many thanks,
Leon Davis




  __
Sent from Yahoo! Mail - a smarter inbox http://uk.mail.yahoo.com



Newbie Repository question

2007-12-08 Thread Davis, Darren (RBI-US)
I've been looking into using maven to compile and run automated unit
tests for a couple of projects I'm working on.  I see a lot of potential
for making this process more efficient with Maven.

 

One project is compiling against standard hibernate jars that came with
Jboss (4.2.0) and the Microsoft SQL server jdbc driver (sqljdbc.jar).  I
was able to find hibernate files in the global repository
(hibernate/hibernate/version 3.0), but they seem really out of date and
don't provide the same classes that the jboss files do.  I did not see
any hibernate sub-section underneath the jboss repository directories.

 

I would like to set this up correctly, but another issue is most of jars
we're using do not have any versioning associated with them.  For
example the cglib.jar in the jboss lib directory doesn't have a version
as part of the filename.  If I extract out the files, there doesn't seem
to be a version for that file specifically, other than a jboss 4.2.0.GA
in the manifest. What would be the correct "maven" way to place these
files in the local repository?  Should I place all of the files under a
'jboss' group, or should they be distributed to the
hibernate/cglib/commons-collections, etc... stamped with a jboss
version?  It also seems that I should define dependencies someplace so
the project pom file doesn't have to manually include each one.  Is
there a standard way of defining that as well?

 

Sorry if these questions seem overly paranoid.  I just don't want to
make some bad decision at this early stage of using Maven and have to go
back in the future and rework everything.



resources plugin question

2007-12-03 Thread Davis Ford
Hi, if I have the general maven project layout with the following:

src/main/resources/mydirectory/file.xml

and general pom.xml with this:

1.1

Is it possible somehow using the resources plugin (or some other
plugin) to cause it to deploy as a jar-file with the following
directory structure inside the jar ->

my-project-1.1.jar:/mydirectory/1.1/file.xml

Said another way, I want to dynamically take the maven ${version}
value from the pom, and insert it dynamically into the resources path
in the jar when it is deployed.

Is there an easy way to accomplish this?

Thanks in advance,
Davis

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



eclipse plugin - exclude pattern for source

2007-06-12 Thread davis

Hi,
If you have eclipse open, it is often convenient to right click
/src/test/java and say "Run as JUnit test" -- which creates a dynamic test
suite on the fly and runs all the tests.

However, I'd really like the ability to add an exclusion pattern to avoid
certain tests that may be integration tests (and take a long time).

In Eclipse, you can do this by right-clicking /src/test/java -> Build Path
-> Configure Inclusion / Exclusion Filters

This ends up editing the .classpath file to add the exclusion patterns you
type in.

What I would really like to do is add this info to the pom.xml, and when I
run mvn eclipse:eclipse, this is automatically added to the .classpath file,
but I can't figure out how to do it.

Is this possible?

Thx,
Davis
-- 
View this message in context: 
http://www.nabble.com/eclipse-plugin---exclude-pattern-for-source-tf3912333s177.html#a11092104
Sent from the Maven - Users mailing list archive at Nabble.com.


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



problem with dependency version ranges?

2007-04-17 Thread Davis Ford

Hi, I recently switched to 2.0.6 from 2.0.5.  We use dependency
version ranges in our jars, but today I am seeing a problem with them.
mvn complains that it can no longer find the version range specified.
Has anyone else seen this problem, and how to work around it?

I have checked the our internal repository (192.168.1.10), and there
are several jars in the range that is specified.  Example:


   thing
   com.whatever
   [0.6.,0.7)


[ERROR] BUILD ERROR
[INFO] 
[INFO] Failed to resolve artifact.
No versions are present in the repository for the artifact with a
range [0.6,0.7)
 com.whatever:thing:jar:null
from the specified remote repositories:
 snapshot-doc-http-repository
(http://192.168.1.10/share/maven-diamond-snapshot),
 central (http://repo1.maven.org/maven2),
 doc-http-repository (http://192.168.1.10/share/maven),
 maven-fast-repo (http://repo1.maven.org/maven2)

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



Re: problem with dependency version ranges?

2007-04-17 Thread Davis Ford

Cleaning out the local repo resolves this problem.

On 4/17/07, Davis Ford <[EMAIL PROTECTED]> wrote:

Hi, I recently switched to 2.0.6 from 2.0.5.  We use dependency
version ranges in our jars, but today I am seeing a problem with them.
 mvn complains that it can no longer find the version range specified.
 Has anyone else seen this problem, and how to work around it?

I have checked the our internal repository (192.168.1.10), and there
are several jars in the range that is specified.  Example:

 
thing
com.whatever
[0.6.,0.7)
 

[ERROR] BUILD ERROR
[INFO] 
[INFO] Failed to resolve artifact.
No versions are present in the repository for the artifact with a
range [0.6,0.7)
  com.whatever:thing:jar:null
from the specified remote repositories:
  snapshot-doc-http-repository
(http://192.168.1.10/share/maven-diamond-snapshot),
  central (http://repo1.maven.org/maven2),
  doc-http-repository (http://192.168.1.10/share/maven),
  maven-fast-repo (http://repo1.maven.org/maven2)




--
Zeno Consulting, Inc.
http://www.zenoconsulting.biz
248.894.4922 phone
313.884.2977 fax

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



Re: maven-eclipse-plugin has problem with muli-project resources

2007-04-17 Thread Davis Ford

Hi Barrie, I understand about create a separate resource module that
can be shared.

Let me ask a quick question though.  You mention you don't use a flat
structure.  This isn't a flat structure as far as i can tell...it is
hierarchical.

It's my understanding that a flat structure puts both parent and child
at the same directory level, but this is not the case.

I wish there were some way around this.

Thanks for looking.

Davis

On 4/17/07, Barrie Treloar <[EMAIL PROTECTED]> wrote:

On 4/17/07, Davis Ford <[EMAIL PROTECTED]> wrote:
> Hi, it appears that in order for eclipse to see relative path links
> like this, an entry needs to be made to the .project file with the
> linkeResources tag.  If you manually add a src folder in eclipse, this
> is the change it makes in .project.
>
> Is there some way to cause the maven-eclipse-plugin to do this via the 
pom.xml?
>
> 
> 
> conf
> 2
> D:/temp/parent/conf
> 
> 

Looking at 
http://maven.apache.org/plugins/maven-eclipse-plugin/eclipse-mojo.html
I can't see how to do this.

However I do know that eclipse:pde does write linkedResources.

I personally do not use a flat structure, I use the hierarchical one.

You might need to describe in more detail what ../conf contains.
If this is a shared configuration, then the usual way to do this is to
create another module project for "conf" and have your projects depend
on "conf" in the pom.xml file.

Then there is no need for eclipse linked resource trickery, everything
is on the classpath.

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





--
Zeno Consulting, Inc.
http://www.zenoconsulting.biz
248.894.4922 phone
313.884.2977 fax

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



Re: maven-eclipse-plugin has problem with muli-project resources

2007-04-16 Thread Davis Ford

Hi, it appears that in order for eclipse to see relative path links
like this, an entry needs to be made to the .project file with the
linkeResources tag.  If you manually add a src folder in eclipse, this
is the change it makes in .project.

Is there some way to cause the maven-eclipse-plugin to do this via the pom.xml?



conf
2
D:/temp/parent/conf



On 4/17/07, Davis Ford <[EMAIL PROTECTED]> wrote:

It says: Project child is missing required source folder: 'D:/temp/parent/conf'

Try the steps to reproduce it..easy to reproduce.

I think perhaps it has more to do with the eclipse jdt core.  Can it
handle absolute paths?  I've tried editing the .classpath file
manually to make it a relative path -- I really can't seem to make it
work.  BTW: using eclipse 3.2.2.

Any ideas?

Regards,
davis

On 4/16/07, Haim Ashkenazi <[EMAIL PROTECTED]> wrote:
> Davis Ford wrote:
> [ .. ]
> > The .classpath file for the guide-ide-eclipse-site project contains this:
> >
> >  > excluding="**/*.java"/>
> >
> > This seems completely reasonable, and the directory does exist, but
> > eclipse cannot build the projectwhy?
> Hi
>
> I don't work on eclipse usually but when you open a project in eclipse and
> it can't build it it usually show you what's the problem in the "Problems"
> view (I'm not sure it's called like that). when I imported maven project
> into eclipse for the first time it showed an error that the project could
> not be built because I don't have an environment variables
> called "M2_REPOS". what is the error when you open your project?
>
> Bye
> --
> Haim
>




--
Zeno Consulting, Inc.
http://www.zenoconsulting.biz
248.894.4922 phone
313.884.2977 fax

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



Re: maven-eclipse-plugin has problem with muli-project resources

2007-04-16 Thread Davis Ford

It says: Project child is missing required source folder: 'D:/temp/parent/conf'

Try the steps to reproduce it..easy to reproduce.

I think perhaps it has more to do with the eclipse jdt core.  Can it
handle absolute paths?  I've tried editing the .classpath file
manually to make it a relative path -- I really can't seem to make it
work.  BTW: using eclipse 3.2.2.

Any ideas?

Regards,
davis

On 4/16/07, Haim Ashkenazi <[EMAIL PROTECTED]> wrote:

Davis Ford wrote:
[ .. ]
> The .classpath file for the guide-ide-eclipse-site project contains this:
>
>  excluding="**/*.java"/>
>
> This seems completely reasonable, and the directory does exist, but
> eclipse cannot build the projectwhy?
Hi

I don't work on eclipse usually but when you open a project in eclipse and
it can't build it it usually show you what's the problem in the "Problems"
view (I'm not sure it's called like that). when I imported maven project
into eclipse for the first time it showed an error that the project could
not be built because I don't have an environment variables
called "M2_REPOS". what is the error when you open your project?

Bye
--
Haim



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



maven-eclipse-plugin has problem with muli-project resources

2007-04-16 Thread Davis Ford

Hi, I posted on this earlier, but it fell on deaf ears, I guess.
Here's a concrete example of the problem I'm experiencing.  I followed
the directions for the maven-eclipse-plugin on generating a multiple
module project, as described here ->
http://maven.apache.org/plugins/maven-eclipse-plugin/reactor.html

[I tried attaching a .zip of this simple example, but it bounced]

This problem is easily reproduced.  I really welcome any clue on how
to workaround it.  How to reproduce:

1. D:\temp>mvn archetype:create -DgroupId=guide.ide.eclipse
-DartifactId=guide-ide-eclipse
2. D:\temp>cd guide-ide-eclipse
3. edit pom.xml, change jar to pom
3. D:\temp\guide-ide-eclipse>mvn archetype:create
-DgroupId=guide.ide.eclipse -DartifactId=guide-ide-eclipse-site
4. If you have the latest maven-eclipse-plugin, this should
auto-magically add the  <->  reference between parent
child projects in each respective pom.xml
5. D:\temp\guide-ide-eclipse>mkdir conf
6. D:\temp\guide-ide-eclipse>cd guide-ide-eclipse-site
7. edit the pom.xml of guide-ide-eclipse-site and add the following
between :
 

   
  ../conf
   

 
8. D:\temp\guide-ide-eclipse>cd guide-ide-eclipse-site
9. D:\temp\guide-ide-eclipse>mvn eclipse:eclipse
10. Try to import either the guide-ide-eclipse or the
guide-ide-eclipse-site project into eclipse.  You will get a build
path error regarding the conf directory.

The .classpath file for the guide-ide-eclipse-site project contains this:



This seems completely reasonable, and the directory does exist, but
eclipse cannot build the projectwhy?

Thanks in advance,

Davis

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



Re: Maven : Automate the import of generated eclipse project to the eclipse ?

2007-04-16 Thread Davis Ford

marouane - try the following:

mvn eclipse:clean eclipse:eclipse

then right-click the project in eclipse and choose refresh (or F5).  running
the mvn commands re-generates the .classpath, .project, and .settings files
in the project dir, but eclipse does not scan for changes, so you have to
force a refresh each time in the IDE.


On 4/16/07, Marouane Amraoui <[EMAIL PROTECTED]> wrote:


Thx for reply.

I generate project in the current workspace but it does'not refresh
himself.

-Message d'origine-
De: Phill Moran [mailto:[EMAIL PROTECTED]
Envoyé: lundi 16 avril 2007 19:09
À: 'Maven Users List'
Objet: RE: Maven : Automate the import of generated eclipse project to the
eclipse ?

You could execute the eclipse:eclipse using external tools but I think
(not
sure) you would have to do this in your current workspace to have it
refresh

-Original Message-
From: Marouane Amraoui [mailto:[EMAIL PROTECTED]
Sent: April 16, 2007 3:03 PM
To: Maven Users List
Subject: Maven : Automate the import of generated eclipse project to the
eclipse
?



I generate my structure of eclipse project from maven.



I make a  .bat file for that purpose. And I used it as an external tools
in
eclipse.



When I execute this bat it generate me in  the workspace of eclipse my
multiproject structure . after that I must to go to the  File --> Import
in
order to make there visible

In the eclipse. So my question there is something that can help me to
automate
this step too. ie : I execute my external tools , it generate me my
structure
project and  appear immediately

In the eclipse, don't need to import them manually  :-) ???



Maven can give me this features or I need to explore eclipse api ?



Thx



---

Merouane AMRAOUI
Consultant Expert
Division Développement
Email.: [EMAIL PROTECTED]

Gsm  .: 065 19 60 99
Tél. | Tel.: 022 98 70 70Téléc | Fax: 022 98 70 70 OMNIDATA , 74 Bv
AbdelMoumen





-
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]





--
Zeno Consulting, Inc.
http://www.zenoconsulting.biz
248.894.4922 phone
313.884.2977 fax


Re: Is there a "mvn" command to clean the local repo?

2007-04-16 Thread Davis Ford

well...you can do it the quick-n-dirty way, and just manually delete
everything under .m2/repository/com/* (or subdirs that you want to refresh)

--davis


On 4/16/07, Baz <[EMAIL PROTECTED]> wrote:


Davis,

Thanks for replying.

After I reviewed the webpage, I wonder how i can delete/refresh one
single directory... for example, "com" directory under the local repo.
There is only "exclude" but no "include".

B.

On 4/16/07, Davis Ford <[EMAIL PROTECTED]> wrote:
> http://maven.apache.org/plugins/maven-dependency-plugin/index.html
>
> see purge-local-repository goal
>
>
>
> On 4/16/07, Baz <[EMAIL PROTECTED]> wrote:
> >
> > All,
> >
> > Is there a mvn command that clean the local repo?
> >
> > Thanks.
> >
> > B.
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
> --
> Zeno Consulting, Inc.
> http://www.zenoconsulting.biz
> 248.894.4922 phone
> 313.884.2977 fax
>

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





--
Zeno Consulting, Inc.
http://www.zenoconsulting.biz
248.894.4922 phone
313.884.2977 fax


Re: Is there a "mvn" command to clean the local repo?

2007-04-16 Thread Davis Ford

http://maven.apache.org/plugins/maven-dependency-plugin/index.html

see purge-local-repository goal



On 4/16/07, Baz <[EMAIL PROTECTED]> wrote:


All,

Is there a mvn command that clean the local repo?

Thanks.

B.

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





--
Zeno Consulting, Inc.
http://www.zenoconsulting.biz
248.894.4922 phone
313.884.2977 fax


mvn eclipse plugin missing required source folder

2007-04-16 Thread Davis Ford

Hello, I have a problem getting the mvn eclipse plugin recognizing a
relative path resource directory.   Using mvn 2.0.6.  The project structure
looks like this:

editor
 subprojecta
  -pom.xml
  -src
-subprojectb
  -pom.xml
  -src
-conf
 -some.config.xml
-pom.xml

editor is a pom only project that has:


  subprojecta
  subprojectb


The pom in each subproject has this:



   
   ../conf
   
   **/*
   
   
   


This actually seems to work fine at runtime, b/c the code can load the xml
files it needs in each sub-project.  However, if I execute mvn
eclipse:eclipse, I get the build path error "Project subprojecta is missing
required source folder: 'D:\svn\editor\conf'.

Any idea on what I'm doing wrong here?

Regards,
Davis


Re: relativePath not working

2007-04-12 Thread Davis Ford

Hi Franz, that seems strange.  The jira indicates the problem when groupId
differs, but in the project I sent you, the groupId is all the same (as far
as I can tell).

Thanks for looking!

Davis


On 4/13/07, franz see <[EMAIL PROTECTED]> wrote:



Good day,

I got your email and I think I saw the bug ( see [1] ).

As for a workaround, I can't think of anything right now.

Cheers,
Franz

[1] http://jira.codehaus.org/browse/MNG-2068


franz see wrote:
>
> Good day,
>
> I just tried creating a simple project with inheritance and I cannot
> duplicate your problem. I ran mvn validate, mvn package, mvn
> compiler:compile and it builds just fine with my Maven 2.0.6, and Java
> 1.5.0_11, running under Windows XP.
>
> I've attached here that simple project, kindly check if it works in your
> machine. If it does not, then I guess it has something to do with your
> machine ( maven setup perhaps? ). If it does, then maybe there's
something
> maybe something in your maven project is causing the failure.
>
> Thanks http://www.nabble.com/file/7847/relative-path-of-parent.zip
> relative-path-of-parent.zip ,
> Franz
>
>
> Davis Ford-2 wrote:
>>
>> Hi Adrian,
>>
>> I've tried nearly everything.  Note, I'm using 2.0.6.  I tried
>>
>>   1 removing the  setting altogether
>>   2 ../pom.xml
>>   3 ../../parent_project
>>   4 ../../parent_project/pom.xml
>>   5  [absolute path here] 
>>
>> I've double-checked the artifactId, groupId, and version in all pom's
>> like
>> 100 times to make sure they match.  I've double-checked the directory
>> structure the same number of times to make sure it is right.
>>
>> If I sit in parent_project dir and execute: mvn -N install
>>
>> Then, yes, I can go into sub-dirs and run commands just fine, b/c it
>> pulls
>> the parent pom from the local repo.  This is not desired, b/c I will
have
>> to
>> tell users to execute this command everytime.  They will find it
>> confusing,
>> and it is yet another step that is easily forgotten.
>>
>> Is there *any* way to get the relativePath to work?  I've seen other
>> posts
>> in the mailing list about it...people having problems, JIRA's
filed.  Is
>> this still a known issue in 2.0.6?
>>
>> Thanks in advance,
>> Davis
>>
>>
>> On 4/12/07, Adrian Shum <[EMAIL PROTECTED]> wrote:
>>>
>>> If I remember correctly, if your parent POM is located at the parent
>>> directory, you don't need to declare the relative path, as mvn2 should
>>> be
>>> able to find it.
>>>
>>> that is, (hope I remember correctly :P ), mvn2 will find the parent
POM
>>> in
>>> the following order:
>>> 1) parent directory
>>> 2) modules in the same multi-module build
>>> 3) repository
>>>
>>> (However, in 2.0.4, there seems to be a bug prohibiting 1 from working
>>> in
>>> some scenerioes)
>>>
>>> Adrian
>>>
>>> 
>>>
>>> From: Davis Ford [mailto:[EMAIL PROTECTED]
>>> Sent: Fri 4/13/2007 8:51 AM
>>> To: Maven Users List
>>> Subject: relativePath not working
>>>
>>>
>>>
>>> Hi, I'm using mvn 2.0.6
>>>
>>> I have a simple structure
>>>
>>> parent_project
>>>sub_project
>>>   pom.xml
>>>pom.xml
>>>
>>> parent_project has this:
>>>
>>>my.org
>>>parent
>>>1.0-SNAPSHOT
>>>pom
>>>
>>> sub_project has this:
>>>
>>>
>>>my.org
>>>parent
>>>1.0-SNAPSHOT
>>>../pom.xml
>>>
>>>my.org
>>>sub
>>>pom
>>>1.0-SNAPSHOT
>>>
>>> anytime i issue any mvn command in the sub_project dir, i get:
>>> org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
>>> etc...
>>>
>>> how can i get relativePath to work?
>>>
>>> thx,
>>> davis
>>>
>>>
>>>
>>>
>>> This email is confidential. If you are not the intended recipient,
>>> please
>>> delete it from your system and notify the sender immediately. Any
>>> unauthorized use, disclosure, dissemination or copying of this email
is
>>> prohibited. Taifook Securities Group, its group companies and their
>>> content
>>> pr

q on mvn dependency plugin

2007-04-12 Thread Davis Ford

hi, i know that mvn depenendency:resolve depdendency:build-classpath will
dump a classpath list of all transitive/non-transitive jars.

i was wondering if there was some other way, either with the dependency
plugin, or with any other plugin, to generate the same output but in nicely
formatted xml:





?

Thanks,
Davis


Re: relativePath not working

2007-04-12 Thread Davis Ford

Hi Adrian,

I've tried nearly everything.  Note, I'm using 2.0.6.  I tried

 1 removing the  setting altogether
 2 ../pom.xml
 3 ../../parent_project
 4 ../../parent_project/pom.xml
 5  [absolute path here] 

I've double-checked the artifactId, groupId, and version in all pom's like
100 times to make sure they match.  I've double-checked the directory
structure the same number of times to make sure it is right.

If I sit in parent_project dir and execute: mvn -N install

Then, yes, I can go into sub-dirs and run commands just fine, b/c it pulls
the parent pom from the local repo.  This is not desired, b/c I will have to
tell users to execute this command everytime.  They will find it confusing,
and it is yet another step that is easily forgotten.

Is there *any* way to get the relativePath to work?  I've seen other posts
in the mailing list about it...people having problems, JIRA's filed.  Is
this still a known issue in 2.0.6?

Thanks in advance,
Davis


On 4/12/07, Adrian Shum <[EMAIL PROTECTED]> wrote:


If I remember correctly, if your parent POM is located at the parent
directory, you don't need to declare the relative path, as mvn2 should be
able to find it.

that is, (hope I remember correctly :P ), mvn2 will find the parent POM in
the following order:
1) parent directory
2) modules in the same multi-module build
3) repository

(However, in 2.0.4, there seems to be a bug prohibiting 1 from working in
some scenerioes)

Adrian



From: Davis Ford [mailto:[EMAIL PROTECTED]
Sent: Fri 4/13/2007 8:51 AM
To: Maven Users List
Subject: relativePath not working



Hi, I'm using mvn 2.0.6

I have a simple structure

parent_project
   sub_project
  pom.xml
   pom.xml

parent_project has this:

   my.org
   parent
   1.0-SNAPSHOT
   pom

sub_project has this:

   
   my.org
   parent
   1.0-SNAPSHOT
   ../pom.xml
   
   my.org
   sub
   pom
   1.0-SNAPSHOT

anytime i issue any mvn command in the sub_project dir, i get:
org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
etc...

how can i get relativePath to work?

thx,
davis




This email is confidential. If you are not the intended recipient, please
delete it from your system and notify the sender immediately. Any
unauthorized use, disclosure, dissemination or copying of this email is
prohibited. Taifook Securities Group, its group companies and their content
providers ("Parties") shall not be responsible for the accuracy or
completeness of this email or its attachment, if any, which could contain
virus, be corrupted, destroyed, incomplete, intercepted, lost or arrive
late.   The Parties do not accept liability for any damage caused by this
email.



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





--
Zeno Consulting, Inc.
http://www.zenoconsulting.biz
248.894.4922 phone
313.884.2977 fax


relativePath not working

2007-04-12 Thread Davis Ford

Hi, I'm using mvn 2.0.6

I have a simple structure

parent_project
   sub_project
  pom.xml
   pom.xml

parent_project has this:

   my.org
   parent
   1.0-SNAPSHOT
   pom

sub_project has this:

   
   my.org
   parent
   1.0-SNAPSHOT
   ../pom.xml
   
   my.org
   sub
   pom
   1.0-SNAPSHOT

anytime i issue any mvn command in the sub_project dir, i get:
org.apache.maven.reactor.MavenExecutionException: Cannot find parent: etc...

how can i get relativePath to work?

thx,
davis


Re: IsolatedClassLoader -> URL with spaces %20 problem

2007-02-19 Thread Davis Ford

Almost forgot...not that this is too interesting, but the test case below
calls a method getJarURLFromURLEntry( ) -- this method is from
org.hibernate.ejb.packaging.JarVisitor.java, and it looks like this:

public static final URL getJarURLFromURLEntry(URL url, String entry) throws
IllegalArgumentException {
   URL jarUrl;
   String file = url.getFile();
   if ( ! entry.startsWith( "/" ) ) entry = "/" + entry;
   file = file.substring( 0, file.length() - entry.length() );
   if ( file.endsWith( "!" ) ) file = file.substring( 0, file.length() - 1
);
   try {
   String protocol = url.getProtocol();

   if ( "jar".equals( protocol )
   || "wsjar".equals( protocol ) ) { //Websphere has it's own
way
   jarUrl = new URL( file );
   }
   else if ( "zip".equals( protocol ) ) { //Weblogic has it's own way
   //we have extracted the zip file, so it should be read as a file
   jarUrl = new URL( "file", null, file );
   }
   else if ("code-source".equals( url.getProtocol() ) ) {
   //OC4J prevent ejb.jar access (ie everything without path
   //fix contributed by the community
   jarUrl = new File(file).toURL();
   }
   else {
   jarUrl = new URL( protocol, url.getHost(), url.getPort(), file
);
   }
   }
   catch (MalformedURLException e) {
   throw new IllegalArgumentException(
   "Unable to determine JAR Url from " + url + ". Cause: " +
e.getMessage()
   );
   }
   return jarUrl;
}

On 2/19/07, Davis Ford <[EMAIL PROTECTED]> wrote:


He, we're using maven 2.0.4 (although I just tried 2.0.5 and the same
problem exists), and we're using Hibernate Entity Manager 3.2.1-ga, and
we're on a Windows Platform.  These 3 things don't seem to work together.

The problem is the default repo for maven jars contains spaces on windows
C:\Documents and Settings\etc.

Hibernate Entity Manager expects to find META-INF\persistence.xml on the
classpath.  The general idea is to bury this in a jar that is loaded as a
dependency on our maven repo classpath, right?

Hibernate has code similar to this in
org.hibernate.ejb.EjbConfiguration.java (I added logger and assertions):

try {
Enumeration xmls = Thread.currentThread()
.getContextClassLoader()
.getResources( "META-INF/persistence.xml" );

if ( ! xmls.hasMoreElements() ) {
fail( "Could not find any META-INF/persistence.xml file in the
classpath");
}
while ( xmls.hasMoreElements() ) {
URL url = xmls.nextElement();
LOGGER.debug( "Analyse of persistence.xml: " + url );
URL jarURL = getJarURLFromURLEntry( url,
"/META-INF/persistence.xml" );
assertFalse("Jar URL should not contain spaces, "+jarURL,
jarURL.toString().contains(" "));
}

1. Create a jar-file, install it in local maven repo.
2. Add META-INF\persistence.xml to the jar file
3. Add a dependency to a new maven test project
4. Paste in code like above -- test case will always fail when it tests
for whitespace in the url.

System.out.println(Thread.currentThread().getContextClassLoader().getClass().getCanonicalName());


prints

org.apache.maven.surefire.booter.IsolatedClassLoader

If I run from Eclipse, I have no problems, and the above println prints
instead:

sun.misc.Launcher.AppClassLoader

I am *desperate* for any kind of solution to this problem that does not
require me to change the local maven repo to a url without spaces.

I need the URLClassLoader (IsolatedClassLoader) to correctly deal with
whitespace and replace it with %20.  If there is some other workaround --
please let me know.  Hibernate ends up throwing an exception and returning
null for the EntityManager which is an absolute show-stopper for us.

Thank you in advance,

Davis








--
Zeno Consulting, Inc.
http://www.zenoconsulting.biz
248.894.4922 phone
313.884.2977 fax


IsolatedClassLoader -> URL with spaces %20 problem

2007-02-19 Thread Davis Ford

He, we're using maven 2.0.4 (although I just tried 2.0.5 and the same
problem exists), and we're using Hibernate Entity Manager 3.2.1-ga, and
we're on a Windows Platform.  These 3 things don't seem to work together.

The problem is the default repo for maven jars contains spaces on windows
C:\Documents and Settings\etc.

Hibernate Entity Manager expects to find META-INF\persistence.xml on the
classpath.  The general idea is to bury this in a jar that is loaded as a
dependency on our maven repo classpath, right?

Hibernate has code similar to this in
org.hibernate.ejb.EjbConfiguration.java (I added logger and assertions):

try {
   Enumeration xmls = Thread.currentThread()
   .getContextClassLoader()
   .getResources( "META-INF/persistence.xml" );

   if ( ! xmls.hasMoreElements() ) {
   fail( "Could not find any META-INF/persistence.xml file in the
classpath");
   }
   while ( xmls.hasMoreElements() ) {
   URL url = xmls.nextElement();
   LOGGER.debug( "Analyse of persistence.xml: " + url );
   URL jarURL = getJarURLFromURLEntry( url, "/META-INF/persistence.xml"
);
   assertFalse("Jar URL should not contain spaces, "+jarURL,
jarURL.toString().contains(" "));
   }

1. Create a jar-file, install it in local maven repo.
2. Add META-INF\persistence.xml to the jar file
3. Add a dependency to a new maven test project
4. Paste in code like above -- test case will always fail when it tests for
whitespace in the url.

System.out.println(Thread.currentThread
().getContextClassLoader().getClass().getCanonicalName());

prints

org.apache.maven.surefire.booter.IsolatedClassLoader

If I run from Eclipse, I have no problems, and the above println prints
instead:

sun.misc.Launcher.AppClassLoader

I am *desperate* for any kind of solution to this problem that does not
require me to change the local maven repo to a url without spaces.

I need the URLClassLoader (IsolatedClassLoader) to correctly deal with
whitespace and replace it with %20.  If there is some other workaround --
please let me know.  Hibernate ends up throwing an exception and returning
null for the EntityManager which is an absolute show-stopper for us.

Thank you in advance,

Davis


Re: plexus compiler issues with annotations

2007-02-09 Thread davis

Hi Eric, thanks for pointing that out.  Unfortunately that is just my typo in
trying to express the post.  The real file does not have that comma.  This
really is an issue with mvn plexus compiler.  It's simple to reproduce, just
try it in a blank new maven project with package-info.java the only file
with an annotation like that (w/o the comma).

I'd file a JIRA issue if I knew how.

I wish there was a fix for this b/c it is really a problem for me.  If
anyone has a fix, let me know.

Regards,
Davis


Eric Redmond wrote:
> 
> Remove the last comma before the "})" tokens.
> 
> Eric
> 
> On 2/8/07, David Ford <[EMAIL PROTECTED]> wrote:
>>
>> Hi, I'm doing a hibernate project where we set up a package-info.java
>> file that looks like this
>>
>>
>>
>> @org.hibernate.annotations.NamedQueries( {
>>
>>
>>
>>   @org.hibernate.annotations.NamedQuery(name = "someQuery", query =
>> "from User u"),
>>
>> })
>>
>> package some.package;
>>
>>
>>
>> The annotation is at the top, the package declaration is at the bottom.
>>
>>
>>
>> Unfortunately, plexus-compiler-javac croaks when trying to parse this.
>> I just tried 1.6-SNAPSHOT and it still has the problem...
>>
>>
>>
>> [parsing started
>> C:\SVN\diamond\orm-tracer\src\main\java\com\teleatlas\global\orm\domain\
>> package-info.java]
>>
>> C:\SVN\diamond\orm-tracer\src\main\java\com\teleatlas\global\orm\domain\
>> package-info.java:116: illegal start of expression
>>
>> })
>>
>> ^
>>
>>
>>
>> However, this works fine in Eclipse, and so I tried
>> plexus-compiler-eclipse.  With that, I get by the parsing issue above,
>> but I get a build failure b/c it cannot seem to find any of my domain
>> classes.
>>
>>
>>
>> I've yet to find any documentation on how to configure
>> plexus-compiler-eclipse.  I tried giving it 1.5 and
>> 1.5 but still no luck.
>>
>>
>>
>> Has anyone else run into this - and have they found a workaround???
>>
>>
>>
>> Thx in advance,
>>
>> Davis
>>
>>
>>
>> PS - can you please cc me on a reply
>>
>>
>>
>>
> 
> 
> -- 
> Eric Redmond
> http://codehaus.org/~eredmond
> 
> 

-- 
View this message in context: 
http://www.nabble.com/plexus-compiler-issues-with-annotations-tf3197100s177.html#a8883224
Sent from the Maven - Users mailing list archive at Nabble.com.


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



mvn and JUnit 4.1

2006-12-07 Thread Davis Ford

Hi, we use JUnit 4.1 in eclipse, but when we run the tests from the
cmd line with mvn, it seems to fail and not use JUnit 4.1 but it uses
the old 3.8.1.

Is there some way to force mvn to use JUnit 4.1?

The mvn release is 2.0.4 we are using.

Thanks in advance,
Davis

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



Re: clear separation of source and target

2006-10-18 Thread Brad Davis

solo turn wrote:

is it possible to do that by:
* configuring maven to put generated files somewhere out of this 
directory, or
This really depends on how you're generating things.  In my instance I'm 
using maven to call ant to call XJC and generate code from a schema.  
This ends up going into a src/generated/java source folder, but that's 
configured in the XJC task, and I would imagine its going to be the same 
for other code generation tools.  You tell the tool where you want it 
and assume that the pom location is going to be the root for any 
relative path.

* configuring the source code control by excluding a directory resp a
fixed set of directories
?
Again, this is system dependent.  We use CVS where I work and so 
excluding something from source control is a matter of adding it to the 
.cvsignore file, thus telling source control tools not to include the 
generated files when syncing with source control.  This is going to be a 
part of the source control system though, not maven.


Brad



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



m2 javadoc report plugin?

2006-06-15 Thread Davis Ford

Hi, with maven 1.x I used to be able to create javadoc reports (i.e.
tag violation warnings, etc.)

Now that we have moved to maven 2.0.4, I can't seem to figure out how
to do that.

The maven javadoc plugin
http://maven.apache.org/plugins/maven-javadoc-plugin for m2 does not
describe this capability.

Anyone know how it can be done?

Thx,
Davis

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



Re: Maven 2 sources/javadocs installation question

2006-06-09 Thread Brad Davis
Because the eclipse plugin doesn't properly set up intra project 
relationships it would be nice to have an explicit build step that could 
generate and deploy javadoc and source jars, even for snapshot releases.


Brad


- Original Message - 
From: "Stephen Duncan" <[EMAIL PROTECTED]>

To: "Maven Users List" 
Sent: Friday, June 09, 2006 6:11 PM
Subject: Re: Maven 2 sources/javadocs installation question



You can simply run mvn -DperformRelease=true install

This will build source & javadoc jars & install them.  No configuration 
option.


-Stephen

On 6/9/06, Matt Wheeler <[EMAIL PROTECTED]> wrote:



Never mind my last email.  I moved the plugin under build outside of
profiles and added a package phase, and it works now.


Matt W.

--


NOTICE: This email message is for the sole use of the
 intended recipient(s) and may contain confidential and
 privileged information. Any unauthorized review, use,
 disclosure or distribution is prohibited. If you are not the
 intended recipient, please contact the sender by reply email
 and destroy all copies of the original message.




--





-- Forwarded message --
From: "Matt Wheeler" <[EMAIL PROTECTED]>
To: users@maven.apache.org
Date: Fri, 09 Jun 2006 09:45:29 -0600
Subject: Maven 2 sources/javadocs installation question


I have a project that I run install on to install the project and all of 
its
sub project's main artifacts in the local repository.  However, I would 
also
like to "automatically" install the sources and the javadocs as well.  I 
can
generate these using sources:jar and javadoc:jar commands, however, I 
cannot
get them to be automatically generated using the profile section in the 
pom

that is shown in the documentation under "Introduction to the POM" at
http://maven.apache.org/guides/introduction/introduction-to-the-pom.html.
 What would I need to do to make that example work?

Also, even if I coudl get the profile to generate the source and javadoc
jars, I am not sure how to install them.  I assume that I could use
install:install-file, but I woudl really like a more automated way if 
there

is one.  I have tried to install them manually, but the problem is that I
can't get it to install in the same directory as the projects main 
artifact.

 For instance, say my project artifact is in
.m2/repository/org/whatever/2.0-SNAPSHOT/stack-code-2.0-SNAPSHOT.jar.
 Well, if I then run a commond something like:

mvn install:install-file -DartifactId=stack-code -DgroupId=org.lds.stack
-Dpackaging=jar -Dversion=2.0-SNAPSHOT
-Dfile=D:/Projects/Stack/stack-code/target/stack-code-2.0-SNAPSHOT-sources.jar

Then, it overwrites the projects main artifact 
stack-code-2.0-SNAPSHOT.jar.

However, if I change the version to 2.0-SNAPSHOT-sources, then it put the
jar (this time with the correct name stack-code-2.0-SNAPSHOT-sources) out 
in
the repository, but under a 2.0-SNAPSHOT-sources directory instead of 
under
the 2.0-SNAPSHOT directory with the main artifact.  I am am seeing 
sources
placed correctly on ibiblio however, so I am just wondering what I am 
doing

wrong, or if there is an easier way to accomplish this?

Thanks,

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





--
Stephen Duncan Jr
www.stephenduncanjr.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]



Re: time-constrained repository instability

2006-05-19 Thread Brad Davis
I have to agree that public repositories should essentially be 
write-once media.  As Maven grows in popularity, the repositories are 
going to need to be stable and artifact deployment will need to become 
an atomic operation. 


Brad


Orjan Austvold wrote:

During the last 8-10 months we have experienced several updates in 
already released artifacts in the maven repository at Ibiblio. Many of 
these has been caused by reports to Maven evangelism.


For us this has been extremely problematic since the time of download 
of dependencies causes developers to have different POMs in their 
local repository. For us this has caused our projects to produce 
different builds dependent on which developer made the build and at 
which time the build was made.


Personally I strongly believe in once an artifact has been released -- 
with or without errors in the artifacts POM -- it should be left in 
the state it's in. If a change is required due to a malformed POM, a 
missing groupId, non-existing parent, missing dependency, wrong scope 
of a dependency or the alike, it should be left in the state it is in. 
If an update is required a new version should be released.


Due to the instability of released artifacts at Ibiblio we are now 
considering setting up our own repository (not a mirror and not a 
maven-proxy repository) to gain complete control over changes in 
released POMs. Of course this is not the intention of Maven 2.


Please comment.



Thanks,
Ørjan Austvold


-
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]



surefire 2.2

2006-05-18 Thread Davis Ford

Hi just wondering if the group has experimented with the new surefire
2.2 plugin release, and if it does indeed solve the GC issue Brett
indicates below.  We are seeing this issue, and looking to update the
plugin, but getting by with feeding arguments to the jvm for now.

Regards,
Davis



FYI, the upcoming 2.2 release of surefire will reduce the memory used
by allowing the test cases to be garbage collected after they've run
instead of at the end. It also enables assertions by default, whether
you are forking or not, by setting the flag on the classloader running
the tests.

- Brett


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



Maven Repository Manager (MRM) home page

2006-05-18 Thread Brad Davis
I was reading in the Maven2 book about the Maven Repository Manager, 
which sounds like an upgraded Maven Proxy with a better UI and more 
flexibility.  Great idea, but clearly not there yet.  Still, since 
there's a URL in the book for the item, shouldn't there at least be a 
placeholder page on the maven site, as opposed to a '404' equivalent page?



Brad


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



Re: Relative to content-type, Is their convention for the file in the repository?

2006-05-18 Thread Brad Davis
I couldn't find anything relating to 'digest', 'hash', 'md5' or 'sha1' 
at http://www.iana.org/assignments/media-types/ so I'd say text/plain.  
Indeed some places encode these hashes as base64 and some as hex, so it 
seems pretty lax.


Brad




Wayne Fay wrote:


pom = text/xml  (its just an XML file... I suppose you could use
application/pom if you really wanted, but that seems excessive to me)

xml = text/xml   (this is widely used and seems "standard")

md5 & sha1 = not so sure, but I imagine someone at IETF or W3C has
come up with some proposal to specify these Content-Types, so if you
Google and find it, report back.

Wayne

On 5/17/06, Paul Spencer <[EMAIL PROTECTED]> wrote:


Relative to content-type, Is their convention for the file in the
repository?

File   Suggested
Extension  Content-type
- --
*.jar  application/java-archive
*.pom  ?
*.xml  ?
*.md5  ?
*.sha1 ?

Granted the content type is set in the web server, documenting this will
be helpful to anyone setting up an maven repository.  I assume this is
also true for maven-proxy


Paul Spencer

-
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: Internal remote repository setup in Maven 2

2006-05-18 Thread Brad Davis

Gustavo Valle wrote:


 
   
 central
 http://localhost:8080/maven
   
 

 
   
 central
 http://localhost:8080/maven
   
 
 

I believe by doing this you are overriding the default location for the 
central repository, and forcing maven to look for everything on 
localhost.  This won't work because it will fail to find its plugins 
there unless youve primed it already. 

What you want, from what you've described is a web app that will act as 
a caching Maven repository.  Maven won't do this itself.  If you 
override the central repository then the override location(s) are the 
only places maven will look for artifacts. 

The solution is Maven Proxy from codehaus.  When you request an artifact 
from Maven Proxy, it looks at a local (to it) repository and serves it 
from there, or if it can't, goes to an actual remote repository to fetch 
it.  Sadly, the site is down currently, and likely till the end of the 
week.  The google cache of the main page is here:  
http://66.102.7.104/search?q=cache:zfDNHXmX7sIJ:maven-proxy.codehaus.org/+maven+proxy+site:codehaus.org&hl=en&lr=&client=firefox-a&strip=1


Personally I recommend using an installed copy of Maven Proxy as a 
mirror for central (specified either in your POM or your settings.xml) 
and using a seperate internal repository for internally developed projects.


Brad

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



Re: repo down?

2006-05-17 Thread Brad Davis
Doesn't the Release plugin actually do this with the prepare phase?  
Determine that you don't depend on any SNAPSHOT items?  Or does the 
maven build not depend on the plugins, so this doesn't work?  In fact, I 
guess the plugins would depend on Maven itself.  How do you address 
eliminating that kind of circular dependency?


Brad


Mark Diggory wrote:

You can't if its the first time you've run maven, anyone trying to  
use maven for the first time can't get the proper plugins because its  
looking for Snapshots on codehaus. Seems if your going to do a full  
release of maven it would be wise to base it on full releases of the  
plugins in the mirrors, or at least a full release of maven and/or  
any plugin maintained and required by maven should be full released  
and often, then this sort of thing wouldn't happen. Look at Eclipse  
and the way they organize thier updates into "integration", "stable"  
and "release" builds.


For instance, EMF has a interim and stable update sites. This is one  
of the reasons I really pushed to have separate snapshot and release  
repositories at Apache, "product stability".


-Mark

p.s. there was a comment I should set up  a mirror or something crazy  
like that, it assumes I have some extensive knowledge of maven, which  
at this point with maven 2 I don't. While I understand you guys do  
allot of development and are focused on new features and bug fixes,  
it makes your product look bad to have single points of failure like  
this, I'm evaluating maven 2 for a project I'm now working on, this  
doesn't bode well in my evaluation.



On May 16, 2006, at 8:25 AM, javed mandary wrote:


You can use the -o flag ,
e.g mvn -o install

this will tell maven to work in offline mode and it wont try to  
check for

updates on the remote repo.

cheers,
 javed

On 5/15/06, Markus Reinhardt <[EMAIL PROTECTED]>  
wrote:




 Am Montag, den 15.05.2006, 11:20 +0200 schrieb Jörg Schaible:

Geoffrey De Smet wrote on Monday, May 15, 2006 10:26 AM:
> Ibiblio is up, but the dns server of maven.org seems to be  down.> 
> Brett Porter wrote:>> http://maven.apache.org/guides/mini/ 
guide-mirror-settings.html>> >> Yes, it's down. Unscheduled, and  
beyond our control, sorry.
But, since the new plugin releases refer to artifacts only  
available in snapshots.maven.codehaus.org/maven2, our complete  
development comes to a sudden stop, because of the automated  
update. Please, make sure for such releases, that all artifacts  are 
available at ibiblio (which is at least mirrored).


Who do I to tell maven not to search for updates? Neither -o nor -npu
switches help. All needed plugins (tomcat-maven-plugin:pom:1.0- 
SNAPSHOT)

are located in my local repo.

Markus Reinhardt

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.3 (GNU/Linux)

iD8DBQBEaEpxTPqyj/tXZEMRAowGAKCfn8AEqNqeA/EVm66Fv53SO9PD6gCgtCzW
gzcI00BTuqBtvCIYuKuP8BA=
=lMx0
-END PGP SIGNATURE-






-
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]



Feature suggestion, was 'Re: repo down?'

2006-05-17 Thread Brad Davis
It strikes me that centralized repositories, even with mirrors is a 
potential scalability problem and point of failure.  Its also a point of 
failure since the more projects use Maven, the more administration has 
to be done to allow Project X, Y, or Z access to publish updates to the 
repo. 

Why not leverage DNS to allow projects to publish to project specific 
repositories?  This would require that the group ID be convertible into 
some sort of DNS resolvable name in a consistent manner, but that's 
nearly the case for many projects already.  Here's how it would work...


As a client, Maven could look at the group ID of say 
org.apache.maven.plugins.  It could do DNS TXT record lookups on 
plugins.maven.apahche.org, then maven.apache.org and then apache.org 
looking for repository information (encoded via some convention in the 
TXT record).  The centralized repository structure could continue to be 
used as a fallback for projects whose group ID can't conform to a DNS 
resolvable address, or who don't have control over their DNS servers at 
that level. 

As a project owner, once the DNS support is there, publishing a new 
version of my artifcats to Maven no longer requires coordination with 
another party.  In fact, publishing to Central changes from a push model 
to a pull model.  A one time agreement to publish items from a given 
group ID means that the central server can now monitor for changes on 
the project specific repositories. 


My 2 cents.

Brad


Brett Porter wrote:


http://maven.apache.org/guides/mini/guide-mirror-settings.html

Yes, it's down. Unscheduled, and beyond our control, sorry.

- Brett

On 5/14/06, Raymond Ritz <[EMAIL PROTECTED]> wrote:


Hey all, is http://repo1.maven.org   down
unexpectedly? If this is a scheduled outage, where can I get 
information on

planned downtime in the future?



Regards,



Raymond Ritz







-
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]



wagon-ftp cannot be downloaded

2006-05-17 Thread Davis Ford

Hi, we use ftp to deploy to our local repo.  As a litmus test for the
environment, I completely wiped out my .m2/repository/*

Then I tried to do a mvn test on one of my projects.  This project has
a parent pom.xml which has:




org.apache.maven.wagon
wagon-ftp
1.0-alpha-6


etc...

But I get the error

Project ID: org.apache.maven.wagon:wagon-ftp

Reason: Error getting POM for 'org.apache.maven.wagon:wagon-ftp' from
the repository: Error transferring file
 org.apache.maven.wagon:wagon-ftp:pom:1.0-alpha-6

from the specified remote repositories:
 central (http://repo1.maven.org/maven2),
 maven-fast-repo (http://repo1.maven.org),

If I do a deploy first, then this seems to work.  But if I try a
compile or test, this always fails?  How to fix this?

Regards,
Davis

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



Central repo slow -- hangs often

2006-05-17 Thread Davis Ford

Hi, it seems getting to the central repo and downloading dependencies
often hangs for me, and i have to restart the process again and again.

I understand the intermittency of network issues, but is there any
recommended solution for this?

I added:


 etc.


a whole bunch of mirrors to my settings.xml, but that does not seem to
alleviate the problem.

Concrete example.  I've tried to d/l

http://www.ibiblio.net/pub/packages/maven2/pcj/pcj/1.2/pcj-1.2.jar

about 5 times now.  Each time it gets to 480/2699K and hangs -- I've
left it hanging for about 10 min. now.

Any ideas?

Thanks in advance,
Davis

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



Re: mvn eclipse:plugin and project inheritance

2006-05-17 Thread Davis Ford

yes, that is the way it is currently set up

On 5/17/06, Taavi Sildeberg <[EMAIL PROTECTED]> wrote:

Hello David,

Do you have inside a module A and s module B parent defined?
Something like this:


 your parent groupid
 your parent artifact id 
 your parent version
   

Taavi

Davis Ford wrote:
> Hi, I have a parent pom.xml project in C:\someplace\pom.xml that has
>
> moduleA
> moduleB
>
> Then I have
>
> C:\someplace\moduleA\pom.xml
> C:\someplace\moduleB\pom.xml
>
> If I execute:
>
> C:\someplace\>mvn clean
> C:\someplace\>mvn compile
> C:\someplace\>mvn test
>
> That works great for moduleA, moduleB
>
> If I execute:
>
> C:\someplace\moduleA\mvn eclipse:eclipse
> C:\someplace\moduleB\mvn eclipse:eclipse
>
> That works great to create eclipse projects for moduleA, moduleB
>
> If I execute:
>
> C:\someplace\mvn eclipse:eclipse
>
> This causes a problem.  If I refresh moduleA, moduleB projects in
> eclipse after doing so, they complain about not finding the other
> subprojects.
>
> What is the best-practice here?  Is there a workaround for this?
>
> Thanks in advance,
> Davis
>
> -
> 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]





--
Zeno Consulting, Inc.
(248) 894-4922 (p)
(206) 202-4077 (f)

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



Re: SNAPSHOT question

2006-05-16 Thread Davis Ford

Wayne - as a matter of principle, I totally agree with you there.
Thanks...it has been a long day.  I was trying to illustrate an
example -- albeit not very wellbut what you say makes total sense.

On 5/16/06, Wayne Fay <[EMAIL PROTECTED]> wrote:

I (personally) think you might want to review your building and
tagging approach...

1.0-SNAPSHOT is "before" 1.0
1.3 is "never" built until after 1.0 is final
Once we build 1.3, the next build would be 1.4-SNAPSHOT
My "deploy" process would be: check out code, change from 1.3-SNAPSHOT
to 1.3, check in, tag with build-1.3, then build and deploy

If you have some grand plan that you're working towards, and this does
not apply or make sense for your organization or your SCM, then you
can safely ignore it. But it just sounds like your SNAPSHOT versioning
plan etc might be a little "off" from the "traditional" approach...

Wayne

On 5/16/06, Davis Ford <[EMAIL PROTECTED]> wrote:
> We are using a horrible tool called MKS Source Integrity.  Believe you
> me -- I have opined for SVN many times.
>
> Building an SCM plugin is not gonna happen soon enough to solve our needs.
>
> So, unless someone on the list has any other insight, it appears the
> only way for a team/developer to do a release of a module is to
> manually edit 
>
> FROM: 1.0-SNAPSHOT
> TO: 1.3
>
> C:\myproject>mvn deploy
>
> Then, manually change it back or ensure that the pom.xml does not get
> checked in with 1.3.  I want to have 1.0-SNAPSHOT checked into version
> control, so our nightly build will do the following:
>
> 1) suck out the latest from this MKS thing
> 2) do a deploy (to the snapshot repo)
> 3) run all integration tests
>
>
>
> On 5/16/06, Wayne Fay <[EMAIL PROTECTED]> wrote:
> > I'd install SVN. ;-)
> >
> > No really, I'm not aware of any way to utilize the release plugin
> > without an SCM. So you'll probably need to build an SCM plugin for
> > your specific SCM tool and integrate it into M2 to properly use the
> > release plugin. Or write a new plugin that works similar to release
> > but does not do the SCM steps first.
> >
> > What are you using, if not CVS or SVN? Starteam? Clear ?
> >
> > Wayne
> >
> > On 5/16/06, Davis Ford <[EMAIL PROTECTED]> wrote:
> > > Hi Wayne,
> > >
> > > I looked at mvn release, but it seems tied to SCM system.
> > > Unfortunately, we don't use svn or cvs -- and I have no clue how to
> > > integrate it with the thing we are using (I really wish we were using
> > > svn).
> > >
> > > Is there a simple example of using "mvn release" that does not depend
> > > on the scm system?
> > >
> > > Thx,
> > > Davis
> > >
> > > On 5/16/06, Wayne Fay <[EMAIL PROTECTED]> wrote:
> > > > You're looking for "mvn release" not deploy. Release will update the
> > > >  tags and install the artifact properly in the specified
> > > > repositories.
> > > >
> > > > However its a little more complex than simply "mvn release" so check
> > > > out the m2 book (better builds with maven), the user list archive, the
> > > > maven website, etc for details.
> > > >
> > > > Wayne
> > > >
> > > > On 5/16/06, Davis Ford <[EMAIL PROTECTED]> wrote:
> > > > > Hi, if I have pom.xml for a project that has
> > > > >
> > > > > 1.0-SNAPSHOT
> > > > >
> > > > > and I do:
> > > > >
> > > > > mvn deploy
> > > > >
> > > > > It sends up a release with the timestamp in the 1.0-SNAPSHOT/ dir.
> > > > >
> > > > > However, what if a developer wants to do a release, not a snapshot?
> > > > >
> > > > > If I try
> > > > >
> > > > > mvn -Dversion=1.2 deploy
> > > > >
> > > > > It uploads a new SNAPSHOT with a timestamp into the 1.0-SNAPSHOT dir.
> > > > >
> > > > > Is there some way to override this?
> > > > >
> > > > > -
> > > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > > >
> > > > >
> > > >
> > > > -
> > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
&

Re: SNAPSHOT question

2006-05-16 Thread Davis Ford

We are using a horrible tool called MKS Source Integrity.  Believe you
me -- I have opined for SVN many times.

Building an SCM plugin is not gonna happen soon enough to solve our needs.

So, unless someone on the list has any other insight, it appears the
only way for a team/developer to do a release of a module is to
manually edit 

FROM: 1.0-SNAPSHOT
TO: 1.3

C:\myproject>mvn deploy

Then, manually change it back or ensure that the pom.xml does not get
checked in with 1.3.  I want to have 1.0-SNAPSHOT checked into version
control, so our nightly build will do the following:

1) suck out the latest from this MKS thing
2) do a deploy (to the snapshot repo)
3) run all integration tests



On 5/16/06, Wayne Fay <[EMAIL PROTECTED]> wrote:

I'd install SVN. ;-)

No really, I'm not aware of any way to utilize the release plugin
without an SCM. So you'll probably need to build an SCM plugin for
your specific SCM tool and integrate it into M2 to properly use the
release plugin. Or write a new plugin that works similar to release
but does not do the SCM steps first.

What are you using, if not CVS or SVN? Starteam? Clear ?

Wayne

On 5/16/06, Davis Ford <[EMAIL PROTECTED]> wrote:
> Hi Wayne,
>
> I looked at mvn release, but it seems tied to SCM system.
> Unfortunately, we don't use svn or cvs -- and I have no clue how to
> integrate it with the thing we are using (I really wish we were using
> svn).
>
> Is there a simple example of using "mvn release" that does not depend
> on the scm system?
>
> Thx,
> Davis
>
> On 5/16/06, Wayne Fay <[EMAIL PROTECTED]> wrote:
> > You're looking for "mvn release" not deploy. Release will update the
> >  tags and install the artifact properly in the specified
> > repositories.
> >
> > However its a little more complex than simply "mvn release" so check
> > out the m2 book (better builds with maven), the user list archive, the
> > maven website, etc for details.
> >
> > Wayne
> >
> > On 5/16/06, Davis Ford <[EMAIL PROTECTED]> wrote:
> > > Hi, if I have pom.xml for a project that has
> > >
> > > 1.0-SNAPSHOT
> > >
> > > and I do:
> > >
> > > mvn deploy
> > >
> > > It sends up a release with the timestamp in the 1.0-SNAPSHOT/ dir.
> > >
> > > However, what if a developer wants to do a release, not a snapshot?
> > >
> > > If I try
> > >
> > > mvn -Dversion=1.2 deploy
> > >
> > > It uploads a new SNAPSHOT with a timestamp into the 1.0-SNAPSHOT dir.
> > >
> > > Is there some way to override this?
> > >
> > > -
> > > 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]
> >
> >
>
>
> --
> Zeno Consulting, Inc.
> (248) 894-4922 (p)
> (206) 202-4077 (f)
>
> -
> 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]





--
Zeno Consulting, Inc.
(248) 894-4922 (p)
(206) 202-4077 (f)

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



Re: SNAPSHOT question

2006-05-16 Thread Davis Ford

Hi Wayne,

I looked at mvn release, but it seems tied to SCM system.
Unfortunately, we don't use svn or cvs -- and I have no clue how to
integrate it with the thing we are using (I really wish we were using
svn).

Is there a simple example of using "mvn release" that does not depend
on the scm system?

Thx,
Davis

On 5/16/06, Wayne Fay <[EMAIL PROTECTED]> wrote:

You're looking for "mvn release" not deploy. Release will update the
 tags and install the artifact properly in the specified
repositories.

However its a little more complex than simply "mvn release" so check
out the m2 book (better builds with maven), the user list archive, the
maven website, etc for details.

Wayne

On 5/16/06, Davis Ford <[EMAIL PROTECTED]> wrote:
> Hi, if I have pom.xml for a project that has
>
> 1.0-SNAPSHOT
>
> and I do:
>
> mvn deploy
>
> It sends up a release with the timestamp in the 1.0-SNAPSHOT/ dir.
>
> However, what if a developer wants to do a release, not a snapshot?
>
> If I try
>
> mvn -Dversion=1.2 deploy
>
> It uploads a new SNAPSHOT with a timestamp into the 1.0-SNAPSHOT dir.
>
> Is there some way to override this?
>
> -
> 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]





--
Zeno Consulting, Inc.
(248) 894-4922 (p)
(206) 202-4077 (f)

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



SNAPSHOT question

2006-05-16 Thread Davis Ford

Hi, if I have pom.xml for a project that has

1.0-SNAPSHOT

and I do:

mvn deploy

It sends up a release with the timestamp in the 1.0-SNAPSHOT/ dir.

However, what if a developer wants to do a release, not a snapshot?

If I try

mvn -Dversion=1.2 deploy

It uploads a new SNAPSHOT with a timestamp into the 1.0-SNAPSHOT dir.

Is there some way to override this?

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



mvn eclipse:plugin and project inheritance

2006-05-16 Thread Davis Ford

Hi, I have a parent pom.xml project in C:\someplace\pom.xml that has

moduleA
moduleB

Then I have

C:\someplace\moduleA\pom.xml
C:\someplace\moduleB\pom.xml

If I execute:

C:\someplace\>mvn clean
C:\someplace\>mvn compile
C:\someplace\>mvn test

That works great for moduleA, moduleB

If I execute:

C:\someplace\moduleA\mvn eclipse:eclipse
C:\someplace\moduleB\mvn eclipse:eclipse

That works great to create eclipse projects for moduleA, moduleB

If I execute:

C:\someplace\mvn eclipse:eclipse

This causes a problem.  If I refresh moduleA, moduleB projects in
eclipse after doing so, they complain about not finding the other
subprojects.

What is the best-practice here?  Is there a workaround for this?

Thanks in advance,
Davis

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



Re: Ad Hoc Maven BOF at JavaOne

2006-05-15 Thread Brad Davis

Any news on this?

Jason van Zyl wrote:

Not certain time yet, but a few people are trying to get some space  
together. Worst case scenerio is that we work something out when  
we're all there.


jason.

On 10 May 06, at 8:49 PM 10 May 06, Wendy Smoak wrote:


On 5/10/06, Jason van Zyl <[EMAIL PROTECTED]> wrote:


If any Maven users are going to be at JavaOne and want to have an
informal BOF let me know. Sun didn't give us any official slots this
year so we would have to do something on our own. I'm going to be
there anyway ... so:

http://blogs.codehaus.org/projects/maven/archives/ 
001367_maven_at_javaone.html



This sounds great.  Any idea yet on a day and time?

--
Wendy

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




Jason van Zyl
[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]



Maven 2 Emma Plugin?

2006-05-15 Thread Davis Ford

Hi, we used to use the maven-emma plugin and maven 1.* but have just
upgraded to maven 2.0.4.

If I put a dependency on emma like this:


emma
maven-emma-plugin
0.5


I get this:

Downloading: 
http://www.ibiblio.org/maven2//emma/maven-emma-plugin/0.5/maven-emma-plugin-0.5.pom
993b downloaded
[WARNING] POM for 'emma:maven-emma-plugin:pom:0.5:compile' is invalid.
It will be ignored for artifact resolution. Reason: Not a v4.0.0 POM.

I see that there is also an artifactId just called "emma" with a
couple versions.

1) What's the difference between emma and maven-emma-plugin?
2) Can I somehow get one or the other to work with maven 2.0.4?
3) If not, is there any other code coverage plugin people know of that
works with maven 2.0.4?

Thx in advance,
Davis

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



log4j config file and mvn

2006-05-11 Thread Davis Ford

Hi, I was wondering if someone might be able to describe how to solve
the following problem:

We have one master project pom.xml that has  in it.

A team can check out a  that has its own pom.xml and build it
independently.  At the end of the day, the master pom.xml builds all
subprojects and runs integration tests.

There is one subproject called logging that controls logging for the
project using log4j.  It has a logging.xml file as a resource.
However, each developer will want to tweak the logging.xml file to
his/her tastes while developing.

What I would like to do is set the logging.xml file as a resource of
the master project, and then have the logging subproject use that file
(if it exists), or if it does not exist, default to its own
logging.xml resource file.

This would allow a developer to edit the master project logging.xml
for their local builds, and have the logging.jar reference that.

How can I accomplish this in mvn, or is there a better way to achieve
the end goal?

Thx,
Davis

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



Re: Maven experts! Maven1.x vs Maven2.x

2006-03-23 Thread Brad Davis
I'm pretty much brand new to Maven, and though I started with version 1 
because of the better documentation, I pretty much dropped it when I 
found it didn't deal with transitive dependencies.  I'm now working on 
getting Maven 2 adopted as a standard build tool in my office, improving 
the Maven 2 Eclipse integration and intend to contribute to the 
documentation and if neccessary, features set of Maven 2. 


Brad Davis

Siegmann Daniel, NY wrote:

We've moved any Maven1 projects into Maven2, and intend to 
use M2 on any new work.


Wayne
   



I may be totally off, but it seems like M1 is kinda dead. Maven 1.1 beta 2
was released half a year ago. Given that, I think there really is no choice
but to upgrade to Maven 2 (sooner or later).

We've just started moving some stuff that was on Ant to M2, but I wish M2
was a little more mature. I'm sure we will transition fully to M2
eventually.

--
Daniel Siegmann
FJA-US, Inc.
(212) 840-2618 ext. 139

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


 





  1   2   >