Re: Site plugin and modules

2009-02-07 Thread Tim McGinnis
Yep.  It creates the pages for the modules but they have the left nav of 
the top project site.xml.


Dennis Lundberg wrote:

Hi

Have you specified the sub-projects in a  element in the parent
POM?

Tim McGinnis wrote:
  

Why doesn't the Site plugin respect submodule site.xml files?  Or am I
doing something wrong?

I run Maven 2.09 with RSA 7.0.0.7.  I have a project that has several
sub-projects (modules).  The project has its own site.xml and the
modules have their own site.xml.

When I run "mvn site-deploy" on the project the resulting site has only
the contents from the project site.xml and not the individual module
site.xml files.  To get the proper html pages for the modules I have to
run "mvn site-deploy" on each individual module.  Shouldn't I just be
able to run site-deploy on the project and the plugin works for the
modules?

Also I notice if I just run "mvn site" on the project the site is only
created for the project, not the modules.

Thanks,

Tim M.

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






  



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



Re: checkstyle plugin error on multimodule project

2009-02-07 Thread tim tim
thanks ossi

my problem is not that checkstyle doesn't find the configuration.
i have my configuration in a dependency in a jar in my repository.
it is found and simple submodules are checkstyled fine.


it's just that checkstyle does not find dependencies on submodules in
the same project.
it is only resolving dependencies that are in the repository, not the
ones that are
in the current project.


when i copy the example from

http://maven.apache.org/plugins/maven-checkstyle-plugin/examples/multi-module-config.html

checkstyle does not even find the checkstyle.xml configuration, as it
can not resolve
the dependency in the same project and only searches for the
build-tools module in the repository.

here is what happens:

$ mvn checkstyle:checkstyle

[INFO] Scanning for projects...
[INFO] Reactor build order:
[INFO]   WhizBang Parent
[INFO]   Unnamed - com.example.whizbang:build-tools:jar:1.0
[INFO]   Unnamed - com.example.whizbang:subProj1:jar:1.0
[INFO]   Unnamed - com.example.whizbang:subProj2:jar:1.0
[INFO] Searching repository for plugin with prefix: 'checkstyle'.
[INFO] 
[INFO] Building WhizBang Parent
[INFO]task-segment: [checkstyle:checkstyle]
[INFO] 
Downloading: 
http://myServer.homelinux.net:8081/artifactory/repo/com/example/whizbang/build-tools/1.0/build-tools-1.0.jar
Downloading: 
http://myServer.homelinux.net:8081/artifactory/repo/com/example/whizbang/build-tools/1.0/build-tools-1.0.jar
[INFO] 
[ERROR] BUILD ERROR
[INFO] 
[INFO] Failed to resolve artifact.

Missing:
--
1) com.example.whizbang:build-tools:jar:1.0

  Try downloading the file manually from the project website.

  Then, install it using the command:
  mvn install:install-file -DgroupId=com.example.whizbang
-DartifactId=build-tools -Dversion=1.0 -Dpackaging=jar
-Dfile=/path/to/file

  Alternatively, if you host your own repository you can deploy the file there:
  mvn deploy:deploy-file -DgroupId=com.example.whizbang
-DartifactId=build-tools -Dversion=1.0 -Dpackaging=jar
-Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]

  Path to dependency:
1) org.apache.maven.plugins:maven-checkstyle-plugin:maven-plugin:2.2
2) com.example.whizbang:build-tools:jar:1.0

--
1 required artifact is missing.

for artifact:
  org.apache.maven.plugins:maven-checkstyle-plugin:maven-plugin:2.2

from the specified remote repositories:
  apache.snapshots (http://people.apache.org/repo/m2-snapshot-repository),
  central (http://repo1.maven.org/maven2)


[INFO] 
[INFO] For more information, run Maven with the -e switch
[INFO] 
[INFO] Total time: 1 second
[INFO] Finished at: Sat Feb 07 10:49:39 CET 2009
[INFO] Final Memory: 7M/80M
[INFO] 


so now checkstyle does not even find the submodule that holds the config.
again "mvn test" runs without problems.


when i leave out the custom checkstyle config and run checkstyle with
the default configuration
the same error appears.
subProj2 depends on subProj2 -> checkstyle tries to download subProj1
from rep -> fails..
here the output:

$ mvn checkstyle:checkstyle
[INFO] Scanning for projects...
[INFO] Reactor build order:
[INFO]   WhizBang Parent
[INFO]   Unnamed - com.example.whizbang:build-tools:jar:1.0
[INFO]   Unnamed - com.example.whizbang:subProj1:jar:1.0
[INFO]   Unnamed - com.example.whizbang:subProj2:jar:1.0
...
[INFO] 
[INFO] Building Unnamed - com.example.whizbang:subProj2:jar:1.0
[INFO]task-segment: [checkstyle:checkstyle]
[INFO] 
Downloading: 
http://myServer.homelinux.net:8081/artifactory/repo/com/example/whizbang/subProj1/1.0/subProj1-1.0.jar
[INFO] 
[ERROR] BUILD ERROR
[INFO] 
[INFO] Failed to resolve artifact.

Missing:
--
1) com.example.whizbang:subProj1:jar:1.0
...



to me it seems like the checkstyle plugin can not handle intraproject
dependencies.

or what am i forgetting?

best, tim




> hallo
>
> the trick is to reference the checkstyle config as a dependency and not
> directly as a file.
>
> there are some hints at:
> http://maven.apache.org/plugins/maven-checkstyle-plugin/examples/multi-module-config.html
>
> we created a module containing only the checkstyle config. the parent
> pom t

Site plugin and modules

2009-02-06 Thread Tim McGinnis


Why doesn't the Site plugin respect submodule site.xml files?  Or am I 
doing something wrong?


I run Maven 2.09 with RSA 7.0.0.7.  I have a project that has several 
sub-projects (modules).  The project has its own site.xml and the 
modules have their own site.xml.


When I run "mvn site-deploy" on the project the resulting site has only 
the contents from the project site.xml and not the individual module 
site.xml files.  To get the proper html pages for the modules I have to 
run "mvn site-deploy" on each individual module.  Shouldn't I just be 
able to run site-deploy on the project and the plugin works for the 
modules?


Also I notice if I just run "mvn site" on the project the site is only 
created for the project, not the modules.


Thanks,

Tim M.

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



checkstyle plugin error on multimodule project

2009-02-06 Thread tim tim
hello

i have a simple multimodule project

pom.xml
|
proj1 pom.xml
|
proj2pom.xml

in the main pom.xml:

proj1
proj2



proj2 depends on proj1.

   
myComp
proj1
0.1-SNAPSHOT
   


this dependency is resolved correctly when i call

mvn test

or when i open the projects via m2eclipse

but when i call

mvn checkstyle:checkstyle

the checkstyle plugin creates correct reports for proj1

but when it tries to work on proj2 i get the following error:

[INFO] 
[ERROR] BUILD ERROR
[INFO] 
[INFO] Failed to resolve artifact.

Missing:
--
1) myComp:proj1:jar:0.1-SNAPSHOT


it tries to load the missing dependency from a repository instead of using the
files in the other submodule like the test and the compile plugins do.

i can not imagine that i have to deploy all jars before i use checkstyle?

how do i use checkstyle for multimodule projects?



thanks, tim

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



Snapshots not being updated?

2009-01-29 Thread Tim
I have a SNAPSHOT artifact (foo.bar) who has a dependency of:

saxon
saxon
9


I changed the group for saxon (internal repo) and changed the SNAPSHOT to
depend on


net.sf
saxon
9


Above this project I had another artifact that used this as a dependency.

foo
bar
1.0-SNAPSHOT


Before I changed saxon's groupId I had packaged this project and was able to
pull down bar SNAPSHOT w/ saxon.saxon as it's dependency. That's fine.
I redeployed saxon as net.sf.saxon and then redeployed foo.bar with an
updated pom that reflected this groupId change (it is showing correctly in
my nexus repo).
But when I rerun my project it still pulls the old foo.bar that wants saxon
in the saxon group.
Even a snapshot-policy and -U doesn't force it to regrab the SNAPSHOT.

Anyone know what is causing this behavior?

-- 

Bill Cosby  - "A word to the wise ain't necessary - it's the stupid ones
that need the advice."


Re: compiltaion of .java problem

2009-01-21 Thread Tim Kettler

SHAILJA schrieb:

 Hi,


Hi,


 I have  directory strucute like this

 a/b

a/c
a/d.java
a/e.java


Understood.


I have one pom.xml  under "a" directory .. Having code for compilation and
redirecting directories from there 
Like


m
4.0.0
a
1.0
pom 

b
c



 ${TOPDIR}/${JAVA_CLASSES_SRC}/${CUR_DIR} -- all properties are defined 
 ${TOPDIR}/${JAVA_CLASSES_DEST}


${basedir}/test
${TOPDIR}/${JAVA_CLASSES_DEST}

--- code for compilation->
 
   maven-compiler-plugin 





If this should somehow represent the contents of your a/pom.xml it's 
just plainly unreadable. The chances that someone on this list will help 
you are much higher if you post the pom in some more readable format, 
like just pasting the actual xml content.






What  happen when I do  mvn compile ,under "a " directory .. Directories b
and c get compiled  but not all .java files under a
  means a/d.java and a/e.java is not getting compild .  WHY ? Plz help me



As far as I can guess from the crippled pom information above, the root 
of your problem is that you want to compile code in the aggregation pom 
 (which has its packaging element set to pom and a modules tag for your 
modules b and c). This will not work out of the box and (and in my 
opinion) is bad style.


Each packaging type has an associated build lifecycle [1]. The default 
lifecycle for pom packagings just doesn't compile any code or does any 
other useful stuff for projects containing java code. What you should do 
is move the java code contained directly under a/ to its own module and 
use the a/pom.xml just for aggregation of the submodules.


If that's not an option for you, you will have to configure each step of 
the build pocess by yourself (bind the compiler plugin to the compile 
phase, bind the jar plugin to the package phase, ...) To make this 
clear: I  discourage you from doing this. I strongly recommed you 
reconsider your current project structure and move the top level java 
code to its own module. And while you're at it, it might be worth to 
also refactor the directory layout to the standard layout [2] proposed 
by maven.


-Tim

[1] 
http://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html


[2] 
http://maven.apache.org/guides/introduction/introduction-to-the-standard-directory-layout.html


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



Re: Can the maven-upload-plugin be used in a open source project?

2009-01-19 Thread Tim Kettler

Jaikiran schrieb:

I was working on a Maven project and was looking for a plugin which could
upload some documentation to some remote location. While searching this
mailing list i came across the maven-upload-plugin which is hosted at 
http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/
http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/ 


Its exactly what i was looking for. But is that plugin meant to be used in a
open source project? I am curious since the plugin is hosted at a *.com
domain. Any inputs?


As the plugin inherits [1] from the Atlassian public parent pom [2] that 
defines the license as BSD you should be ok.


-Tim

[1] 
http://repository.atlassian.com/maven2/com/atlassian/maven/plugins/maven-upload-plugin/1.1/maven-upload-plugin-1.1.pom
[2] 
http://repository.atlassian.com/maven2/com/atlassian/pom/atlassian-public-pom/18/atlassian-public-pom-18.pom


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



Re: Simple question I think - how can I default to local repo if connection to internal repository is down?

2008-12-30 Thread Tim
Use the offline flag

On Tue, Dec 30, 2008 at 1:31 PM, Rick  wrote:

> I've googled this and tried to search the archives but it's hard to
> get a direct hit.
>
> We are using an internal repository but if for some reason that
> repository goes down, isn't there a way the maven build can still
> proceed using the files in the user's local repository (assuming of
> course the pom hasn't changes and dependencies since they last were
> connected.) Right now, if that internal repository is down, the builds
> will not work. My repository definitions look like this (I know there
> is debate about where to put the repository info, but I like it in the
> project's parent pom instead of on the user's machine.):
>
> 
> 
> central
> http://company-repo-IP:8081/artifactory/repo
> 
> false
> 
> 
> 
> snapshots
> http://company-repo-IP:8081/artifactory/repo
> 
> false
> 
> 
> 
> maven2-repository.dev.java.net
> Java.net Repository for Maven
> http://download.java.net/maven/2/
> default
> 
> 
> maven2-repository.dev.java.net
> Java.net Repository for Maven
> http://download.java.net/maven/2/
> default
> 
> 
> jboss.net repo
> Java.net Repository for Maven
> http://repository.jboss.org/maven2
> default
> 
>  
>  
> 
> central
> http://company-repo-IP:8081/artifactory/plugins-releases
> 
> 
> false
> 
> 
> 
> snapshots
> http://company-repo-IP:8081/artifactory/plugins-snapshots
> 
> 
> false
> 
> 
>  
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>


Re: mvn deploy - no route to host exception

2008-12-22 Thread Tim
metadata.DefaultRepositoryMetadataM
> anager.resolveAlways(DefaultRepositoryMetadataManager.java:352)
>at
> org.apache.maven.artifact.transform.SnapshotTransformation.resolveLatest
> SnapshotBuildNumber(SnapshotTransformation.java:161)
>at
> org.apache.maven.artifact.transform.SnapshotTransformation.transformForD
> eployment(SnapshotTransformation.java:100)
>... 21 more
> Caused by: org.apache.maven.wagon.TransferFailedException: Error
> transferring file
>at
> org.apache.maven.wagon.providers.http.LightweightHttpWagon.fillInputData
> (LightweightHttpWagon.java:104)
>at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:68)
>at
> org.apache.maven.artifact.manager.DefaultWagonManager.getRemoteFile(Defa
> ultWagonManager.java:470)
>at
> org.apache.maven.artifact.manager.DefaultWagonManager.getArtifactMetadat
> aFromDeploymentRepository(DefaultWagonManager.java:379)
>at
> org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataM
> anager.getArtifactMetadataFromDeploymentRepository(DefaultRepositoryMeta
> dataManager.java:380)
>at
> org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataM
> anager.resolveAlways(DefaultRepositoryMetadataManager.java:348)
>... 23 more
> Caused by: java.net.NoRouteToHostException: No route to host: connect
>at java.net.PlainSocketImpl.socketConnect(Native Method)
>at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
>at
> java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
>at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
>at java.net.Socket.connect(Socket.java:519)
>at java.net.Socket.connect(Socket.java:469)
>at sun.net.NetworkClient.doConnect(NetworkClient.java:157)
>at sun.net.www.http.HttpClient.openServer(HttpClient.java:382)
>at sun.net.www.http.HttpClient.openServer(HttpClient.java:509)
>at sun.net.www.http.HttpClient.(HttpClient.java:231)
>at sun.net.www.http.HttpClient.New(HttpClient.java:304)
>at sun.net.www.http.HttpClient.New(HttpClient.java:316)
>at
> sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConn
> ection.java:817)
>at
> sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnecti
> on.java:769)
>at
> sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.ja
> va:694)
>        at
> sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnec
> tion.java:938)
>at
> org.apache.maven.wagon.providers.http.LightweightHttpWagon.fillInputData
> (LightweightHttpWagon.java:83)
>... 28 more
>
> -Original Message-
> From: Brian E. Fox [mailto:bri...@reply.infinity.nu]
> Sent: Monday, December 22, 2008 3:41 PM
> To: Maven Users List
> Subject: RE: mvn deploy - no route to host exception
>
> -e will also show the full stack trace.
>
> -Original Message-
> From: Tim [mailto:che...@gmail.com]
> Sent: Monday, December 22, 2008 2:48 PM
> To: Maven Users List
> Subject: Re: mvn deploy - no route to host exception
>
> I had this problem recently but I thought that -X showed me what it was
> trying to connect to. That didn't work for you?
> On Mon, Dec 22, 2008 at 1:45 PM, EJ Ciramella
> wrote:
>
> > I said "please" didn't I ;-)
> >
> > Point taken - just posting here as well so people who google "No path
> to
> > host exceptions" with regard to maven 2 may diagnose their own
> problems
> > quickly.
> >
> > Thank you!
> >
> > -Original Message-
> > From: bmat...@gmail.com [mailto:bmat...@gmail.com] On Behalf Of
> Baptiste
> > MATHUS
> > Sent: Monday, December 22, 2008 2:33 PM
> > To: Maven Users List
> > Subject: Re: mvn deploy - no route to host exception
> >
> > Hi,
> > First, I thought that saying hello and thanks was quite simple.
> > Second, remember this is a user mailing list, with the flow of mails
> > coming through it, your question is lekily to be forgotten. So, if you
>
> > have an improvement request, you'd better file it if you ever want to
> > see something coming (and obviously, "chasing" the patch yourself will
>
> > help :-)).
> >
> > Cheers.
> >
> > 2008/12/22 EJ Ciramella 
> >
> > > Can someone please update the deploy plugin such that when people
> get
> > > exceptions like the "no route to host" exception, it prints out the
> > > host it tried connecting to?
> > >
> > > That had me chasing my tail and tracking back through all my
> > > dependencies this weekend
> > >
> >
> >
> >
> > --
> > Baptiste  MATHUS - http://batmat.net Sauvez un arbre, Mangez
> un
> > castor !
> >
> > -
> > 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
>
>


Re: mvn deploy - no route to host exception

2008-12-22 Thread Tim
I had this problem recently but I thought that -X showed me what it was
trying to connect to. That didn't work for you?
On Mon, Dec 22, 2008 at 1:45 PM, EJ Ciramella wrote:

> I said "please" didn't I ;-)
>
> Point taken - just posting here as well so people who google "No path to
> host exceptions" with regard to maven 2 may diagnose their own problems
> quickly.
>
> Thank you!
>
> -Original Message-
> From: bmat...@gmail.com [mailto:bmat...@gmail.com] On Behalf Of Baptiste
> MATHUS
> Sent: Monday, December 22, 2008 2:33 PM
> To: Maven Users List
> Subject: Re: mvn deploy - no route to host exception
>
> Hi,
> First, I thought that saying hello and thanks was quite simple.
> Second, remember this is a user mailing list, with the flow of mails
> coming through it, your question is lekily to be forgotten. So, if you
> have an improvement request, you'd better file it if you ever want to
> see something coming (and obviously, "chasing" the patch yourself will
> help :-)).
>
> Cheers.
>
> 2008/12/22 EJ Ciramella 
>
> > Can someone please update the deploy plugin such that when people get
> > exceptions like the "no route to host" exception, it prints out the
> > host it tried connecting to?
> >
> > That had me chasing my tail and tracking back through all my
> > dependencies this weekend
> >
>
>
>
> --
> Baptiste  MATHUS - http://batmat.net Sauvez un arbre, Mangez un
> castor !
>
> -
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>


using the maven-source-plugin

2008-11-10 Thread tim tim
hello all,

i have problems using the maven-source-plugin.
the problem is that when i call

> mvn install

the project is build and deployed into my local repository, but the
sources are not.

i am following the instructions  "Installing the sources along with
your artifact"
on

 http://maven.apache.org/plugins/maven-source-plugin/usage.html

and hence the build section of my pom looks like this:
  



org.apache.maven.plugins

maven-eclipse-plugin
2.4


true

true



org.apache.maven.plugins

maven-dependency-plugin



org.apache.maven.plugins
maven-source-plugin


attach-sources
verify

jar









thanks a lot, tim

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



mvn2 url resolution for SNAPSHOT sources wrong

2008-10-13 Thread tim tim
hello there,

i have a problem with downloading the sources from a snapshot repository.

when i call

 mvn dependency:sources

(or mvn eclipse:eclipse -DdownloadSources=true)

the compiled jar is downloaded correctly, but the sources jar is
searched for in a wrong directory

download for the compiled jar is correct ->
http://snapshots.jboss.org/maven2/org/drools/solver/drools-solver-core/5.0.0.SNAPSHOT/drools-solver-core-5.0.0.20081009.190700-124.jar

wrong, the timestamp is part of the path ->
http://snapshots.jboss.org/maven2/org/drools/solver/drools-solver-core/5.0.0.20081009.190700-124/drools-solver-core-5.0.0.20081009.190700-124-sources.jar


the sources are there, i can browse and download them manually:
http://snapshots.jboss.org/maven2/org/drools/solver/drools-solver-core/5.0.0.SNAPSHOT/


and the snapshot release of a different project (jboss-seam-pdf) from
the same repository is retrieved correctly:

Downloading: 
http://snapshots.jboss.org/maven2/org/jboss/seam/jboss-seam-pdf/2.1.0-SNAPSHOT/jboss-seam-pdf-2.1.0-20081010.041610-288-sources.jar
Downloading: 
http://snapshots.jboss.org/maven2/org/jboss/seam/jboss-seam-pdf/2.1.0-SNAPSHOT/jboss-seam-pdf-2.1.0-20081010.041610-288.jar


i asked the owners of the faulty repository, and they don't seem to
have the same problem.

http://www.nabble.com/drools-5.0.0-SNAPSHOT-Maven-repository-broken--ts19881450.html

and comparing the poms of the working jboss-seam-pdf and the
drools-solver repository i can not find any difference. (but i am a
mvn newbie)

my system is:

Maven version: 2.0.8
Java version: 1.6.0_06
OS name: "linux" version: "2.6.24-19-generic" arch: "amd64" Family: "unix"



below is a simple pom.xml, that creates the error for me (on two
different computers in different networks):

---

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


testMavenDownloadSources
test
0.1-SNAPSHOT
testMavenDownload


testMavenDownload





org.apache.maven.plugins

maven-eclipse-plugin
2.4


true

true




org.apache.maven.plugins

maven-dependency-plugin








snapshots.jboss.org
http://snapshots.jboss.org/maven2


repository.jboss.org
http://repository.jboss.org/maven2






org.jboss.seam
jboss-seam-pdf
2.1.0-SNAPSHOT   



org.drools.solver
drools-solver-core
5.0.0.SNAPSHOT



    



---

thank you, tim

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



Re: What it is repository.xml file

2008-09-16 Thread Tim Moloney


I believe that it is being generated by the maven-obr-plugin.  Something 
that you built is an OSGi bundle.  When it was installed into your local 
repository, its metadata was added to repository.xml.  This allows your 
local Maven repository to also serve as an OSGi Bundle Repository (OBR).


During your builds look for lines like

...
[INFO] [bundle:install]
[INFO] Parsing file:/home/username/.m2/repository/repository.xml
[INFO] Installing 
org/apache/project/org.apache.project.bundle/0.1.0-SNAPSHOT/org.apache.project.bundle-0.1.0-SNAPSHOT.jar

[INFO] Writing OBR metadata
...

I don't know why your repository.xml got mangled, if that's the case.  
If your repository.xml file is not mangled, the project metadata in 
repository.xml will tell you which projects create OSGi bundles.  If you 
don't want repository.xml, add -DobrRepository=NONE to the build command 
on these projects.  See 
http://cwiki.apache.org/FELIX/apache-felix-maven-obr-plugin.html for 
more information.


Tim


Brett Porter wrote:

repository.xml is not a Maven file - is there a plugin running shortly
before this in the output that is attempting to read it?

- Brett

2008/9/16 tomascejka <[EMAIL PROTECTED]>:
  

Hi,

I study Maven and scanning directory .m2 and find repository.xml file. When
I read it, there are list of description about plugins, jars and project,
which I manage via Maven.

There is not try to duplicate threads because I asked about the problem in
Hudson forum -
http://www.nabble.com/Hudson-logFatal-Error--repository.xml%3A3%3A1%3A-Premature-end-of-file.-td18460386.html#a18587472
link . It was not right place to place this question.

What is this file for?
When does it arise - during all builds or just new plugin or jar was be
added(downloaded)?

[INFO] Parsing file:/root/.m2/repository/repository.xml
[Fatal Error] repository.xml:3:1: Premature end of file.
org.xml.sax.SAXParseException: Premature end of file.

I have found out that repository.xml is blank. I removed it a executed build
over project again. And problem has not occured already. But there is
question why the situation occured and how I can prevent this problem again.

There is another important problem. When this problem occured Hudson does
not send email about job failed.

Even some test do not executed. There is console output of java bundle:

started
Build failed before it gets to this module
finished: NOT_BUILT


Note:
I tried to find meaning of repository.xml. Only I found out, that file is
generated by Maven, when I read it
. If you have some links about more information. Please send me.

#enviroment
SUSE Sles 10
Hudson 1.229
Maven 2.0.9


--
View this message in context: 
http://www.nabble.com/What-it-is-repository.xml-file-tp19510483p19510483.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]







  



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



Re: Filtering of a SINGLE property

2008-07-06 Thread Tim Kettler

Hi,

If you absolutely have go the way of filtering Java files, I would 
probably do it that way:


1. Put the java files to filter in a separate directory 
(src/main/java-filtered)


2. Add a filtered resource to the pom 
(target/generated/sources/java-filtered)


3. Make this additional source directory known with the 
build-helper-maven-plugin [1].


-Tim

[1] http://mojo.codehaus.org/build-helper-maven-plugin/

Peter Horlock schrieb:

Well, sure, we COULD do it at runtime, but
a) this would cost performance (okay, to be honest, of course, it could once
be loaded and runtime and so on, but still it would at least clutter the
code with additional stuff we didn't when we were using Maven 1).
b) For political reasons It would be good if everything would work as close
as possible as it was before I introduced Maven 2...

Peter




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



Re: Access to remote repositories

2008-07-06 Thread Tim Kettler
I'm not using Eclipse, so I can't give you an authoritative answer. The 
only thing I know is that central for example contains an index 
directory [1]. Perhaps other repositories don't maintain such an index.


Please open a new thread with a more matching subject if you need more 
help/information about this topic. It would probably also be useful if 
you would tell which eclipse plugin you are using, as there are two of 
them: m2eclipse and q4e.


-Tim

[1] http://repo1.maven.org/maven2/.index/

buters schrieb:

Thank you very much Tim.

But it would be fine if you me explain, why am I not able to index any
repository with Maven Index in eclipse besides central, local and from
Artifactory. If I try Add Dependency to my project, that doesn't exist in
one of these  repositories, eclipse doesn't find this plugin, though I've
defined repository in my pom.xml. Or I must ignore eclipse errors, set
 manual and try to run Maven goals?

Thanks beforehand,
regards, buters

Tim Kettler wrote:

buters schrieb:

Hi,

Hi,


would you explain me how can I acces to e.g.
http://repository.jboss.com/maven2/

I know that I have to add this in settings.txt

You probably mean settings.xml.



  
 artifactory 
 admin 
 password 
  


This is only needed if the repository is password protected. For public 
repositories like central, codehaus or the jboss repository you can 
simply omit that part, just configure the repository in the repositories 
section and you are done.



It is clear in case of Artifactory which id, username and password should
be
used.
But which id, username and password must I use for other remote
repositories
(beside central)?

Thanks beforehand,
regards, buters

-Tim

-
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: Access to remote repositories

2008-07-06 Thread Tim Kettler

buters schrieb:

Hi,


Hi,


would you explain me how can I acces to e.g.
http://repository.jboss.com/maven2/

I know that I have to add this in settings.txt


You probably mean settings.xml.



  
 artifactory 
 admin 
 password 
  




This is only needed if the repository is password protected. For public 
repositories like central, codehaus or the jboss repository you can 
simply omit that part, just configure the repository in the repositories 
section and you are done.



It is clear in case of Artifactory which id, username and password should be
used.
But which id, username and password must I use for other remote repositories
(beside central)?

Thanks beforehand,
regards, buters


-Tim

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



Re: Access to e.g. jboss lib

2008-07-06 Thread Tim Kettler
What you can do, is to declare the dependencies on the jboss jars you 
need in a wrapper pom (with an artifactId jboss-all for example) and 
deploy/install that to your repository. You then have to declare the 
many depencies just once and in your projects you can just declare a 
dependency on the wrapper pom.


Regarding your question about the importance of bulk-importing jars, I 
can only say that I think this is a very bad idea. Maven is all about 
unambiguousness and repeatability of builds and so every dependency of a 
project should be well-defined, which is certainly not the case when 
bulk importing a directory of jars.


.Tim

buters schrieb:

I was simply trying to avoid 30 dependencies in my pom.xml. I thought that I
can only have one reference to all libraries. Furthermore I don't know
versions of plugins, that jboss uses. Here jar-files stand without any
version, not as in the repository. But that is important, sometimes or?

regards, buters


Tim Kettler wrote:

What does accessing the jboss jars has to do with plugins?

Anyway, JBoss maintains an own maven repository [1] you can add to 
settings.xml or pom. I don't know if the specific jars you need are 
available from there, but it's worth a try.


-Tim

[1] http://repository.jboss.com/maven2/

buters schrieb:

This difficult way I want to avoid. This is difficult because I have to
do
with a number of plugins. It is me circumstantially for every plugin "mvn
install:install-file" to execute. I want to find a better way.


Wayne Fay wrote:

The proper way to do this is to refer to the JBoss dependencies just
like any other dep, with a  tag.

If you can't find the specific file/version of the jar you need
already deployed in Central, then you can use "mvn
install:install-file" to install it into your local repo cache
directly, then add the  tag to add it to your project.

Wayne

On 7/5/08, buters <[EMAIL PROTECTED]> wrote:

Hi,

how can I access e.g. to jboss jars? I know that ${env.JBOSS_HOME} can
be
used. But how can I use this, that I don't know. What schould I insert
in
my
pom.xml?

Thanks beforehand,
best regards, buters
--
View this message in context:
http://www.nabble.com/Access-to-e.g.-jboss-lib-tp18290267p18290267.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]



-
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: Access to e.g. jboss lib

2008-07-05 Thread Tim Kettler

What does accessing the jboss jars has to do with plugins?

Anyway, JBoss maintains an own maven repository [1] you can add to 
settings.xml or pom. I don't know if the specific jars you need are 
available from there, but it's worth a try.


-Tim

[1] http://repository.jboss.com/maven2/

buters schrieb:

This difficult way I want to avoid. This is difficult because I have to do
with a number of plugins. It is me circumstantially for every plugin "mvn
install:install-file" to execute. I want to find a better way.


Wayne Fay wrote:

The proper way to do this is to refer to the JBoss dependencies just
like any other dep, with a  tag.

If you can't find the specific file/version of the jar you need
already deployed in Central, then you can use "mvn
install:install-file" to install it into your local repo cache
directly, then add the  tag to add it to your project.

Wayne

On 7/5/08, buters <[EMAIL PROTECTED]> wrote:

Hi,

how can I access e.g. to jboss jars? I know that ${env.JBOSS_HOME} can be
used. But how can I use this, that I don't know. What schould I insert in
my
pom.xml?

Thanks beforehand,
best regards, buters
--
View this message in context:
http://www.nabble.com/Access-to-e.g.-jboss-lib-tp18290267p18290267.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]



-
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: deploy own artifacts to a remote Repo

2008-06-26 Thread Tim Kettler

[EMAIL PROTECTED] schrieb:
Hi, 


Hi,

we have an open-source developement, where you actually could download the 
latest releases from the website.
It would be much more easier, if we were able to deploy the latest 
releases to an existing, remote Repo and just display the group/artifactId 
and the URL of the repo at the website.


Where´s the place to deploy own artifacts so they can be used by others?


The best way is to deploy the artifacts to a repository in your control 
and sync [1] that repository to central.



Thanx, Torsten




-Tim

[1] http://maven.apache.org/guides/mini/guide-central-repository-upload.html

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



Re: maven-ejb3-plugin

2008-06-22 Thread Tim Kettler

Hi,

you don't need to use the maven-ejb3-plugin. It was developed because a 
draft version of the EJB3 specification contained a new .ejb3 packaging 
type. This new type was dropped for the final specification and the 
plugin never maid it out of the sandbox and was never released. Just use 
the standard maven-ejb-plugin.


-Tim

langlois yan schrieb:

Hi,

I would like to use EJB3 in my application. As I want to use an EAR archive 
which contains un web module and an EJB3 module I need to package my ejb3 with 
maven-ejb3-plugin and not with maven-ejb-plugin. This behaviour is mandatory by 
the maven-ear-plugin.

After a long search I find that the maven-ejb3-plugin is not in the central 
repository. So I downloaded it and install it (svn checkout 
http://svn.apache.org/repos/asf/maven/sandbox/trunk/plugins/maven-ejb3-plugin/).
 Does someone know why this plugin is not in the centrale repository ? I think 
it would help a lot of people like me if it were there.

Yan.



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



Re: regarding creating new maven project

2008-06-20 Thread Tim Kettler

Ravinder Kankanala schrieb:
Hi 



Hi,

neither the issues nor the developer mailinglists are the right place 
for this kinds of questions. Please ask usage related questions on the 
users list next time. Apart from these lists just being the wrong place 
to ask this kinds of question, the audience (and therefore your chance 
to get an answer) is much larger on the users list.


I've moved this thread to the users list, so please answer there.



I have download the maven2.0.9 and I have set the maven path.

 


Then I have created one folder my-app, in that I have created pom.xml file.

Then I executed this command like this

 


C:\mvnapp>mvn archetype:create -DgroupId=com.mycompany.app
-DartifactId=my-app



You don't need to manually create the project directory and pom file. 
That's part of what the archetype plugin you tried to use is meant for.




I am getting the following error: 

 


[INFO] Scanning for projects...

[INFO] Searching repository for plugin with prefix: 'archetype'.

[INFO] org.apache.maven.plugins: checking for updates from central

[WARNING] repository metadata for: 'org.apache.maven.plugins' could not be
retrieved from repository: central due to an error: Error transferring file

[INFO] Repository 'central' will be blacklisted

[INFO]


[ERROR] BUILD ERROR

[INFO]


[INFO] The plugin 'org.apache.maven.plugins:maven-archetype-plugin' does not
exist or no valid version could be found

[INFO]


[INFO] For more information, run Maven with the -e switch

[INFO]


[INFO] Total time: 32 seconds

[INFO] Finished at: Fri Jun 20 12:03:47 IST 2008

[INFO] Final Memory: 1M/254M

[INFO]



So please anything else need to configure and anything else modify to it
pom.xml file.



This error usually means that maven can't communicate with the remote 
repository (note the 'Error transferring file' warning). Most often this 
is caused by some firewall or proxy setup that is needed to allow maven 
to access the internet. Instructions on how to configure proxy settings 
in maven are located here [1].


As a general suggestion to new users I advice you to at least read the 
'Getting Started Guide' [2] and also take a look at the available free 
book about maven2 listed here [3].




Please help in this  I need urgent.

 


Is there any required to additional configuration.

 


Thanks in Advance.

 


Regards,

KRReddy 



-Tim

[1] http://maven.apache.org/guides/mini/guide-proxies.html
[2] http://maven.apache.org/guides/getting-started/index.html
[3] http://maven.apache.org/articles.html

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



Re: Embedded error: Unknown artefact type[test-jar]

2008-06-15 Thread Tim Kettler
What I was guessing is, that you declared an artifact with a 'test' 
classifier in the modules section of the ear, as the artifact type for 
test jars is 'test-jar', which is not supported by the ear plugin. 
However, I can't see such a declaration in your pom.


-Tim

JINDAL, Mukta, IDC schrieb:

Somehow, "mvn clean" is working now, but I'm still getting error in
several other commands say "mvn eclipse:eclipse", "mvn install" and "mvn 
package" :

[INFO] [ear:generate-application-xml]
[INFO] 
[ERROR] BUILD ERROR
[INFO] 
[INFO] Failed to initialize ear modules

Embedded error: Unknown artifact type[test-jar]
[INFO] 
[INFO] For more information, run Maven with the -e switch
[INFO] 
[INFO] Total time: 8 seconds
[INFO] Finished at: Fri Jun 13 11:42:04 IST 2008
[INFO] Final Memory: 8M/17M
[INFO] 


Regards,
Mukta Jindal

-Original Message-
From: JINDAL, Mukta, IDC
Sent: 13 June 2008 10:50
To: 'Maven Users List'
Subject: RE: Embedded error: Unknown artefact type[test-jar]

C:\sandbox\rbsfm\netpositioner\ear>mvn help:effective-pom [INFO] Scanning for 
projects...
[INFO] Searching repository for plugin with prefix: 'help'.
[INFO] artifact org.apache.maven.plugins:maven-help-plugin: checking for 
updates  from central
Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-help-p
lugin/2.0.2/maven-help-plugin-2.0.2.pom
3K downloaded
Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-help-p
lugin/2.0.2/maven-help-plugin-2.0.2.jar
23K downloaded
[INFO] 
[INFO] Building Net Positioner: Enterprise Application
[INFO]task-segment: [help:effective-pom] (aggregator-style)
[INFO] 
[INFO] [help:effective-pom]
[INFO]


Effective POM for project 'com.rbsfm.netpositioner:ear:ear:4.0-SNAPSHOT'



  
netpositioner
com.rbsfm.netpositioner
4.0-SNAPSHOT
  
  4.0.0
  com.rbsfm.netpositioner
  ear
  ear
  Net Positioner: Enterprise Application
  4.0-SNAPSHOT
  Net Positioner EAR
  http://www.netpositioner.com/ear
  
C:\sandbox\rbsfm\netpositioner\ear\src\main\java
src/main/scripts
C:\sandbox\rbsfm\netpositioner\ear\src\test\java
C:\sandbox\rbsfm\netpositioner\ear\target\classes
C:\sandbox\rbsfm\netpositioner\ear\target\test-classes<
/testOutputDirectory>

  
C:\sandbox\rbsfm\netpositioner\ear\src\main\resources
  


  
C:\sandbox\rbsfm\netpositioner\ear\src\test\resources
  

C:\sandbox\rbsfm\netpositioner\ear\target
ear-4.0-SNAPSHOT

  
maven-compiler-plugin

  1.5
  1.5

  
  
maven-surefire-plugin
2.4.1
  
  
maven-ear-plugin

  Net Positioner
  Net Positioner
  1.4
  

  com.rbsfm.netpositioner
  position-persistor


  com.rbsfm.netpositioner
  position-updator

  
  **/log4j*,
  **/commons-logging*

  
  
maven-help-plugin
2.0.2
  

  
  

  digital-sales-maven2
  Digital Sales Technology Maven 2 Repository
  http://digital-sales-tech/maven2


  digisales
  digisales
  http://fx-trading.fm.rbsgrp.net/maven2/


  java.net
  http://download.java.net/maven/2


  java.net legacy
  http://download.java.net/maven/1
  legacy


  
false
  
  central
  Maven Repository Switchboard
  http://repo1.maven.org/maven2

  
  

  
never
  
  
false
  
  central
  Maven Plugin Repository
  http://repo1.maven.org/maven2

  
  

  org.slf4j
  slf4j-simple
  1.4.3
  test


  com.rbsfm.netpositioner
  position-updator
  4.0-SNAPSHOT


  org.slf4j
  jcl104-over-slf4j
  1.4.3


  org.slf4j
  slf4j-api
  1.4.3


  org.springframework
  spring-test
  2.5.1
  test
  

  commons-logging
  commons-logging

  


 

Re: How to build a own goal

2008-06-15 Thread Tim Kettler

chokdee schrieb:

Hi all,


Hi,


i am new to maven but have many experience in Ant. After reading "Better
Builds with maven..." I didnt read how to build my own goals.


Goals (also called mojos) are part of a plugin. How to develop new 
plugins is described in chapter 5 of the book you mention.


However, writing custom plugins is rarely needed these days as there are 
plugins available for many use-cases. The plugins developed by the maven 
team are listed here [1] and more plugins are available from the mojo 
project [2] over at codehaus.org. If you don't find a suitable plugin at 
this sites and a web search like '{your actual topic} maven plugin' also 
fails, feel free to just ask on this list.



E.g I want to write a masterbuild goal, that do everything necessary for the
team.


Reading the above sentence, I have the gut feeling that you 
misunderstood the maven way of managing builds, because this 
'masterbuild goal' as you call it is probably exactly what the pom.xml 
is meant for.


If you can describe in more detail what your masterbuild goal should do, 
we can help you do it the maven way.



Regards
Juergen


-Tim

[1] http://maven.apache.org/plugins/
[2] http://mojo.codehaus.org/plugins.html

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



Re: Glassfish, Maven, dependencies fail to download on bootstrap, build, whatever - SocketException: invalid argument

2008-06-14 Thread Tim Kettler

Hi,

as you mention FreeBSD, perhaps you have the same problem as described 
here [1].


-Tim

[1] 
http://www.nabble.com/java.net.SocketException---need-help-in-getting-started-to17650673.html#a17650673


Da Rock schrieb:

I have to admit I'm a newbie to Maven, I'm following directions from 2
different sites with similar instructions to build Glassfish on FreeBSD.
I actually only want Glassfish, but apparently this is the process I
must follow... but after several days of searching, looking for
workarounds and fixes I cannot find anything that resolves this, and yet
I can't believe I'm the only one with this problem!

I downloaded the source package from Glassfish, but during my searches
for how to build it (as there is no readme or any other instructions) I
discovered I needed to cvs it. I also discovered I needed to add
glassfish.cvstag=SJSAS91_UR2_BRANCH to the project.properties file. In
any case I get to the bootstrap stage and the build fails because of a
mountain of unsatisfied dependencies. It seems maven simply can't
download the files required because I could manually download them.

The error appears to be a server down/file not found as near as I can
tell from my investigations online, but this is not the case. I've added
repos but still have had no success. One repo that I have navigated to
is http://download.java.net/javaee5/external/shared, and this appears to
contain all the files needed.

I'm assuming there must be something I'm doing but I haven't the
slightest as to what. Any clues? This is becoming a huge project just to
get the server built...


-
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: Embedded error: Unknown artefact type[test-jar]

2008-06-12 Thread Tim Kettler

Hi,

please show us the output of 'mvn help:effective-pom' for the ear 
subproject in question.


-Tim

JINDAL, Mukta, IDC schrieb:

Please help.. I didn't get any clues till now...

My application structure is as follows:

main-project
 |
 |---project1
 | |
 | |---pom.xml
 |
 |---project2
 | |
 | |---pom.xml
 |
 |---ear
 | |
 | |---pom.xml
 |
 |---pom.xml


I'm getting this error while doing even "mvn clean" on main-project since I have added 
the sub-project "ear".


Regards,
Mukta Jindal

-Original Message-
From: JINDAL, Mukta, IDC
Sent: 12 June 2008 16:41
To: 'Maven Users List'
Subject: Embedded error: Unknown artefact type[test-jar]

Hi All,

I'm getting following error while trying to do "mvn clean package" to get an 
ear :

[INFO] [ear:generate-application-xml]
[INFO] 
[ERROR] BUILD ERROR
[INFO] 
[INFO] Failed to initialize ear modules

Embedded error: Unknown artifact type[test-jar] [INFO] 

[INFO] For more information, run Maven with the -e switch [INFO] 

[INFO] Total time: 17 seconds
[INFO] Finished at: Thu Jun 12 16:27:49 IST 2008 [INFO] Final Memory: 15M/27M 
[INFO] 


I'm not using "test-jar" in any of the POMs. Please help..


Regards,
Mukta Jindal
RBS India Development Centre (P) Ltd
DLF Cyber Greens, Phase III
Sector 25-A, Gurgaon - 122002
O +91 124 672 4170 | M +91 999 908 0608

P Please don't print this e-mail unless you really need to.


***
The Royal Bank of Scotland plc. Registered in Scotland No 90312. Registered 
Office: 36 St Andrew Square, Edinburgh EH2 2YB.
Authorised and regulated by the Financial Services Authority

This e-mail message is confidential and for use by the addressee only. If the 
message is received by anyone other than the addressee, please return the 
message to the sender by replying to it and then delete the message from your 
computer. Internet e-mails are not necessarily secure. The Royal Bank of 
Scotland plc does not accept responsibility for changes made to this message 
after it was sent.

Whilst all reasonable care has been taken to avoid the transmission of viruses, 
it is the responsibility of the recipient to ensure that the onward 
transmission, opening or use of this message and any attachments will not 
adversely affect its systems or data. No responsibility is accepted by The 
Royal Bank of Scotland plc in this regard and the recipient should carry out 
such virus and other checks as it considers appropriate.
Visit our websites at:
www.rbs.com
www.rbs.com/gbm
www.rbsgc.com
***

__
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
__

__
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
__


-
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-Jboss-Packaging-Plugin error locating jboss-spring.xml

2008-06-11 Thread Tim Kettler

File a bug report in jira [1] to make the developers aware of it.

-Tim

[1] http://jira.codehaus.org/browse/MJBOSSPACK

Andrew Madu schrieb:

Problem solved!

Even though the 'deploymentDescriptorFile' attribute is described as one
which can be optionally set, this is not the case. It needs to be explicitly
set.

Andrew

On Thu, Jun 12, 2008 at 12:39 AM, Andrew Madu <[EMAIL PROTECTED]> wrote:


Hi,
could someone oblige me and test the following plugin, in a bog standard
maven app project, with the build command 'mvn jboss-packages:spring' and
tell me whether the plugin breaks or not? (a jboss-spring.xml file needs to
be placed in src/main/resources/META-INF):

[code]
  


org.codehaus.mojo
jboss-packaging-maven-plugin

myCompany

true



jboss-spring






[/code]

I keep getting an 'Error assembling archive...Embeded error: Could not find
descriptor files: jboss-spring.xml' message when running the build command.

My development platform:

Eclipse SDK Version: 3.3.2
JDK1.6.0_06
Springframework 2.5.5
Maven Version 2.0.9

Many thanks in advance.


On Wed, Jun 11, 2008 at 3:17 PM, Andrew Madu <[EMAIL PROTECTED]> wrote:


Hi,
I ma receiving the following error message when I call 'mvn
jboss-packaging:spring':

[code]
Embedded error: Could not find descriptor files: jboss-spring.xml
[/code]

The file, jboss-spring.xml, exists in src/main/resources/META-INF/. What
am I missing here?

My development platform:

Eclipse SDK Version: 3.3.2
JDK1.6.0_06
Springframework 2.5.5
Maven Version 2.0.9

the plugin in question is jboss-packaging-maven-plugin (2.0-beta-1).

Many thanks in advance.

--
Regards

Andrew








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



Re: Excluding packages and classes from jar

2008-06-10 Thread Tim Kettler

Peter Horlock schrieb:

thanks a lot, this helped.

One more, however:
Now it creates the jar as it should, but I would like to have a different
name for it when installating it into the local / remote repo.

Under target, it creates:
myproject-mysubversion-1.1.jar

but when installing or deploying, it installs /deploys it as:
myproject-1.1.jar (just like the jar that contains all classes).


All artifacts in a repository have to follow a common naming schema so 
that maven can locate them. The schema is:


  artifactid-version[-classifier].packaging

This is fixed, you can't put arbitrary named jars in there.


I tried:

maven-install-plugin

 myproject-mysubversion

 

as well as:

maven-install-plugin

yproject-mysubversion-${version}.${packaging}

 


Where did you get that configuration parameters from? The 
install-plugin's documentation [1] doesn't mention these.



but both just installed the file as myproject-1.1.jar into my repository.
This could lead to really bad confusions... :-(


That's expected, the install-plugin doesn't know these parameters and 
just ignores them.



Any ideas?


I would configure it like this in my pom:

  
org.apache.maven.plugins
maven-jar-plugin

  
package-stripped-jar
package

  jar


  stripped
  
pkg1/Class1.class
pkg2/**
  

  

  

This configures a second execution of the jar plugin in addition to the 
default execution because of the jar-packaging. This second execution 
creates the stripped down jar with the given classifier and attaches it 
to the build.


The install (and deploy) plugin will automatically pick up the main 
artifact (created by the default jar execution) and the second one with 
the clsssifier and installs/deploys them to the repository.


when you need to reference the stripped plugin in another project the 
dependency would look like this:


  
mygroup.id
my-artifact
3.14159
stripped
  


Thanks guys,

Peter Horlock



-Tim

[1] http://maven.apache.org/plugins/maven-install-plugin/install-mojo.html

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



Re: Excluding packages and classes from jar

2008-06-10 Thread Tim Kettler

Hi,

Peter Horlock schrieb:

Hi Rémy, thanks for your reply. I also tried mvn package -Pmyflag, but this
did't work out either - btw -p SPACE FLAG is what is said on the maven docu
site:
http://maven.apache.org/guides/introduction/introduction-to-profiles.html :

mvn groupId:artifactId:goal -P profile-1,profile-2

However, the new Maven - The definitive Guide - Pdf book says -PMYFLAG.

---
Next, as you suggested, I tried it directly without a profile, and it
neither worked :-(
I am not even sure if what I am trying is supposed to be working - I
am trying to exclude certain classes or package - not simple
exluding a certain src folder, like "include "src/java" but exclude
"src/java2" or so - I am trying to do in on a package or class basis -


org.apache.maven.plugins
maven-jar-plugin


package

jar




**/com/mycompany/mypackage/mysubpackage/MyClassA.java

**/com/mycompany/mypackage/mysubpackage/packageA/*

**/com/mycompany/mypackage/mysubpackage/packageB/*






I suppose the exclude paths are wrong - but how should I define them?
src/java/com...?


The jar-plugin works on the compiled output in target/classes, so 
ecluding *.java files can't work. I just tried with a simple test project:


  .
  |-- pom.xml
  `-- src
  `-- main
  `-- java
  |-- pkg1
  |   |-- Class1.java
  |   `-- Class2.java
  `-- pkg2
  |-- Class1.java
  `-- Class2.java


and this plugin configuration in the pom:

  
org.apache.maven.plugins
maven-jar-plugin

  
pkg1/Class1.class
pkg2/**
  

  

After 'mvn package' the resulting jar contained just pkg1/Class2.class, 
just as expected.



Thanks in advance,

Peter



Hope this helps
-Tim

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



Re: Creating a Custom Artifact Handler

2008-06-08 Thread Tim Kettler

Andrew Madu schrieb:

Hi Tim,
Perfect! That does exactly what I want.

One thing I would like to know, and in relation to the 'standard 
directory layout', is if I have the following directory in my project:


src/main/webapp

shouldn't a corresponding web/web-inf directory structure also be part 
of the build in much the same way that having a jboss-spring.xml file 
situated in src/main/resources will create a corresponding 
META-INF/jboss-spring.xml structure in the final build? How would I go 
about doing this?


I'm not sure I understand you correctly here, but when you build a war 
(packaging = war) you can put content under 'src/main/webapp/WEB-INF' 
and maven will create a 'WEB-INF' directory with this content in the 
final war. See here [1] for documentation.



Many thanks in advance.



-Tim

[1] http://maven.apache.org/plugins/maven-war-plugin/usage.html

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



Re: Creating a Custom Artifact Handler

2008-06-08 Thread Tim Kettler

Andrew Madu schrieb:

Hi,


Hi,

can anyone tell me the location of the jar which allows for the creation 
of custom artifact handlers in its component.xml file?


The default artifact handlers are defined in maven-core's component.xml 
[1] but you don't need to modify this if you want to use a custom 
artifact type. You just create a components.xml containing your artifact 
handler and lifecycle definition in your plugin and define your plugin 
in projects using the custom artifact type as a packaging with the 
 tag set to true.


While searching for an existing plugin showing this I stumbled upon the 
jboss-packaging-maven-plugin [2] over at the mojo project. Incidentally, 
 this plugin provides the spring dependency type you talk about in your 
other thread.



My pltfoem is as follows:
WIN XP SP1
JDK 1.6.0_06
Maven 2.0.9

Many thanks in advance.



-Tim

[1] 
http://svn.apache.org/viewvc/maven/components/trunk/maven-core/src/main/resources/META-INF/plexus/components.xml?view=markup

[2] http://mojo.codehaus.org/jboss-packaging-maven-plugin/

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



Re: need help in ant's javadoc task (from maven)

2008-06-06 Thread Tim Kettler

Niranjan Deshpande schrieb:

so whts wrong in my case?


The antrun-plugin by default, to don't bloat the build, only provides 
access to the core ant tasks. If you want to use other ant tasks (like 
) you need to declare the jar containing them as a 
depenendency of the plugin. For the  task the only 
dependency you need to declare should be:


  
  ant
  ant-nodeps
  1.6.5
  

-Tim


On Fri, Jun 6, 2008 at 7:31 PM, Sean Hennessy <[EMAIL PROTECTED]>
wrote:


 of course..echoproperties adds dependency..to another ant component.
 here is segment of my ugly pom.xml
[snip]
 
 
   maven-antrun-plugin
   
 
   pre-site
   
 
 
 
 
 
   
 
   
   pom.xml: timestamp ${TODAY_UK}
   
 
 
 
 
 
 
 
   
   
 run
   
 
   
   
   
   org.apache.maven
   maven-artifact-ant
   2.0.4
   
   
   ant
   ant
   1.6.5
   
   
   ant-contrib
   cpptasks
   1.0b3
   
   
   ant-contrib
   ant-contrib
   1.0b2
   
   
   ant
   optional
   1.5.4
   
   
   ant
   ant-nodeps
   1.6.5
   

   
 
[snip]

 in build.xml
 
  

-Original Message-
From: Niranjan Deshpande [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 06, 2008 9:02 AM
To: Maven Users List; [EMAIL PROTECTED]
Subject: Re: need help in ant's javadoc task (from maven)


I got this when I ran your debug script. Error executing ant tasks


_

Embedded error: The following error occurred while executing this line:
/home/apli/APPWeb/src/main/build/generate/generate-appcodes.xml:37:

Could not create task or type of type: echoproperties.

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

This is common and has a number of causes; the usual
solutions are to read the manual pages then download and install needed JAR
files, or fix the build file:
 - You have misspelt 'echoproperties'.
  Fix: check your spelling.
 - The task needs an external JAR file to execute
and this is not found at the right place in the classpath.
  Fix: check the documentation for dependencies.
  Fix: declare the task.
 - The task is an Ant optional task and the JAR file and/or libraries
implementing the functionality were not found at the time you
yourself built your installation of Ant from the Ant sources.
  Fix: Look in the ANT_HOME/lib for the 'ant-' JAR corresponding to the
task and make sure it contains more than merely a META-INF/MANIFEST.MF.
If all it contains is the manifest, then rebuild Ant with the needed
libraries present in ${ant.home}/lib/optional/ , or alternatively,
download a pre-built release version from apache.org
 - The build file was written for a later version of Ant
  Fix: upgrade to at least the latest release version of Ant
 - The task is not an Ant core or optional task
and needs to be declared using .
 - You are attempting to use a task defined using
or  but have spelt wrong or not
  defined it at the point of use

Remember that for JAR files to be visible to Ant tasks implemented in
ANT_HOME/lib, the files must be in the same directory or on the classpath

Please neither file bug reports on this problem, nor email the Ant mailing
lists, until all of these causes have been explored, as this is not an Ant
bug.


_

my xml file is in src/main/build/generate folder
and the dependency jars are in folder src/main/build/lib and
src/main/webapp/WEB-INF/lib I am using the  to
point to these jars and and the tools.classpath is used by the ant's doclet
task fpr the "path" attribute.

What might be wrong?



On 6/6/08, Sean Hennessy <[EMAIL PROTECTED]> wrote:




  

 
-"/>

 
 
 
 
 
   

-Original Message-
From: Niranjan Deshpande [mailto:[EMAIL PROTECTED]
Sent: Friday, June 06, 2008 5:54 AM
To: [EMAIL PROTECTED]; Maven Users List
Subject: need help in ant's javadoc task (from maven)


I am trying to generate a .properties file using javadocs in a java
source file, and i am using ant's  task to do this.

but i am getting this error when i run the antrun plugin

generate.appcodes:
[javadoc] Generating Javadoc
[javadoc] Javadoc execution
[javadoc] javadoc: Cannot find doclet class
com.company.app.util.doclet.AppCodesD

Re: Calling ant tasks from maven pom

2008-06-05 Thread Tim Kettler

Niranjan Deshpande schrieb:

Tim i indeed wht u suggested

 


but the build xmls just dont seem to to reached..


It's working for me with this test project:

  .
  |-- pom.xml
  `-- src
  `-- main
  |-- antscripts
  |   |-- antscript1.xml
  |   `-- antscript2.xml
  `-- java


relevant snippet from pom.xml:

  
org.apache.maven.plugins
maven-antrun-plugin

  
hello-from-ant
generate-sources

  run

  


  
target="printhello"/>
target="printhello"/>

  

  


When invoking maven with a phase liek 'mvn package' tha ant tasks get 
executed during the spcified 'generate-sources' phase. And when invoking 
the antrun-plugin directly via 'mvn antrun:run' the scripts get called, too.


As you see I used the default  section outside of the 
. If you don't need to invoke the ant scripts standalone, I 
would move the configuration back inside the defined execution.


-Tim


On Thu, Jun 5, 2008 at 6:53 PM, Tim Kettler <[EMAIL PROTECTED]> wrote:


Hi, (again :-) )

Niranjan Deshpande schrieb:

 I am trying to execute ant tasks from maven's pom as below.




maven-antrun-plugin

1.1





generate-sources















run








The generate.sh file has 10 xml files that i want to run as
ant -buildfile -filename

for the time being I am running the plugin as maven antrun:run, just to
find
whether the .sh file is called or not. But i am geting this:
[INFO] [antrun:run]
[INFO] Executing tasks
[INFO] Executed tasks

I have added a ECHO in the .sh file, but i see none at the output



First to answer your concrete problem: When you call a plugin goal directly
from the commandline it uses the common configuration under
 as there may be more than one execution defined
and there is no sane way to decide which ones configuration to use.

Secondly, just to recap that I understood correctly what you are doing:

You have a maven build from which you want to call a shell script which in
turn triggers a few ant builds?!?

Cant you just configure multiple calls of the  task [1] in your
antrun-plugin configuration and throw away the shell script completely?

-Tim

[1] http://ant.apache.org/manual/CoreTasks/ant.html

-
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: Calling ant tasks from maven pom

2008-06-05 Thread Tim Kettler


Hi, (again :-) )

Niranjan Deshpande schrieb:

 I am trying to execute ant tasks from maven's pom as below.




maven-antrun-plugin

1.1





generate-sources















run








The generate.sh file has 10 xml files that i want to run as
ant -buildfile -filename

for the time being I am running the plugin as maven antrun:run, just to find
whether the .sh file is called or not. But i am geting this:
[INFO] [antrun:run]
[INFO] Executing tasks
[INFO] Executed tasks

I have added a ECHO in the .sh file, but i see none at the output



First to answer your concrete problem: When you call a plugin goal 
directly from the commandline it uses the common configuration under 
 as there may be more than one execution 
defined and there is no sane way to decide which ones configuration to use.


Secondly, just to recap that I understood correctly what you are doing:

You have a maven build from which you want to call a shell script which 
in turn triggers a few ant builds?!?


Cant you just configure multiple calls of the  task [1] in your 
antrun-plugin configuration and throw away the shell script completely?


-Tim

[1] http://ant.apache.org/manual/CoreTasks/ant.html

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



Re: [m2] Error getting reports from the plugin 'org.apache.maven.plugins:maven-project-info-reports-plugin'

2008-06-05 Thread Tim Kettler

Hi,

Mick Knutson schrieb:

I have the following for my reports declaration:
...

Then I noticed Checkstyle 2.2 got downloaded this morning on my build (mvn
site actually), but then I got this failure:


[...]

Could this be related to this [1] recent discussion on the dev list. I 
haven't followed the discussion closely, but skimming through your log 
it's about the same topic: site plugin, project-info-report and snapshots


-Tim

[1] 
http://www.nabble.com/Multiple-concurrent-SNAPSHOTs-for-MSITE-and-MPIR-isn%27t-working-to17607858.html


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



Re: download maven-antrun-plugin

2008-06-05 Thread Tim Kettler

Hi,

Niranjan Deshpande schrieb:

please give me the link from where I can download this plugin.



You don't need to download a plugin in maven 2 manually, just configure 
it in your POM and maven will take care of downloading it to your local 
repository during execution.


On the plugin homepage [1] you can find instructions on how to configure 
it in your POM.


-Tim

[1] http://maven.apache.org/plugins/maven-antrun-plugin/

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



Re: Ant Task - Build maven pom.xml

2008-06-04 Thread Tim Kettler

Hi,

halsafar schrieb:

I am trying to write an ant script to automate some maven tasks and hopefully
decide not to rebuild the entire thing if it detects no changes.  Just to
give an idea I am working with Jasig CAS Server which has several modules
all which are Maven projects.  The build time is brutal on this beast and it
will always rebuild no matter what it seems.  So even if Ant won't help I am
still stuck using Ant as I need to auto-deploy the CAS Server to both a
Tomcat and Glassfish server.  Now everything has been done and Maven is
being run from a simple  call in the build.xml for the ant script.  I
did find some Official Maven Ant Tasks jar I would like to try.  However I
have been unable to find any examples which actually show this maven ant
tasks   building a maven project.  Any help?


The maven ant tasks bring the dependency management features of maven to 
ant, they don't enable ant to build a maven project. Anyway, here [1] is 
the link to the official homepage containing usage instructions.


-Tim

[1] http://maven.apache.org/ant-tasks.html

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



Re: plugin jar: A better way to add custom classpath entries in manifest file?

2008-06-04 Thread Tim Kettler

Hi,

Maximilian Eberl schrieb:

The problem:

I have resources OUTSIDE the jar like config files 
that have to be edited by the user and resources IN 
the jar, so that the user cannot accidently delete 
or willingly replace them. Images, for example.


Using those in a (SWT-)class would look like:

Image img01 = new Image(display, "/img/nice.png");

This will look up for a file nice.png in a subfolder 
"img" packed in the jar along with the classes:


JAR
 --com/mycompany/swtapp/MyClass.class
 |-img/nice.png


I'm no SWT expert, but looking at the Image Javadoc [1] it seems this is
a misunderstanding on your side. The constructor you are using is
intended to load images out of files on the filesystem and not to load
an image from a classpath resource. The correct way to load images from
resources would be to get a stream of the resource from a classloader
and then pass this to the image constructor.

Or I'm just reading the javadoc completely wrong or just misunderstood
you ;-)


But ONLY if the manifest File contains an extra
entry


I don't understand why this helps in your situation in the first place
but the need to add the 'img' directory to the classpath should go away
if you load the images properly as classpath resources.


ClassPath: img

If this is not explicitely written in the 
MANIFEST.MF, the app throws a NullPointer.


I tried the tag:
true
but this only adds the dependency classpath
Do I have to define the img-folder as a
dependency? 


I tried to use
img
but mvn didn't recognize the tag (of course).

I had to specify a custom manifest file
with 
src/main/META-INF/MANIFEST.MF

looking like this:
 Main-Class: com/mycompany/swtapp/App
 Class-Path: img

just for the simple Task of adding a 
ClassPath entry to the manifest file.


OK, it did what I expected, but isn't there a
more elegant way to do it? For example a simple
-Tag in the archiver plugin
could do the work.



-Tim

[1]
http://help.eclipse.org/stable/nftopic/org.eclipse.platform.doc.isv/reference/api/org/eclipse/swt/graphics/Image.html




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



Re: java.net.SocketException - need help in getting started

2008-06-04 Thread Tim Kettler

Hi,

googling hints that it's a bug in the java sdk on freebsd. There is a 
similar bug report like yours for freebsd 6 posted for IDEA [1] which 
says that IPv6 support in the jdk is the problem. This [2] is another 
bug report of the same problem with the solution to set the JAVAVM_OPTS 
like this:


  export JAVAVM_OPTS_java=-Djava.net.preferIPv4Stack=true"

And finally this bug was reported [3] on the freebsd-java list some time 
ago.


Hope this helps
-Tim

[1] http://www.jetbrains.net/jira/browse/IDEA-15976
[2] 
http://unix.derkeiler.com/Mailing-Lists/FreeBSD/stable/2007-11/msg00220.html

[3] http://lists.freebsd.org/pipermail/freebsd-java/2007-August/006544.html

Gianni Doe schrieb:
Hi, I'm completely new to maven and just trying out the "Maven in 5 
Minutes" but not getting very far.
When I try to create a new project I get the exception below; my machine 
has unimpeded access to the internet so the issue is not firewall related.

I'd appreciate some suggestions.

[EMAIL PROTECTED]:/data/Projects$ mvn -X archetype:create -DgroupId=com.test 
-DartifactId=testapp


+ Error stacktraces are turned on.
Maven version: 2.0.9
Java version: 1.6.0_03-p4
OS name: "freebsd" version: "7.0-stable" arch: "amd64" Family: "unix"
[DEBUG] Building Maven user-level plugin registry from: 
'/home/shares/.m2/plugin-registry.xml'
[DEBUG] Building Maven global-level plugin registry from: 
'/usr/local/apache-maven/conf/plugin-registry.xml'

[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'archetype'.
[DEBUG] Loading plugin prefixes from group: org.apache.maven.plugins
[INFO] org.apache.maven.plugins: checking for updates from central
[WARNING] repository metadata for: 'org.apache.maven.plugins' could not 
be retrieved from repository: central due to an error: Error 
transferring file

[DEBUG] Exception
org.apache.maven.wagon.TransferFailedException: Error transferring file
at 
org.apache.maven.wagon.providers.http.LightweightHttpWagon.fillInputData(LightweightHttpWagon.java:104) 


at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:68)
at 
org.apache.maven.artifact.manager.DefaultWagonManager.getRemoteFile(DefaultWagonManager.java:470) 

at 
org.apache.maven.artifact.manager.DefaultWagonManager.getArtifactMetadata(DefaultWagonManager.java:370) 

at 
org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.resolve(DefaultRepositoryMetadataManager.java:97) 

at 
org.apache.maven.plugin.DefaultPluginMappingManager.loadPluginMappings(DefaultPluginMappingManager.java:103) 

at 
org.apache.maven.plugin.DefaultPluginMappingManager.loadPluginMappings(DefaultPluginMappingManager.java:87) 

at 
org.apache.maven.plugin.DefaultPluginMappingManager.getByPrefix(DefaultPluginMappingManager.java:61) 

at 
org.apache.maven.plugin.DefaultPluginManager.getPluginDefinitionForPrefix(DefaultPluginManager.java:154) 

at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.getMojoDescriptor(DefaultLifecycleExecutor.java:1468) 

at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.segmentTaskListByAggregationNeeds(DefaultLifecycleExecutor.java:405) 

at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:137) 


at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:287)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) 

at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) 


at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at 
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)

at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.net.SocketException: Invalid argument
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
at java.net.Socket.connect(Socket.java:519)
at java.net.Socket.connect(Socket.java:469)
at sun.net.NetworkClient.doConnect(NetworkClient.java:157)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:394)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:529)
at sun.net.www.http.HttpClient.(HttpClient.java:233)
at sun.net.www.http.HttpClient.New(HttpClient.java:306)
at sun.net.www.http.HttpClient.New(HttpClient.java:

Re: Need help | Getting NPE while using "mvn install"

2008-06-04 Thread Tim Kettler

JINDAL, Mukta, IDC schrieb:

But 'mvn install' should only install the project's artifact in your local repository 
(~/.m2/repository/...) and not try to deploy it to a remote repo. >> Or have 
you configured the deploy plugin in yor pom to run in the install phase, which IMHO 
would be a bad practice?


How can I check this thing ? I searched for words "deploy" and "install" in my 
POM but found none.


You can run 'mvn help:effective-pom' [1]. This prints out the actual POM 
maven is using to build the project, including configurations made in 
parent poms.



In plugins, we have only following entries:
  



maven-compiler-plugin

1.5
1.5




org.apache.maven.plugins
maven-surefire-plugin
2.4.1
    






-Tim

[1] http://maven.apache.org/plugins/maven-help-plugin/

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



Re: Need help | Getting NPE while using "mvn install"

2008-06-04 Thread Tim Kettler

JINDAL, Mukta, IDC schrieb:

Thanks for the reply, Tim.

I am executing "mvn install", not "mvn deploy".


But 'mvn install' should only install the project's artifact in your 
local repository (~/.m2/repository/...) and not try to deploy it to a 
remote repo. Or have you configured the deploy plugin in yor pom to run 
in the install phase, which IMHO would be a bad practice?



Also, I tried using scpext, but got following error:


Sorry, my fault, that should be scpexe.

Here [1] you will find a small guide on how to deploy via scpexe.


[INFO] 
[ERROR] BUILD ERROR
[INFO] 
[INFO] Error deploying artifact: Unsupported Protocol: 'scpext': Cannot find 
wagon which supports the requested protocol: scpext
Component descriptor cannot be found in the component repository: 
org.apache.maven.wagon.Wagonscpext.

Regards,
Mukta Jindal



[...]

-Tim

[1] 
http://maven.apache.org/plugins/maven-deploy-plugin/examples/deploy-ssh-external.html


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



Re: Need help | Getting NPE while using "mvn install"

2008-06-03 Thread Tim Kettler

JINDAL, Mukta, IDC schrieb:

Hi All,


Hi,



I am getting following error while using "mvn install" though "mvn package" is 
working fine.


Judging from the stacktrace below you ran 'mvn deploy', not 'mvn 
install' (see the reference to the deploy mojo). As the deploy phase is 
executed after the install phase, install seems to work just fine.



I did entire cleanup, restarted machine too.

What could be the possible reasons ?



The deploy tries to upload your artifact via SCP (JCrafts JSCH is the 
SSH library used by maven) to the remote repository you have configured 
in the  section of your POM and fails doing this.


You have to investigate why exactly it is failing for you. I would start 
trying to test if uploading something manually via commandline scp does 
work and then double check the maven ssh configuration. Another option 
is to try to switch from scp: to scpext: protocol in 
, so maven don't uses JSCH but the commandline 
scp application.





[INFO] 
[ERROR] FATAL ERROR
[INFO] 
[INFO] null
[INFO] 
[INFO] Trace
java.lang.NullPointerException
at com.jcraft.jsch.Session.disconnect(Unknown Source)
at 
org.apache.maven.wagon.providers.ssh.jsch.AbstractJschWagon.closeConnection(AbstractJschWagon.java:207)
at 
org.apache.maven.wagon.AbstractWagon.disconnect(AbstractWagon.java:153)
at 
org.apache.maven.artifact.manager.DefaultWagonManager.disconnectWagon(DefaultWagonManager.java:675)
at 
org.apache.maven.artifact.manager.DefaultWagonManager.getRemoteFile(DefaultWagonManager.java:551)
at 
org.apache.maven.artifact.manager.DefaultWagonManager.getArtifactMetadata(DefaultWagonManager.java:363)
at 
org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.resolveAlways(DefaultRepositoryMetadataManager.java:364)
at 
org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.resolveAlways(DefaultRepositoryMetadataManager.java:318)
at 
org.apache.maven.artifact.transform.SnapshotTransformation.resolveLatestSnapshotBuildNumber(SnapshotTransformation.java:161)
at 
org.apache.maven.artifact.transform.SnapshotTransformation.transformForDeployment(SnapshotTransformation.java:100)
at 
org.apache.maven.artifact.transform.DefaultArtifactTransformationManager.transformForDeployment(DefaultArtifactTransformationManager.java:78)
at 
org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:71)
at 
org.apache.maven.plugin.deploy.DeployMojo.execute(DeployMojo.java:162)
at 
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:447)
at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:539)
at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:480)
at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:459)
at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:311)
at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:278)
at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:143)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:333)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:126)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:282)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)

at org.codehaus.classworlds.Launcher.main(Launcher.java:375)

Thanks,
Mukta Jindal.



-Tim


***
The Royal Bank of Scotland plc. Registered in Scotland No 90312. Registered Office: 36 St Andrew Square, Edinburgh EH2 2YB. 
Authorised and regulated by the Financial Services Authority 
 
This e-mail message is confidential and for use by the 
addressee only. If the message is received by anyone other 
than the addressee, please return the message to the sender 
by replying to it and then delet

Re: Embedded error: Prohibited package name: java.lang

2008-06-01 Thread Tim Kettler

Hi,

John schrieb:

I am trying to use Maven 2.0.9 on OS X, with the latest Apple updates, and
am getting the following error when I run a basic "mvn install site"
command:

[INFO] Compiling 1 source file to
/Users/john/downloads/jms-mdb-sample/jms-mdb-sample-ejb/target/classes
[INFO] 


[ERROR] BUILD ERROR
[INFO] 


[INFO] Fatal error compiling

Embedded error: Prohibited package name: java.lang



Make sure your classes aren't in the java.lang package i.e. they aren't 
like java.lang.MyClass. You can also try to run maven with the -X option 
to show more information about the error like the thrown exception and a 
stacktrace.



I have tried to research the error by doing some googling but haven't come
up with any helpful information.

I would be very appreciative of any assistance to help me get past this.

Thanks,
John



-Tim

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



Re: Forcing site plugin version

2008-05-29 Thread Tim Kettler

Correct, project/build/pluginManagement.

Lalor, Brian schrieb:

-Original Message-
From: Tim Kettler [mailto:[EMAIL PROTECTED] 
Sent: Thursday, May 29, 2008 2:53 AM

To: Maven Users List
Subject: Re: Forcing site plugin version

Hi,

just add this to your pom:

   
 
   
 org.apache.maven.plugins
 maven-site-plugin
 2.0-beta-7
   
 
   


I believe that goes into the project/build element, correct?

-
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: What goals are available by defaut?

2008-05-29 Thread Tim Kettler

Hi,

unlike with maven1 there are no bundled plugins distributed with maven2, 
everything is downloaded on demand. The plugins developed by the maven 
team are listed here [1] and another huge collection of plugins is 
developed by the mojo project on codehaus.org [2]. If you're searching a 
specific plugin not available at the above locations, a google search 
like "PRODUCT_NAME maven plugin" usually helps. If you can't find a 
plugin you need at all, don't hesitate to ask here.


As a general advise to new maven users I would recommend reading at 
least the Getting Started Guide [3] and having a look at one of the free 
books about maven [4], [5]. A collection of useful guides is available 
here [6].


-Tim

[1] http://maven.apache.org/plugins/
[2] http://mojo.codehaus.org/plugins.html
[3] http://maven.apache.org/guides/getting-started/index.html
[4] http://www.sonatype.com/book/#
[5] http://www.exist.com/?q=node/151
[6] http://maven.apache.org/guides/index.html

darren smith schrieb:
Hello, 


Am very new to maven. I'd like to know what goals are available for my
firm-provided installation of maven.  I've searched the web and come up with
"mvn -g" but that doesn't seem to work on my version of maven (2.0.6).

So, is there a simple way to find out what goals my maven installation
offers me?

Regards,

Darren



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



Re: Forcing site plugin version

2008-05-28 Thread Tim Kettler

Hi,

just add this to your pom:

  

  
org.apache.maven.plugins
maven-site-plugin
2.0-beta-7
  

  


2.0-beta-7 isn't released yet, so you will have to build it yourself and 
then install it to your local repository or cut an internal release and 
deploy it to your internal repository.


-Tim

[EMAIL PROTECTED] schrieb:

I am using Maven 2.0.9 and am running into the bug detailed here:
http://jira.codehaus.org/browse/MSITE-211

Currently by default it seems to be using 2.0-beta-6 of the site plugin.

According to the bug report the bug is fixed in 2.0-beta-7.

How do I force Maven to use 2.0-beta-7 of this plugin?

Thanks

--
Craig Dickson
Software Engineering Manager
Behr Process Corporation
Santa Ana, California



_
The information contained in this e-mail message may be proprietary, 
privileged, confidential or protected from disclosure. If you are not the 
intended recipient, any dissemination, distribution or copying is strictly 
prohibited. If you think that you have received this e-mail message in 
error, please e-mail the sender. 



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



Re: RES: Problem with classloader in maven plugin

2008-05-22 Thread Tim Kettler

Hi,

Claudio Ranieri schrieb:

Hi,

Why the maven plugins doesn´t load all libraries declared in pom.xml?


You have to distinguish between the plugin project and the project you 
are using the plugin with. All libraries (with a proper scope) declared 
in the pom of the plugin project are available (on the classpath) to the 
plugin during execution. This includes libraries you are specifying in 
the  section of the project using your plugin.


The libraries declared in the pom of the project you are using your 
plugin in however, are not available. And for a good reason, just think 
abaout the bad things that could happen when both, the plugin and your 
project use the same library for example, but a different version of it.


The conclusion in one sentence: You don't ever want the dependencies 
(classpathes) of your project and the dependencies of a plugin used 
during the build of your project mixed.



I tried to use the initClassLoader because this code works in 
jaxws-maven-plugin.
In the code of jaxws-maven-plugin there is:

" Need to build a URLClassloader since Maven removed it form the chain "

Why?


I don't know the jaxws-maven-plugin, so I can't really tell anything 
about its design and implementation. You will have to ask the developers 
of the plugin about such specific questions.


All advice I can give you is that you should read and learn about the 
different kinds of classloaders (and classloaders in generel) in Java 
and how to properly use them.


So far, all plugins I've seen the source code of construct a new 
classloader with the classes the external tool needs and then use the 
loadClass() method of that classloader to get an instance of the class 
they need. Examples of this can be seen in the compiler-plugin or 
fit-maven-plugin (as someone on the dev list already wrote).



Thanks


-Tim


-----Mensagem original-
De: Tim Kettler [mailto:[EMAIL PROTECTED]
Enviada em: quarta-feira, 21 de maio de 2008 10:57
Para: Maven Users List
Assunto: Re: Problem with classloader in maven plugin

Hi,

you've missunderstood the concept of a context classloader.

A documentation bug [1] is open since a long time. Setting the context
classloader doesn't mean that all classes created from that point on are
created through this classloader. See here [2] and [3] for more information.

[1] http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4868493
[2] http://www.javaworld.com/javaqa/2003-06/01-qa-0606-load.html
[3] http://www.javageeks.com/Papers/ClassForName/index.html

-Tim

Claudio Ranieri schrieb:

Hi

I am trying to create a maven plugin to jboss wsconsume, but I have a problem 
with classloader in plugin.
My plugin is based in an ant task (WSConsumeTask).
I am using maven 2.0.8 on Windows machine.
When I created a simple Java project with libraries necessary, my code works.
How shown below:

public static void main(String[] args) {
  WSConsumeTask t = new WSConsumeTask();
  t.setWsdl("https://xxx/crypto?wsdl";);
  t.setVerbose(true);
  t.setKeep(true);
  t.execute();
}

But when I am using into maven plugin, I got problem with classloader.
I got this exception:

C:\eclipse\workspace\TestePluginMaven\output\com\buscape\bean\CryptoService.java:7:
 cannot find symbol
symbol  : class Service
location: package javax.xml.ws
import javax.xml.ws.Service;
^
C:\eclipse\workspace\TestePluginMaven\output\com\buscape\bean\CryptoService.java:8:
 cannot find symbol
symbol  : class WebEndpoint
location: package javax.xml.ws
import javax.xml.ws.WebEndpoint;
^
C:\eclipse\workspace\TestePluginMaven\output\com\buscape\bean\CryptoService.java:9:
 cannot find symbol
symbol  : class WebServiceClient
location: package javax.xml.ws
import javax.xml.ws.WebServiceClient;

The plugin classloader doesn´t load the jaxws libraries. But this libraries was 
added in pom.xml of plugin.
I tried to add dependencies tag in my plugin config, but didn´t works. How 
shown below:


  jboss
  maven-jbossws-plugin
  1.0.0
  
true
true
https://xxx/crypto?wsdl
  
  

  jboss.jbossws
  jaxws-tools
  3.0.1-native-2.0.4.GA
  compile


  jboss.jbossws
  jboss-jaxws
  3.0.1-native-2.0.4.GA
  compile

  


I tried too to use an initClassLoader based in jaxws-maven-plugin source, how 
shown below:

   private String initClassLoader(ClassLoader parent) throws 
MojoExecutionException {
try {
List classpathFiles = 
project.getCompileClasspathElements();
URL[] urls = new URL[classpathFiles.size() + 4];
StringBuffer classPath = new StringBuffer();
for (int i = 0; i < classpathFiles.size(); ++i) {
getLog().debug((String)classpathFiles.get(i));
urls[i] = new 
File((String)classpathFiles.get(i)).toURL();

Re: [SURVEY] How does your team retrieve artifacts?

2008-05-22 Thread Tim Kettler

> [x] Our team uses HTTP to retrieve our artifacts

HTTPS actually

> [ ] Our team uses the filesystem

Don't using this at the moment, but I think a filesystem based 
repository could be really useful for example when one wants/needs to 
ship a repository with a product.


-Tim

Jason van Zyl schrieb:

Hi,

I'm just trying to get some data on what protocol is used to retrieve 
artifacts. This question strictly relates to what you use for retrieval. 
Most people I have seen use a web server or a shared network drive, but 
I'd like to get some feedback.


[ ] Our team uses HTTP to retrieve our artifacts
[ ] Our team intends to use HTTP to retrieve our artifacts
[ ] Our team uses the filesystem
[ ] Our team does not use HTTP or the filesystem because  please say 
what protocol you use and the reason


Thanks,

Jason

--
Jason van Zyl
Founder,  Apache Maven
jason at sonatype dot com
--

A language that doesn’t affect the way you think about programming is 
not worth knowing.


— Alan Perlis




-
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: Problem with classloader in maven plugin

2008-05-21 Thread Tim Kettler

Hi,

you've missunderstood the concept of a context classloader.

A documentation bug [1] is open since a long time. Setting the context 
classloader doesn't mean that all classes created from that point on are 
created through this classloader. See here [2] and [3] for more information.


[1] http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4868493
[2] http://www.javaworld.com/javaqa/2003-06/01-qa-0606-load.html
[3] http://www.javageeks.com/Papers/ClassForName/index.html

-Tim

Claudio Ranieri schrieb:

Hi

I am trying to create a maven plugin to jboss wsconsume, but I have a problem 
with classloader in plugin.
My plugin is based in an ant task (WSConsumeTask).
I am using maven 2.0.8 on Windows machine.
When I created a simple Java project with libraries necessary, my code works.
How shown below:

public static void main(String[] args) {
  WSConsumeTask t = new WSConsumeTask();
  t.setWsdl("https://xxx/crypto?wsdl";);
  t.setVerbose(true);
  t.setKeep(true);
  t.execute();
}

But when I am using into maven plugin, I got problem with classloader.
I got this exception:

C:\eclipse\workspace\TestePluginMaven\output\com\buscape\bean\CryptoService.java:7:
 cannot find symbol
symbol  : class Service
location: package javax.xml.ws
import javax.xml.ws.Service;
^
C:\eclipse\workspace\TestePluginMaven\output\com\buscape\bean\CryptoService.java:8:
 cannot find symbol
symbol  : class WebEndpoint
location: package javax.xml.ws
import javax.xml.ws.WebEndpoint;
^
C:\eclipse\workspace\TestePluginMaven\output\com\buscape\bean\CryptoService.java:9:
 cannot find symbol
symbol  : class WebServiceClient
location: package javax.xml.ws
import javax.xml.ws.WebServiceClient;

The plugin classloader doesn´t load the jaxws libraries. But this libraries was 
added in pom.xml of plugin.
I tried to add dependencies tag in my plugin config, but didn´t works. How 
shown below:


  jboss
  maven-jbossws-plugin
  1.0.0
  
true
true
https://xxx/crypto?wsdl
  
  

  jboss.jbossws
  jaxws-tools
  3.0.1-native-2.0.4.GA
  compile


  jboss.jbossws
  jboss-jaxws
  3.0.1-native-2.0.4.GA
  compile

  


I tried too to use an initClassLoader based in jaxws-maven-plugin source, how 
shown below:

   private String initClassLoader(ClassLoader parent) throws 
MojoExecutionException {
try {
List classpathFiles = 
project.getCompileClasspathElements();
URL[] urls = new URL[classpathFiles.size() + 4];
StringBuffer classPath = new StringBuffer();
for (int i = 0; i < classpathFiles.size(); ++i) {
getLog().debug((String)classpathFiles.get(i));
urls[i] = new 
File((String)classpathFiles.get(i)).toURL();
classPath.append((String)classpathFiles.get(i));
classPath.append(File.pathSeparatorChar);
}
urls[classpathFiles.size()] = new 
File(project.getBuild().getOutputDirectory()).toURL();

urls[classpathFiles.size() + 1] = 
getArtifact("jboss.jbossws:jboss-jaxws");

urls[classpathFiles.size() + 2] = 
getArtifact("jboss.jbossws:jaxws-tools");

File toolsJar = new 
File(System.getProperty("java.home"),"../lib/tools.jar");
if (!toolsJar.exists()) {
toolsJar = new 
File(System.getProperty("java.home"),"lib/tools.jar");
}
urls[classpathFiles.size() + 3] = toolsJar.toURL();

System.out.println("urls: "+Arrays.toString(urls));

URLClassLoader cl = new URLClassLoader(urls,parent);
// Set the new classloader
Thread.currentThread().setContextClassLoader(cl);

System.setProperty("java.class.path",classPath.toString());
String sysCp = System.getProperty("java.class.path");
return sysCp;
}
catch (MalformedURLException e) {
throw new MojoExecutionException(e.getMessage(),e);
}
catch (DependencyResolutionRequiredException e) {
throw new MojoExecutionException(e.getMessage(),e);
}

}

public void execute() throws MojoExecutionException {
  // Need to build a URLClassloader since Maven removed it form 
the chain
ClassLoader parent = this.getClass().getClassLoader();
String originalSystemClasspath = this.initClassLoader( parent );

tr

Re: AW: WAS6-plugin error

2008-05-21 Thread Tim Kettler
I don't think this is possible. Why isn't just building the project (in 
Continuum) with 'mvn post-integration-test' or something like that an 
option?


Lustig, Marc (Allianz Deutschland AG) schrieb:

ty for the hint, but this won't help as we want to use the was6-plugin for 
Continuous Integration (with Continuum), i. e. the deployment package will be 
build by Continuum in an arbitrary tmp-file, hence we don't no the path in 
advance.

The was6-plugin should either pick the deployment package up from the 
target-dir, or alternatively, from the local maven repo.

Is either of this possible?


-Ursprüngliche Nachricht-
Von: Tim Kettler [mailto:[EMAIL PROTECTED] 
Gesendet: Mittwoch, 21. Mai 2008 10:58

An: Maven Users List
Betreff: Re: WAS6-plugin error

Hi,

I've never used the was-plugin, but looking at the documentation and 
source code, it seems that the default assumption of the 'installAp' 
goal is that it is running as part of a maven build.


The 'earFile' parameter is automatically populated with the current 
projects main artifact [1], which is obviously not available when you 
invoke the goal standalone. What should work, is that you specify the 
ear file explicitly on the command line:


   mvn -Dwas6.earFile=/path/to/my.ear  was6:installApp

Hope this helps
-Tim

[1] http://mojo.codehaus.org/was6-maven-plugin/installApp-mojo.html#earFile

Lustig, Marc (Allianz Deutschland AG) schrieb:

mvn package

..
[INFO] BUILD SUCCESSFUL
..

mvn was6:installApp

...
[ERROR] FATAL ERROR
[INFO]

[INFO] null
[INFO]

[INFO] Trace
java.lang.NullPointerException
at
org.codehaus.mojo.was6.WsInstallAppMojo.configureBuildScript(WsInstallAp
pMojo.java:54)


the pom.xml look like this:

org.codehaus.mojo

was6-maven-plugin
1.0-alpha-2



integration-test

integration-test


wsStopServer

installApp

wsStartServer
  




c:/Programme/ibm/SDP70/runtimes/base_v61
localhost
admin



AppSrv01

SOAP
8880
true
   
	

false



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




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


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




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



Re: WAS6-plugin error

2008-05-21 Thread Tim Kettler

Hi,

I've never used the was-plugin, but looking at the documentation and 
source code, it seems that the default assumption of the 'installAp' 
goal is that it is running as part of a maven build.


The 'earFile' parameter is automatically populated with the current 
projects main artifact [1], which is obviously not available when you 
invoke the goal standalone. What should work, is that you specify the 
ear file explicitly on the command line:


  mvn -Dwas6.earFile=/path/to/my.ear  was6:installApp

Hope this helps
-Tim

[1] http://mojo.codehaus.org/was6-maven-plugin/installApp-mojo.html#earFile

Lustig, Marc (Allianz Deutschland AG) schrieb:

mvn package

..
[INFO] BUILD SUCCESSFUL
..

mvn was6:installApp

...
[ERROR] FATAL ERROR
[INFO]

[INFO] null
[INFO]

[INFO] Trace
java.lang.NullPointerException
at
org.codehaus.mojo.was6.WsInstallAppMojo.configureBuildScript(WsInstallAp
pMojo.java:54)


the pom.xml look like this:

org.codehaus.mojo

was6-maven-plugin
1.0-alpha-2



integration-test

integration-test


wsStopServer

installApp

wsStartServer
  




c:/Programme/ibm/SDP70/runtimes/base_v61
localhost
admin



AppSrv01

SOAP
8880
true
   
	

false



-
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: AW: How to install / deploy a custom artifact?

2008-05-20 Thread Tim Kettler

Hi,

if you build the zip with the assembly-plugin just use the singe or 
attach goal to build the assembly. It will then get attached to the 
project automatically and the deploy plugin will deploy it alongside the 
other project artifacts in the deploy phase.


If you generate the zip in some other way, you can use the 
buildhelper-plugin [1] from the mojo project to attach arbitrary 
artifacts to your projects.


-Tim

[1] http://mojo.codehaus.org/build-helper-maven-plugin/

Nicolai Wöller schrieb:

Hi again,

I know that I have to use the deploy phase when I want to deploy an artifact 
;-) My question was how do I tell maven to deploy or install a custom artifact 
and not just a plain .jar-file.


-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Im Auftrag von Jeff MAURY
Gesendet: Dienstag, 20. Mai 2008 12:46
An: Maven Users List
Betreff: Re: How to install / deploy a custom artifact?

Use the mvn deploy phase.

Jeff MAURY

On Tue, May 20, 2008 at 12:40 PM, Nicolai Wöller <[EMAIL PROTECTED]>
wrote:


Hello,

I am building a custom artifact (.zip-file) during the package phase, 
which I'd like to install and / or deploy into a local / remote maven 
repository instead of the plain .jar-file.

Is this possible and how do I manage to do this?

Thanks

Nico





--
La mélancolie c'est communiste
Tout le monde y a droit de temps en temps La mélancolie n'est pas capitaliste 
C'est même gratuit pour les perdants La mélancolie c'est pacifiste On ne lui 
rentre jamais dedans La mélancolie oh tu sais ça existe Elle se prend même avec 
des gants La mélancolie c'est pour les syndicalistes Il faut juste sa carte de 
permanent

Miossec (2006)

http://www.jeffmaury.com
http://riadiscuss.jeffmaury.com
http://www.lastfm.fr/listen/user/jeffmaury/personal


-
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: classpath fileseparator problem in generated manifest file under winxp

2008-05-19 Thread Tim Kettler
What do you mean by working example? you project build is behaving 
exactly as it should. Class-path entries in a jar manifest are


  "...relative URLS .. " [1]

and a file URL per definition [2] (section 3.10) contains forward slashes.

If your library-jars are located in the same directory as the jar with 
the class-path entry you don't need a prefix at all. If the jars are 
located in a subdirectory called 'libs' you need to specify the prefix 
as 'libs/'


-Tim

[1] 
http://java.sun.com/javase/6/docs/technotes/guides/jar/jar.html#Main%20Attributes

[2] http://www.rfc.net/rfc1738.html

Thalmeiner Zsolt schrieb:

Can you send me a simple working example?
Thank you in advance.
th

Paolo Compieta írta:

This is not a Maven problem.

The classpath entry in the manifest file is platform independent, and all
paths are relative to the containing jar - you shouldn't even need the 
"./"

prefix.
see http://mindprod.com/jgloss/jar.html#CLASSPATH

Regards,
PC


Thalmeiner Zsolt wrote:
 

Using the .\ tag I want to get ".\"
(backslash) as prefix but the manifest file contains "./" (slash)
prefixes. Unfortunatelly running the jar under WinXP doesn't recognizes
paths with slashes :(
I wrote to the list because I didn't found any information in doc 
pages to

handle this problem.

Regards,
th

-
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: duplicate war directory inside WEB-INF/classes

2008-05-19 Thread Tim Kettler

Hi,

I just tried with your POM (obviously without parent) and a simple test 
project:


  .
  |-- pom.xml
  `-- src
  `-- main
  |-- resources
  |   `-- test.properties
  `-- webapp
  |-- WEB-INF
  |   |-- beans
  |   |-- defs
  |   |-- flows
  |   |-- jsps
  |   `-- web.xml
  |-- css
  `-- index.jsp

and the war created by 'mvn package' (maven 2.0.9, war-plugin 
2.1-alpha-1) looks just as it should, no duplicate entries:


  .
  |-- META-INF
  |-- WEB-INF
  |   |-- beans
  |   |-- classes
  |   |   `-- test.properties
  |   |-- defs
  |   |-- flows
  |   |-- jsps
  |   `-- web.xml
  |-- css
  `-- index.jsp

It seems, there is something wrong on your side, not mavens. I would 
suggest that you just copy the project structure to a new directory 
iteratively, checking when the error starts happening.


By the way, the war plugin definition with the empty configuration in 
your pom.xml is redundant, the war plugin is executed by default if you 
specify packaging 'war'.


-Tim

aidanb5 schrieb:

Hi, I'm trying to build a simple war using maven 2 the structure follows the
standard directory layout:

sja/src/main/resources contains a property file
sja/src/main/webapp contains the webapp and has the following subdirs

./css
./WEB-INF/defs
./WEB-INF/beans
./WEB-INF/flows
./WEB-INF/jsps

my pom is as follows:

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

4.0.0

base-project
com.sms
1.0

com.sms.iforms2.forms
sjawar
war
SJA war



1.0




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








base project just contains the pointer to a maven proxy repository - no
actual application configuration.


when i run the build (mvn clean package) I get a war file but within the
WEB-INF/classes directory is another nested copy of the entire war so in
effect i end with with:

sjawar-1.0.war/web-inf/classes/sjawar-1.0/web-inf   etc

Could someone please help me with this as I'm totally stuck.

Thanks!



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



Re: Maven not recognising the local repository

2008-05-18 Thread Tim Kettler

Hi,

More information is needed to solve your problem. Can you post the exact 
error message maven prints (probably it would be best to post the 
relevant output from the build log running maven with -X).


How was the repository poulated? Did maven download the dependencies at 
one point and now just doesn't see them anymore or did you copy them 
there manually.


Did you configure something in your settings.xml regarding the location 
of your local repository?


-Tim

NinaBinde schrieb:

My project fails to compile since it is not recognising any of the packages
in the repository. The repository is in my local Document and Settings/...
folder and I can see all the jars there.  
Anybody has any clues as why this would happen? Thanks in advance.



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



Re: filtering web.xml

2008-05-16 Thread Tim Kettler
There's currently a discussion on the dev list [1] about releasing the 
next version of the war plugin. I posted there yesterday that this bug 
should be fixed before a release, you can express your opinion there as 
well. Additionally, you can vote on the bug report in jira, to make it 
more visible to the developers that this is an urgent issue for users.


-Tim

[1] 
http://www.nabble.com/Releasng-the-war-and-deploy-plugins-to17155510.html


Henri Gomez schrieb:

There is a patch provided in http://jira.codehaus.org/browse/MWAR-133.

How can I contact the maintener for a fix ?

2008/5/16 Henri Gomez <[EMAIL PROTECTED]>:

I tested with 2.1-alpha and same problem ;(

2008/5/16 Tim Kettler <[EMAIL PROTECTED]>:

It's a bug in the war plugin. The resource filtering is seriously borked
there, see here [1] for a bug report back from Nov 2007. The obvious and
simple workaround would be to filter web.xml as a normal resource in a
custom invocation of the resource plugin. But unfortunately there is a bug
in the resource plugin as well [2] (open since 2006), causing it to not
recognize a resources element in the plugin configuration.

Sometimes maven is no fun at all :-(

[1] http://jira.codehaus.org/browse/MWAR-133
[2] http://jira.codehaus.org/browse/MRESOURCES-8

Henri Gomez schrieb:

I suspect something weird in maven-war plugin (2.0.2) since I get the
same error from m2eclipse which use maven 2.1 embedded

2008/5/16 Henri Gomez <[EMAIL PROTECTED]>:

*.version => pom.version

*.name => pom.name

2008/5/16 Henri Gomez <[EMAIL PROTECTED]>:

Problem in maven-war 2.0.2 or in maven 2.0.9 ?

2008/5/16 Tim Kettler <[EMAIL PROTECTED]>:

Strange, indeed.

Looks like a bug to me. I tried with this in web.xml and no filter
property
files:

 pom.name: ${pom.name}
 user.name: ${user.name}
 name: ${name}
 foo.name: ${foo.name}

 pom.version: ${pom.version}
 os.version: ${os.version}
 version: ${version}
 foo.version: ${foo.version}

And the filtered result is this:

 pom.name: servlet
 user.name: servlet
 name: servlet
 foo.name: servlet

 pom.version: 1.0
 os.version: 1.0
 version: 1.0
 foo.version: 1.0

It seems that the system properties get somehow shadowed by the
standard pom
properties. This seems to be the case even for custom properties like
foo.version that are not defined anywhere.

-Tim

Henri Gomez schrieb:

Strange.

I could get thru filter ${user.home} or ${java.version} but not
${user.name}

Any idea ?

2008/5/16 Henri Gomez <[EMAIL PROTECTED]>:

Many thanks Tim.

I was using the same thing, excepted WEB-INF

It works now !

2008/5/16 Tim Kettler <[EMAIL PROTECTED]>:

Hi,

I do it like this:

 
 
   
 org.apache.maven.plugins
 maven-war-plugin
 
   
 
   ${basedir}/src/main/webapp/WEB-INF
   
 web.xml
   
   WEB-INF
   true
 
   
 
   
 
 

and I think this is the right way to do it since standard resources
end
up
somewhere under 'target/classes' and I don't want that polluted with
a
web.xml file.

-Tim

Henri Gomez schrieb:

Hi to all,

In a war project I'd like to filter the
src/main/webapp/WEB-INF/web.xml
:

ie : update the display name to include the pom version

 My Site Application
v${pom.version}

I read some threads and it's not clear if it should be done by
web-resources or standard filtering.

ie :


http://www.nabble.com/War-plugin-and-filtering-webapp-files-to4384723.html


Advice welcome, I'm using maven-war-plugin 2.0.2

regards and thanks for your help, I'm being crasy :)


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


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



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


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



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



-
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: filtering web.xml

2008-05-16 Thread Tim Kettler
It's a bug in the war plugin. The resource filtering is seriously borked 
there, see here [1] for a bug report back from Nov 2007. The obvious and 
simple workaround would be to filter web.xml as a normal resource in a 
custom invocation of the resource plugin. But unfortunately there is a 
bug in the resource plugin as well [2] (open since 2006), causing it to 
not recognize a resources element in the plugin configuration.


Sometimes maven is no fun at all :-(

[1] http://jira.codehaus.org/browse/MWAR-133
[2] http://jira.codehaus.org/browse/MRESOURCES-8

Henri Gomez schrieb:

I suspect something weird in maven-war plugin (2.0.2) since I get the
same error from m2eclipse which use maven 2.1 embedded

2008/5/16 Henri Gomez <[EMAIL PROTECTED]>:

*.version => pom.version

*.name => pom.name

2008/5/16 Henri Gomez <[EMAIL PROTECTED]>:

Problem in maven-war 2.0.2 or in maven 2.0.9 ?

2008/5/16 Tim Kettler <[EMAIL PROTECTED]>:

Strange, indeed.

Looks like a bug to me. I tried with this in web.xml and no filter property
files:

 pom.name: ${pom.name}
 user.name: ${user.name}
 name: ${name}
 foo.name: ${foo.name}

 pom.version: ${pom.version}
 os.version: ${os.version}
 version: ${version}
 foo.version: ${foo.version}

And the filtered result is this:

 pom.name: servlet
 user.name: servlet
 name: servlet
 foo.name: servlet

 pom.version: 1.0
 os.version: 1.0
 version: 1.0
 foo.version: 1.0

It seems that the system properties get somehow shadowed by the standard pom
properties. This seems to be the case even for custom properties like
foo.version that are not defined anywhere.

-Tim

Henri Gomez schrieb:

Strange.

I could get thru filter ${user.home} or ${java.version} but not
${user.name}

Any idea ?

2008/5/16 Henri Gomez <[EMAIL PROTECTED]>:

Many thanks Tim.

I was using the same thing, excepted WEB-INF

It works now !

2008/5/16 Tim Kettler <[EMAIL PROTECTED]>:

Hi,

I do it like this:

 
  

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

  
${basedir}/src/main/webapp/WEB-INF

  web.xml

WEB-INF
true
  

  

  
 

and I think this is the right way to do it since standard resources end
up
somewhere under 'target/classes' and I don't want that polluted with a
web.xml file.

-Tim

Henri Gomez schrieb:

Hi to all,

In a war project I'd like to filter the src/main/webapp/WEB-INF/web.xml
:

ie : update the display name to include the pom version

  My Site Application v${pom.version}

I read some threads and it's not clear if it should be done by
web-resources or standard filtering.

ie :

http://www.nabble.com/War-plugin-and-filtering-webapp-files-to4384723.html


Advice welcome, I'm using maven-war-plugin 2.0.2

regards and thanks for your help, I'm being crasy :)

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


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



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



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




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




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



Re: filtering web.xml

2008-05-16 Thread Tim Kettler

Strange, indeed.

Looks like a bug to me. I tried with this in web.xml and no filter 
property files:


  pom.name: ${pom.name}
  user.name: ${user.name}
  name: ${name}
  foo.name: ${foo.name}

  pom.version: ${pom.version}
  os.version: ${os.version}
  version: ${version}
  foo.version: ${foo.version}

And the filtered result is this:

  pom.name: servlet
  user.name: servlet
  name: servlet
  foo.name: servlet

  pom.version: 1.0
  os.version: 1.0
  version: 1.0
  foo.version: 1.0

It seems that the system properties get somehow shadowed by the standard 
pom properties. This seems to be the case even for custom properties 
like foo.version that are not defined anywhere.


-Tim

Henri Gomez schrieb:

Strange.

I could get thru filter ${user.home} or ${java.version} but not ${user.name}

Any idea ?

2008/5/16 Henri Gomez <[EMAIL PROTECTED]>:

Many thanks Tim.

I was using the same thing, excepted WEB-INF

It works now !

2008/5/16 Tim Kettler <[EMAIL PROTECTED]>:

Hi,

I do it like this:

 
   
 
   org.apache.maven.plugins
   maven-war-plugin
   
 
   
 ${basedir}/src/main/webapp/WEB-INF
 
   web.xml
 
 WEB-INF
 true
   
 
   
 
   
 

and I think this is the right way to do it since standard resources end up
somewhere under 'target/classes' and I don't want that polluted with a
web.xml file.

-Tim

Henri Gomez schrieb:

Hi to all,

In a war project I'd like to filter the src/main/webapp/WEB-INF/web.xml :

ie : update the display name to include the pom version

   My Site Application v${pom.version}

I read some threads and it's not clear if it should be done by
web-resources or standard filtering.

ie :
http://www.nabble.com/War-plugin-and-filtering-webapp-files-to4384723.html


Advice welcome, I'm using maven-war-plugin 2.0.2

regards and thanks for your help, I'm being crasy :)

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



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




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




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



Re: filtering web.xml

2008-05-16 Thread Tim Kettler

Hi,

I do it like this:

  

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

  

  ${basedir}/src/main/webapp/WEB-INF
  
web.xml
  
  WEB-INF
  true

  

  

  

and I think this is the right way to do it since standard resources end 
up somewhere under 'target/classes' and I don't want that polluted with 
a web.xml file.


-Tim

Henri Gomez schrieb:

Hi to all,

In a war project I'd like to filter the src/main/webapp/WEB-INF/web.xml :

ie : update the display name to include the pom version

My Site Application v${pom.version}

I read some threads and it's not clear if it should be done by
web-resources or standard filtering.

ie : http://www.nabble.com/War-plugin-and-filtering-webapp-files-to4384723.html


Advice welcome, I'm using maven-war-plugin 2.0.2

regards and thanks for your help, I'm being crasy :)

-
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: Component descriptor cannot be found in the component repository: org.apache.maven.lifecycle.mapping.LifecycleMappingmaven-archetype.

2008-05-15 Thread Tim Kettler

Hi,

an archetype project is a standard jar project. There is no specific 
'maven-archetype' packaging defined, hence the error. Just omit the 
 declaration or change it to 'jar'.


Have a look here [1] for a short introduction of how to create 
archetypes by hand and here [2] for a description of the goals of the 
archetype plugin.


-Tim

[1] http://maven.apache.org/guides/mini/guide-creating-archetypes.html
[2] http://maven.apache.org/plugins/maven-archetype-plugin/

Stefano Fornari schrieb:

Hi All,
I am building an archetype and since I took an example from somewhere,
the packaging was maven-plugin. Trying to release it, I get the
following deprecation warning:

[WARNING] ***
[WARNING] Deprecation Alert:
[WARNING] No mojo descriptors were found in this project which
has a packaging type of maven-plugin.
[WARNING] In future versions of the plugin tools, this will
fail the build.
[WARNING] If this project is an archetype, change the
packaging type from maven-plugin to maven-archetype.
[WARNING] 

But if I change the packaging to maven-archetype, I get the error in
the subject.

What do I miss?

Thanks in advance.
Ste




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



Re: how to debug Maven Model?

2008-05-14 Thread Tim Kettler

Hi,

MavenXpp3Writer is part of the maven-model artifact. It's a class 
generated by the modello-maven-plugin. To get the sources you can either 
check out maven 2.0.9 from svn [1] and generate the sources yourself or 
grab the source artifact from central [2].


-Tim

[1] http://svn.apache.org/viewvc/maven/components/tags/maven-2.0.9/
[2] 
http://repo1.maven.org/maven2/org/apache/maven/maven-model/2.0.9/maven-model-2.0.9-sources.jar



[EMAIL PROTECTED] schrieb:
Hi, 

I´m having a problem with the site-url of my project, it´s not created 
correct.

mvn help:effective-pom shows an invalid path.

Therefore, I want to debug Maven-2.0.9.

I´ve connected Eclipse via a Remote Java Application - all works fine, the 
debugger stops at "EffectivePomMojo".
Starting there I now want to step in "MavenXpp3Writer" or the Maven-Model 
itself.


Where can I find those sources?

Thanx, torsten






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



Re: mvn add test folders

2008-05-11 Thread Tim Kettler

Hi,

trying to answer your questions one after the other:

1. Your original question (How to ensure your testdata directory gets
   copied to test-classes):

By default maven expects resources for unit testing that should end up 
in the classpath in src/test/resources. If you have resources in other 
directories you must declare them as an additional resources:


  
   [...]
   
 [...]
 
   
  [your folder here] 
   
 
 [...]
   
   [...]
  

Read more about this in the pom description [1] and the description of 
the resource plugin [2].


2. Accessing your resources via the filesystem:

It is considered bad style to access resources on the classpath as file 
objects (think about resources in jar files). You really should use 
*.getResourceAsStream(*) for accessing such resources.


If you really have to go the way of accessing your testdata via the 
filesystem (File objects) there is no need to have them on the classpath 
(read: add them as resources to your pom). Instead just access them from

their filesystem location (src/test/testdata).

Your example from one of your other mails:

  File("abc.doc").exists()

just can not work, since you are trying to access the file via a 
relative location, assuming the file is in your current working 
directory, which is not the case. The default working directory should 
be your projects root directory, if I remember correctly.


Instead you should access your files via an absolute location. This is 
what Deng pointed you to with the PlexusTestCase [3]. It's the base 
TestCase used by plexus for all its unit tests. It provides a utility 
method to retrieve the absolute path of your projects root directory 
(getBaseDir()). You can easily adapt this utility method from Plexus to 
your own TestCases and the create File objects in the way Deng suggested:


  File( getBasedir(), "/target/test-classes/abc.doc" )

Hope this helps
-Tim

[1] http://maven.apache.org/pom.html
[2] http://maven.apache.org/plugins/maven-resources-plugin/index.html
[3] 
https://svn.codehaus.org/plexus/plexus-containers/trunk/plexus-container-default/src/main/java/org/codehaus/plexus/PlexusTestCase.java


Karthik Krishnan schrieb:

Hi Deng,

I have no idea what you are talking about. I have looked at the plexus, but
I am sorry to say that i did not understood the question. I am using TestNG
to unit test components.

Thanks,

Kartik

On Fri, May 9, 2008 at 9:14 PM, Maria Odea Ching <[EMAIL PROTECTED]> wrote:


try new File( getBasedir(), "/target/test-classes/abc.doc" ) assuming
you're
extending the PlexusTestCase :-)

-Deng

On Fri, May 9, 2008 at 3:58 AM, krishnan.1000 <[EMAIL PROTECTED]>
 wrote:


Hi,

I have tried moving them to src/test/resources, but I have found that if

I

have to create a file object of a file say abc.doc, present under
src/test/resources,  then new File("abc.doc").exists() returns false
always,
but the ClassLoader.getSystemResourceAsStream("abc.doc") != null returns
true. I need access to the file object.

Maria Odea Ching-5 wrote:

You might need to write code in your unit tests for copying your test
resources from src/test/testdata to target/test-classes as I don't

think

you
could set this in the plugin config.
The other alternative is to move your test resources to

src/test/resources

so that it automatically gets copied in target/test-classes but you
mentioned changing the structure is not an option for you..

HTH,
Deng

On Thu, May 8, 2008 at 2:24 PM, krishnan.1000 <[EMAIL PROTECTED]
wrote:


Hi,

I have a project that uses a set of sample data for unittesting on

the

project. Since there are many other developer on the project, this

would

help them simulate the same working environment.

The test folders are in the project root- src/test/testdata/abc.doc

and

so
on...  This has been a standard practise in my company.

However, when I run mvn test, I see that this folder is not copied

under

the
target/test-classes folder.  Is there a way to make sure that this

folder

is
copied. Keeping the same folder structure.

Thanks,

Karthik Krishnan
--
View this message in context:
http://www.nabble.com/mvn-add-test-folders-tp17120968p17120968.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]





--
View this message in context:
http://www.nabble.com/mvn-add-test-folders-tp17120968p17135234.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]







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



Re: How to restrict deploy

2008-05-06 Thread Tim Kettler
Hi,

just adjust the filesystem permissions on the FTP-Server so that only
authorized people can deploy. Or give only login access to this group of
people.

-Tim

Subramanian, N.Venkata schrieb:
> Hi 
>   Our maven repository is such that anybody ( in  our team ) can
> deploy artifacts into the repository. We would like to
> restrict/authenticate so that things are in control. 
> 
> Please let me know the mechanism to restrict in deploying the artifacts.
> We are using wagon-ftp to deploy.
> 
> Thanks
> -Venkat
> 
> -
> 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: Forcing the execution of a phase before a goal

2008-05-04 Thread Tim Kettler

Hi carioca,

A maven build consists of a lifecycle. A lifecycle is defined by an 
ordered list of phases (like compile, test, install ...) each phase 
execution includes the execution of all other phases before it. And 
finally there are goals that are bound to a specific phase of the 
lifecycle. See here [1] or here [2] for a more comprehensive description.


So what you can do is bind the goal in question to the phase just after 
the phase that should be executed before the goal.


Hope that helps

-Tim

[1] 
http://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html

[2]
http://www.sonatype.com/book/reference/simple-project.html#section-simple-core

carioca schrieb:

Hi,

I am still looking for a solution to this problem. Can anyone help?

Thanks.



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



Re: Maven project in IDEA

2008-05-04 Thread Tim Kettler

FlashXL schrieb:

How can I generate POM-file form existing IDEA project?


I don't think this is possible at the moment. Neither the maven provided 
idea plugin nor IDEA itself support this. There was a  'Idea Maven2 Kick 
Start Plugin' mentioned for last years plugin contest [1] but I don't 
think this got implemented.


-Tim

[1] http://plugins.intellij.net/contest/entries/

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



Re: Problem with pdfbox-0.7.3.pom

2008-04-25 Thread Tim Kettler

Hi,

Marc Schneider schrieb:

Hello,

I don't know if this is the right place to talk about this 


Not really. You should contact the reucon guys directly, as it is their
repository.


but I think that this pom is wrong ;


[...]

And this is one of the reasons one should think very carefully about
which repositories to use. Deployed artifacts in a repository should
change under no circumstances.

On top of that, the repository you point to isn't a valid remote repo at
all. It misses the manditory maven-metadata.* files. It seems this is
just a copied local repo.

Why don't you use central in the first place? Pdfbox [1] is available there.


Does anybody know about this ?

Thanks,
Marc/



-Tim

[1] http://repo1.maven.org/maven2/pdfbox/pdfbox/0.7.3/



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



Re: metrics report-plugin (for cyclomatic complexity + loc)

2008-04-22 Thread Tim Moloney

aldana wrote:
hi, 


to make code smells more visible and to better find out refactoring targets
amongst others i want to introduce some metrics. for that i miss a plugin
which measures the cyclomatic complexity and loc (for classes, methods). 
surprisingly i did not find any maven plugin which offers this...


maybe somebody can point me out to one?

thanks.

-
manuel aldana
aldana((at))gmx.de
software-engineering blog: http://www.aldana-online.de
  


I have not used it yet, but one I've bookmarked for future use is:

- Java NCSS
 http://www.kclee.com/clemens/java/javancss/

- Java NCSS Maven plugin
 http://mojo.codehaus.org/javancss-maven-plugin/

Hopefully, others have used it and can give us tips, feedback, and 
comparisons against other possible tools.


Tim


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



Re: Definitive Guide - is it real?

2008-04-14 Thread Tim O'Brien
It's in the works. I think it would be better to write a book  
about writing a book, but only because I wanted to write that.


Tim

On Apr 14, 2008, at 11:07 AM, Dan Tran wrote:


big +1.

On Mon, Apr 14, 2008 at 8:23 AM, Brian E. Fox <[EMAIL PROTECTED] 
> wrote:
Maybe we should add a chapter to the book to show how to make the  
book?



-Original Message-
From: Manfred Moser [mailto:[EMAIL PROTECTED]
Sent: Monday, April 14, 2008 12:14 AM
To: users@maven.apache.org
Subject: Re: Definitive Guide - is it real?




Jason van Zyl-2 wrote:



Right, this is where the book-like features are missing from Doxia  
and



though I would like to fix them the primary concern at hand was
getting the Maven book out.




Sounds like my suspicion is correct and you can currently not use  
Doxia

to
create something like the Definitive Guide. I hope I am wrong and
somebody
can show me how to get it going but at this stage I have the  
feeling I

will
have to learn docbook ..
--
View this message in context:
http://www.nabble.com/Definitive-Guide---is-it-real--tp16656704s177p1667
0486.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]


-
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: Definitive Guide - is it real?

2008-04-14 Thread Tim O'Brien
Manfred,  sorry it took me so long to respond.   (I wasn't subscribed  
to the user list until yesterday ).


On Apr 13, 2008, at 11:14 PM, Manfred Moser wrote:





Jason van Zyl-2 wrote:



Right, this is where the book-like features are missing from Doxia  
and

though I would like to fix them the primary concern at hand was
getting the Maven book out.




Sounds like my suspicion is correct and you can currently not use  
Doxia to
create something like the Definitive Guide. I hope I am wrong and  
somebody
can show me how to get it going but at this stage I have the feeling  
I will

have to learn docbook ..


Here, I wrote about why we converted to DocBook:  
http://blogs.sonatype.com/book/2008/04/14/120817710.html

I know it isn't party line in Mavenland, but I can't stand APT.   
Writing a 500+ page book that has to stay up to date for a few  
decades, you've got to think about things like roundtrip from wiki- 
like to pre-print back to wiki-like.IMO, if you really are writing  
a big book, writing it in APT would be like trying to sail the pacific  
in a small raft, you can certainly do it. Now, there's an idea  
brewing out there about creating some good roundtrip tools from doxia  
markup to docbook and then back again.   If we ever see that, then I  
think that's going to be the thing that people migrate to, but I can't  
wait for that to materialize.




--
View this message in context: 
http://www.nabble.com/Definitive-Guide---is-it-real--tp16656704s177p16670486.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]




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



Re: ejb3 jboss persistence problem

2008-04-12 Thread Tim Torbeyns
am not a maven specialist
but when I go to:
http://repository.jboss.com/jboss/jboss-persistence-api/3.0.0-SNAPSHOT
I see a lib folder

don't know if this is ok for maven ?

2008/4/12, neo anderson <[EMAIL PROTECTED]>:
>
>  Previously I successfully build ejb3 example with jboss version 4.2.2 by
>  specifying jboss library in the 'systempath'. Now I want to make use of the
>  maven (jboss) repository. So I change to use the dependency section of
>  pom.xml, modifying repository and dependency section; it is as follow:
>
> 
> 
> jboss-maven2
> http://repository.jboss.com
> 
> 
>
>  ...
> 
> jboss
> jboss-persistence-api
> 3.0.0-SNAPSHOT
> 
> 
> jboss
> jboss-ejb-api
> 4.2.0.GA
> 
>
>
>  But maven returns message like
>
>  Missing:
>  --
>  1) jboss:jboss-persistence-api:jar:3.0.0-SNAPSHOT
>
>   Try downloading the file manually from the project website.
>
>
>  I am able to to see the jar file located in the
>  http://repository.jboss.com/jboss/jboss-persistence-api/ (The dependency for
>  jboss-ejb-api works fine.) How to solve this error without downing/
>  installing the jar manually?
>
>  Thanks for help,
>
> --
>  View this message in context: 
> http://www.nabble.com/ejb3-jboss-persistence-problem-tp16653034s177p16653034.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]
>
>

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



[m2] pom filtering: pom.url vs propertyname.url

2008-04-12 Thread Tim Torbeyns
Hi,

In my pom.xml file I have the following:
[xml]
some url


  

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

  
src\main\webapp
true

  **/*.xml

  

  

  



  the url of my database

[/xml]

In an other xml file, that is located in the src\main\webapp
directory, I have the following:
[xml]

[/xml]

This is the output after maven ran:
[xml]

[/xml]

What I expected to see was this:
[xml]

[/xml]

Am I missing something ?
Thanks in advance.

Tim

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



Re: Looking to make internal repository externally access

2008-04-11 Thread Tim Kettler

Hi,

for basic auth just put a  element [1] with the same id as your
repository definition in your settings.xml. If you want more security
than just basic auth, there is a guide [2] describing authentication
with client certificates over https on the maven homepage.

-Tim

[1] http://maven.apache.org/settings.html#Servers
[2] http://maven.apache.org/guides/mini/guide-repository-ssl.html

Mike Leonardo schrieb:

Hello,

My company has an internal maven repo that I would like to have accessible from 
the outside. The problem
is that it's a private repo - so we want to at least have basic auth on it when 
it is externally accessible.
Up until now we've been just using vpn - but we we've been having

issues with our vpn software. How can I set

up my applications to use the repo, but somehow include a basic auth

username and password to connect to the repo?


Thanks for pointing me in the right direction.
- Mike

-
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: embedded maven engine

2008-04-11 Thread Tim Kettler

Hi,

there is a project called maven-embedder [1] for integrating maven in
other application (IDE's ...).

You also may want to have a look at two other projects that might
provide what you are looking for. First there is POMStrap [1], its an
application bootstrapper working with pom files. And second there is
PAX-Runner [3] from the OPS4J project which is a frontend for various
OSGi frameworks (Concierge, Equinox, Felix and Knopflerfish) that can
bootstrap from bundles specified as dependencies in a pom file.

Hope that helps
-Tim

[1] http://maven.apache.org/guides/mini/guide-embedding-m2.html
[2] http://pomstrap.prefetch.com/en/
[3] http://wiki.ops4j.org/confluence/display/ops4j/Pax+Runner

Jan Torben Heuer schrieb:

Hi,

Is it possible to embed the maven engine in a java program?

I think of using it as plugin management for an application.

I want to define an artifact (my pointing to a pom or giving
an "group:artifact:version" string. Then I want maven to resolve, download
and add the artifact+dependencies to my classpath at runtime.

Has anyone tried it, yet? If not, will it be worth a try?


Thanks!

Jan


-
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: where to find maven 2 simian report plugin?

2008-04-10 Thread Tim Kettler

Hi,

the plugin is here [1]. However, there seems to be no release of it yet.
You can subscribe to the mojo project's mailinglist and ask the there
for an release. Or you can grab the sources from here [2] and and just
make an internal release of the plugin.

-Tim

David Delbecq schrieb:

Hello,

I migrated a projet from maven1 to maven2. Compile, package and 
deployement process ahve now been successfully migrated. We have however 
some problems with reports. We can't find what's the maven2 equivalent 
of maven1 simian report plugin? We get this:


[INFO] The plugin 'org.codehaus.mojo:simian-maven-plugin' does not exist 
or no valid version could be found


I search google but can't find maven2 simian report plugin. Was it not 
ported to maven2? Is another plugin using a tool similar to simian for 
reporting code ducplication?




[1] http://mojo.codehaus.org/simian-report-maven-plugin
[2] https://svn.codehaus.org/mojo/trunk/sandbox/simian-report-maven-plugin/

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



Re: package does not exit error with 3rd party jar dependency

2008-03-24 Thread Tim Kettler

Hi,

As Simon guessed, too, I guess it's just a char-set/file-encoding issue. 
Can you go to a plain texteditor available on your platform (notepad, 
gedit, kate, nano ... whatever is available) and create a simple test 
class in src/main/java:


Test.java:
  import com.gigaspaces.*;

  public class Test {}

and try if this is compiled by maven. If yes, then it's really just an 
encoding issue. Then just try to delete the import statement from 
App.java and the readd it.


And no, there is no chance that maven tries to compile without your 
specified jar dependency. You can double check by invoking maven with 
debug output enabled 'mvn -X ...' Maven then prints the classpath it's 
using for compilation.


-Tim

Avi Laviad schrieb:

ok, thanks for the mailing tip - didn't thought about it. im using gmail and
it made it automatically.
i will keep replying at top for now like you for not having more mess.

the error is broken bcuz the command line print it like that. nothing to do
with the code.

the project is compiled fine at Eclipse.
i just "mvn install:install-file" the jar i reference to from Eclipse. so
the files im sure the file i need is there.

is there a chance that maven try to compile without this jar?

On Mon, Mar 24, 2008 at 10:56 AM, simon <[EMAIL PROTECTED]> wrote:


Hi Avi,

First, when someone replies by adding their comments at the bottom of
the reply email, please do not then add your comments at the top. It's
rude and makes the email hard to read. I'm posting at the top here only
to avoid making things worse.

The error message looks suspicious:
 package com.gigaspace
 s does not exist
Is the package-name really being broken across two lines like this? If
so, maybe your import statement has a non-ascii character embedded into
it that is confusing the compiler.

I suggest also running "jar tf" on the file in the repository, ie under
"~/.m2/repository/gigaspaces/.." and checking that the files you expect
are really in that jar.

Regards,

Simon

On Mon, 2008-03-24 at 10:48 +0200, Avi Laviad wrote:

well, unfortunely you guessed wrong... im using .
and the classpath element included my wanted ,jar file.

my pom.xml is:
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.MyProjectName
  MyProjectName
  jar
  1.0-SNAPSHOT
  MyProjectName
  http://maven.apache.org
  

  gigaspaces
  JSpaces
  6.5


  junit
  junit
  3.8.1
  test

  

and the error is:
[ERROR] BUILD FAILURE
[INFO]

[INFO] Compilation failure
C:\Projects\MyProjectName\src\main\java\com\MyProjectName\App.java:[3,0]
package com.gigaspace
s does not exist

C:\Projects\MyProjectName\src\main\java\com\MyProjectName\App.java:[3,0]
package com.gigaspace
s does not exist

[INFO]

[DEBUG] Trace
org.apache.maven.BuildFailureException: Compilation failure
C:\Projects\MyProjectName\src\main\java\com\MyProjectName\App.java:[3,0]
package com.gigaspace
s does not exist
Is these details are any help?
Avi.



On Sun, Mar 23, 2008 at 9:06 PM, Wendy Smoak <[EMAIL PROTECTED]> wrote:


On Sun, Mar 23, 2008 at 11:51 AM, Avi Laviad <[EMAIL PROTECTED]>

wrote:

 the project is compiled and build successfully when i try it on

Eclipse.

 the error is "package com.gigaspaces.* does not exist".
 I think its compile error because it doesn't find the .jar file it

should

 reference to - and this is my problem - i added a dependency in the
 pom.xmlfor the .jar that i need but it seems that maven ignores it

and

 try to compile without it.

We need to see more of the pom and the error in order to help.  I'll
take one more guess... any chance that dependency you posted is inside
 instead of just  ?

Add -X to the command line and Maven will print out a lot of
information, including the classpath.  Then you can see if the jar is
on the classpath at all.

--
 Wendy

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




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







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



Re: inherit execution only for packaging war

2008-03-20 Thread Tim Kettler

Wendy Smoak schrieb:

On Wed, Mar 19, 2008 at 6:51 AM, Kees van Dieren
<[EMAIL PROTECTED]> wrote:


 In our root pom.xml we have the maven war plugin defined:

...

 On mvn package, it will run mvn war:inplace, but not only for war artifacts,
 but also for jar artifacts.

 How can we make this execution only applicable for projects with packaging
 war?


Is it a bug in the war plugin perhaps?  Should it somehow "know" not
to run in the jar modules?


It's not a bug. The war plugin execution is explicitly configured in the
parent pom and hence it's executed in every module inheriting from the
parent.

The correct way to configure something like this, is to configure the
war plugin in the  section of the pom. The
configuration is then picked up by child modules that have the war
plugin in their lifecycle (like war modules).

-Tim


If you don't get more info here, I'd construct a simple example to
demonstrate when it does the wrong thing, and attach it to an issue in
JIRA.  http://jira.codehaus.org/browse/MWAR




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



Need some help

2007-12-19 Thread Tim Schulz
We are running continuum 1.0.3 on a redhat linux box. We have 28 projects
under the one instance. Everything was working fine until yesterday, then
one of the projects in the "show projects" view was marked with the red x,
but when we go into the build history it shows that it built successfully.
Being relatively new to continuum, can someone explain where to look for the
cause of the discrepancy. Also, can someone point me to some documentation
on house keeping tasks that I need to be doing to keep continuum running
optimally.  Thanks.


Tim Schulz
701-282-1042
Lead Staff Analyst
Claims and Corporate Services
Information Services

IS CARES
Confidentiality Notice:  This e-mail message and any attachments is for the
sole use of the intended recipient's) and may contain confidential and
privileged information.  Any unauthorized review, use, disclosure,
distribution or copying is prohibited.  If you are not the intended
recipient(s), please contact the sender by replying to this e-mail and
destroy/delete all copies of this e-mail message.





Re: Profile activation based on JDK version

2007-12-11 Thread Tim Moore


On Dec 11, 2007, at 2:31 AM, Thorsten Möller wrote:

Based on the documentation that is available from the Maven Web site  
it is

unclear to me what the exact semantic of the  tag is: will it be
activated for i) all major Versions greather or equal than the one  
specified

including sub versions or ii) only for the exact major version and all
subversions. In other words, will a 1.5 trigger only for  
1.5.y
versions or also for 1.6.x, 1.7.x, ...? Provided that the latter one  
holds
my question then would be "how can I create two profiles -- one for  
1.5.x

and one for 1.6.x -- and make sure that always only one gets activated
exclusively"?



According to <http://maven.apache.org/guides/introduction/introduction-to-profiles.html 
> it matches the prefix of the JDK version, so 1.5 will match 1.5.0,  
1.5.0_13, 1.5.1, etc. but not 1.6.

--
Tim Moore / [EMAIL PROTECTED]
ATLASSIAN - http://www.atlassian.com
Our products help over 8,500 customers in more than 95 countries to  
collaborate





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



Re: ejb building not working

2007-10-31 Thread Tim Kettler
Hi Costa,

I moved this back to the maven-users list, other people might be
interested in this, too.

Have you checked that your ejb-xml.jar exists in
${project.build.outputDirectory}/META-INF/ ? This would translate to
target/classes/WEB-INF if you stick to the pom defaults.

If you target EJB 3.0, configure the plugin to that version [1] and the
plugin will not fail the build if the file is missing.

-Tim

[1] http://maven.apache.org/plugins/maven-ejb-plugin/usage.html

Costa Argiroglou schrieb:
> Hi Tim,
> 
> I currently have this problem but I don't know what to resolve it… Verry 
> usefull mail, don't you think ? ;)
> In fact, I hope you found the solution and you could help me. If not, let me 
> know and if I find a solution, I'll send you an email.
> 
> Have a nice day
> 
> Costa
> 
> _
> Emmenez vos amis avec vous, grâce à Messenger sur votre GSM.
> http://get.live.com/mobile/messenger


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



Re: Maven runs surefire plugin for testing by default. How to change this?

2007-10-30 Thread Tim Kettler
Hi,

as Brett told you on the dev list, just use the skip parameter to
disable surefire execution. The surefire plugin is bound to the
lifecycle by the default packagings and can't be removed.

-Tim

Kalyan Akella schrieb:
> Hi,
> 
> Recently, I developed a Java-based maven plugin intended to run in the test
> phase of the maven build instead of the standard surefire-plugin. It has
> just one goal, 'test'. When I configured my project's POM to include my
> plugin for the testing phase and made sure the POM doesn't refernce surefire
> anywhere, maven still invokes the surefire:test goal during the test phase.
> Could someone please help me how to avoid maven running surefire plugin and
> instead run mine.
> 
> Here are the details of my plugin POM and that of the Project POM:
> 
> Plugin POM:
> 
> 4.0.0
> sample.plugin
> maven-sample-plugin
> maven-plugin
> 1.0
> My Sample Plugin
> 
> 
> org.apache.maven
> maven-plugin-api
> 2.0
> 
> 
>   org.apache.maven
>   maven-artifact
>   2.0
> 
> 
> junit
> junit
> 4.4
> 
> 
> 
> 
> 
> 
> org.apache.maven.plugins
> maven-compiler-plugin
> 
>  1.5
> 1.5
> 
> 
> 
> 
> 
> 
> 
> Project POM:
> 
> 4.0.0
> sample.project
> hello
> 1.0-SNAPSHOT
> pom
> Hello World
> 
> test
> 
> 
> 
> dev
> 
> 
> ${filters.dir}/dev-env.properties
> 
> 
> 
> sample.plugin
> maven-sample-plugin
> 1.0
> 
> 
> 
> test
> 
> test
> 
> false
> 
> 
> 
> nfs
> 
> .*Test.class
> 
> 
> .*Abstract.* Test.class
> .*$.*.class
> .*Poller.*.class
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> org.apache.maven.plugins
> maven-compiler-plugin
> 
> 1.5
> 1.5
> 
> 
> 
> sample.plugin
> maven-sample-plugin
>  1.0
> 
> 
> test
> 
> test
> 
> 
> 
> 
> 
> 
> .*Test.class
> 
> 
> .*Abstract.* Test.class
> .*$.*.class
> 
> 
> 
> 
> 
> 
> 
> 
> 
> Moreover, I included the following annotations while coding this plugin:
> @requiresDependencyResolution test
> @phase test
> @goal test
> 
> Please help me. Thank you.
> Sincere Regards,
> Kalyan
> 


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



Re: use a dependency in system scope witout version

2007-10-29 Thread Tim Kettler
Hi,

have a look at the dependency guide [1] for the correct usage of system
scope dependencies. It boils down to: groupId/artifactId/version are
your choice (somthing like sun.jdk/runtime/1.5.0.11 will do in your
case), systemPath is not the path of the directory of the jar, but the
path of the jar itself.

-Tim

[1]
http://maven.apache.org/guides/introduction/introduction-to-dependency-mechanism.html

Sonar, Nishant schrieb:
> Hi 
> 
>  
> 
> Can I use a dependency with scope=system with no version number
> 
>  
> 
> I want to use  rt.jar which is inside C:\Java\jdk1.5.0_11\jre\lib . now
> this jar doesn't has a verion number
> 
> How should I use ot
> 
>  
> 
> 
> 
> what to use here?
> 
> What to use here?
> 
> what version if no version for the jar
> 
> system
> 
>  C:\Java\jdk1.5.0_11\jre\lib
> 
> 
> 
>  
> 
>  
> 
> Regards,
> 
> Nishant Sonar
> 
>  
> 
> 


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



Re: HOW TO RUN MULTIPLE PACKAGING USING DIFFERENT ENV?

2007-10-29 Thread Tim Kettler
mailming schrieb:
> This is a great approach, and I do see the ear-plugin package twice. 
> 
> However, after server testing, I c the filters in the profile doesn't get to
> processed, that is, the packaging doesn't go back to resource level redo
> filtering, which is I need. 
> 
> Do I have some key concept missing?

I don't think so. I didn't had filtering (and some other things) in mind
when i gave this approach. Buildung for multiple environments in one go
will not work in this cases (probably in no cases than really simple
ones), just build one after the other.

> 
> Tim Kettler wrote:
>> Hi,
>>
>> please don't write in all caps (even if it's just the subject), this is 
>> considered rude. People will decide to read and answer you question not 
>> based on how strong you try to advertise it but on how good you describe 
>> your problem and if they know an answer.
>>
>> Regarding your question. this should do what you want:
>>
>> 
>>4.0.0
>>my-test-app
>>my-test-group
>>1.0-SNAPSHOT
>>
>>
>>  
>>alpha
>>
>>  
>>env_alpha
>>  
>>
>>
>>  
>>
>>  org.apache.maven.plugins
>>  maven-jar-plugin
>>  2.1
>>  
>>
>>  build-alpha-ear
>>  package
>>  
>>jar
>>  
>>  
>>alpha
>>  
>>
>>  
>>
>>  
>>
>>  
>>
>> 
>>
>> You can then build with 'mvn -Denv_alpha package'. If you have more 
>> environments you want to create packgings for, just copy the profile and 
>> change the names accordingly and then invoke maven like this 'mvn 
>> -Denv_alpha -Denv_beta package'.
>>
>> Note that the example uses the jar plugin but for an ear it works 
>> exactly the same, just substitue the plugins.
>>
>> If you want to deploy the extra artifacts to your repository you need to 
>> attach them with the build-helper plugin [1].
>>
>> -Tim
>>
>> [1] http://mojo.codehaus.org/build-helper-maven-plugin/
>>
>> mailming schrieb:
>>> I am trying to implement packaging multiple into multiple ear files using
>>> profile activation, using classifier. 
>>>
>>> for example 
>>>
>>> mvn package -DEnv=Alpha 
>>>
>>> maven package into file-0.5-snapshot-alpha.ear
>>>
>>> and then 
>>>
>>> mvn package -DEnv=Delta 
>>>
>>> maven package into file-0.5-snapshot-delta.ear
>>>
>>> but I need to do multiple packaging which is 
>>>
>>> do something like mvn package -DEnv=Delta package -DEnv=Alpha, so it can
>>> package twice in the same process and with different Env profile, 
>>>
>>> Hopefully this is doable.
>>>
>>> --Ming
>>>
>>
>> -
>> 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: Activate Profile

2007-10-29 Thread Tim Kettler
OMax schrieb:
>> When I attempt to activate a different profile on the Maven command 
>> line, I _still_ get the activeByDefault profile, and not the one I wanted.
> 
> It's opposite of what I have, at least on 2.0.7. If I activate different
> profile it's taken into the account but not the default one.

That's the way it's intended to work and it really should work this way,
IMO.

> But I would wanted the default one to be activated always not only when there
> where no profiles specified (that is how I translate activate by default) -
> this is exactly your behavior :)

If you have somthing that should be configured or invoked always, it
simply does not belong into a profile, but in the default build section
(or wherever else it goes).

> Oleksandr Maksymchuk, 
> http://omax.org.ua OMax 

-Tim

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



Re: Debugging failed junit-test

2007-10-26 Thread Tim Kettler
Hi,

Jan Torben Heuer schrieb:
> Wayne Fay wrote:
> 
>> I'm not sure that I understand you entirely, but here goes If you
>> have shared test files, you will need to create a "test-jar" artifact
>> and add it as a dependency to any projects that need to use it.
>>
>> This is documented in a mini-guide:
>> http://maven.apache.org/guides/mini/guide-attached-tests.html
> 
> Why can't I reference test-classes in other modules?
> 
> I have a project with two modules. module1 dependsOn module2:
> 
> 
> 
> 
> I can reference m2's classes from m1, but NOT m2's testclasses. That is what
> I do not understand.

They are simply not part of the artifact maven creates for module2. The
artifact maven creates contains just the production code (classes and
resources from 'src/main/*') as no one seriously wants to have their
unit tests packaged alongsite the final deliverable of the project.

If you have shared testing code between two projects, just create a
third module containig this shared code and declare it as a dependency
in the two other modules with test or follow the guide
Wanyne pointed you to and create a "test-jar" of the testing code in
module2 and reference that with test scope.

> Jan

-Tim

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



Re: How to configurate java.class.path property under a given test

2007-10-23 Thread Tim Kettler
David schrieb:
> Dear Tim,
> 
> It works for me under eclipse, but not under maven from command line. On my 
> code what I use is to get the system property using:
> 
> System.getProperty("java.class.path");

The property seems to contain the classpath used for the forked surefire
execution and doesn't contain the project classes & dependencies.
Surefire uses a custom classloader to provide the project's classes. You
can file a rfe to the surefire project that it should modify the
property (if that's possible at all) to contain the project's classes
and dependencies.

> Are you ussing Maven 1.x?, becuase on the following link:
> http://maven.apache.org/guides/mini/guide-maven-classloading.html
> 
> There is a comment about a different behaviour when using Maven 1.x, I am 
> using Maven 2.x

No, I'm on m2 and I never extensively used m1, So I can't really comment
 on differences between both.

> This is my output:
> 
> P:\ceb2b2000-commons\ceb2b2000-commons-io>mvn test
> [INFO] Scanning for projects
> [INFO] 
> -
> ---
> [INFO] Building ceb2b2000-commons-io
> [INFO]task-segment: [test]
> [INFO] 
> -
> ---
> [INFO] [resources:resources]
> [INFO] Using default encoding to copy filtered resources.
> [INFO] [compiler:compile]
> [INFO] Nothing to compile - all classes are up to date
> [INFO] [resources:testResources]
> [INFO] Using default encoding to copy filtered resources.
> [INFO] [compiler:testCompile]
> [INFO] Nothing to compile - all classes are up to date
> [INFO] [surefire:test]
> [INFO] Surefire report directory: 
> P:\ceb2b2000-commons\ceb2b2000-commons-io\targ
> et\surefire-reports
> ---
>  T E S T S
> ---
> Running com.ceb2b2000.commons.io.TestFileUtils
> System.getProperty("java.class.path")=
> C:\Documents and 
> Settings\dleal\.m2\repository\org\codehaus\plexus\plexus-archiv
> er\1.0-alpha-7\plexus-archiver-1.0-alpha-7.jar;C:\Documents and 
> Settings\dleal\.
> m2\repository\org\apache\maven\surefire\surefire-api\2.3\surefire-api-2.3.jar;C:
> \Documents and 
> Settings\dleal\.m2\repository\org\codehaus\plexus\plexus-containe
> r-default\1.0-alpha-8\plexus-container-default-1..0-alpha-8.jar;C:\Documents 
> and
> Settings\dleal\.m2\repository\org\codehaus\plexus\plexus-utils\1.1\plexus-utils-
> 1.1.jar;C:\Documents and 
> Settings\dleal\.m2\repository\org\apache\maven\surefire
> \surefire-booter\2.3\surefire-booter-2.3.jar;C:\Documents and 
> Settings\dleal\.m2
> \repository\classworlds\classworlds\1.1-alpha-2\classworlds-1.1-alpha-2.jar;C:\D
> ocuments and 
> Settings\dleal\.m2\repository\commons-lang\commons-lang\2.1\commons
> -lang-2.1.jar;C:\Documents and 
> Settings\dleal\.m2\repository\junit\junit\3.8..1\j
> unit-3.8.1.jar
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.031 sec
> Results :
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> 
> [INFO] BUILD SUCCESSFUL
> [INFO] 
> 
> [INFO] Total time: 1 second
> [INFO] Finished at: Tue Oct 23 15:36:26 CEST 2007
> [INFO] Final Memory: 4M/7M
> [INFO] 
> 
> P:\ceb2b2000-commons\ceb2b2000-commons-io>
> 
> 
> - Original Message 
> From: Tim Kettler <[EMAIL PROTECTED]>
> To: Maven Users List 
> Sent: Tuesday, October 23, 2007 3:07:48 PM
> Subject: Re: How to configurate java.class.path property under a given test
> 
> David schrieb:
>> Dear members,
>>
>> I have a method that find a file on classpath and I want to check that it 
>> works fine. My testing class works fine
>> under Eclipse, for example but under mave it doesn't work properly. The 
>> reason is that during the testing process I
>> assume there is at least a directory location on classpath, but under maven 
>> the java.class.path, contains only jar files.
> 
> That's not true. This is from one of my projects:
> 
> [DEBUG]  (f) classpathElements = [
> /home/tik/Develop/wallabystreet/mtn4java/target/classes,
> /home/tik/Develop/wallabystreet/mtn4java/target/test-classes,
> /home/tik/.m2/repository/org/codehaus/plexus/plexus-utils/1.4.1/plexus-utils-1.4.1.jar,
> /home/tik/.m2/repository/net/sf/oval/oval/1.0/oval-1.0.jar,
> /home/tik/.m2/repository/org/testng/testng/5.1/testng-5.1-jdk15.jar

Re: potential bug (urgent): snapshot download not working

2007-10-23 Thread Tim Kettler
Hi,

aldana schrieb:
> hi already started a thread, see
> http://www.nabble.com/stuck-state-when-downloading-snapshots-tf4672399s177.html
> where i thought i did a configuration error. but now i really think i am
> heading to a bug, which is very critical and severe (in fact it makes
> working with snapshots impossible!).
> 
> after downloading a snapshot apart from jar maven-metadata-internal.xml gets
> created in local rep too. after that it does not compare to a new snapshot
> release from internal repository, though the timestamp and respective jar
> from interal rep could be newer. when deleting maven-metadata-internal.xml
> from local rep, maven is willing again to compare metadata and to get latest
> snapshot. this is weird, it should always compare metadata with internal
> rep.

The default update-checking frequency for artifacts is once per day. You
can configure this on a per repository basis in your repository
definitions with the  tag. See here [1] for an description.

> has anybody got similar problems? maven2 jira showed me some issues
> regarding this but they are told to be fixed. i am using maven 2.0.7.
> 
> 
> apart from above problems i noticed that the timestamps in
> maven-metadata-internal.xml are not correct. funny thing is that the
> timestamp is set two hours earlier as my system clock.

-Tim

[1] http://maven.apache.org/ref/2.0.4/maven-settings/settings.html


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



Re: maven package error

2007-10-23 Thread Tim Kettler
That's a strange error. Can you provide a testproject producing this
error. Then I can try on my box and try to see what's causing this.

rgarciafernandez schrieb:
> this is de debug mode:
> 
> [DEBUG] Retrieving parent-POM:
> org.apache.maven.surefire:surefire-providers::2.3 for project:
> null:surefire-junit:jar:2.3 from the repository.
> [DEBUG]   org.apache.maven.surefire:surefire-junit:jar:2.3 (selected for
> null)
> [DEBUG] org.apache.maven.surefire:surefire-api:jar:2.3:compile (selected
> for compile)
> [DEBUG]   org.codehaus.plexus:plexus-utils:jar:1.1:compile (selected for
> compile)
> [DEBUG]   commons-lang:commons-lang:jar:2.1:compile (selected for
> compile)
> [DEBUG] junit:junit:jar:3.8.1:compile (selected for compile)
> [DEBUG] Adding to surefire test classpath: C:\Documents and
> Settings\isra_2\.m2\repository\junit\junit\3.8.1\junit-3.8.1.jar
> [DEBUG] Adding to surefire test classpath: C:\Documents and
> Settings\isra_2\.m2\repository\org\apache\maven\surefire\surefire-api\2.3\surefire-api-2.3.jar
> [DEBUG] Adding to surefire test classpath: C:\Documents and
> Settings\isra_2\.m2\repository\org\codehaus\plexus\plexus-utils\1.1\plexus-utils-1.1.jar
> [DEBUG] Adding to surefire test classpath: C:\Documents and
> Settings\isra_2\.m2\repository\commons-lang\commons-lang\2.1\commons-lang-2.1.jar
> [DEBUG] Adding to surefire test classpath: C:\Documents and
> Settings\isra_2\.m2\repository\org\apache\maven\surefire\surefire-junit\2.3\surefire-junit-2.3.jar
> [INFO]
> 
> [ERROR] FATAL ERROR
> [INFO]
> 
> [INFO] null
> [INFO]
> 
> [DEBUG] Trace
> java.lang.NullPointerException
>   at
> org.apache.maven.plugin.surefire.SurefirePlugin.constructSurefireBooter(SurefirePlugin.java:594)
>   at
> org.apache.maven.plugin.surefire.SurefirePlugin.execute(SurefirePlugin.java:391)
>   at
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:443)
> 
> ...(more)
> 
> with -e:
> 
> [INFO] [surefire:test]
> [INFO]
> 
> [ERROR] FATAL ERROR
> [INFO]
> 
> [INFO] null
> [INFO]
> 
> [INFO] Trace
> java.lang.NullPointerException
>   at
> org.apache.maven.plugin.surefire.SurefirePlugin.constructSurefireBooter(SurefirePlugin.java:594)
> 
> 
> ...:S
> 
> 
> 
> Tim Kettler wrote:
>> The log from your previous mail contains this:
>>
>>   [ERROR] reactor-execute : D:\mis cosas\workspace\inventory
>>
>> 'mis cosas' <- contains a space. If that's not the root of the problem,
>> try running maven with '-e' (enable output of error stacktraces) or -X
>> (enable debug output) and see if that sheds more light on what goes wrong.
>>
>> -Tim
>>
>> rgarciafernandez schrieb:
>>> I have no spaces in the path, or i don´t undestand u... sorry but we
>>> can't
>>> fix it :S
>>>
>>> basedirectory: ${project_loc}
>>> goals: package
>>>
>>> and th pom:
>>>
>>> war
>>>   0.0.1
>>>   
>>> 
>>>   
>>> maven-compiler-plugin
>>> 
>>>   1.5
>>>   1.5
>>> 
>>>   
>>> 
>>>   
>>>
>>>
>>>
>>> Tim Kettler wrote:
>>>> Hi,
>>>>
>>>> try to run it from a directory without spaces in the path.
>>>>
>>>> -Tim
>>>>
>>>> rgarciafernandez schrieb:
>>>>> [INFO] Scanning for projects...
>>>>> [INFO]
>>>>> 
>>>>> [INFO] Building Unnamed - inventory:inventory:war:0.0.1
>>>>> [INFO]task-segment: [package]
>>>>> [INFO]
>>>>> 
>>>>> [INFO] resources:resources
>>>>> [INFO] Using default encoding to copy filtered resources.
>>>>> [WARN] While downloading hibernate:hibernate:3.1rc2
>>>>>   This artifact has been relocated to org.hibernate:hibernate:3.1rc2.
>>>>>
>>>>>
>

Re: maven package error

2007-10-23 Thread Tim Kettler
The log from your previous mail contains this:

  [ERROR] reactor-execute : D:\mis cosas\workspace\inventory

'mis cosas' <- contains a space. If that's not the root of the problem,
try running maven with '-e' (enable output of error stacktraces) or -X
(enable debug output) and see if that sheds more light on what goes wrong.

-Tim

rgarciafernandez schrieb:
> I have no spaces in the path, or i don´t undestand u... sorry but we can't
> fix it :S
> 
> basedirectory: ${project_loc}
> goals: package
> 
> and th pom:
> 
> war
>   0.0.1
>   
> 
>   
> maven-compiler-plugin
>     
>   1.5
>   1.5
> 
>   
> 
>   
> 
> 
> 
> Tim Kettler wrote:
>> Hi,
>>
>> try to run it from a directory without spaces in the path.
>>
>> -Tim
>>
>> rgarciafernandez schrieb:
>>> [INFO] Scanning for projects...
>>> [INFO]
>>> 
>>> [INFO] Building Unnamed - inventory:inventory:war:0.0.1
>>> [INFO]task-segment: [package]
>>> [INFO]
>>> 
>>> [INFO] resources:resources
>>> [INFO] Using default encoding to copy filtered resources.
>>> [WARN] While downloading hibernate:hibernate:3.1rc2
>>>   This artifact has been relocated to org.hibernate:hibernate:3.1rc2.
>>>
>>>
>>> [INFO] compiler:compile
>>> [INFO] Nothing to compile - all classes are up to date
>>> [INFO] resources:testResources
>>> [INFO] Using default encoding to copy filtered resources.
>>> [INFO] compiler:testCompile
>>> [INFO] Nothing to compile - all classes are up to date
>>> [INFO] surefire:test
>>> [ERROR] reactor-execute : D:\mis cosas\workspace\inventory
>>> Diagnosis: null
>>> FATAL ERROR: Error executing Maven for a project
>>> [INFO]
>>> 
>>> [ERROR] BUILD ERROR
>>> [INFO]
>>> 
>>> [INFO] null
>>> [INFO]
>>> 
>>> [INFO] For more information, run Maven with the -e switch
>>> [INFO]
>>> 
>>> [INFO] Total time: 2 seconds
>>> [INFO] Finished at: Tue Oct 23 14:17:16 CEST 2007
>>> [INFO] Final Memory: 4M/8M
>>> [INFO]
>>> 
>>> [INFO]
>>> 
>>> [INFO] BUILD SUCCESSFUL
>>> [INFO]
>>> 
>>> [INFO] Total time: 2 seconds
>>> [INFO] Finished at: Tue Oct 23 14:17:16 CEST 2007
>>> [INFO] Final Memory: 4M/8M
>>> [INFO]
>>> 
>>>
>>>
>>> Important :
>>> [INFO] surefire:test
>>> [ERROR] reactor-execute : D:\mis cosas\workspace\inventory
>>> Diagnosis: null
>>>
>>> I don't know what to do...
>>> to make it run, to package to a war file my project. I need help please
>>
>> -
>> 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: How to configurate java.class.path property under a given test

2007-10-23 Thread Tim Kettler
David schrieb:
> Dear members,
> 
> I have a method that find a file on classpath and I want to check that it 
> works fine. My testing class works fine
> under Eclipse, for example but under mave it doesn't work properly. The 
> reason is that during the testing process I
> assume there is at least a directory location on classpath, but under maven 
> the java.class.path, contains only jar files.

That's not true. This is from one of my projects:

[DEBUG]   (f) classpathElements = [
/home/tik/Develop/wallabystreet/mtn4java/target/classes,
/home/tik/Develop/wallabystreet/mtn4java/target/test-classes,
/home/tik/.m2/repository/org/codehaus/plexus/plexus-utils/1.4.1/plexus-utils-1.4.1.jar,
/home/tik/.m2/repository/net/sf/oval/oval/1.0/oval-1.0.jar,
/home/tik/.m2/repository/org/testng/testng/5.1/testng-5.1-jdk15.jar
]

The classes and test-classes directories are on the classpath.

> So I can't check if some file exist on some directory of my classpath. I 
> would need for my test, just the "." directory,
> but I don't find the way to add this information before the test start.

In fact, it's not good to access resources in the classpath directly via
the file system. You should access them as resources via the
classloader. See this thread [1] for an example.

-Tim

[1]
http://www.nabble.com/Problems-with-loading-non-Java-resources-from-classpath-in-JUnit--tests-tf3734983s177.html#a10605055

> 
> On the 
> 
> I have seen other posts about this problem, but without any real good 
> solution, for example:
> http://www.mail-archive.com/users@maven.apache.org/msg47276.html
> 
> On surefire documentation:
> http://maven.apache.org/plugins/maven-surefire-plugin/test-mojo.html
> 
> probably using properly one of the following properties: 
> environmentVariables, jvm, could be solved, but I don't figure out how to 
> deal with this.
> 
> Thanks,
> 
> David
> 
> __
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around 
> http://mail.yahoo.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: maven package error

2007-10-23 Thread Tim Kettler
Hi,

try to run it from a directory without spaces in the path.

-Tim

rgarciafernandez schrieb:
> [INFO] Scanning for projects...
> [INFO]
> 
> [INFO] Building Unnamed - inventory:inventory:war:0.0.1
> [INFO]task-segment: [package]
> [INFO]
> 
> [INFO] resources:resources
> [INFO] Using default encoding to copy filtered resources.
> [WARN] While downloading hibernate:hibernate:3.1rc2
>   This artifact has been relocated to org.hibernate:hibernate:3.1rc2.
> 
> 
> [INFO] compiler:compile
> [INFO] Nothing to compile - all classes are up to date
> [INFO] resources:testResources
> [INFO] Using default encoding to copy filtered resources.
> [INFO] compiler:testCompile
> [INFO] Nothing to compile - all classes are up to date
> [INFO] surefire:test
> [ERROR] reactor-execute : D:\mis cosas\workspace\inventory
> Diagnosis: null
> FATAL ERROR: Error executing Maven for a project
> [INFO]
> 
> [ERROR] BUILD ERROR
> [INFO]
> 
> [INFO] null
> [INFO]
> 
> [INFO] For more information, run Maven with the -e switch
> [INFO]
> 
> [INFO] Total time: 2 seconds
> [INFO] Finished at: Tue Oct 23 14:17:16 CEST 2007
> [INFO] Final Memory: 4M/8M
> [INFO]
> 
> [INFO]
> 
> [INFO] BUILD SUCCESSFUL
> [INFO]
> 
> [INFO] Total time: 2 seconds
> [INFO] Finished at: Tue Oct 23 14:17:16 CEST 2007
> [INFO] Final Memory: 4M/8M
> [INFO]
> 
> 
> 
> Important :
> [INFO] surefire:test
> [ERROR] reactor-execute : D:\mis cosas\workspace\inventory
> Diagnosis: null
> 
> I don't know what to do...
> to make it run, to package to a war file my project. I need help please


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



Re: Artifact [...] is not a dependency of the project

2007-10-21 Thread Tim Kettler
Hi,

you have to declare the ejb-jar and war as normal dependencies in the
 section of the ear's pom. The module section in the
ear-plugin
configuration is only used for customizing some details of a module
(like you have
done with the context root). So your pom should look similar to this:

  [...]
  

  net.sf.sample
  publication-ejb
  YOUR_VERSION_HERE
  ejb



  net.sf.sample
  publication-war
  YOUR_VERSION_HERE
  war

  
  [...]
  

   maven-ear-plugin 
  
Sample EAR for publication
Sample EAR for publication

  
net.sf.sample
publication-war
/publication
  

  

  

If you are new to maven, I suggest reading the two free books on maven
written by
the deveoplers. You can find links to the books here [1], both give a good
introduction to maven and the underlying concepts and both contain a
complete
example of a JEE app developed with maven.

-Tim

[1] http://maven.apache.org/articles.html

[EMAIL PROTECTED] schrieb:
> I encounter a new problem whilst following the sample programme at 
> http://cwiki.apache.org/GMOxDOC20/very-simple-entity-ejb-example.html. I run 
> the command 'mvn compile' it issues the error "Artifact [...] is not a 
> dependency of the project." 
> 
> After searching the google, someone says that it can be amended by adding tag 
> type at http://www.mail-archive.com/users@maven.apache.org/msg33078.html. For 
> example, "ejb". Whilst another page 
> (http://jira.codehaus.org/browse/MNG-1562?page=com.atlassian.jira.plugin.system.issuetabpanels:changehistory-tabpanel)
>  reports that as a bug then it has been fixed in the later version 2.0.7. 
> However, I still obtain the same error.
> 
> My file structure looks similar the second one.
> 
> I have 
> 
> pulication folder resided at  the top-most dir. The file structure looks like 
> follow:
> 
> publication 
> +---[publication-ear]
> +---[publication-ejb]
> +---[publication-war]
> 
> the pom.xml which describes plugin looks like follow:
> 
>  maven-ear-plugin 
> 
>  Sample EAR for publication 
> 
>  Sample EAR for publication 
> 
> 5
> 
>   
> net.sf.sample
> publication-ejb
> 
> publication-ejb-1.0-SNAPSHOT.jar
> 
> 
> net.sf.sample
>  publication-war 
> /publication
> 
> publication-war-1.0-SNAPSHOT.war
> 
> 
> 
> 
> How to solve this problem?
> 
> I appreciate any suggestion.
> 
> Thank you very much.
> 
> 
> 
> 
> 
> 
> 
>
> ,
> 想即時通知通訊錄裡的所有親朋好友好消息,就來Yahoo!奇摩電子信箱發簡訊,一次搞定!http://tw.mobile.yahoo.com/texts/mail.php


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



Re: maven compile ejb example error

2007-10-20 Thread Tim Kettler
Hi,

the Stateless annotation is part of the ejb api. You need this artifact:

  
org.apache.geronimo.specs
geronimo-ejb_3.0_spec
1.0
  

-Tim

[EMAIL PROTECTED] schrieb:
> I follow the example from 
> http://cwiki.apache.org/GMOxDOC20/very-simple-entity-ejb-example.html. Whilst 
> compiling the source, the maven issues error with 
> 
> cannot find symbol
> symbol  : class Stateless
> location: package javax.ejb
> 
> I think that is because the bean class import the javax.ejb.Stateless class 
> which can not be found even by including dependency as follow:
> 
> 
> org.apache.geronimo.specs
> geronimo-j2ee_1.4_spec
> 1.0
> provided
> 
> 
> The unzipped jar shows no Stateless class file in the 
> geronimo-j2ee_1.4_spec.jar
> 
> What should I do in order to get the source compiled correctly?
> 
> Thank you very much
> 
> 
>杜絕網路駭客,保障帳號安全 - 馬上設定 Yahoo!奇摩安全圖章!


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



Re: M2 release:prepare fails with Subversion to tag SCM reason: Source url is from different repository

2007-10-19 Thread Tim Kettler
Hi,

bmat schrieb:
> mvn release:prepare
> ---
> 
> I recently had this problem using a local installation of subversion and
> using file uris e.g. 
> 
> scm:svn:file://localhost/repostory/myproject/trunk

The syntax for urls is: [protokoll]://[path]. A file url to the path
'/my/path' looks like this:

  file:///my/path

You url is missing the leading slash of the path.

-Tim

> I could not get this to work... so I installed Apache 2.0 (Note 2.0 NOT 2.2
> cos this doesn't work with subversion apparently).  Now using the following
> (NOTE: the trailing slash! this is important)
>   
> scm:svn:http://localhost/svn/repository/myproject/trunk/
> 
> this works fine for me (even on windows vista! amazing!)
> 
> This link was useful : "http://www.codeproject.com/w2k/SubversionApache.asp";
> but the authentication file is wrong i think..at least it didn't work for
> me.  If you change the recommended line from this
> [/] * = r [test1:/] user1 = rw user2 = [test2:/] user1 = r user2 = rw
> to this
> [test1:/myproject] 
> user1 = rw 
> user2 = rw 
> 
> it should work... it is important to specify the repository name here if
> SVNParentPath is specified in apache httpd.conf.
> 
> 
> I hope this saves somebody some time and hair as I've nearly pulled all mine
> out :-)
> Cheers
> Ben
> 
> 
> 
> 
> Markku Saarela wrote:
>> Hi,
>>
>> We are using Maven2 2.0.4 with Subversion 1.3 and now we can't make 
>> anymore releases. Previously we success.
>>
>> Here is snippet from parent pom.xml
>>
>>   
>> scm:svn:svn://fitst37/income/trunk
>> 
>> scm:svn:svn://fitst37/income/trunk
>>   
>>
>>   
>> maven-release-plugin
>> 
>>   saarfmar
>>   12345
>> 
>>   
>>
>> Here is output:
>>
>> [INFO] [release:prepare]
>> [INFO] Resuming release from phase 'scm-tag'
>> [INFO] Tagging release with the label 1.0.0...
>> [INFO] Executing: svn --non-interactive copy --file 
>> C:\DOCUME~1\saarfmar\LOCALS~1\Temp\maven-scm-108
>> 0661760.commit . svn://fitst37/income/tags/1.0.0
>> [INFO] Working directory: C:\temp\income
>> [INFO] 
>> 
>> [ERROR] BUILD FAILURE
>> [INFO] 
>> 
>> [INFO] Unable to tag SCM
>> Provider message:
>> The svn tag command failed.
>> Command output:
>> svn: Commit failed (details follow):
>> svn: Source url 'svn://[EMAIL PROTECTED]/income/trunk' is from different 
>> repository
>>
>> [INFO] 
>> 
>> [DEBUG] Trace
>> org.apache.maven.BuildFailureException: Unable to tag SCM
>> Provider message:
>> The svn tag command failed.
>> Command output:
>> svn: Commit failed (details follow):
>> svn: Source url 'svn://[EMAIL PROTECTED]/income/trunk' is from different 
>> repository
>>
>> at 
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor
>> .java:555)
>>
>> Anyone have any idea what do to?
>>
>> Regards,
>>
>> Markku Saarela
>>
>> -
>> 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: assembly:single failing

2007-10-19 Thread Tim Kettler
Hi,

is the pom where the assembly is build also used as the parent pom for
the modules? If yes, you've hit a design flaw in maven. Currently, the
parent relationship introduces a dependency from child to parent, hence
the parent is build first and the artifact of the child doesn't exist
yet. Look at your log output, you should see that the parent project is
build first.

See this thread [1] for an explanation from a developer. If you  need to
create the assembly attached to the build lifecycle instead of the
proposed solution to just build it manually you need to factor out
either the parent-pom features or the assembly building stuff to a
separate pom.

-Tim

[1]
http://www.nabble.com/Problem-attaching-assembly-to-multi-module-pom-project-tf4576505s177.html#a13063505n

[EMAIL PROTECTED] schrieb:
> Hi again,
> 
> (thanks to Stéphane Veyret for my previous question, I moved out the 
>  and  tags in an  tag and it is triggered now -- 
> but does not work as expected)
> 
> I know the subject has been brought up multiple times, but reading the 
> whole summary thread 
> (http://www.mail-archive.com/users@maven.apache.org/msg53354.html, linking 
> to http://jira.codehaus.org/browse/MASSEMBLY-97), I still can not use 
> assembly:single in my multi-module project.
> 
> My main pom looks like :
> 
> ...
> 
> 
>  
> 
> maven-assembly-plugin
> 2.2-beta-1
> false
> 
> false
> 
> src/main/assembly/assembly.xml descriptor>
> 
> 
> 
> 
> 
> package
> 
> single
> 
> 
> 
> 
> 
> 
> From what I've read, the phase must be bound for the single goal. If I use 
> 'mvn package' from the command line, I get :
> 
> [INFO] Failed to create assembly: Artifact: 
> foo:module:jar:3.0.7-SNAPSHOT (included by module) does not have an 
> artifact with a file. Please ensure the package phase is run before the 
> assembly is generated.
> 
> If it run 'assembly:assembly' from the command line, I get (for the main 
> project) :
> 
> [INFO] Error reading assemblies: No assembly descriptors found.
> 
> 
> any idea about why it seems to work for everybody else except me? :)
> 
> best regards,
> 
> --Stéphane
> 
> 
> This message and any attachments (the "message") is
> intended solely for the addressees and is confidential. 
> If you receive this message in error, please delete it and 
> immediately notify the sender. Any use not in accord with 
> its purpose, any dissemination or disclosure, either whole 
> or partial, is prohibited except formal approval. The internet
> can not guarantee the integrity of this message. 
> BNP PARIBAS (and its subsidiaries) shall (will) not 
> therefore be liable for the message if modified. 
> 
> -
> 
> Ce message et toutes les pieces jointes (ci-apres le 
> "message") sont etablis a l'intention exclusive de ses 
> destinataires et sont confidentiels. Si vous recevez ce 
> message par erreur, merci de le detruire et d'en avertir 
> immediatement l'expediteur. Toute utilisation de ce 
> message non conforme a sa destination, toute diffusion 
> ou toute publication, totale ou partielle, est interdite, sauf 
> autorisation expresse. L'internet ne permettant pas 
> d'assurer l'integrite de ce message, BNP PARIBAS (et ses
> filiales) decline(nt) toute responsabilite au titre de ce 
> message, dans l'hypothese ou il aurait ete modifie.
> 
> 


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



Re: Possible conflict with ejb and jar plugins

2007-10-18 Thread Tim Kettler
I think the reason he's using both plugins is that the ejb-plugin
currently doesn't provide the includes/excludes configuration as
the jar plugin. So the intention is not to produce two (main) artifacts
from the same pom but to just to have the ejb and a ejb-client jar.

What happens with this pom snippet is that the jar produced by the
jar-plugin is overwritten by the jar produced by the ejb-plugin, as both
produce main artifacts (with the same filename) for the project. You can
try moving the jar-plugin configuration afer the ejb-plugin in your pom
and see if that helps.

The real solution for this of course is to support the includes/excludes
configuration in the ejb plugin, too.

-Tim

Wayne Fay schrieb:
> Is there a specific reason you're building both artifacts out of the
> one codebase? Can you not break it into 2 separate codebases and
> specify one as "jar" and the other as "ejb" and then put a dependency
> in the ejb on the jar project, as I'm assuming the ejb needs the jar
> files to work (like a utility library)?
> 
> This is the "Maven way" to do things. Of course, you can do it however
> you want, but I generally find it easiest to just do what Maven is
> expecting.
> 
> Wayne
> 
> On 10/18/07, Mark_E <[EMAIL PROTECTED]> wrote:
>> Hi Wayne,
>>I am actually building both a jar and ejb in the same project, here are
>> the 2 plugins I use.
>>
>> 
>>  org.apache.maven.plugins
>>  maven-jar-plugin
>>  2.2-SNAPSHOT
>>  
>> 
>>   **/handlers/**/*.*
>> 
>>  
>>  
>> 
>>org.apache.maven.plugins
>>maven-ejb-plugin
>>
>> 
>>   ejb-client
>>package
>>   
>>  ejb
>>   
>> 
>>
>>
>>  2.1
>>  true
>>  
>>
>>  true
>>  lib
>>
>>  
>>  
>>  com/**/ejb/**/*.class
>>  META-INF/jboss.xml
>>  META-INF/ejb-jar.xml
>>  
>>
>> 
>>
>> If Maven does not like that I am build both artifacts, I may just create the
>> EJB inside the antrun plugin, since I already have the compiled classes from
>> the compile phase. If you have any other suggestions, that would be great.
>>
>>
>> Regards,
>> Mark
>>
>> Wayne Fay wrote:
>>> Are you building both a Jar and an EJB Jar in a single Maven project?
>>> Or are these 2 separate projects that have a common parent?
>>>
>>> Maven likes 1 artifact per module. Please explain your project better
>>> and/or send the poms for diagnosis.
>>>
>>> Wayne
>>>
>>> On 10/18/07, Mark_E <[EMAIL PROTECTED]> wrote:
>>>> Hello,
>>>>  I am running into a strange situation with the maven-ejb-plugin and
>>>> maven-jar-plugin
>>>>
>>>> I am performing a build, building a jar and an ejb. Seems that when I
>>>> execute the ejb plugin during the package phase, it messes up the
>>>> execution
>>>> of the maven-jar-plugin.
>>>>
>>>> For example, I am using the snapshot version of the maven-jar-plugin
>>>> (2.2)
>>>> that contains the excludes fix. If I build both an ejb and jar in my
>>>> project, it seems to override the exclude switch in the jar plugin and I
>>>> get
>>>> files I do not want in the jar.
>>>>
>>>> If I turn off the maven-ejb-plugin in my build and re-run the mvn package
>>>> command, the exclude switch in the jar plugin works fine and I do not get
>>>> the files I excludes from my jar.
>>>>
>>>> I am running version 2.1 of the EJB Plugin.
>>>>
>>>> Just wondering if anyone else is running into this. Maybe I am doing
>>>> something wrong? I thought it might be the clientInclude switch used in
>>>> the
>>>> ejb plugin so I disabled this in my pom.xml but the issue still exists. I
>>>> have to comment out the ejb plugin all together to get the excludes for
>>>> the
>>>> jar to work.
>>>>
>>>> Anyway, if anyone has any suggestions, I would appreciate them very much.
>>>> I
>>>> need to get this resolved and I would like to use the maven plugin 

Re: Javadoc Plugin 2.3 - Generating Doc caused Out of Memory -Xmx doent help

2007-10-18 Thread Tim Kettler
Hi,

in the subject you say genereating the javadoc causes the OOME, but
judging from the log output it seems it's in the antrun-plugin
execution. Have you just tried invoking maven itself with more memory:

mvn -Xmx... or MAVEN_OPTS=-Xmx...

-Tim

Mac-Systems schrieb:
> Hello,
> 
> since yesterday we never generated Javadoc for our large Multiprojekt.
> I included the javadoc plugin and run : mvn site
> all is fine so far, javadoc is generated, but in a subprojekt which uses
> the "generate sources"
> phase to call some ANT script . Now i get exactly there a out of memory
> Error.
> Well, i do not believe the error comes from that ANT Plugin (i tested i
> already), as Javadoc is the only thing
> i changed to my pom for a while, below i tried to set the memory options
> for the javadoc plugin whithout
> any luck (i get again an OOM Error).
> 
> Someone can tell me what i am doing wrong there ?
> 
> 
>
>org.apache.maven.plugins
>maven-javadoc-plugin
>2.3
>
> 
> 
> 
> ..
>
>org.apache.maven.plugins
>maven-javadoc-plugin
>
>
>   http://java.sun.com/j2se/1.5.0/docs/api/
>
>false
>true
>1024m
>512m
> 
> 
> 
> Following output i get:
> 
> 
> [INFO] [antrun:run {execution: }]
> [INFO] Executing tasks
> [echo] Generiere Sourcecode fuer Projekt...
> 
> init:
> 
> ejbdoclet:
> PermGen space
> ParameterImpl instances:   0
> MethodImpl instances:  0
> ConstructorImpl instances: 0
> SimpleNode instances:  0
> SourceClass instances: 0
> XDoc instances:0
> DefaultXTag instances: 0
> BinaryClass instances: 0
> UnknownClass instances:0
> Total memory:171
> Free memory:90
> Try to increase heap size. Can be done by defining ANT_OPTS=-Xmx640m
> See the JDK tooldocs.
> 
> 
> 
> Before i was using version 2.2 of javadoc Plugin, the output was more
> like the standard java out of memory error.
> 
> I set also ANT_OPTS to an high value, also which now results.
> 
> Anyone can help ?
> 
> best regards,
> Jens
> 
> 
> 
> 
> 
> -
> 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: ejb building not working

2007-10-18 Thread Tim Kettler
Hi,

the ejb-plugin checks, if
${project.build.outputDirectory}/META-INF/ejb-jar.xml exists if the ejb
version is less than 3.0. Check if your ejb-jar.xml is really present in
that location.

-Tim

EJ Ciramella schrieb:
> Has anyone run across this particular type of error:
>  
> [ERROR] BUILD ERROR
> [INFO]
> 
> [INFO] Error assembling EJB: META-INF/ejb-jar.xml is required for
> ejbVersion 2.x
> [INFO]
> 
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Error assembling
> EJB: META-INF/ejb-jar.xml is required for ejbVersion 2.x
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Default
> LifecycleExecutor.java:564)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifec
> ycle(DefaultLifecycleExecutor.java:480)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultL
> ifecycleExecutor.java:459)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandle
> Failures(DefaultLifecycleExecutor.java:311)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(
> DefaultLifecycleExecutor.java:278)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifec
> ycleExecutor.java:143)
> at
> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:330)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:123)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:272)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav
> a:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
> Impl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at
> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> at
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Error
> assembling EJB: META-INF/ejb-jar.xml is required for ejbVersion 2.x
> at org.apache.maven.plugin.ejb.EjbMojo.execute(EjbMojo.java:223)
> at
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginMa
> nager.java:420)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Default
> LifecycleExecutor.java:539)
> ... 16 more
>  
>  
> Yet I DO have a META-INF/ejb-jar.xml file
> 


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



Re: Java doc generation

2007-10-16 Thread Tim Kettler
The plugin executes 'javadoc -J-fullversion' to retrieve the version of
the javadoc tool and expects output like this:

  java full version "1.5.0_11-b03"


See here for reference [1]. Can you try if your javadoc prints the
version information in some other format.

-Tim

[1]
https://svn.apache.org/repos/asf/maven/plugins/tags/maven-javadoc-plugin-2.3/src/main/java/org/apache/maven/plugin/javadoc/AbstractJavadocMojo.java

Sinduria,Anuradha schrieb:
> I created a symbolic link, java doc generation started but it got stuck and
> generated this error
> 
> 
> [INFO] Generate "JavaDocs" report.
> [INFO]
> 
> [ERROR] FATAL ERROR
> [INFO]
> 
> [INFO] For input string: "dial"
> [INFO]
> 
> [INFO] Trace
> java.lang.NumberFormatException: For input string: "dial"
> at
> sun.misc.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:1224)
> at java.lang.Float.parseFloat(Float.java:394)
> at
> org.apache.maven.plugin.javadoc.AbstractJavadocMojo.getJavadocVersion(Abstra
> ctJavadocMojo.java:2966)
> at
> org.apache.maven.plugin.javadoc.AbstractJavadocMojo.executeReport(AbstractJa
> vadocMojo.java:1085)
> at
> org.apache.maven.plugin.javadoc.JavadocReport.generate(JavadocReport.java:13
> 1)
> at
> org.apache.maven.plugins.site.ReportDocumentRenderer.renderDocument(ReportDo
> cumentRenderer.java:67)
> at
> org.apache.maven.doxia.siterenderer.DefaultSiteRenderer.renderModule(Default
> SiteRenderer.java:239)
> at
> org.apache.maven.doxia.siterenderer.DefaultSiteRenderer.render(DefaultSiteRe
> nderer.java:115)
> at
> org.apache.maven.plugins.site.SiteMojo.renderLocale(SiteMojo.java:124)
> at org.apache.maven.plugins.site.SiteMojo.execute(SiteMojo.java:92)
> at
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManage
> r.java:443)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLife
> cycleExecutor.java:539)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle
> (DefaultLifecycleExecutor.java:480)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifec
> ycleExecutor.java:459)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFail
> ures(DefaultLifecycleExecutor.java:311)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(Defa
> ultLifecycleExecutor.java:278)
> at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycle
> Executor.java:143)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:334)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:125)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:272)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39
> )
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
> .java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at
> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
> at
> org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> [INFO]
> 
> 
> Thanks and Regards,
> Anuradha Sinduria
>  
> 
> -Original Message-
> From: Tim Kettler [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, October 16, 2007 1:47 PM
> To: Maven Users List
> Subject: Re: Java doc generation
> 
> Hi,
> 
> this is a known bug [1]. It's fixed in svn but a fixed version is not
> released yet. Aa a workaround, just create a symlink.
> 
> -Tim
> 
> [1] http://jira.codehaus.org/browse/PLXUTILS-34
> 
> Sinduria,Anuradha schrieb:
>>  
>>
>> Hi All,
>>
>>  
>>
>> I want to do Java doc generation while doing "mvn site" on my UNIX Free
> BSD
>> 6.2.
>>
>> I added following in my pom
>>
>>  
>>
>> 
>>
>>org.apache.maven.plugins
>>
>>maven-javadoc-plug

Re: Maven plugin for JPA processing

2007-10-16 Thread Tim Kettler
Hi,

there is a apt-maven-plugin in the sanbox of the mojo project [1].

-Tim

[1] http://svn.codehaus.org/mojo/trunk/sandbox/apt-maven-plugin/

Zarick Lau schrieb:
> Dear users and developers,
> 
> I have come across an article on here
> http://weblogs.java.net/blog/ss141213/archive/2005/12/how_to_automati.html
> 
> Which use apt to inspect all JPA beans (check @Entity) and update
> the persistence.xml.
> 
> Is there any corresponding plugin in Maven?
> 
> I intended to make one, but just want to make sure that, no one else are 
> already
> working on it (or made one already).
> 
> Best regards,
> Zarick
> 
> -
> 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: Java doc generation

2007-10-16 Thread Tim Kettler
Hi,

this is a known bug [1]. It's fixed in svn but a fixed version is not
released yet. Aa a workaround, just create a symlink.

-Tim

[1] http://jira.codehaus.org/browse/PLXUTILS-34

Sinduria,Anuradha schrieb:
>  
> 
> Hi All,
> 
>  
> 
> I want to do Java doc generation while doing "mvn site" on my UNIX Free BSD
> 6.2.
> 
> I added following in my pom
> 
>  
> 
> 
> 
>org.apache.maven.plugins
> 
>maven-javadoc-plugin
> 
>
> 
>   
> 
> http://java.sun.com/j2se/1.5.0/docs/api/
> 
> http://plexus.codehaus.org/ref/1.0-alpha-9/apidocs
> 
> http://jakarta.apache.org/commons/dbcp/apidocs/
> 
>   
> 
> 
> 
> 
> 
>  
> 
> I am getting the following error
> 
>  
> 
> [INFO] Generate "JavaDocs" report.
> 
> [INFO]
> 
> 
> [ERROR] BUILD ERROR
> 
> [INFO]
> 
> 
> [INFO] Error during page generation
> 
>  
> 
> Embedded error: Error rendering Maven report: Unable to find javadoc
> version: Error while executing process.
> 
> java.io.IOException: /bin/bash: not found
> 
> [INFO]
> 
> 
>  
> 
> My bash is in /usr/local/bin/bash and I have sh shell inside /bin (/bin/sh)
> 
>  
> 
> I tried below plugin also but getting same error:
> 
>  
> 
> 
> 
> maven-javadoc-plugin
> 
> 
> 
>
> 
>   uml
> 
>   
> 
>  gr.spinellis.umlgraph.doclet.UmlGraph
> 
>  
> 
> umlgraph
> 
> UMLGraph
> 
> 4.2-SNAPSHOT
> 
>  
> 
>  -views
> 
>  target/uml
> 
>  private
> 
>   
> 
>   
> 
>  javadoc
> 
>   
> 
>
> 
>
> 
>   html
> 
>   
> 
>  private
> 
>   
> 
>   
> 
>  javadoc
> 
>   
> 
>
> 
> 
> 
> 
> 
>  
> 
> Please advice how to resolv it.
> 
>  
> 
> Thanks and Regards,
> 
> Anuradha Sinduria
> 
>  
> 
>  
> 
> 


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



Re: How to specify repository on the command line?

2007-10-16 Thread Tim Kettler
Hi,

just look at the appfuse homepage [1] there a examples for all
archetypes on the quickstart page.

-Tim

[1] http://www.appfuse.org/display/APF/Home

siegfried schrieb:
> I'm trying to use the appfuse-basic-string described at
> http://docs.codehaus.org/display/MAVENUSER/Archetypes+List and it is not
> working. I think I need to specify the URL of the repository on the command
> line. I did maven -help but was surprised to find such a small number of
> switches and no switch for the repository. I did a google search for maven
> repositories thinking surely someone else already asked this question but I
> could not find my answer.
> 
>  
> 
> (1) How do I specify the URL of the repository if there is no pom.xml
> yet?
> 
> (2) Do I need to specify http://static.appfuse.org/releases as the
> repository for the appfuse archetypes? I tried "mvn archetype:create
> -DgroupId=www.signitek -DartifactId=demo-basic-spring
> -DarchetypeArtifactId=org.appfuse.archetypes
> -DarchetypeGroupId=appfuse-basic-spring
> -DremoteRepositories=http://static.appfuse.org/releases"; but this did not
> help.
> 
> (3) If not, what am I doing wrong?
> 
>  
> 
>  
> 
> Thanks,
> 
> Siegfried
> 
>  
> 
>  
> 
>  
> 
> mvn archetype:create -DgroupId=www.signitek -DartifactId=demo-basic-spring
> -DarchetypeArtifactId=org.appfuse.archetypes
> -DarchetypeGroupId=appfuse-basic-spring
> 
> [INFO] Scanning for projects...
> 
> [INFO] Sea
> 
> rching repository for plugin with prefix: 'archetype'.
> 
> [INFO]
> 
> 
> [INFO] Building Maven Default Project
> 
> [INFO]task-segment: [archetype:create] (aggregator-style)
> 
> [INFO]
> 
> 
> [INFO] Setting property: classpath.resource.loader.class =>
> 'org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader'.
> 
> [INFO] Setting property: velocimacro.messages.on => 'false'.
> 
> [INFO] Setting property: resource.loader => 'classpath'.
> 
> [INFO] Setting property: resource.manager.logwhenfound => 'false'.
> 
> [INFO] ** 
> 
> [INFO] Starting Jakarta Velocity v1.4
> 
> [INFO] RuntimeInstance initializing.
> 
> [INFO] Default Properties File:
> org\apache\velocity\runtime\defaults\velocity.properties
> 
> [INFO] Default ResourceManager initializing. (class
> org.apache.velocity.runtime.resource.ResourceManagerImpl)
> 
> [INFO] Resource Loader Instantiated:
> org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader
> 
> [INFO] ClasspathResourceLoader : initialization starting.
> 
> [INFO] ClasspathResourceLoader : initialization complete.
> 
> [INFO] ResourceCache : initialized. (class
> org.apache.velocity.runtime.resource.ResourceCacheImpl)
> 
> [INFO] Default ResourceManager initialization complete.
> 
> [INFO] Loaded System Directive:
> org.apache.velocity.runtime.directive.Literal
> 
> [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Macro
> 
> [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Parse
> 
> [INFO] Loaded System Directive:
> org.apache.velocity.runtime.directive.Include
> 
> [INFO] Loaded System Directive:
> org.apache.velocity.runtime.directive.Foreach
> 
> [INFO] Created: 20 parsers.
> 
> [INFO] Velocimacro : initialization starting.
> 
> [INFO] Velocimacro : adding VMs from VM library template :
> VM_global_library.vm
> 
> [ERROR] ResourceManager : unable to find resource 'VM_global_library.vm' in
> any resource loader.
> 
> [INFO] Velocimacro : error using  VM library template VM_global_library.vm :
> org.apache.velocity.exception.ResourceNotFoundException: Unable to find
> resource 'VM_global_library.vm'
> 
> [INFO] Velocimacro :  VM library template macro registration complete.
> 
> [INFO] Velocimacro : allowInline = true : VMs can be defined inline in
> templates
> 
> [INFO] Velocimacro : allowInlineToOverride = false : VMs defined inline may
> NOT replace previous VM definitions
> 
> [INFO] Velocimacro : allowInlineLocal = false : VMs defined inline will be
> global in scope if allowed.
> 
> [INFO] Velocimacro : initialization complete.
> 
> [INFO] Velocity successfully started.
> 
> [INFO] [archetype:create]
> 
> [INFO] Defaulting package to group ID: www.signitek
> 
> [INFO] artifact appfuse-basic-spring:org.appfuse.archetypes: checking for
> updates from central
> 
> [WARNING] re

<    1   2   3   4   5   6   7   8   9   10   >