RE: War plugin transitive dependency

2007-06-08 Thread Váry Péter
Hi all,

If this is not possible with maven, it is an answer as well. Then I can think 
about writing a plugin, or simply accepting dependency as it is.

Any insight would be usefull.

Regards,
Péter 

-Original Message-
From: Váry Péter [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 07, 2007 6:15 PM
To: users@maven.apache.org
Subject: War plugin transitive dependency

Hi all,

For the short version jump at the end of the letter :o)

 long version

I am new to maven, but impressed with the features, and possibilities. I would 
like to migrate our ant based build system to a maven based one. The main 
reason is dependencies, especially transitive dependencies.

We have approximately 50 small modules, and about half of them are web modules, 
with plenty of - tree structured - dependencies. There are dependencies between 
the web modules as well (say news web module depends on HTML editor web module, 
and user web module depends on group web module, and most importantly portal 
web module depends on news, and user module)

There are more than 70 small websites using these modules, and some own code, 
and web resources (jsp, js, css etc.) to build wars running on tomcat.

In our current build system in every module we package the classes in a jar, 
and put the web resources in a stub. And for the products we collect these 
stubs, and jars, and merge it along with the product specific ones.

 short version

With using the war plugin, we can declare transitive dependencies, A depends on 
B, and B depends on C. With SNAPSHOT versions I would like to see every changes 
in C appear immediately in A, without any manual interaction (or as few as 
possible).

I have tried another way to create assemblies from warstub-s, but I was unable 
to declare them as dependencies.

Any idea how can I solve this problem with maven?

Thanks,
Peter


-
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: Daytrader doesn't compile

2007-06-08 Thread Timothy Reilly

Posting these back on the user list:

 From: Eduardo  [wrote:] 
 Sent: Monday, June 04, 2007 10:01 AM
 To: Timothy Reilly
 Subject: Daytrader doesn't compile
 
 Hello Timothy,
 
 I have the exact same error when trying to install the 
 daytrader application... Did you come to any conclussions?
 
 Thanks,
 
 Eduardo 
 

Another one:
 -Original Message-
 From: Leonid [wrote:] 
 Sent: Sunday, June 03, 2007 2:45 PM
 To: Timothy Reilly
 Subject: Daytrader doesn't compile

 Yes, I've got the same error
 
 
 No virus found in this outgoing message.
 Checked by AVG Free Edition.
 Version: 7.5.472 / Virus Database: 269.8.5/826 - Release Date:
31-May-07 16:51


Orginal message:
http://www.nabble.com/Daytrader-doesn%27t-compile-tf3813171s177.html#a10
794039



The best I can gather is that something changed in the axis generated
sources and they are no longer compatible with the project. 
Setting the axistools-maven-plugin version fixes part of the issue.

1)
The easiest things to do is checkout the Daytrader 1.1.0 from svn:
svn -co https://svn.apache.org/repos/asf/geronimo/daytrader/tags/1.1.0
daytrader

This built fine for me.


2)
The harder way was to set the axistools-maven-plugin version to 1.0, and
then fix the additional errors. Eventually, this built once I had the
third party jars etc. (Caveat: I did not go beyond getting it to
compile - so the fixes below may or not work at runtime.)
My difference looks like this:


---
daytraderOrig/wsappclient/src/main/java/org/apache/geronimo/samples/dayt
rader/client/ws/ClientApp.java  Sat Apr 08 06:32:04 2006
+++
daytrader/wsappclient/src/main/java/org/apache/geronimo/samples/daytrade
r/client/ws/ClientApp.java  Fri Jun 08 01:47:33 2007
@@ -1354,7 +1354,8 @@
0);
result = orderData.toString();
} else if
(action.equalsIgnoreCase(Orders)) {
-   Object[] orders =
getTrade().getOrders(currentUser);
+   ArrayOfOrderDataBean ordersBean
= getTrade().getOrders(currentUser);
+   Object[] orders =
ordersBean.getOrderDataBean();
if (orders.length == 0) {
result = No orders;
}
@@ -1365,7 +1366,8 @@
}
 
} else if
(action.equalsIgnoreCase(Holdings)) {
-   Object[] holdings =
getTrade().getHoldings(currentUser);
+   ArrayOfHoldingDataBean
holdingsBean = getTrade().getHoldings(currentUser);
+   Object[] holdings =
holdingsBean.getHoldingDataBean();
if (holdings.length == 0) {
result = No holdings;
}
---
daytraderOrig/ejb/src/main/java/org/apache/geronimo/samples/daytrader/so
ap/TradeWebSoapProxy.java   Sat Apr 08 06:32:04 2006
+++
daytrader/ejb/src/main/java/org/apache/geronimo/samples/daytrader/soap/T
radeWebSoapProxy.java   Fri Jun 08 03:22:52 2007
@@ -134,14 +134,14 @@
 * @see
org.apache.geronimo.samples.daytrader.TradeServices#getAllQuotes()
 */
public Collection getAllQuotes() throws Exception,
RemoteException {
-   return
convertQuoteDataBeanWSArrayToCollectionBase(getTrade().getAllQuotes());
+   return
convertQuoteDataBeanWSArrayToCollectionBase(getTrade().getAllQuotes().ge
tQuoteDataBean());
}
 
/* (non-Javadoc)
 * @see
org.apache.geronimo.samples.daytrader.TradeServices#getClosedOrders(java
.lang.String)
 */
public Collection getClosedOrders(String userID) throws
Exception, RemoteException {
-   Object[] orders = getTrade().getClosedOrders(userID);
+   Object[] orders =
getTrade().getClosedOrders(userID).getOrderDataBean();
ArrayList ordersRet = new ArrayList();
if (orders.length == 0) {
return ordersRet;
@@ -163,7 +163,7 @@
 * @see
org.apache.geronimo.samples.daytrader.TradeServices#getHoldings(java.lan
g.String)
 */
public Collection getHoldings(String userID) throws Exception,
RemoteException {
-   Object[] holdings = getTrade().getHoldings(userID);
+   Object[] holdings =
getTrade().getHoldings(userID).getHoldingDataBean();
ArrayList holdingsRet = new ArrayList();
if (holdings.length == 0) {
return holdingsRet;
@@ -186,7 +186,7 @@
 * @see
org.apache.geronimo.samples.daytrader.TradeServices#getOrders(java.lang.
String)
 */
public Collection getOrders(String userID) throws Exception,
RemoteException {
- 

Configuration questions

2007-06-08 Thread Kevin . A . D'Arcy

Hi all,

Just two quick configuration questions:

1. In most of the projects I work on there are different sets of
configuration files that are used depending on whether the application
is in various stages of test/production and I'm wondering what the best
way is to handle these in regard to the Maven standard folder structure.
I'm guessing the src/main/resources folder is where they should go, but
when I'm running a build through Maven, how do I tell it to include one set
of config file and ignore the rest?

2. When setting up a folder structure of an EAR project containing a WAR,
should the EAR project folder contain the WAR (i.e. as a module) or should
the two projects be at the same folder level?

Many thanks,

Kev



**
This document is strictly confidential and is intended for use by the addressee 
unless otherwise indicated.

This email has been scanned by an external email security system.

Allied Irish Banks

AIB and AIB Group are registered business names of Allied Irish Banks p.l.c. 
Allied Irish Banks, p.l.c. is regulated by the Financial Regulator.  Registered 
Office: Bankcentre, Ballsbridge, Dublin 4. Tel: + 353 1 6600311; Registered in 
Ireland: Registered No. 24173
**


Re: Lifecyle Question

2007-06-08 Thread Jo Vandermeeren

Hi Jens,

Post your pom.xml files, so we can have a look..

Cheers
Jo

On 6/7/07, Mac Systems [EMAIL PROTECTED] wrote:


Hello Maven Users,

i'd like to how this can happen:

I have an Multiprojekt:

mvn compile

work well, all is compiled!

If i do

mvn package

i get an Error that some package and test-jar not found. Can someone
explain a bit how this can happen ?

greets,
Jens

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




antrun plugin in non-aggregrate mode

2007-06-08 Thread Kevin Stembridge
Hi all,
I'm calling antrun:run from a parent project and it tries to do the same 
in submodules. (Is this what you call an aggregator?) 
Is there any way to prevent this?

Cheers,
Kevin

---

This e-mail may contain confidential and/or privileged information. If you 
are not the intended recipient (or have received this e-mail in error) 
please notify the sender immediately and destroy this e-mail. Any 
unauthorized copying, disclosure or distribution of the material in this 
e-mail is strictly forbidden.

Re: docbook + maven

2007-06-08 Thread Steve Ebersole
If you look at the code and projects using it, yes, I am aware of this.
Or did you miss the directories containing the font definitios
tongue-in-cheekly named no-idea-what-to-do-with-these-yet? ;)

Actually I was leaning on the expertise of the Red Hat documentation
team here, since DocBook (nor xslt, really) is not my forte.  I have yet
to breach this particular topic with them.

If you have a particular need/requirement, well, patches welcome ;)


On Thu, 2007-06-07 at 13:15 +0200, Tamás Cservenák wrote:
 Hello,
 
 I had another problem with docbook plugins for maven2. I will just describe
 it, as it is too often overseen :)
 
 My problem was FOP and it's configuration in docbkx plugin. I needed docbook
 in maven2 to generate docs in Hungarian language. The FOP per default
 produces PDF with Adobe Default font set (16 fonts) and with all of them in
 LATIN1 encoding, which is not enough for Eastern European languages.
 
 The resolution is to introduce different fonts beside defaults to FOP.
 See:
 http://xmlgraphics.apache.org/fop/0.20.5/fonts.html#register
 
 Just a thought, since as i read your code, you do the similar thing as
 docbkx:
 
 http://anonsvn.jboss.org/repos/hibernate/trunk/sandbox/maven-poc/plugins/maven-jboss-docbook-plugin/src/main/java/org/jboss/maven/plugin/docbook/gen/render/PdfRenderer.java
 
 http://docbkx-tools.googlecode.com/svn/trunk/docbkx-maven-plugin/src/main/java/com/agilejava/docbkx/maven/AbstractPdfMojo.java
 
 
 The configuration customization for FOP is unreachable in both cases, thus
 it both would renders unusable PDFs in non-LATIN1 environments.
 
 The solution would be to make FOP configuration reachable from maven config,
 or at least create a possibility to direct the FOP to use some specific
 config-file from within the project.
 
 
 Btw, the docbkx project moved from agilejava.com to
 http://code.google.com/p/docbkx-tools/
 
 Cheers,
 ~t~
 
 
 On 6/4/07, Steve Ebersole [EMAIL PROTECTED] wrote:
 
  As part of migrating Hibernate to use Maven, one of the big issues I ran
  into was the current state of DocBook plugins for Maven.  The current
  mojo-codehaus hosted plugin is insufficient.  There is another more
  widely used one done by one Wilfred Springer as part of something called
  agilejava.  The agilejava one is fairly full featured, but is really
  pretty bare bones in terms of configuration (its is mainly a simplistic
  wrapper around the defined DocBook xslt parameters).
 
  In my estimation the, agilejava one was closer to usability, but Mr.
  Springer did not seem interested in accepting my volunteer to help
  improve his plugin.  So I began implementing my own.
 
  It works off of a slightly different approach than the other two.  The
  biggest difference being that custom stylesheets are packaged as
  separate projects and included via the Maven dependency mechanism.  This
  allows true reuse of the stylesheets across projects.  The other is
  planned better support of translations which is important for Hibernate,
  and most projects using DocBook.
 
  This however led to a conceptual question regarding how to best handle
  image references.  As background, in DocBook, the way images normally
  get resolved is as via xslt templates.  The DocBook supplied templates
  do a hard file lookup relative to a xslt parameter named 'img.src.path'
  if it is set; and really this is format specific as well.  Regardless,
  though, I need a mechanism to access the image files from these style
  projects and be able to resolve reference to them from the DocBook
  source or xsl stylesheets.  I have identified a few potential approaches
  to achieve that:
  1) force separation of (a) xslt and (b) resources like images/css into
  separate projects.  Specifically, #b would need a custom packaging which
  would allow me to find resources and unarchive them locally into a
  staging dir for use in 'img.src.path'.  A variation on this would be to
  bundle them together with a custom packaging and somehow extract just
  the resources.
  2) Apply custom graphics resolution templates to the built xsl
  transformers, hoping that the custom xslt does not itself do this.
 
  I'm not (necessarily) looking for volunteers (although certainly that is
  welcome).  More I just need people's thoughts on the various approaches,
  especially those using or familiar with DocBook.
 
  Thanks,
  Steve
 
 
  -
  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: procedure for upgrade to 1.1 ?

2007-06-08 Thread Emmanuel Venisse

We don't have a procedure yet because the database is different.
The best way for now is to install alpha-2 and add all your project in it.

Emmanuel

Ionut S a écrit :
Nobody upgraded from 1.0.3 to 1.1 alpha2 ? 


Ionut S [EMAIL PROTECTED] wrote: Hi,
I wanted to move today to 1.1 alpha2, but I couldn't find the procedure for 
upgrade.. Will you have an upgrade procedure soon ?

Thank you !

   
-
Get the Yahoo! toolbar and be alerted to new email wherever you're surfing. 

   
-

Looking for a deal? Find great prices on flights and hotels with Yahoo! 
FareChase.




Re: procedure for upgrade to 1.1 ?

2007-06-08 Thread Ionut S
Thanks for your response, this is what I wanted to hear.

Should we expect (in the near future) a tool to migrate the data from one 
version to another ?

Emmanuel Venisse [EMAIL PROTECTED] wrote: We don't have a procedure yet 
because the database is different.
The best way for now is to install alpha-2 and add all your project in it.

Emmanuel

Ionut S a écrit :
 Nobody upgraded from 1.0.3 to 1.1 alpha2 ? 
 
 Ionut S  wrote: Hi,
 I wanted to move today to 1.1 alpha2, but I couldn't find the procedure for 
 upgrade.. Will you have an upgrade procedure soon ?
 
 Thank you !
 

 -
 Get the Yahoo! toolbar and be alerted to new email wherever you're surfing. 
 

 -
 Looking for a deal? Find great prices on flights and hotels with Yahoo! 
 FareChase.



   
-
Ready for the edge of your seat? Check out tonight's top picks on Yahoo! TV. 

maven-jar-plugin wraps manifest.mf line at wrong position

2007-06-08 Thread 張旭

Dear friends,
I have encountered a strange problem when specify  custom manifest file when
using the maven-jar-plugin.
I've a very very long line in the manifest file that maybe have hundreds
columns.
It seems that the plug-in will automatically wrap the line every 70 cols.
Is there a parameter in configuration that can override the default
behavior?

Thanks in advance.


Re: Maven-proxy and error

2007-06-08 Thread Thorsten Heit
Hi,

 Which section of maven-proxy.properties is relevant to a firewall. Is it
 the
 proxies section.

Yes.


 Here is my maven-proxy.properties...

*snip*


  PROXIES
 #This is just a hack, it should auto discover them
 proxy.list=one,two,three
 #Unauthenticated proxy
 proxy.one.host=proxy1.example.com
 proxy.one.port=3128
 
 #Authenticated proxy
 proxy.two.host=proxy2.example.org
 proxy.two.port=80
 proxy.two.username=username2
 proxy.two.password=password2

Here you have to enter your proxy settings, i.e. proxy.name.host, 
proxy.name.port etc.


 #www.ibiblio.org
 repo.www-ibiblio-org.url=http://repo1.maven.org/maven2
 repo.www-ibiblio-org.description=www.ibiblio.org
 repo.www-ibiblio-org.proxy=one
 repo.www-ibiblio-org.hardfail=true

...and in that section you refer to the above proxy settings by simply using a 
line such as repo.www-ibiblio-org.proxy=name


BTW:
AFAIK maven-proxy isn't developed anymore so I would think about switching to 
another repository proxy/cache such as Artifactory, Archivar, Proximity or 
whatever.


HTH

Thorsten

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



Re: calling plugin in another plugin?

2007-06-08 Thread 張旭

Thanks to everyone.

Now I know there is no way through maven2 api to call another plugin. Am I
right?

According to Jason, it's a bad idea to call one plugin directly in another.

But I still think it's maybe very convenience to do things like that so I
can use functions of other plugin directly and have parameters passed to
other plugin totally under my control.


On 6/7/07, David Jackman [EMAIL PROTECTED] wrote:


Here's another situation where I want to have a plugin call another
plugin.  Can you tell me the right way to accomplish this?

In our group we have a release procedure that involves a few more steps
beyond running the release:prepare mojo.  In fact, some of the parameters
into the release:prepare mojo are based on internal standards, so they could
be computed automatically.  I want to create a single plugin that embodies
this entire release process that also calls the release:prepare mojo with
the correct parameters as part of that process.

This would be another situation where one plugin invokes another
plugin.  Obviously there is coupling there.  What is a better way to achieve
this without that coupling (is it even possible)?  Would I create a
lifecycle within my mojo that puts the necessary data on the bus and invokes
the release:prepare mojo as part of that lifecycle (thinking in Maven 2.1terms)?

..David..


-Original Message-
From: Kenney Westerhof [mailto:[EMAIL PROTECTED]
Sent: Wednesday, June 06, 2007 5:48 PM
To: Maven Users List
Subject: Re: calling plugin in another plugin?



Nunn, Gerald wrote:
 Jason,

 It's a bad practice, and leads to coupling between plugins which is
 bad. We've seen the aftermath of this happening in Maven 1.x.

 Since I'm doing this already I'm curious how this could be done better
and accomplish my goal, I'm a relative newbie to Mojos so I'm wondering if I
am missing a better approach.

 In my case, I needed a plugin that can handle a WebLogic shared library.
A shared library is a WAR or EAR that contains many different assets
including JARs and in order to be able to use these in Maven I've created a
plugin that temporarily unpacks the shared library and installs each JAR
individually under a library group name. It also creates a parent POM for
the library that can be used to drag in all the dependencies defined by the
library.

 In order to do this, my plugin needs to install each file individually.
Rather then rewrite the install plugin, I simply use my invoker class to
invoke the install plugin for each file I have unpacked passing in the
necessary parameters to make this work.

 How could I accomplish the same goal using the approach you outlined?

This is a one-time setup, and really not part of the build.
You should have had those jars in the ears/wars in a repository already.

Either create a shellscript for it, or a pom, declaring a dependency on
the war/ear (i assume that one _is_
in a repository? if not - it shouldn't be part of the maven build
lifecycle).

You use the maven-dependency-plugin to unpack the war/ear (for instance in
generate-resources), say to
${project.build.directory}/foo/
and specify a series of executions of the install plugin (for instance in
process-resources), each one configured
with the location a jar in ${project.build.directory}/foo/.

Anyway, this is not recommended practice, but I can see why your plugin is
useful.
The eclipse plugin has a similar mojo, that scans an eclipse installation
directory for plugins
and installs each plugin as a maven2 artifact in the local directory. It
doesn't use
the install mojo, afaik, but the maven api's.
I'm assuming your plugin is similar, in that it can unpack/install
wars/ears found in a bea weblogic installation
directory?

-- Kenney


 Thanks,

 Gerald

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




Re: procedure for upgrade to 1.1 ?

2007-06-08 Thread Emmanuel Venisse

I hope we'll can do it but it isn't our priority for now.

Emmanuel

Ionut S a écrit :

Thanks for your response, this is what I wanted to hear.

Should we expect (in the near future) a tool to migrate the data from one 
version to another ?

Emmanuel Venisse [EMAIL PROTECTED] wrote: We don't have a procedure yet 
because the database is different.
The best way for now is to install alpha-2 and add all your project in it.

Emmanuel

Ionut S a écrit :
Nobody upgraded from 1.0.3 to 1.1 alpha2 ? 


Ionut S  wrote: Hi,
I wanted to move today to 1.1 alpha2, but I couldn't find the procedure for 
upgrade.. Will you have an upgrade procedure soon ?

Thank you !

   
-
Get the Yahoo! toolbar and be alerted to new email wherever you're surfing. 

   
-

Looking for a deal? Find great prices on flights and hotels with Yahoo! 
FareChase.




   
-
Ready for the edge of your seat? Check out tonight's top picks on Yahoo! TV. 




Re: Inclusions of test classes not inherited by TestCase

2007-06-08 Thread Martin Monsorno
Hi,

thanks for the answers.  I know that I can controls, which tests are
executed by including or excluding some of them, but that's not the
point.  Any tests, that match the inclusion pattern, should not be
executed, if they are not a Junit TestCase, i.e. extend 
junit.framework.TestCase and is not abstract.  E.g. this class:

code
public class DoesThisExecuteTest {
}
/code

should not be considered as test case and be executed, but it is when
running mvn test:

...
Running de.kvb.apo.corrservice.DoesThisExecuteTest
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0 sec  
FAILURE!
...

with this report:

---
Test set: de.kvb.apo.corrservice.DoesThisExecuteTest
---
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0 sec  
FAILURE!
de.kvb.apo.corrservice.DoesThisExecuteTest  Time elapsed: 0 sec   ERROR!
java.lang.Exception: No runnable methods
at 
org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:34)
at 
org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42)


That's not a real problem, and will not exist any more with Junit 4,
but, well, it's not really clean, is it?

Regards,
Martin.


-- 
Martin Monsorno
mailto:[EMAIL PROTECTED]


Pt! Schon vom neuen GMX MultiMessenger gehört?
Der kanns mit allen: http://www.gmx.net/de/go/multimessenger

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



Re: maven-jar-plugin wraps manifest.mf line at wrong position

2007-06-08 Thread Heinrich Nirschl
On Fri, 2007-06-08 at 16:21 +0800, 張旭 wrote:
 Dear friends,
 I have encountered a strange problem when specify  custom manifest file when
 using the maven-jar-plugin.
 I've a very very long line in the manifest file that maybe have hundreds
 columns.
 It seems that the plug-in will automatically wrap the line every 70 cols.
 Is there a parameter in configuration that can override the default
 behavior?

The plugin does the right thing and you really don't want to override
that. From the Jar specification:

quote
No line may be longer than 72 bytes (not characters), in its
UTF8-encoded form. If a value would make the initial line longer than
this, it should be continued on extra lines (each starting with a single
SPACE).
/quote

- Henry


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



Re: maven-jar-plugin wraps manifest.mf line at wrong position

2007-06-08 Thread Jo Vandermeeren

Hi Zhang,

All MANIFEST.MF files that contain lines longer than 72 bytes are invalid,
according to the Jar Manifest specification.
That's why the plugin splits them, which is the only way to create a valid
manifest.
And no, AFAIK, you can not force the plugin to create invalid manifest
files.

Here is the specification extract:

  - Line length:
  No line may be longer than 72 bytes (not characters), in its
  UTF8-encoded form. If a value would make the initial line longer than this,
  it should be continued on extra lines (each starting with a single SPACE).


You can find the spec here:
http://java.sun.com/j2se/1.5.0/docs/guide/jar/jar.html#Notes on Manifest and
Signature Files

Cheers
Jo


On 6/8/07, 張旭 [EMAIL PROTECTED] wrote:


Dear friends,
I have encountered a strange problem when specify  custom manifest file
when
using the maven-jar-plugin.
I've a very very long line in the manifest file that maybe have hundreds
columns.
It seems that the plug-in will automatically wrap the line every 70 cols.
Is there a parameter in configuration that can override the default
behavior?

Thanks in advance.



Re: Configuration questions

2007-06-08 Thread Jo Vandermeeren

On 6/7/07, Kevin.A.D'[EMAIL PROTECTED] Kevin.A.D'[EMAIL PROTECTED] wrote:


how do I tell it to include one set of config file and ignore the rest?



You can specify separate resource sets for different profiles.

2. When setting up a folder structure of an EAR project containing a WAR,

should the EAR project folder contain the WAR (i.e. as a module) or should
the two projects be at the same folder level?



You can put both modules at the same folder level, add the webapp as a
dependency of the ear module, and configure the maven-ear-plugin
configuration.

e.g.
trunk/parent
 - ear module
 - webapp module

Cheers
Jo


Re: War plugin transitive dependency

2007-06-08 Thread Jo Vandermeeren

On 6/7/07, Váry Péter [EMAIL PROTECTED] wrote:


With using the war plugin, we can declare transitive dependencies, A
depends on B, and B depends on C. With SNAPSHOT versions I would like to see
every changes in C appear immediately in A, without any manual interaction
(or as few as possible).




Hi Peter,

Maven depends on artifacts which installed in your repository.
When depending on SNAPSHOT versions, Maven will use that latest installed
(or deployed, determined by the check interval) version of the dependency.

So, if you have made changes in C, don't expect B and A to see them, unless
module C has been (re)installed in the repository.
When you build from a common parent (which contains A, B and C as modules),
Maven will order the module's build based upon defined dependencies between
them.
This is why builds started from the parent level, can guarantee that B and A
will see the latest changes made in C.

Cheers
Jo


Classpath issues with maven 2.0.6

2007-06-08 Thread Minto.van.der.Sluis


Hi folks

Unfortunately I run into classpath problems when running my unittests
with 'mvn test'.

I have the following situation. To be able to test static blocks in my
classes under various conditions I need to be sure these static block
are executed multiple times. The only thing I know that can achieve this
situation is using a separate classloader for every test. After some
googling I found the ReloadableClassLoader from
http://sourceforge.net/projects/escher .

In eclipse I was able to get this to work and verified that I have a
different classloader for every test. However when running the same
unittest (that worked in eclipse) from 'mvn test'. I run into a
ClassNotFoundException  :-(

Looking a bit deeper I discovered the classpath being used in Eclipse
contains a lot more entries than the one being used by maven. 

Eclipse has:
K:\Sources\Prefs\memoryprefs\target\test-classes
K:\Sources\Prefs\memoryprefs\target\classes

K:\Repositories\maven2\.m2\repository\junit\junit\4.3.1\junit-4.3.1.jar

K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-api\1.4.0\slf4j-ap
i-1.4.0.jar

K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-simple\1.4.0\slf4j
-simple-1.4.0.jar

K:\DevTools\eclipse\3.3M6\eclipse\configuration\org.eclipse.osgi\bundles
\70\1\.cp

K:\DevTools\eclipse\3.3M6\eclipse\configuration\org.eclipse.osgi\bundles
\68\1\.cp

Maven has:
K:\DevTools\maven\maven-2.0.6\boot\classworlds-1.1.jar

Looking even deeper I found out that ReloadableClassLoader uses system
property 'java.class.path' to get the actual classpath. 

My question now is, how can I make sure that my classes under test will
be part of the classpath. In other words how can I get maven to add all
necessary dependencies to the java.class.path system property.
Alternatively, assuming maven uses java -cp, how can I reach the proper
classpath to feed my custom ClassLoader.

Any help is appreciated.

Kind regards,

Minto van der Sluis

--- Today's code is tomorrow's legacy. ---



DISCLAIMER
De informatie in deze e-mail is vertrouwelijk en uitsluitend bestemd voor de 
geadresseerde. Indien u niet de geadresseerde bent, wordt u er hierbij op 
gewezen, dat u geen recht heeft kennis te nemen van de rest van deze e-mail, 
deze te gebruiken, te kopieren of te verstrekken aan andere personen dan de 
geadresseerde. Indien u deze e-mail abusievelijk hebt ontvangen, brengt u dan 
alstublieft de afzender op de hoogte, waarbij u bij deze gevraagd wordt het 
originele bericht te vernietigen. Politie Amsterdam-Amstelland is niet 
verantwoordelijk voor de inhoud van deze e-mail en wijst iedere 
aansprakelijkheid af voor en/of in verband met alle gevolgen en/of schade van 
een onjuiste of onvolledige verzending ervan. Tenzij uitdrukkelijk het 
tegendeel blijkt, kunnen aan dit bericht geen rechten worden ontleend. Het 
gebruik van Internet e-mail brengt zekere risico's met zich. Daarom wordt 
iedere aansprakelijkheid voor het gebruik van dit medium door de Politie 
Amsterdam-Amstelland van de hand gewezen. 


Configuring scp logging

2007-06-08 Thread Taylor, Paul

By default when using scp for deployment it outputs the amount uploaded
in 4k increments.  Is there a way of configuring this to increase the
increments or turn it off completely?  When deploying large files this
creates a lot of output resulting in large log files.

Paul



IONA Technologies PLC (registered in Ireland)
Registered Number: 171387
Registered Address: The IONA Building, Shelbourne Road, Dublin 4, Ireland

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



m2 assembly confusion

2007-06-08 Thread Nigel Magnay

I have a project that is buildig in Hudson, that uses the m2 assembly plugin.

In the project pom, it explicitly sets the version of that plugin to 2.1.

It builds correctly from the commandline, and it mostly builds
correctly in hudson, but occasionally (I suspect it might be an update
issue), it fails - and it seems to be using / including the 2.2-beta-1
plugin AND the 2.1.

I don't know if this is a m2 bug, or a hudson bug, or a combination
(m2 2.0.5, hudson 1.106); attached is the build output:


[INFO] [jar:jar]
[INFO] Building jar:
e:\tomcat-home\.hudson\jobs\KES\workspace\trunk\sample-publication\workflow-guide-package\target\workflow-guide-package-2.0-SNAPSHOT.jar
-
this realm = 
app0.child-container[org.apache.maven.plugins:maven-assembly-plugin]
urls[0] = file:/C:/Documents and
Settings/tomcat/.m2/repository/org/apache/maven/plugins/maven-assembly-plugin/2.2-beta-1/maven-assembly-plugin-2.2-beta-1.jar
urls[1] = file:/C:/Documents and
Settings/tomcat/.m2/repository/org/apache/maven/plugins/maven-assembly-plugin/2.1/maven-assembly-plugin-2.1.jar
urls[2] = file:/C:/Documents and
Settings/tomcat/.m2/repository/org/codehaus/plexus/plexus-archiver/1.0-alpha-6/plexus-archiver-1.0-alpha-6.jar
urls[3] = file:/C:/Documents and
Settings/tomcat/.m2/repository/org/apache/maven/maven-archiver/2.0.4/maven-archiver-2.0.4.jar
urls[4] = file:/C:/Documents and
Settings/tomcat/.m2/repository/org/apache/maven/shared/file-management/1.0/file-management-1.0.jar
Number of imports: 0


this realm = plexus.core.maven
urls[0] = 
file:/E:/XAMPP/xampp/tomcat/webapps/hudson/WEB-INF/lib/maven-interceptor-1.106.jar
urls[1] = file:/c:/maven/lib/commons-cli-1.0.jar
urls[2] = file:/c:/maven/lib/doxia-sink-api-1.0-alpha-7.jar
urls[3] = file:/c:/maven/lib/jsch-0.1.27.jar
urls[4] = file:/c:/maven/lib/jtidy-4aug2000r7-dev.jar
urls[5] = file:/c:/maven/lib/maven-artifact-2.0.5.jar
urls[6] = file:/c:/maven/lib/maven-artifact-manager-2.0.5.jar
urls[7] = file:/c:/maven/lib/maven-core-2.0.5-javadoc.jar
urls[8] = file:/c:/maven/lib/maven-core-2.0.5.jar
urls[9] = file:/c:/maven/lib/maven-error-diagnostics-2.0.5.jar
urls[10] = file:/c:/maven/lib/maven-model-2.0.5.jar
urls[11] = file:/c:/maven/lib/maven-monitor-2.0.5.jar
urls[12] = file:/c:/maven/lib/maven-plugin-api-2.0.5.jar
urls[13] = file:/c:/maven/lib/maven-plugin-descriptor-2.0.5.jar
urls[14] = file:/c:/maven/lib/maven-plugin-parameter-documenter-2.0.5.jar
urls[15] = file:/c:/maven/lib/maven-plugin-registry-2.0.5.jar
urls[16] = file:/c:/maven/lib/maven-profile-2.0.5.jar
urls[17] = file:/c:/maven/lib/maven-project-2.0.5.jar
urls[18] = file:/c:/maven/lib/maven-reporting-api-2.0.5.jar
urls[19] = file:/c:/maven/lib/maven-repository-metadata-2.0.5.jar
urls[20] = file:/c:/maven/lib/maven-settings-2.0.5.jar
urls[21] = file:/c:/maven/lib/plexus-interactivity-api-1.0-alpha-4.jar
urls[22] = file:/c:/maven/lib/wagon-file-1.0-beta-2.jar
urls[23] = file:/c:/maven/lib/wagon-http-lightweight-1.0-beta-2.jar
urls[24] = file:/c:/maven/lib/wagon-http-shared-1.0-beta-2.jar
urls[25] = file:/c:/maven/lib/wagon-provider-api-1.0-beta-2.jar
urls[26] = file:/c:/maven/lib/wagon-ssh-1.0-beta-2.jar
urls[27] = file:/c:/maven/lib/wagon-ssh-common-1.0-beta-2.jar
urls[28] = file:/c:/maven/lib/wagon-ssh-external-1.0-beta-2.jar
urls[29] = file:/c:/maven/lib/xml-apis-1.0.b2.jar
urls[30] = file:/C:/Documents and
Settings/tomcat/.m2/repository/ant/ant/1.5/ant-1.5.jar
Number of imports: 0


this realm = plexus.core
urls[0] = file:/c:/maven/core/plexus-container-default-1.0-alpha-9.jar
urls[1] = file:/c:/maven/core/plexus-utils-1.1.jar
Number of imports: 0
-
[HUDSON] Archiving
e:\tomcat-home\.hudson\jobs\KES\workspace\trunk\sample-publication\workflow-guide-package\pom.xml
[HUDSON] Archiving
e:\tomcat-home\.hudson\jobs\KES\workspace\trunk\sample-publication\workflow-guide-package\target\workflow-guide-package-2.0-SNAPSHOT.jar
[INFO] 
[ERROR] BUILD ERROR
[INFO] 
[INFO] Internal error in the plugin manager executing goal
'org.apache.maven.plugins:maven-assembly-plugin:2.2-beta-1:attached':
Unable to find the mojo
'org.apache.maven.plugins:maven-assembly-plugin:2.2-beta-1:attached'
in the plugin 'org.apache.maven.plugins:maven-assembly-plugin'
org/codehaus/plexus/archiver/ArchiveFileFilter
[INFO] 

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



RE: War plugin transitive dependency

2007-06-08 Thread Váry Péter
Hi Jo,

The main idea is:
- I change C, and install it to the repository
- When working with A, I do not get the changes in C

If I working with jar-s, and A is transitively dependent on C, then if a new C 
is installed into the repository, I will get the new version. But with war - it 
does not count the transitive dependencies, so I does not get the changes.

Regards,
Péter

-Original Message-
From: Jo Vandermeeren [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 08, 2007 11:01 AM
To: Maven Users List
Subject: Re: War plugin transitive dependency

On 6/7/07, Váry Péter [EMAIL PROTECTED] wrote:

 With using the war plugin, we can declare transitive dependencies, A
 depends on B, and B depends on C. With SNAPSHOT versions I would like to see
 every changes in C appear immediately in A, without any manual interaction
 (or as few as possible).



Hi Peter,

Maven depends on artifacts which installed in your repository.
When depending on SNAPSHOT versions, Maven will use that latest installed
(or deployed, determined by the check interval) version of the dependency.

So, if you have made changes in C, don't expect B and A to see them, unless
module C has been (re)installed in the repository.
When you build from a common parent (which contains A, B and C as modules),
Maven will order the module's build based upon defined dependencies between
them.
This is why builds started from the parent level, can guarantee that B and A
will see the latest changes made in C.

Cheers
Jo

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



Re: [M2] Creating internal remote repsistory for Oracle ADF project

2007-06-08 Thread Andrew Birchall

Thanks a lot Wayne, that's great help.

It does seem a lot of work to do this for every jar file the project
depends on but I guess I can write a script to do it.

I feel that the documentation for Maven is not that good. Its not very
clear or well structured, making it hard to find what you need,
especially for people who are new to it.

For example, the Introduction to Repositories page
(http://maven.apache.org/guides/introduction/introduction-to-repositories.html),
which talks about Internal Repositories, contains no information about
using mvn deploy:deploy-file.

There's also hardly anything on this in the Better Build with Maven
book from Mergere.

I think this is a gap in the Maven documentation. But I also feel that
the Maven documentation is weakness in the Maven project generally and
probably hinders it's adoption.

Thanks very much
Andy Birchall

On 07/06/07, Wayne Fay [EMAIL PROTECTED] wrote:

mvn install:install-file and mvn deploy:deploy-file are your friends
-- and they are very well-documented [1] [2] including a FAQ [3].
Assuming you have oc4j.jar and want to push it into the shared
corporate repo:

mvn deploy:deploy-file -DgroupId=com.oracle.jdevelope​r
-DartifactId=oc4j -Dversion=10.1.3.2 -Dpackaging=jar -Dfile=oc4j.jar
-DgeneratePom=true -DrepositoryId=your_id
-Durl=file://somewhere/m2/repo

You will have to pick the groupId, artifactId, version for all your
jars. Also, you will need to follow the directions regarding setting
up the repositoryId in your settings.xml and of course get the right
file:// path. But that's it.

Wayne

[1] http://maven.apache.org/plugin​s/maven-install-plugin/usage.ht​ml
[2] http://maven.apache.org/plugin​s/maven-deploy-plugin/usage.htm​l
[3] http://maven.apache.org/guides​/mini/guide-deploying-3rd-party​-jars.html

On 6/7/07, Andrew Birchall [EMAIL PROTECTED] wrote:
 Hello,
 I am trying to Mavenize a multi-module J2EE Oracle ADF project that is
 currently built with several Ant scripts and developed in JDeveloper
 10.1.3.2

 One of the main problems I have is that the project depends on many
 Artifacts (jar files) distributed with JDeveloper.

 Thus, In order to build this project with Maven I have to set up an
 internal repository in our company with all the JDeveloper jar files.
 At the moment I am trying to do this with the file:// protocol on a
 network share.

 However I'm not really sure the way to go about this and I can't seem
 to find any good documentation on it. Non of the jars distributed with
 JDeveloper are versioned. Do I have to version all the jar files
 myself and put them in the correct package directories, in order to
 conform to the Maven repository layout convention? How do I know what
 version to re-name the jar files to?

 If I do have to do this its a BIG and tedious job because there's so
 many dependencies. And what about the pom files for each jar, how do
 these get created?

 I'd be very grateful to hear from anyone who can help
 Kind regards
 Andy Birchall

 --​---​
 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 disable dowloading beta versions of plugins

2007-06-08 Thread Minto.van.der.Sluis


HI,

Does maven also have somekind of a switch that forces the use of
specified versions?

I ask this because it is too easy to forget version number for some
plugins. For instance I can use 'mvn test' without specifying
maven-surefire-plugin. With the kind of switch I am looking for this
would result in a warning saying something like 'No version specified
for plugin XXX using version YYY'.

Hmm, looking at it again. This might even be default behavior. An extra
options in the pom to enforce version numbers, could be used to stop
processing when a plugin lacks a version number.

Regards,

Minto
 
--- Today's code is tomorrow's legacy. --- 



-Oorspronkelijk bericht-
Van: Jason van Zyl [mailto:[EMAIL PROTECTED] 
Verzonden: donderdag 7 juni 2007 16:19
Aan: Maven Users List
Onderwerp: Re: how to disable dowloading beta versions of plugins


On 7 Jun 07, at 10:10 AM 7 Jun 07, Karan Malhi wrote:

 - How do I tell maven to stop downloading the beta versions of plugins

 and just download the latest stable releases of plugins?

Specify versions of the plugins you want to use in your projects. Do not
leave it to chance. Not specify versions of all things is bad practice.

 - Can I ask maven to clean the repo of all beta versions of plugins or

 do i have to manually remove them?

 --
 Karan Malhi

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



Thanks,

Jason

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




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


DISCLAIMER
De informatie in deze e-mail is vertrouwelijk en uitsluitend bestemd voor de 
geadresseerde. Indien u niet de geadresseerde bent, wordt u er hierbij op 
gewezen, dat u geen recht heeft kennis te nemen van de rest van deze e-mail, 
deze te gebruiken, te kopieren of te verstrekken aan andere personen dan de 
geadresseerde. Indien u deze e-mail abusievelijk hebt ontvangen, brengt u dan 
alstublieft de afzender op de hoogte, waarbij u bij deze gevraagd wordt het 
originele bericht te vernietigen. Politie Amsterdam-Amstelland is niet 
verantwoordelijk voor de inhoud van deze e-mail en wijst iedere 
aansprakelijkheid af voor en/of in verband met alle gevolgen en/of schade van 
een onjuiste of onvolledige verzending ervan. Tenzij uitdrukkelijk het 
tegendeel blijkt, kunnen aan dit bericht geen rechten worden ontleend. Het 
gebruik van Internet e-mail brengt zekere risico's met zich. Daarom wordt 
iedere aansprakelijkheid voor het gebruik van dit medium door de Politie 
Amsterdam-Amstelland van de hand gewezen. 

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



RE: Settings.xml under source control?

2007-06-08 Thread Minto.van.der.Sluis


Hi Moe,

Are you sure you want settings.xml under source control? Lots of times
the settings.xml contains user specific settings like usernames and
passwords.

Regards,

Minto


-Oorspronkelijk bericht-
Van: Moe, Vidar [mailto:[EMAIL PROTECTED] 
Verzonden: vrijdag 8 juni 2007 11:28
Aan: users@maven.apache.org
Onderwerp: Settings.xml under source control?


Hi!
 
We would like to have the settings.xml file in a custom location to
easily being able to have it under source control. We can control the
placement of the settings.xml file by the 
 
-Dorg.apache.maven.user-settings
 
but it is cumersome for developers to add this param for every mvn
command they are going to run. - Can this parameter be applied globally
somehow, so that the developers do not have to add it everytime?
 
Thanks in advance,
 
Regards,
Vidar Moe


This message contains information that may be privileged or confidential
and is the property of the Capgemini Group. It is intended only for the
person to whom it is addressed. If you are not the intended recipient,
you are not authorized to read, print, retain, copy, disseminate,
distribute, or use this message or any part thereof. If you receive this
message in error, please notify the sender immediately and delete all
copies of this message.


DISCLAIMER
De informatie in deze e-mail is vertrouwelijk en uitsluitend bestemd voor de 
geadresseerde. Indien u niet de geadresseerde bent, wordt u er hierbij op 
gewezen, dat u geen recht heeft kennis te nemen van de rest van deze e-mail, 
deze te gebruiken, te kopieren of te verstrekken aan andere personen dan de 
geadresseerde. Indien u deze e-mail abusievelijk hebt ontvangen, brengt u dan 
alstublieft de afzender op de hoogte, waarbij u bij deze gevraagd wordt het 
originele bericht te vernietigen. Politie Amsterdam-Amstelland is niet 
verantwoordelijk voor de inhoud van deze e-mail en wijst iedere 
aansprakelijkheid af voor en/of in verband met alle gevolgen en/of schade van 
een onjuiste of onvolledige verzending ervan. Tenzij uitdrukkelijk het 
tegendeel blijkt, kunnen aan dit bericht geen rechten worden ontleend. Het 
gebruik van Internet e-mail brengt zekere risicos met zich. Daarom wordt iedere 
aansprakelijkheid voor het gebruik van dit medium door de Politie 
Amsterdam-Amstelland van de hand gewezen. 

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



Re: Settings.xml under source control?

2007-06-08 Thread Emmanuel Venisse

We don't have something to set it globally but you can add it in your mvn 
script.

Emmanuel

Moe, Vidar a écrit :

Hi!
 
We would like to have the settings.xml file in a custom location to

easily being able to have it under source control. We can control the
placement of the settings.xml file by the 
 
-Dorg.apache.maven.user-settings
 
but it is cumersome for developers to add this param for every mvn

command they are going to run. - Can this parameter be applied globally
somehow, so that the developers do not have to add it everytime?
 
Thanks in advance,
 
Regards,

Vidar Moe


This message contains information that may be privileged or confidential and is 
the property of the Capgemini Group. It is intended only for the person to whom 
it is addressed. If you are not the intended recipient,  you are not authorized 
to read, print, retain, copy, disseminate,  distribute, or use this message or 
any part thereof. If you receive this  message in error, please notify the 
sender immediately and delete all  copies of this message.




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



Re: Classpath issues with maven 2.0.6

2007-06-08 Thread Jo Vandermeeren

On 6/8/07, [EMAIL PROTECTED]
[EMAIL PROTECTED]
wrote:


Looking a bit deeper I discovered the classpath being used in Eclipse
contains a lot more entries than the one being used by maven.



Hi Minto

The classpath used to startup maven is different from the one that is used
to build and test your modules.
Hence the dependencies section in your pom.xml file.

Have you included the libraries needed for testing as test-scoped
dependencies in the pom.xml file of the resp. module?

Cheers
Jo


Settings.xml under source control?

2007-06-08 Thread Moe, Vidar

Hi!
 
We would like to have the settings.xml file in a custom location to
easily being able to have it under source control. We can control the
placement of the settings.xml file by the 
 
-Dorg.apache.maven.user-settings
 
but it is cumersome for developers to add this param for every mvn
command they are going to run. - Can this parameter be applied globally
somehow, so that the developers do not have to add it everytime?
 
Thanks in advance,
 
Regards,
Vidar Moe


This message contains information that may be privileged or confidential and is 
the property of the Capgemini Group. It is intended only for the person to whom 
it is addressed. If you are not the intended recipient,  you are not authorized 
to read, print, retain, copy, disseminate,  distribute, or use this message or 
any part thereof. If you receive this  message in error, please notify the 
sender immediately and delete all  copies of this message.


Problem with creating deployment code RMIC code during ejb build

2007-06-08 Thread Kiran Kodlady

Hell all,


Got struck with one  problem with ejb project  :

In my current ejb project i am doing migration of ant scripts to maven
2.0.6.
Project structure is like below :

XYZProject--ejbmodule---java
   META-INF-ejb-jar.xml
  

explanation : XYZProject module consists Home interface, Remote interface 
Service Bean class. Though I am able to bundle the jar file along with
client jar, But i am unable to generate the Deployment code and RMIC code..

one more question  - is there  any tag to provide custom path for 
ejb-jar.xml  in pom.xml ?

Could u plz help in solving this problem ??

Thanks  alot in advance

Kiran Kodlady
-- 
View this message in context: 
http://www.nabble.com/Problem-with-creating-deployment-code---RMIC-code-during-ejb-build-tf3889218s177.html#a11024762
Sent from the Maven - Users mailing list archive at Nabble.com.


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



Re: War plugin transitive dependency

2007-06-08 Thread Jo Vandermeeren

On 6/8/07, Váry Péter [EMAIL PROTECTED] wrote:


If I working with jar-s, and A is transitively dependent on C, then if a
new C is installed into the repository, I will get the new version. But with
war - it does not count the transitive dependencies, so I does not get the
changes.




Hi Peter,

Aha, war dependencies are something completely different.
So, as you experienced, it is always good to be as specific as possible
about your problem.

I assume that your module A is an ear, module B is a war, and module C is a
jar?

By default, the dependencies of a webapp (module B) are packaged within the
war artifact itself.
If you depend on that module in an ear module (A), the war artifact will
simply be included, and its dependencies will not be checked.
This is valid because changes in module B's dependencies would require a
rebuild of the webapp in this setup.

You can however make this work in the same way as you apparently expect it
to do.
You achieve this by depending on C in your ear and package the dependencies
of module B in the ear instead.
Some configuration has to be made to modify the manifest classpath of the
webapp et cetera.

If you have multiple modules in the ear which depend on the same
dependencies (or some of them), this is the preferred configuration.
Otherwise you end up with a bloated ear full of duplicate libraries.

Jeroen Leenarts has written an enlightening article about this some time
ago:
http://blog.leenarts.net/2007/02/11/maven-2s-ear-plugin-gives-me-a-headache/

Cheers
Jo


RE: Classpath issues with maven 2.0.6

2007-06-08 Thread Minto.van.der.Sluis


Hi Jo,

Yes I have, look at the pom files below. 

Also not that in the maven case the test and project classes are not
part of the classpath being used by the tests.

Regards,

Minto


My project pom file:
===
project
  modelVersion4.0.0/modelVersion

  parent
groupIdnl.xup.prefs/groupId
artifactIdroot/artifactId
version0.1-SNAPSHOT/version
relativePath../relativePath
  /parent

  groupIdnl.xup.prefs/groupId
  artifactIdmemoryprefs/artifactId
  packagingjar/packaging
  version1.0-SNAPSHOT/version
  nameMemoryPrefs/name

  dependencies
dependency
  groupIdorg.slf4j/groupId
  artifactIdslf4j-api/artifactId
  scopecompile/scope
/dependency

dependency
  groupIdjunit/groupId
  artifactIdjunit/artifactId
  scopetest/scope
/dependency
dependency
  groupIdorg.slf4j/groupId
  artifactIdslf4j-simple/artifactId
  scopetest/scope
/dependency
  /dependencies
/project 

The parent pom:
==
project
  modelVersion4.0.0/modelVersion

  groupIdnl.xup.prefs/groupId
  artifactIdroot/artifactId
  packagingpom/packaging
  version0.1-SNAPSHOT/version
  nameXup Prefs/name

  dependencyManagement
dependencies
  dependency
groupIdjunit/groupId
artifactIdjunit/artifactId
version4.3.1/version
  /dependency
  dependency
groupIdorg.slf4j/groupId
artifactIdslf4j-api/artifactId
version1.4.0/version
  /dependency
  dependency
groupIdorg.slf4j/groupId
artifactIdslf4j-simple/artifactId
version1.4.0/version
  /dependency
/dependencies
  /dependencyManagement

  modules
...
modulememoryprefs/module
...
  /modules

  build
plugins
  plugin
groupIdorg.apache.maven.plugins/groupId
artifactIdmaven-compiler-plugin/artifactId
configuration
  !-- 
  Since the preference API was introcuded in java 1.4 we want
  the various implementations to work on that version as well.
  --
  source1.4/source
  target1.4/target
/configuration
  /plugin
/plugins
  /build
  
/project
-Oorspronkelijk bericht-
Van: Jo Vandermeeren [mailto:[EMAIL PROTECTED] 
Verzonden: vrijdag 8 juni 2007 12:38
Aan: Maven Users List
Onderwerp: Re: Classpath issues with maven 2.0.6

On 6/8/07, [EMAIL PROTECTED]
[EMAIL PROTECTED]
wrote:

 Looking a bit deeper I discovered the classpath being used in Eclipse 
 contains a lot more entries than the one being used by maven.


Hi Minto

The classpath used to startup maven is different from the one that is
used to build and test your modules.
Hence the dependencies section in your pom.xml file.

Have you included the libraries needed for testing as test-scoped
dependencies in the pom.xml file of the resp. module?

Cheers
Jo


DISCLAIMER
De informatie in deze e-mail is vertrouwelijk en uitsluitend bestemd voor de 
geadresseerde. Indien u niet de geadresseerde bent, wordt u er hierbij op 
gewezen, dat u geen recht heeft kennis te nemen van de rest van deze e-mail, 
deze te gebruiken, te kopieren of te verstrekken aan andere personen dan de 
geadresseerde. Indien u deze e-mail abusievelijk hebt ontvangen, brengt u dan 
alstublieft de afzender op de hoogte, waarbij u bij deze gevraagd wordt het 
originele bericht te vernietigen. Politie Amsterdam-Amstelland is niet 
verantwoordelijk voor de inhoud van deze e-mail en wijst iedere 
aansprakelijkheid af voor en/of in verband met alle gevolgen en/of schade van 
een onjuiste of onvolledige verzending ervan. Tenzij uitdrukkelijk het 
tegendeel blijkt, kunnen aan dit bericht geen rechten worden ontleend. Het 
gebruik van Internet e-mail brengt zekere risico's met zich. Daarom wordt 
iedere aansprakelijkheid voor het gebruik van dit medium door de Politie 
Amsterdam-Amstelland van de hand gewezen. 

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



RE: Classpath issues with maven 2.0.6

2007-06-08 Thread Minto.van.der.Sluis


Hi Jo,

The ReloadableClassLoader was copied into the test sources. That's why
there is no dependency for that one.

The class it could not find was not ReloadableClassLoader, but the class
I want to load. This is actually the class under test. 

313 [main] ERROR nl.xup.prefs.memoryprefs.PreferencesTestBase -
Faild reloading nl.xup.prefs.memoryprefs.MemoryPreferencesFactory
java.lang.ClassNotFoundException:
nl.xup.prefs.memoryprefs.MemoryPreferencesFactory 
...

Some more detailed output can be found below.

BTW, thanks for the quick responses :-)

Regards,

Minto


Snippet of the mvn test -X ouput:
==
snip
[INFO] [resources:testResources]
[INFO] Using default encoding to copy filtered resources.
[DEBUG] nl.xup.prefs:memoryprefs:jar:1.0-SNAPSHOT (selected for null)
[DEBUG]   org.slf4j:slf4j-api:jar:1.4.0:compile (selected for compile)
[DEBUG]   junit:junit:jar:4.3.1:test (selected for test)
[DEBUG]   org.slf4j:slf4j-simple:jar:1.4.0:test (selected for test)
[DEBUG] Configuring mojo
'org.apache.maven.plugins:maven-compiler-plugin:2.0:testCompile' --
[DEBUG]   (f) basedir = K:\Sources\Prefs\memoryprefs
[DEBUG]   (f) buildDirectory = K:\Sources\Prefs\memoryprefs\target
[DEBUG]   (f) classpathElements =
[K:\Sources\Prefs\memoryprefs\target\classes,
K:\Sources\Prefs\memoryprefs\target\test-classes,
K:\Repositories\maven2\.m2\repository\junit\junit\4.3.1\junit-4.3.1.jar,
K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-simple\1.4.0\slf4j
-simple-1.4.0.jar,
K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-api\1.4.0\slf4j-ap
i-1.4.0.jar]
[DEBUG]   (f) compileSourceRoots =
[K:\Sources\Prefs\memoryprefs\src\test\java]
[DEBUG]   (f) compilerId = javac
[DEBUG]   (f) debug = true
[DEBUG]   (f) fork = false
[DEBUG]   (f) optimize = false
[DEBUG]   (f) outputDirectory =
K:\Sources\Prefs\memoryprefs\target\test-classes
[DEBUG]   (f) outputFileName = memoryprefs-1.0-SNAPSHOT
[DEBUG]   (f) source = 1.4
[DEBUG]   (f) staleMillis = 0
[DEBUG]   (f) target = 1.4
[DEBUG]   (f) verbose = false
[DEBUG] -- end configuration --
[INFO] [compiler:testCompile]
[DEBUG] Using compiler 'javac'.
[DEBUG] Source directories: [K:\Sources\Prefs\memoryprefs\src\test\java]
[DEBUG] Classpath: [K:\Sources\Prefs\memoryprefs\target\classes
 K:\Sources\Prefs\memoryprefs\target\test-classes
 K:\Repositories\maven2\.m2\repository\junit\junit\4.3.1\junit-4.3.1.jar
 
K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-simple\1.4.0\slf4j
-simple-1.4.0.jar
 
K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-api\1.4.0\slf4j-ap
i-1.4.0.jar]
[DEBUG] Output directory:
K:\Sources\Prefs\memoryprefs\target\test-classes
[INFO] Nothing to compile - all classes are up to date
[DEBUG] nl.xup.prefs:memoryprefs:jar:1.0-SNAPSHOT (selected for null)
[DEBUG]   org.slf4j:slf4j-api:jar:1.4.0:compile (selected for compile)
[DEBUG]   junit:junit:jar:4.3.1:test (selected for test)
[DEBUG]   org.slf4j:slf4j-simple:jar:1.4.0:test (selected for test)
[DEBUG]
org.apache.maven.plugins:maven-surefire-plugin:maven-plugin:2.1.2:runtim
e (selected for runtime)
[DEBUG] Retrieving parent-POM:
org.apache.maven.surefire:surefire-root::1.1 for project:
null:surefire-booter:jar:1.5.2 from the repository.
[DEBUG]   org.apache.maven.surefire:surefire-booter:jar:1.5.2:runtime
(selected for runtime)
[DEBUG] junit:junit:jar:3.8.1:runtime (selected for runtime)
[DEBUG] Retrieving parent-POM:
org.apache.maven.surefire:surefire-root::1.1 for project:
null:surefire:jar:1.5.2 from the repository.
[DEBUG] org.apache.maven.surefire:surefire:jar:1.5.2:runtime
(selected for runtime)
[DEBUG] Retrieving parent-POM: org.codehaus.plexus:plexus::1.0.4 for
project: null:plexus-utils:jar:1.0.5 from the repository.
[DEBUG]   org.codehaus.plexus:plexus-utils:jar:1.0.5:runtime
(selected for runtime)
[DEBUG] classworlds:classworlds:jar:1.1-alpha-2:runtime
(selected for runtime)
[DEBUG]   org.apache.maven:maven-plugin-api:jar:2.0:runtime (selected
for runtime)
[DEBUG]   org.codehaus.plexus:plexus-utils:jar:1.0.5:runtime (removed -
nearer found: 1.0.4)
[DEBUG]   org.codehaus.plexus:plexus-utils:jar:1.0.4:runtime (selected
for runtime)
[DEBUG]   org.apache.maven.surefire:surefire:jar:1.5.2:runtime (selected
for runtime)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.5:runtime (removed
- nearer found: 1.0.4)
[DEBUG]   org.codehaus.plexus:plexus-utils:jar:1.1:runtime (removed -
nearer found: 1.0.4)
[DEBUG]   org.apache.maven:maven-artifact:jar:2.0:runtime (selected for
runtime)
[DEBUG]   junit:junit:jar:3.8.1:runtime (selected for runtime)
[DEBUG] Configuring mojo
'org.apache.maven.plugins:maven-surefire-plugin:2.1.2:test' --
[DEBUG]   (f) basedir = K:\Sources\Prefs\memoryprefs
[DEBUG]   (f) childDelegation = true
[DEBUG]   (f) classesDirectory =
K:\Sources\Prefs\memoryprefs\target\classes
[DEBUG]   (f) classpathElements =
[K:\Sources\Prefs\memoryprefs\target\classes,
K:\Sources\Prefs\memoryprefs\target\test-classes,

Re: Classpath issues with maven 2.0.6

2007-06-08 Thread Vandermeeren, Jo

On 6/8/07, [EMAIL PROTECTED] 
[EMAIL PROTECTED] wrote:




Hi Jo,

Yes I have, look at the pom files below.




Hi Minto

I only see junit and 2 slf4j dependencies.
The ReloadableClassLoader class you mentioned earlier.. Did you include it
as source?
I would expect a dependency to the library that contains it.

Which class is causing the ClassNotFoundException?


Also not that in the maven case the test and project classes are not

part of the classpath being used by the tests.




Could you paste some information about the build output when you run mvn
test -X?
Search for classpathElements and paste it back here.
As I said earlier, you can't predict the classpath that is used to run your
tests by looking at the classpath that is used to start Maven.

PS. Groeten aan de flikken! ;)
(Transl: Say hello to the cops)

Cheers
Jo


Re: password argument is null. scm ext connection

2007-06-08 Thread Emmanuel Venisse

What do you use foe ext connection? ssh?

You can set CVS_RSH on your OS to ssh or what you use.

Emmanuel

Arun P Johny a écrit :

Hi all,

I'm getting the following error when I try to execute the command 'mvn 
release:prepare'


-Error
--other downloads
Downloading: 
http://mirrors.ibiblio.org/pub/mirrors/maven2/org/apache/maven/scm/maven-scm-provider-perforce/1.0/maven-scm-provider-perforce-1.0.jar 


61K downloaded
[INFO] [release:prepare]
[INFO] Verifying that there are no local modifications...
[INFO] Executing: cvs -z3 -f -d 
:ext:[EMAIL PROTECTED]:/var/lib/cvs/root -n

-q update -d
[INFO] Working directory: F:\build_7_5\Folklore
java.lang.IllegalArgumentException: password argument is null
  at 
ch.ethz.ssh2.Connection.authenticateWithPassword(Connection.java:307)


  at 
org.apache.maven.scm.provider.cvslib.cvsjava.util.ExtConnection.open(ExtConnection.java:122) 

  at 
org.apache.maven.scm.provider.cvslib.cvsjava.util.CvsConnection.connect(CvsConnection.java:164) 

  at 
org.apache.maven.scm.provider.cvslib.cvsjava.util.CvsConnection.processCommand(CvsConnection.java:475) 

  at 
org.apache.maven.scm.provider.cvslib.cvsjava.command.status.CvsJavaStatusCommand.executeCvsCommand(CvsJavaStatusCommand.java:50) 

  at 
org.apache.maven.scm.provider.cvslib.command.status.AbstractCvsStatusCommand.executeStatusCommand(AbstractCvsStatusCommand.java:52) 

  at 
org.apache.maven.scm.command.status.AbstractStatusCommand.executeCommand(AbstractStatusCommand.java:43) 

  at 
org.apache.maven.scm.command.AbstractCommand.execute(AbstractCommand.java:58) 

  at 
org.apache.maven.scm.provider.cvslib.AbstractCvsScmProvider.executeCommand(AbstractCvsScmProvider.java:521) 

  at 
org.apache.maven.scm.provider.cvslib.AbstractCvsScmProvider.status(AbstractCvsScmProvider.java:641) 

  at 
org.apache.maven.scm.provider.AbstractScmProvider.status(AbstractScmProvider.java:693) 

  at 
org.apache.maven.shared.release.phase.ScmCheckModificationsPhase.execute(ScmCheckModificationsPhase.java:98) 

  at 
org.apache.maven.shared.release.DefaultReleaseManager.prepare(DefaultReleaseManager.java:194) 

  at 
org.apache.maven.shared.release.DefaultReleaseManager.prepare(DefaultReleaseManager.java:131) 

  at 
org.apache.maven.shared.release.DefaultReleaseManager.prepare(DefaultReleaseManager.java:94) 

  at 
org.apache.maven.plugins.release.PrepareReleaseMojo.execute(PrepareReleaseMojo.java:127) 

  at 
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412) 

  at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:534) 

  at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:488) 

  at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:458) 

  at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:306) 

  at 
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:219) 

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


  at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
  at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
  at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
  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] 


[ERROR] BUILD FAILURE
[INFO] 


[INFO] Unable to check for local modifications
Provider message:
The cvs command failed.
Command output:

[INFO] 


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


[INFO] Total time: 2 minutes 18 seconds
[INFO] Finished at: Tue Jun 05 18:40:22 GMT+05:30 2007
[INFO] Final Memory: 5M/10M
[INFO] 



I'm using 'ext' to connect to my cvs
when I tried to debug the problem i found that in
   org.apache.maven.scm.provider.cvslib.cvsjava.util.CvsConnection.connect
   value of 

Re: Settings.xml under source control?

2007-06-08 Thread Max Bowsher
Moe, Vidar wrote:
 Hi!
  
 We would like to have the settings.xml file in a custom location to
 easily being able to have it under source control. We can control the
 placement of the settings.xml file by the 
  
 -Dorg.apache.maven.user-settings
  
 but it is cumersome for developers to add this param for every mvn
 command they are going to run. - Can this parameter be applied globally
 somehow, so that the developers do not have to add it everytime?

Look at the source of the 'mvn' script and see that it sources
/etc/mavenrc and ~/.mavenrc. Use one of these to adjust MAVEN_OPTS.

Max.



signature.asc
Description: OpenPGP digital signature


Re: Cascading package dependencies

2007-06-08 Thread André Salvati

Hi Wayne,

Thanks for your answer.

I've been working just with modules (children) on my workspace. Is there 
any workaround on Eclipse? I didn't want to remenber all modules 
dependencies.


How do you do it?




Wayne Fay escreveu:

No, this is not possible. However, if you run mvn install from the
top-level (father) project, it will run mvn install on all the
modules (children) you've defined, which achieves the same results
you're looking for.

Wayne

On 6/6/07, André Salvati [EMAIL PROTECTED] wrote:

Hi,

I'm a newbie with Maven 2 (2.0.6). Just wondering the following 
situation:


I'm working with 3 modules: 1 father (Project1) and 2 children (Project2
and Project3). Project2 depends on Project3.

Firstly, I'd like Maven was able to detect updates, compile, build and
package Project3 in case of issuing mvn install on Project2. Is it
possible?

These are excerpts from my .pom files:

Projetc1 (father):

modules
moduleProject2/module
moduleProject3/module
/modules


Projetc2

dependencies
dependency
groupIdxpto/groupId
artifactIdProject3/artifactId
version1.0-SNAPSHOT/version
scopeprovided/scope
/dependency
/dependencies







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




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






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



Re: [M2] Creating internal remote repsistory for Oracle ADF project

2007-06-08 Thread Vanja Petreski

Hi,

try with this one: http://www.sonatype.com/book/index.html ;)

Vanja

On 6/8/07, Andrew Birchall [EMAIL PROTECTED] wrote:


Thanks a lot Wayne, that's great help.

It does seem a lot of work to do this for every jar file the project
depends on but I guess I can write a script to do it.

I feel that the documentation for Maven is not that good. Its not very
clear or well structured, making it hard to find what you need,
especially for people who are new to it.

For example, the Introduction to Repositories page
(
http://maven.apache.org/guides/introduction/introduction-to-repositories.html
),
which talks about Internal Repositories, contains no information about
using mvn deploy:deploy-file.

There's also hardly anything on this in the Better Build with Maven
book from Mergere.

I think this is a gap in the Maven documentation. But I also feel that
the Maven documentation is weakness in the Maven project generally and
probably hinders it's adoption.

Thanks very much
Andy Birchall

On 07/06/07, Wayne Fay [EMAIL PROTECTED] wrote:
 mvn install:install-file and mvn deploy:deploy-file are your friends
 -- and they are very well-documented [1] [2] including a FAQ [3].
 Assuming you have oc4j.jar and want to push it into the shared
 corporate repo:

 mvn deploy:deploy-file -DgroupId=com.oracle.jdevelope​r
 -DartifactId=oc4j -Dversion=10.1.3.2 -Dpackaging=jar -Dfile=oc4j.jar
 -DgeneratePom=true -DrepositoryId=your_id
 -Durl=file://somewhere/m2/repo

 You will have to pick the groupId, artifactId, version for all your
 jars. Also, you will need to follow the directions regarding setting
 up the repositoryId in your settings.xml and of course get the right
 file:// path. But that's it.

 Wayne

 [1] http://maven.apache.org/plugin​s/maven-install-plugin/usage.ht​ml
 [2] http://maven.apache.org/plugin​s/maven-deploy-plugin/usage.htm​l
 [3] http://maven.apache.org/guides​/mini/guide-deploying-3rd-party​-
jars.html

 On 6/7/07, Andrew Birchall [EMAIL PROTECTED] wrote:
  Hello,
  I am trying to Mavenize a multi-module J2EE Oracle ADF project that is
  currently built with several Ant scripts and developed in JDeveloper
  10.1.3.2
 
  One of the main problems I have is that the project depends on many
  Artifacts (jar files) distributed with JDeveloper.
 
  Thus, In order to build this project with Maven I have to set up an
  internal repository in our company with all the JDeveloper jar files.
  At the moment I am trying to do this with the file:// protocol on a
  network share.
 
  However I'm not really sure the way to go about this and I can't seem
  to find any good documentation on it. Non of the jars distributed with
  JDeveloper are versioned. Do I have to version all the jar files
  myself and put them in the correct package directories, in order to
  conform to the Maven repository layout convention? How do I know what
  version to re-name the jar files to?
 
  If I do have to do this its a BIG and tedious job because there's so
  many dependencies. And what about the pom files for each jar, how do
  these get created?
 
  I'd be very grateful to hear from anyone who can help
  Kind regards
  Andy Birchall
 
 
--​---​
  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 plugin in another plugin?

2007-06-08 Thread Kenney Westerhof



張旭 wrote:

Thanks to everyone.

Now I know there is no way through maven2 api to call another plugin. Am I
right?


No, but for your sake, let's say yes. ;)


According to Jason, it's a bad idea to call one plugin directly in another.


Also according to any other maven developer. It's totally against the 
principals of maven.


But I still think it's maybe very convenience to do things like that so I
can use functions of other plugin directly and have parameters passed to
other plugin totally under my control.


If you do this kind of things in a plugin, the POM is no longer descriptive of 
the process.
Your plugin would have an influence on the build, which could change the build. 
For instance,
your plugin could add a dependency depending on the current time (bad example 
but it illustrates the problem).
In this case, the build is no longer repeatable, which is bad.

As to using functions of plugins directly: that's not recommended.
Plugins/Mojos should be thin wrappers around a library. You'd want to use the 
library directly.
The mojo's not only make those libraries available to your build, but also hook 
them in in a precise way.

And you don't want to control parameters of other plugins - the POM author 
should control those.

In maven 2.1 there is a shared-context component that can be used by plugins to 
communicate data
to eachother, but it will not allow you to call plugins.

The only API you are allowed to use if you should depend on another plugin 
would be the Mojo api: execute().
You can never count on any 3rd party library (the plugin's dependency) being 
there, as the Mojo is
a facade or front-end for those libraries. And you should not depend on another 
plugin and call it,
because you cannot configure it properly - this is dealt with in maven core.

Consider this the same limitation as Ant poses. You don't want the 'mkdir' task to have any 
influence on the 'javac' task. The only communication between these two is through the configuration

of those tasks. In ant, there are no 2 tasks that call eachother. Maven mojo's 
are comparable with ant tasks,
though more goal oriented, and no maven mojo will call another mojo directly.

Whatever you're trying to accomplish, there's a better, Maven-way, to do it.

-- Kenney




On 6/7/07, David Jackman [EMAIL PROTECTED] wrote:


Here's another situation where I want to have a plugin call another
plugin.  Can you tell me the right way to accomplish this?

In our group we have a release procedure that involves a few more steps
beyond running the release:prepare mojo.  In fact, some of the parameters
into the release:prepare mojo are based on internal standards, so they 
could
be computed automatically.  I want to create a single plugin that 
embodies

this entire release process that also calls the release:prepare mojo with
the correct parameters as part of that process.

This would be another situation where one plugin invokes another
plugin.  Obviously there is coupling there.  What is a better way to 
achieve

this without that coupling (is it even possible)?  Would I create a
lifecycle within my mojo that puts the necessary data on the bus and 
invokes
the release:prepare mojo as part of that lifecycle (thinking in Maven 
2.1terms)?


..David..


-Original Message-
From: Kenney Westerhof [mailto:[EMAIL PROTECTED]
Sent: Wednesday, June 06, 2007 5:48 PM
To: Maven Users List
Subject: Re: calling plugin in another plugin?



Nunn, Gerald wrote:
 Jason,

 It's a bad practice, and leads to coupling between plugins which is
 bad. We've seen the aftermath of this happening in Maven 1.x.

 Since I'm doing this already I'm curious how this could be done better
and accomplish my goal, I'm a relative newbie to Mojos so I'm 
wondering if I

am missing a better approach.

 In my case, I needed a plugin that can handle a WebLogic shared 
library.

A shared library is a WAR or EAR that contains many different assets
including JARs and in order to be able to use these in Maven I've 
created a

plugin that temporarily unpacks the shared library and installs each JAR
individually under a library group name. It also creates a parent POM for
the library that can be used to drag in all the dependencies defined 
by the

library.

 In order to do this, my plugin needs to install each file individually.
Rather then rewrite the install plugin, I simply use my invoker class to
invoke the install plugin for each file I have unpacked passing in the
necessary parameters to make this work.

 How could I accomplish the same goal using the approach you outlined?

This is a one-time setup, and really not part of the build.
You should have had those jars in the ears/wars in a repository already.

Either create a shellscript for it, or a pom, declaring a dependency on
the war/ear (i assume that one _is_
in a repository? if not - it shouldn't be part of the maven build
lifecycle).

You use the maven-dependency-plugin to unpack the war/ear (for 
instance in


Re: Classpath issues with maven 2.0.6

2007-06-08 Thread Vandermeeren, Jo

On 6/8/07, [EMAIL PROTECTED] 
[EMAIL PROTECTED] wrote:


Snippet of the mvn test -X ouput:
==
snip
[DEBUG] Test Classpath :
[DEBUG] K:\Sources\Prefs\memoryprefs\target\test-classes
[DEBUG] K:\Sources\Prefs\memoryprefs\target\classes
[DEBUG] K:\Sources\Prefs\memoryprefs\target\classes
[DEBUG] K:\Sources\Prefs\memoryprefs\target\test-classes
[DEBUG]
K:\Repositories\maven2\.m2\repository\junit\junit\4.3.1\junit-4.3.1.jar
[DEBUG]
K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-simple\1.4.0\slf4j
-simple-1.4.0.jar
[DEBUG]
K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-api\1.4.0\slf4j-ap
i-1.4.0.jar
snap




Hi Minto

I have reduced your output to show nothing but the test classpath that is
defined by your project.
As you can see, both target/classes and target/test-classes are included.
(Twice, it seems.. kind of strange..)
Also your dependencies are listed.

The only stuff that is appended by Eclipse are the eclipse jars..
Note that compilation and running tests in Eclipse is done by Eclipse
itself, not by Maven.

If your custom classloader uses the system classloader for delegation, there
is no way to catch the additional libararies.
Since the sourceode of the classloader is already in your project, you might
as well adjust it.
Try using the context classloader as a parent instead.

Cheers
Jo


assembly plugin, module sets, binaries and includeDependencies

2007-06-08 Thread Kevin Stembridge
Hi all,
I'm having a problem with the assembly plugin. It isn't including 
dependencies for a binary within a module set.  I have the following 
configuration:



moduleSet
 
  includes
includemy.company:my-artifact/include
  /includes
 
  binaries
includeDependenciestrue/includeDependencies
useStrictFilteringtrue/useStrictFiltering
outputDirectorylib/outputDirectory
unpackfalse/unpack
  /binaries
 
/moduleSet
 
The module artifact is included fine, but none of its dependencies. There 
doesn't seem to be any issue raised for this problem yet. Just wondering 
if anyone has seen it before.

Cheers,
Kevin



---

This e-mail may contain confidential and/or privileged information. If you 
are not the intended recipient (or have received this e-mail in error) 
please notify the sender immediately and destroy this e-mail. Any 
unauthorized copying, disclosure or distribution of the material in this 
e-mail is strictly forbidden.

Maven, CVS, Eclipse, and Continuum

2007-06-08 Thread Greg Thompson
It seems that there are many rough edges relating to multimodule project 
development in Eclipse.  I've searched the mailing lists and found 
various people saying that they have usable setups, but I'm not sure 
that I buy it.  I've tried:


1. Flat project layout: parent POM references child modules as 
../module1, while the children have relativePath to 
../parent/pom.xml.  The CVS layout is the same: blahblah/parent, 
blahblah/module1, blahblah/module2.  Problems with this are, at least:


a. continuum checks the projects out into numbered directories, thereby 
breaking the relative references.


b. generating the site from within continuum yields broken links here 
and there.


c. continuum aside, I seem to recall that the site plugin does odd 
things in this configuration.


2. Nest project layout: parent POM references child modules as 
module1, while the children use the default relativePath.  The CVS 
layout matches: blahblah/parent, blahblah/parent/module1, 
blahblah/parent/module2.  Problems with this are, at least:


a. to get the projects into Eclipse, we have to jump through hoops like 
check out the parent into the workspace (so we have a parent project), 
use the eclipse:eclipse goal to generate files, and then import the 
modules as eclipse projects (so we have a module1 project and a 
module2 project).  This is sub-optimal, as each module is really in 
the workspace twice, once as a top-level Java project and once as a 
sub-directory in the parent project.


b. when adding to Continuum, Continuum checks out the parent and each 
module as separate projects (even though all modules are sub-dirs of the 
parent).  I have to manually delete the modules so that there's only the 
parent in continuum, and then remove the --non-recursive option.


Surely someone has figured out a better way.  Is such better way clearly 
documented somewhere (rather than in a scattering of email messages that 
may or may not be relevant given recent changes to Maven, Continuum, and 
the myriad plugins involved)?


Any advice would be appreciated.  Thanks.
--
-Greg

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



Re: calling plugin in another plugin?

2007-06-08 Thread Kenney Westerhof



David Jackman wrote:
Here's another situation where I want to have a plugin call another plugin.  
Can you tell me the right way to accomplish this?


In our group we have a release procedure that involves a few more steps 
beyond running the release:prepare mojo.  In fact, some of the parameters 
into the release:prepare mojo are based on internal standards, so they could

be computed automatically.
I want to create a single plugin that embodies this entire release process that 
also calls the release:prepare mojo with the correct parameters as part of that process.


This would be another situation where one plugin invokes another plugin.  
Obviously there is coupling there.  What is a better way to achieve this without that

coupling (is it even possible)?  Would I create a lifecycle within my mojo that 
puts
the necessary data on the bus and invokes the release:prepare mojo as part of 
that lifecycle (thinking in Maven 2.1 terms)?


This is the wrong approach - you don't want to wrap the release plugin, but 
extend it.
You could take a look at the release project ( 
https://svn.apache.org/repos/asf/maven/release/trunk ).
The release-manager works with an internal 'lifecycle' of it's own, with phases 
etc.
I'm sure there's a place there where you can attach a component of your own 
that does the preparation you need.

When you found the spot to hook in your functionality, you create a new project 
in your corp SCM,
that has a dependency on release-manager. It declares a components.xml with 
your component(s) listed,
in such a way that the release-manager picks them up and attaches them to the 
proper phase.

Take a look at 
release/maven-release-manager/src/main/resources/META-INF/plexus/components.xml).
 The first component
declares the phases, the other components implement these phases.
Your component declaration in your components.xml would look something like 
this:

   component
 roleorg.apache.maven.shared.release.phase.PreparePhase/role
 role-hintinput-variables/role-hint
 
implementationcom.yourcompany.maven.release.phase.CustomPreparePhase/implementation
   /component

and your CustomPreparePhase class would implement PreparePhase.

then you package this project up, and in your company root pom you declare a 
pluginManagement section
for the release plugin, listing a dependency on your project containing the 
above, like so:
pluginManagement
 plugins
   plugin
 artifactIdmaven-release-plugin/...
 dependencies
   dependency
 groupIdcom.yourcompany.maven
 artifactIdyour-extension/artifactId
 version.

then whenever you do a release:prepare, your component will be injected into 
the release manager
and be executed.

That's imho the proper approach.

-- Kenney




..David..


-Original Message-
From: Kenney Westerhof [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, June 06, 2007 5:48 PM

To: Maven Users List
Subject: Re: calling plugin in another plugin?



Nunn, Gerald wrote:

Jason,

It's a bad practice, and leads to coupling between plugins which is  
bad. We've seen the aftermath of this happening in Maven 1.x.
Since I'm doing this already I'm curious how this could be done better and accomplish my goal, I'm a relative newbie to Mojos so I'm wondering if I am missing a better approach. 


In my case, I needed a plugin that can handle a WebLogic shared library. A 
shared library is a WAR or EAR that contains many different assets including 
JARs and in order to be able to use these in Maven I've created a plugin that 
temporarily unpacks the shared library and installs each JAR individually under 
a library group name. It also creates a parent POM for the library that can be 
used to drag in all the dependencies defined by the library.

In order to do this, my plugin needs to install each file individually. Rather 
then rewrite the install plugin, I simply use my invoker class to invoke the 
install plugin for each file I have unpacked passing in the necessary 
parameters to make this work.

How could I accomplish the same goal using the approach you outlined?


This is a one-time setup, and really not part of the build.
You should have had those jars in the ears/wars in a repository already.

Either create a shellscript for it, or a pom, declaring a dependency on the 
war/ear (i assume that one _is_
in a repository? if not - it shouldn't be part of the maven build lifecycle).

You use the maven-dependency-plugin to unpack the war/ear (for instance in 
generate-resources), say to
${project.build.directory}/foo/
and specify a series of executions of the install plugin (for instance in 
process-resources), each one configured
with the location a jar in ${project.build.directory}/foo/.

Anyway, this is not recommended practice, but I can see why your plugin is 
useful.
The eclipse plugin has a similar mojo, that scans an eclipse installation 
directory for plugins
and installs each plugin as a maven2 artifact in the local directory. It 

Re: Build of maven 2.0.x branch: test failures

2007-06-08 Thread Kenney Westerhof



Graham Leggett wrote:

On Wed, June 6, 2007 4:53 pm, Jason van Zyl wrote:


Just built and it works fine. You on windows?


On windows and inside a firewall:


---
 T E S T S
---
Running org.apache.maven.cli.BatchModeDownloadMonitorTest
Downloading: null://nullnull/null



This looks like an URL that's gone pear shaped. It may be the test falls
off the tracks if it cannot reach the net.


I have the same output on linux, but the test passes. This isn't the test that 
fails
though, this is:


Running org.apache.maven.plugin.PluginParameterExpressionEvaluatorTest
Tests run: 11, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 1.391 sec  FAILURE! 


(later on in the output:


Results :

Failed tests:
 testTwoExpressions(org.apache.maven.plugin.PluginParameterExpressionEvaluatorT
est)

Tests run: 52, Failures: 1, Errors: 0, Skipped: 0 


)

can you give me the contents of 
maven-core/target/surefire-reports/org.apache.maven.plugin.PluginParameterExpressionEvaluatorTest.txt?

Mine is:

---
Test set: org.apache.maven.plugin.PluginParameterExpressionEvaluatorTest
---
Tests run: 11, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.631 sec


Cheers,

 Kenney




Regards,
Graham
--



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


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



Feature branches and merging

2007-06-08 Thread Hayes, Peter
I'd like to get some feedback on best practices of developing with
Maven.

Suppose we have a 1.0-SNAPSHOT mainline development version of a
multi-module maven project.  We would like to create a feature branch
off the mainline dev branch.  When developing on the feature branch I
would think we would need to change the version of all modules to
something like 1.0-wizzbang-SNAPSHOT.  Is that the recommended approach?
Is there an automated manner of changing all poms' versions in a single
command?  I know the release plugin does something like this but I don't
think it is exactly intended for this.

Finally, when merging the feature branch back to the mainline branch, we
would not want to merge the version fields in the POM as those would
only be appropriate on the feature branch.  We use clearcase, but is
this normally a difficult problem in code repositories?  Is there a way
to mark the version tag as non-mergable?

Thanks,

Peter Hayes
Architecture  Shared Technology Services | Fidelity Investments
Management Technology



Re: Problem with creating deployment code RMIC code during ejb build

2007-06-08 Thread Jo Vandermeeren

On 6/8/07, Kiran Kodlady [EMAIL PROTECTED] wrote:


one more question  - is there  any tag to provide custom path for 
ejb-jar.xml  in pom.xml ?




Create your own descriptor at src/main/resources/META-INF/ejb-jar.xml.
No need to specify it in the pom, as long as src/main/resources is included
as resource directory (by default), your ejb-jar.xml will bin included.

Cheers
Jo


Re: Maven, CVS, Eclipse, and Continuum

2007-06-08 Thread Greg Thompson

Christian Bauer wrote:

Hi Greg,

you can avoid topic

2.a) ... This is sub-optimal, as each module is really in the 
workspace twice, once as a top-level Java project and once as a 
sub-directory in the parent project.


by only checking out the root project (with all sub modules) and then
importing the modules from the the location within the root project.You
then have multiple projects, but only one codebase in the workspace.
This is very easy with Eclipse 3.2.2, in Eclipse 3.2.1 you should not
check out the root project  into the workspace but into another
directory and import from there.


Thanks, Christian.  That's actually what I had done.  So you really have 
two views into each module: one through the parent (where the checkout 
really is), and one through the module's project (which is really a 
pointer into the parent).


Is this the recommended way (path of least resistance)?  Especially in 
comparison to a flat layout?

--
-Greg

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



Re: Maven, CVS, Eclipse, and Continuum

2007-06-08 Thread Christian Bauer

Hi Greg,

you can avoid topic

2.a) ... This is sub-optimal, as each module is really in 
the workspace twice, once as a top-level Java project and once as a 
sub-directory in the parent project.



by only checking out the root project (with all sub modules) and then
importing the modules from the the location within the root project.You
then have multiple projects, but only one codebase in the workspace.
This is very easy with Eclipse 3.2.2, in Eclipse 3.2.1 you should not
check out the root project  into the workspace but into another
directory and import from there.

Christian


Greg Thompson schrieb:
It seems that there are many rough edges relating to multimodule project 
development in Eclipse.  I've searched the mailing lists and found 
various people saying that they have usable setups, but I'm not sure 
that I buy it.  I've tried:


1. Flat project layout: parent POM references child modules as 
../module1, while the children have relativePath to 
../parent/pom.xml.  The CVS layout is the same: blahblah/parent, 
blahblah/module1, blahblah/module2.  Problems with this are, at least:


a. continuum checks the projects out into numbered directories, thereby 
breaking the relative references.


b. generating the site from within continuum yields broken links here 
and there.


c. continuum aside, I seem to recall that the site plugin does odd 
things in this configuration.


2. Nest project layout: parent POM references child modules as 
module1, while the children use the default relativePath.  The CVS 
layout matches: blahblah/parent, blahblah/parent/module1, 
blahblah/parent/module2.  Problems with this are, at least:


a. to get the projects into Eclipse, we have to jump through hoops like 
check out the parent into the workspace (so we have a parent project), 
use the eclipse:eclipse goal to generate files, and then import the 
modules as eclipse projects (so we have a module1 project and a 
module2 project).  This is sub-optimal, as each module is really in 
the workspace twice, once as a top-level Java project and once as a 
sub-directory in the parent project.


b. when adding to Continuum, Continuum checks out the parent and each 
module as separate projects (even though all modules are sub-dirs of the 
parent).  I have to manually delete the modules so that there's only the 
parent in continuum, and then remove the --non-recursive option.


Surely someone has figured out a better way.  Is such better way clearly 
documented somewhere (rather than in a scattering of email messages that 
may or may not be relevant given recent changes to Maven, Continuum, and 
the myriad plugins involved)?


Any advice would be appreciated.  Thanks.






--

Dipl.-Inform. Christian Bauer
Softwareentwickler und Berater

-
GETIT GmbH
Emil-Figge-Straße 76-80
44227 Dortmund

Fon: +49.231.9742.7873
Fax: +49.231.9742. 356
http://www.getit.de

Amtsgericht Dortmund
HRB-Nr. 13836

Geschäftsführer:
Dr. Joachim Janoth
Dr. Thomas Krämerkämper


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



RE: Classpath issues with maven 2.0.6

2007-06-08 Thread Minto.van.der.Sluis


Hi Jo,

I can not use the parent class loader since that would render the whole
exercise useless. The whole point is not using the standard classloader
otherwise it is impossible to unload classes. Remember, I want to test
static blocks ( static { some code } ) . So I need fresh copies of my
class for every single test. That's why I use the ReloadableClassLoader.

This custom classloader does not use the normal commandline but the
'java.class.path' system property to determine the classpath. Retrieving
this system property reveals only one classpath entry.

K:\DevTools\maven\maven-2.0.6\boot\classworlds-1.1.jar 

Thus all entries in the classpath reported by 'mvn -X' do not show up
here.

An alternative to using 'java.class.path' is fine with me, but from
where can I programmatically retrieve the classpath to feed to the
custom classloader. Is it possible to get the classpath from the active
classloader?

Regards,

Minto


-Oorspronkelijk bericht-
Van: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Namens
Vandermeeren, Jo
Verzonden: vrijdag 8 juni 2007 14:49
Aan: Maven Users List
Onderwerp: Re: Classpath issues with maven 2.0.6

On 6/8/07, [EMAIL PROTECTED] 
[EMAIL PROTECTED] wrote:

 Snippet of the mvn test -X ouput:
 ==
 snip
 [DEBUG] Test Classpath :
 [DEBUG] K:\Sources\Prefs\memoryprefs\target\test-classes
 [DEBUG] K:\Sources\Prefs\memoryprefs\target\classes
 [DEBUG] K:\Sources\Prefs\memoryprefs\target\classes
 [DEBUG] K:\Sources\Prefs\memoryprefs\target\test-classes
 [DEBUG]
 K:\Repositories\maven2\.m2\repository\junit\junit\4.3.1\junit-4.3.1.ja
 r
 [DEBUG]
 K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-simple\1.4.0\slf
 4j
 -simple-1.4.0.jar
 [DEBUG]
 K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-api\1.4.0\slf4j-
 ap
 i-1.4.0.jar
 snap



Hi Minto

I have reduced your output to show nothing but the test classpath that
is defined by your project.
As you can see, both target/classes and target/test-classes are
included.
(Twice, it seems.. kind of strange..)
Also your dependencies are listed.

The only stuff that is appended by Eclipse are the eclipse jars..
Note that compilation and running tests in Eclipse is done by Eclipse
itself, not by Maven.

If your custom classloader uses the system classloader for delegation,
there is no way to catch the additional libararies.
Since the sourceode of the classloader is already in your project, you
might as well adjust it.
Try using the context classloader as a parent instead.

Cheers
Jo


DISCLAIMER
De informatie in deze e-mail is vertrouwelijk en uitsluitend bestemd voor de 
geadresseerde. Indien u niet de geadresseerde bent, wordt u er hierbij op 
gewezen, dat u geen recht heeft kennis te nemen van de rest van deze e-mail, 
deze te gebruiken, te kopieren of te verstrekken aan andere personen dan de 
geadresseerde. Indien u deze e-mail abusievelijk hebt ontvangen, brengt u dan 
alstublieft de afzender op de hoogte, waarbij u bij deze gevraagd wordt het 
originele bericht te vernietigen. Politie Amsterdam-Amstelland is niet 
verantwoordelijk voor de inhoud van deze e-mail en wijst iedere 
aansprakelijkheid af voor en/of in verband met alle gevolgen en/of schade van 
een onjuiste of onvolledige verzending ervan. Tenzij uitdrukkelijk het 
tegendeel blijkt, kunnen aan dit bericht geen rechten worden ontleend. Het 
gebruik van Internet e-mail brengt zekere risicos met zich. Daarom wordt iedere 
aansprakelijkheid voor het gebruik van dit medium door de Politie 
Amsterdam-Amstelland van de hand gewezen. 

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



RE: War plugin transitive dependency

2007-06-08 Thread Váry Péter
Hi Jo,

I have checked the link (not working with FF 2.0.0.4, but ok with IE 6.0), and 
through several days of googling I have found the skinny war solution for the 
ear problem.
Unfortunately it does not help me in this situation: I do not have ear-s 
(working with tomcat), just war-s. One portal - one war. Every module is one 
war, or jar. Modules depend on each other like news.war (with jsp, html etc) 
depends on HTML editor war (with other jsp, html etc), and the product depends 
on news.war, with its own html-s, and jsp-s.

Any idea?

Thanks,
Peter
 

-Original Message-
From: Jo Vandermeeren [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 08, 2007 12:18 PM
To: Maven Users List
Subject: Re: War plugin transitive dependency

On 6/8/07, Váry Péter [EMAIL PROTECTED] wrote:

 If I working with jar-s, and A is transitively dependent on C, then if a
 new C is installed into the repository, I will get the new version. But with
 war - it does not count the transitive dependencies, so I does not get the
 changes.



Hi Peter,

Aha, war dependencies are something completely different.
So, as you experienced, it is always good to be as specific as possible
about your problem.

I assume that your module A is an ear, module B is a war, and module C is a
jar?

By default, the dependencies of a webapp (module B) are packaged within the
war artifact itself.
If you depend on that module in an ear module (A), the war artifact will
simply be included, and its dependencies will not be checked.
This is valid because changes in module B's dependencies would require a
rebuild of the webapp in this setup.

You can however make this work in the same way as you apparently expect it
to do.
You achieve this by depending on C in your ear and package the dependencies
of module B in the ear instead.
Some configuration has to be made to modify the manifest classpath of the
webapp et cetera.

If you have multiple modules in the ear which depend on the same
dependencies (or some of them), this is the preferred configuration.
Otherwise you end up with a bloated ear full of duplicate libraries.

Jeroen Leenarts has written an enlightening article about this some time
ago:
http://blog.leenarts.net/2007/02/11/maven-2s-ear-plugin-gives-me-a-headache/

Cheers
Jo

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



[m2] Multi-project dependency issue

2007-06-08 Thread Orford, Ian
I'm using maven 2.0.6.

I have a multi-module project.

P is the parent POM that has modules A, B, C and D.
P defines A, B, C and D in dependencyManagement
A has P as a parent and no dependencies at all.
B has P as a parent and defines A in dependencies
C has P as a parent and defines A and B in dependencies
D has P as a parent and defines C in dependencies

Mvn install compiles A, then B. The trouble starts because it then moves
onto D. Since C hasn't been installed, it fails.

Any gotchas in this area I should be aware of?

Thanks, Ian


--
This e-mail is confidential and the information contained in it may be 
privileged.  It should not be read, copied or used by anyone other than the 
intended recipient.  If you have received it in error, please contact the 
sender immediately by telephoning +44 (0)20 7623 8000 or by return email, and 
delete the e-mail and do not disclose its contents to any person.  We believe, 
but do not warrant, that this e-mail and any attachments are virus free, but 
you must take full responsibility for virus checking.  Please refer to 
http://www.dresdnerkleinwort.com/disc/email/ and read our e-mail disclaimer 
statement and monitoring policy.

Dresdner Kleinwort is the trading name of the investment banking division of 
Dresdner Bank AG, and operates through Dresdner Bank AG, Dresdner Kleinwort 
Limited, Dresdner Kleinwort Securities Limited and their affiliated or 
associated companies.  Dresdner Bank AG is a company incorporated in Germany 
with limited liability and registered in England (registered no. FC007638, 
place of business 30 Gresham Street, London EC2V 7PG), and is authorised by the 
German Federal Financial Supervisory Authority and by the Financial Services 
Authority ('FSA') and regulated by the FSA for the conduct of designated 
business in the UK.  Dresdner Kleinwort Limited is a company incorporated in 
England (registered no. 551334, registered office 30 Gresham Street, London 
EC2V 7PG), and is authorised and regulated by the FSA.  Dresdner Kleinwort 
Securities Limited is a company incorporated in England (registered no. 
1767419, registered office 30 Gresham Street, London EC2V 7PG), and is 
authorised and regulated by the FSA.



Problem with wagon-ftp [can't connect]

2007-06-08 Thread CasMeiron

Hi guys... i have a problem with wagon ftp.
Im using ftp protocol to deploy my site, look the configuration in my pom:

distributionManagement
   site
 idpimpas-framework-site/id
 urlftp://framework.pimpas.net/url
   /site
 /distributionManagement
build
...
extensions
extension
groupIdorg.apache.maven.wagon/groupId
artifactIdwagon-ftp/artifactId
/extension
/extensions
...
/build

I got the wagon patch to create directories using ftp, im my settings.xml i
have something like:
servers
   server
 idpimpas-framework-site/id
 usernameusername/username
 passwordpassword/password
   /server
 /servers

I can connect direct in ftp using this informations, but mvn site:deploy
give me an error:

[INFO] [site:deploy]
Reply received: 220 (vsFTPd 2.0.5)

ftp://framework.pimpas.net - Session: Disconnecting
ftp://framework.pimpas.net - Session: Disconnected
[INFO]

[ERROR] FATAL ERROR
[INFO]

[INFO] null
[INFO]

[INFO] Trace
java.lang.NullPointerException
   at org.apache.maven.wagon.providers.ftp.FtpWagon.openConnection
(FtpWagon
.java:131)
   at org.apache.maven.wagon.AbstractWagon.connect(AbstractWagon.java
:143)
   at org.apache.maven.wagon.AbstractWagon.connect(AbstractWagon.java
:106)
   at org.apache.maven.plugins.site.SiteDeployMojo.execute(
SiteDeployMojo.j
ava:153)
   at org.apache.maven.plugin.DefaultPluginManager.executeMojo
(DefaultPlugi
nManager.java:443)
   at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals
(Defa
ultLifecycleExecutor.java:539)
   at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandalone
Goal(DefaultLifecycleExecutor.java:493)
   at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal
(Defau
ltLifecycleExecutor.java:463)
   at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan
dleFailures(DefaultLifecycleExecutor.java:311)
   at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen
ts(DefaultLifecycleExecutor.java:278)
   at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute
(DefaultLi
fecycleExecutor.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
(DelegatingMethodAcces
sorImpl.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)

Any help?!
tkz.

--
Paulo Cesar Silva Reis
---
Powered by GMAIL


Re: [M2] Creating internal remote repsistory for Oracle ADF project

2007-06-08 Thread Andrew Birchall

Thanks Vanja that looks pretty good, though even here, they don't seem
to mention mvn:deploy much. The section on Wagon and Repositories
looks pretty good though, I'll take a closer look at it later.
Cheers
Andy

On 08/06/07, Vanja Petreski [EMAIL PROTECTED] wrote:

Hi,

try with this one: http://www.sonatype.com/book/index.html ;)

Vanja

On 6/8/07, Andrew Birchall [EMAIL PROTECTED] wrote:

 Thanks a lot Wayne, that's great help.

 It does seem a lot of work to do this for every jar file the project
 depends on but I guess I can write a script to do it.

 I feel that the documentation for Maven is not that good. Its not very
 clear or well structured, making it hard to find what you need,
 especially for people who are new to it.

 For example, the Introduction to Repositories page
 (
 http://maven.apache.org/guides/introduction/introduction-to-repositories.html
 ),
 which talks about Internal Repositories, contains no information about
 using mvn deploy:deploy-file.

 There's also hardly anything on this in the Better Build with Maven
 book from Mergere.

 I think this is a gap in the Maven documentation. But I also feel that
 the Maven documentation is weakness in the Maven project generally and
 probably hinders it's adoption.

 Thanks very much
 Andy Birchall

 On 07/06/07, Wayne Fay [EMAIL PROTECTED] wrote:
  mvn install:install-file and mvn deploy:deploy-file are your friends
  -- and they are very well-documented [1] [2] including a FAQ [3].
  Assuming you have oc4j.jar and want to push it into the shared
  corporate repo:
 
  mvn deploy:deploy-file -DgroupId=com.oracle.jdevelope​r
  -DartifactId=oc4j -Dversion=10.1.3.2 -Dpackaging=jar -Dfile=oc4j.jar
  -DgeneratePom=true -DrepositoryId=your_id
  -Durl=file://somewhere/m2/repo
 
  You will have to pick the groupId, artifactId, version for all your
  jars. Also, you will need to follow the directions regarding setting
  up the repositoryId in your settings.xml and of course get the right
  file:// path. But that's it.
 
  Wayne
 
  [1] http://maven.apache.org/plugin​s/maven-install-plugin/usage.ht​ml
  [2] http://maven.apache.org/plugin​s/maven-deploy-plugin/usage.htm​l
  [3] http://maven.apache.org/guides​/mini/guide-deploying-3rd-party​-
 jars.html
 
  On 6/7/07, Andrew Birchall [EMAIL PROTECTED] wrote:
   Hello,
   I am trying to Mavenize a multi-module J2EE Oracle ADF project that is
   currently built with several Ant scripts and developed in JDeveloper
   10.1.3.2
  
   One of the main problems I have is that the project depends on many
   Artifacts (jar files) distributed with JDeveloper.
  
   Thus, In order to build this project with Maven I have to set up an
   internal repository in our company with all the JDeveloper jar files.
   At the moment I am trying to do this with the file:// protocol on a
   network share.
  
   However I'm not really sure the way to go about this and I can't seem
   to find any good documentation on it. Non of the jars distributed with
   JDeveloper are versioned. Do I have to version all the jar files
   myself and put them in the correct package directories, in order to
   conform to the Maven repository layout convention? How do I know what
   version to re-name the jar files to?
  
   If I do have to do this its a BIG and tedious job because there's so
   many dependencies. And what about the pom files for each jar, how do
   these get created?
  
   I'd be very grateful to hear from anyone who can help
   Kind regards
   Andy Birchall
  
  
 --​---​
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
  --​---​
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 




Re: [m2] Multi-project dependency issue

2007-06-08 Thread Vandermeeren, Jo

On 6/8/07, Orford, Ian [EMAIL PROTECTED] wrote:


P is the parent POM that has modules A, B, C and D.
P defines A, B, C and D in dependencyManagement
A has P as a parent and no dependencies at all.
B has P as a parent and defines A in dependencies
C has P as a parent and defines A and B in dependencies
D has P as a parent and defines C in dependencies

Mvn install compiles A, then B. The trouble starts because it then moves
onto D. Since C hasn't been installed, it fails.




Hi Ian,

Are you building from the directory that contains the parent pom.xml?
Are modules A,B,C,D listed as modules in the parent pom.xml?

Cheers
Jo


RE: [m2] Multi-project dependency issue

2007-06-08 Thread Orford, Ian
Yes to both.
Not only that, in the parent pom, the modules are listed in the order I
want them built - ie A,B,C,D
 

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On Behalf Of Vandermeeren, Jo
 Sent: 08 June 2007 14:21
 To: Maven Users List
 Subject: Re: [m2] Multi-project dependency issue
 
 On 6/8/07, Orford, Ian [EMAIL PROTECTED] wrote:
 
  P is the parent POM that has modules A, B, C and D.
  P defines A, B, C and D in dependencyManagement A has P 
 as a parent 
  and no dependencies at all.
  B has P as a parent and defines A in dependencies C has P as a 
  parent and defines A and B in dependencies D has P as a 
 parent and 
  defines C in dependencies
 
  Mvn install compiles A, then B. The trouble starts because it then 
  moves onto D. Since C hasn't been installed, it fails.
 
 
 
 Hi Ian,
 
 Are you building from the directory that contains the parent pom.xml?
 Are modules A,B,C,D listed as modules in the parent pom.xml?
 
 Cheers
 Jo
 


--
This e-mail is confidential and the information contained in it may be 
privileged.  It should not be read, copied or used by anyone other than the 
intended recipient.  If you have received it in error, please contact the 
sender immediately by telephoning +44 (0)20 7623 8000 or by return email, and 
delete the e-mail and do not disclose its contents to any person.  We believe, 
but do not warrant, that this e-mail and any attachments are virus free, but 
you must take full responsibility for virus checking.  Please refer to 
http://www.dresdnerkleinwort.com/disc/email/ and read our e-mail disclaimer 
statement and monitoring policy.

Dresdner Kleinwort is the trading name of the investment banking division of 
Dresdner Bank AG, and operates through Dresdner Bank AG, Dresdner Kleinwort 
Limited, Dresdner Kleinwort Securities Limited and their affiliated or 
associated companies.  Dresdner Bank AG is a company incorporated in Germany 
with limited liability and registered in England (registered no. FC007638, 
place of business 30 Gresham Street, London EC2V 7PG), and is authorised by the 
German Federal Financial Supervisory Authority and by the Financial Services 
Authority ('FSA') and regulated by the FSA for the conduct of designated 
business in the UK.  Dresdner Kleinwort Limited is a company incorporated in 
England (registered no. 551334, registered office 30 Gresham Street, London 
EC2V 7PG), and is authorised and regulated by the FSA.  Dresdner Kleinwort 
Securities Limited is a company incorporated in England (registered no. 
1767419, registered office 30 Gresham Street, London EC2V 7PG), and is 
authorised and regulated by the FSA.


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



Re: [M2] Creating internal remote repsistory for Oracle ADF project

2007-06-08 Thread Wayne Fay

There's also a free PDF better Builds with Maven book from
Mergere.com which is a big help as well.

Wayne

On 6/8/07, Andrew Birchall [EMAIL PROTECTED] wrote:

Thanks Vanja that looks pretty good, though even here, they don't seem
to mention mvn:deploy much. The section on Wagon and Repositories
looks pretty good though, I'll take a closer look at it later.
Cheers
Andy

On 08/06/07, Vanja Petreski [EMAIL PROTECTED] wrote:
 Hi,

 try with this one: http://www.sonatype.com/book/index.html ;)

 Vanja

 On 6/8/07, Andrew Birchall [EMAIL PROTECTED] wrote:
 
  Thanks a lot Wayne, that's great help.
 
  It does seem a lot of work to do this for every jar file the project
  depends on but I guess I can write a script to do it.
 
  I feel that the documentation for Maven is not that good. Its not very
  clear or well structured, making it hard to find what you need,
  especially for people who are new to it.
 
  For example, the Introduction to Repositories page
  (
  
http://maven.apache.org/guides/introduction/introduction-to-repositories.html
  ),
  which talks about Internal Repositories, contains no information about
  using mvn deploy:deploy-file.
 
  There's also hardly anything on this in the Better Build with Maven
  book from Mergere.
 
  I think this is a gap in the Maven documentation. But I also feel that
  the Maven documentation is weakness in the Maven project generally and
  probably hinders it's adoption.
 
  Thanks very much
  Andy Birchall
 
  On 07/06/07, Wayne Fay [EMAIL PROTECTED] wrote:
   mvn install:install-file and mvn deploy:deploy-file are your friends
   -- and they are very well-documented [1] [2] including a FAQ [3].
   Assuming you have oc4j.jar and want to push it into the shared
   corporate repo:
  
   mvn deploy:deploy-file -DgroupId=com.oracle.jdevelope​r
   -DartifactId=oc4j -Dversion=10.1.3.2 -Dpackaging=jar -Dfile=oc4j.jar
   -DgeneratePom=true -DrepositoryId=your_id
   -Durl=file://somewhere/m2/repo
  
   You will have to pick the groupId, artifactId, version for all your
   jars. Also, you will need to follow the directions regarding setting
   up the repositoryId in your settings.xml and of course get the right
   file:// path. But that's it.
  
   Wayne
  
   [1] http://maven.apache.org/plugin​s/maven-install-plugin/usage.ht​ml
   [2] http://maven.apache.org/plugin​s/maven-deploy-plugin/usage.htm​l
   [3] http://maven.apache.org/guides​/mini/guide-deploying-3rd-party​-
  jars.html
  
   On 6/7/07, Andrew Birchall [EMAIL PROTECTED] wrote:
Hello,
I am trying to Mavenize a multi-module J2EE Oracle ADF project that is
currently built with several Ant scripts and developed in JDeveloper
10.1.3.2
   
One of the main problems I have is that the project depends on many
Artifacts (jar files) distributed with JDeveloper.
   
Thus, In order to build this project with Maven I have to set up an
internal repository in our company with all the JDeveloper jar files.
At the moment I am trying to do this with the file:// protocol on a
network share.
   
However I'm not really sure the way to go about this and I can't seem
to find any good documentation on it. Non of the jars distributed with
JDeveloper are versioned. Do I have to version all the jar files
myself and put them in the correct package directories, in order to
conform to the Maven repository layout convention? How do I know what
version to re-name the jar files to?
   
If I do have to do this its a BIG and tedious job because there's so
many dependencies. And what about the pom files for each jar, how do
these get created?
   
I'd be very grateful to hear from anyone who can help
Kind regards
Andy Birchall
   
   
  --​---​
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: Settings.xml under source control?

2007-06-08 Thread Wim Deblauwe

I also don't think you should put it under source control. Better to create
a super pom for all your projects or to have an example
settings.xmlunder souce control that developers can use to create
their own
settings.xml.

regards,

Wim

Op 08-06-07 heeft [EMAIL PROTECTED] 
[EMAIL PROTECTED] het volgende geschreven:




Hi Moe,

Are you sure you want settings.xml under source control? Lots of times
the settings.xml contains user specific settings like usernames and
passwords.

Regards,

Minto


-Oorspronkelijk bericht-
Van: Moe, Vidar [mailto:[EMAIL PROTECTED]
Verzonden: vrijdag 8 juni 2007 11:28
Aan: users@maven.apache.org
Onderwerp: Settings.xml under source control?


Hi!

We would like to have the settings.xml file in a custom location to
easily being able to have it under source control. We can control the
placement of the settings.xml file by the

-Dorg.apache.maven.user-settings

but it is cumersome for developers to add this param for every mvn
command they are going to run. - Can this parameter be applied globally
somehow, so that the developers do not have to add it everytime?

Thanks in advance,

Regards,
Vidar Moe


This message contains information that may be privileged or confidential
and is the property of the Capgemini Group. It is intended only for the
person to whom it is addressed. If you are not the intended recipient,
you are not authorized to read, print, retain, copy, disseminate,
distribute, or use this message or any part thereof. If you receive this
message in error, please notify the sender immediately and delete all
copies of this message.


DISCLAIMER
De informatie in deze e-mail is vertrouwelijk en uitsluitend bestemd voor
de geadresseerde. Indien u niet de geadresseerde bent, wordt u er hierbij op
gewezen, dat u geen recht heeft kennis te nemen van de rest van deze e-mail,
deze te gebruiken, te kopieren of te verstrekken aan andere personen dan de
geadresseerde. Indien u deze e-mail abusievelijk hebt ontvangen, brengt u
dan alstublieft de afzender op de hoogte, waarbij u bij deze gevraagd wordt
het originele bericht te vernietigen. Politie Amsterdam-Amstelland is niet
verantwoordelijk voor de inhoud van deze e-mail en wijst iedere
aansprakelijkheid af voor en/of in verband met alle gevolgen en/of schade
van een onjuiste of onvolledige verzending ervan. Tenzij uitdrukkelijk het
tegendeel blijkt, kunnen aan dit bericht geen rechten worden ontleend. Het
gebruik van Internet e-mail brengt zekere risicos met zich. Daarom wordt
iedere aansprakelijkheid voor het gebruik van dit medium door de Politie
Amsterdam-Amstelland van de hand gewezen.

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





--
Vigilog - an open source log file viewer: http://vigilog.sourceforge.net
Blog: http://www.jroller.com/page/Fester


Re: Inclusions of test classes not inherited by TestCase

2007-06-08 Thread Wayne Fay

Another perspective on this issue is that naming a file which is not a
test with the name *Test.java is not particularly clean either, right?

Maven is not just a build tool -- it is also a collection of best
practices enforced by default configurations provided in the plugins.
It sounds like the best practice only tests are named *Test in my
project is something you don't agree with -- in this case, you will
not want to accept the defaults, but instead override them with extra
configuration specific to your project.

Wayne

On 6/8/07, Martin Monsorno [EMAIL PROTECTED] wrote:

Hi,

thanks for the answers.  I know that I can controls, which tests are
executed by including or excluding some of them, but that's not the
point.  Any tests, that match the inclusion pattern, should not be
executed, if they are not a Junit TestCase, i.e. extend
junit.framework.TestCase and is not abstract.  E.g. this class:

code
public class DoesThisExecuteTest {
}
/code

should not be considered as test case and be executed, but it is when
running mvn test:

...
Running de.kvb.apo.corrservice.DoesThisExecuteTest
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0 sec  
FAILURE!
...

with this report:

---
Test set: de.kvb.apo.corrservice.DoesThisExecuteTest
---
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0 sec  
FAILURE!
de.kvb.apo.corrservice.DoesThisExecuteTest  Time elapsed: 0 sec   ERROR!
java.lang.Exception: No runnable methods
at 
org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:34)
at 
org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42)


That's not a real problem, and will not exist any more with Junit 4,
but, well, it's not really clean, is it?

Regards,
Martin.


--
Martin Monsorno
mailto:[EMAIL PROTECTED]


Pt! Schon vom neuen GMX MultiMessenger gehört?
Der kanns mit allen: http://www.gmx.net/de/go/multimessenger

-
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: Cascading package dependencies

2007-06-08 Thread Wayne Fay

I don't use really use Eclipse much, especially not for building Maven
projects. I use the command line for Maven as we are required to have
all projects building successfully under Maven at all times.

I (nearly) always build my projects from the top which means all the
modules etc will be updated during the compilation.

Wayne

On 6/8/07, André Salvati [EMAIL PROTECTED] wrote:

Hi Wayne,

Thanks for your answer.

I've been working just with modules (children) on my workspace. Is there
any workaround on Eclipse? I didn't want to remenber all modules
dependencies.

How do you do it?




Wayne Fay escreveu:
 No, this is not possible. However, if you run mvn install from the
 top-level (father) project, it will run mvn install on all the
 modules (children) you've defined, which achieves the same results
 you're looking for.

 Wayne

 On 6/6/07, André Salvati [EMAIL PROTECTED] wrote:
 Hi,

 I'm a newbie with Maven 2 (2.0.6). Just wondering the following
 situation:

 I'm working with 3 modules: 1 father (Project1) and 2 children (Project2
 and Project3). Project2 depends on Project3.

 Firstly, I'd like Maven was able to detect updates, compile, build and
 package Project3 in case of issuing mvn install on Project2. Is it
 possible?

 These are excerpts from my .pom files:

 Projetc1 (father):

 modules
 moduleProject2/module
 moduleProject3/module
 /modules


 Projetc2

 dependencies
 dependency
 groupIdxpto/groupId
 artifactIdProject3/artifactId
 version1.0-SNAPSHOT/version
 scopeprovided/scope
 /dependency
 /dependencies







 -
 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: Settings.xml under source control?

2007-06-08 Thread Chris Helck
Hi all,

There are two settings.xml files: one in mvn's conf directory and the
other in a user's home directory. I don't see many issues with putting
mvn's setting.xml under SCM. We put the maven binaries and setting.xml
under SCM and both developers and certification people find this helpful
in that it provides a consistent environment. Maven's settings.xml
contains common profiles, mirrors, and so on. The user's settings.xml
may contain user names and passwords. The comment about not putting user
specific data in Maven's settings.xml is correct whether you use SCM or
not.

If a particular user wants to put his own settings.xml file in SCM then
who am I to complain?

Regards,
Christopher Helck  

-Original Message-
From: Wim Deblauwe [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 08, 2007 10:55 AM
To: Maven Users List
Subject: Re: Settings.xml under source control?

I also don't think you should put it under source control. Better to
create a super pom for all your projects or to have an example
settings.xmlunder souce control that developers can use to create their
own settings.xml.

regards,

Wim

Op 08-06-07 heeft [EMAIL PROTECTED] 
[EMAIL PROTECTED] het volgende geschreven:



 Hi Moe,

 Are you sure you want settings.xml under source control? Lots of times

 the settings.xml contains user specific settings like usernames and 
 passwords.

 Regards,

 Minto


 -Oorspronkelijk bericht-
 Van: Moe, Vidar [mailto:[EMAIL PROTECTED]
 Verzonden: vrijdag 8 juni 2007 11:28
 Aan: users@maven.apache.org
 Onderwerp: Settings.xml under source control?


 Hi!

 We would like to have the settings.xml file in a custom location to 
 easily being able to have it under source control. We can control the 
 placement of the settings.xml file by the

 -Dorg.apache.maven.user-settings

 but it is cumersome for developers to add this param for every mvn 
 command they are going to run. - Can this parameter be applied 
 globally somehow, so that the developers do not have to add it
everytime?

 Thanks in advance,

 Regards,
 Vidar Moe

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




--
Vigilog - an open source log file viewer: http://vigilog.sourceforge.net
Blog: http://www.jroller.com/page/Fester

**
This communication and all information (including, but not limited to,
 market prices/levels and data) contained therein (the Information) is
 for informational purposes only, is confidential, may be legally
 privileged and is the intellectual property of ICAP plc and its affiliates
 (ICAP) or third parties. No confidentiality or privilege is waived or
 lost by any mistransmission. The Information is not, and should not
 be construed as, an offer, bid or solicitation in relation to any
 financial instrument or as an official confirmation of any transaction.
 The Information is not warranted, including, but not limited, as to
 completeness, timeliness or accuracy and is subject to change
 without notice. ICAP assumes no liability for use or misuse of the
 Information. All representations and warranties are expressly
 disclaimed. The Information does not necessarily reflect the views of
 ICAP. Access to the Information by anyone else other than the
 recipient is unauthorized and any disclosure, copying, distribution or
 any action taken or omitted to be taken in reliance on it is prohibited. If
 you receive this message in error, please immediately delete it and all
 copies of it from your system, destroy any hard copies of it and
 notify the sender.
**


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



Classpath in exec:java

2007-06-08 Thread sharrissf

Can someone point me to a sample of executing a java program from exec:java
that requires a jar in the class path that comes from an external package.
In otherwords, manually setting the classpath. This isn't working for me.

plugin
   groupIdorg.codehaus.mojo/groupId
   artifactIdexec-maven-plugin/artifactId
   executions
 execution
   goals
 goaljava/goal
   /goals
   phaseprocess-test-resources/phase
 /execution
   /executions
  configuration
mainClasscom.tc.object.tools.BootJarTool/mainClass
executablejava/executable
  arguments
argument-classpath/argument
   
argument${project.build.directory}/dependency/terracotta-trunk/lib/tc.jar/argument
argumentmake/argument
  /arguments
   /configuration
 /plugin

Thanks for any help
-- 
View this message in context: 
http://www.nabble.com/Classpath-in-exec%3Ajava-tf3890648s177.html#a11029155
Sent from the Maven - Users mailing list archive at Nabble.com.


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



Re: War plugin transitive dependency

2007-06-08 Thread Vandermeeren, Jo

On 6/8/07, Váry Péter [EMAIL PROTECTED] wrote:


Unfortunately it does not help me in this situation: I do not have ear-s
(working with tomcat), just war-s. One portal - one war. Every module is one
war, or jar. Modules depend on each other like news.war (with jsp, html
etc) depends on HTML editor war (with other jsp, html etc), and the product
depends on news.war, with its own html-s, and jsp-s.




AFAIK, dependencies of wars are not resolved transitively.
If a war depends on another one, the contents of both are merged
(overlayed).

Nothing else to do than installing B first, to make the changes in C appear
in A with the standard maven-war-plugin.

However, appfuse's maven-warpath-plugin might be of interest.
http://static.appfuse.org/maven-warpath-plugin/index.html
It allows the dependencies of a war to be resolved transitively.

Anyway, running your build from the common parent directory will guarantee a
correct build reactor sequence.
So there is always a last resort..


Cheers
Jo


Re: Classpath issues with maven 2.0.6

2007-06-08 Thread Vandermeeren, Jo

On 6/8/07, [EMAIL PROTECTED]
[EMAIL PROTECTED] 
wrote:


I can not use the parent class loader since that would render the whole
exercise useless. The whole point is not using the standard classloader
otherwise it is impossible to unload classes. Remember, I want to test
static blocks ( static { some code } ) . So I need fresh copies of my
class for every single test. That's why I use the ReloadableClassLoader.




Hi Minto


Whether you like it or not, every ClassLoader has a parent, except for the
system class loader.
If you don't specify a parent ClassLoader, the default parent will be the
system class loader.
But this class loader is not always what we want.

And that's the reason why I adviced you to use the correct parent class
loader, i.c. the class loader that was used to load the definition of your
custom classloader (ReloadableClassLoader).

Every Class knows its ClassLoader, so you could get yours by calling
getClass().getClassLoader().
That is the correct parent loader and will introduce the desired class path
to your custom class loader.
Make sure that one is used when the custom class loader is created. It has
to be passed in the construcor.

Fiddling with the java.class.path system property in this context smells
too much like hacking to me.


Cheers
Jo


This custom classloader does not use the normal commandline but the

'java.class.path' system property to determine the classpath. Retrieving
this system property reveals only one classpath entry.

K:\DevTools\maven\maven- 2.0.6\boot\classworlds-1.1.jar

Thus all entries in the classpath reported by 'mvn -X' do not show up
here.

An alternative to using 'java.class.path' is fine with me, but from
where can I programmatically retrieve the classpath to feed to the
custom classloader. Is it possible to get the classpath from the active
classloader?

Regards,

Minto


-Oorspronkelijk bericht-
Van: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Namens
Vandermeeren, Jo
Verzonden: vrijdag 8 juni 2007 14:49
Aan: Maven Users List
Onderwerp: Re: Classpath issues with maven 2.0.6

On 6/8/07, [EMAIL PROTECTED] 
[EMAIL PROTECTED]  wrote:

 Snippet of the mvn test -X ouput:
 ==
 snip
 [DEBUG] Test Classpath :
 [DEBUG] K:\Sources\Prefs\memoryprefs\target\test-classes
 [DEBUG] K:\Sources\Prefs\memoryprefs\target\classes
 [DEBUG] K:\Sources\Prefs\memoryprefs\target\classes
 [DEBUG] K:\Sources\Prefs\memoryprefs\target\test-classes
 [DEBUG]
 K:\Repositories\maven2\.m2\repository\junit\junit\4.3.1\junit- 4.3.1.ja
 r
 [DEBUG]
 K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-simple\1.4.0\slf
 4j
 -simple-1.4.0.jar
 [DEBUG]
 K:\Repositories\maven2\.m2\repository\org\slf4j\slf4j-api\1.4.0\slf4j-
 ap
 i-1.4.0.jar
 snap



Hi Minto

I have reduced your output to show nothing but the test classpath that
is defined by your project.
As you can see, both target/classes and target/test-classes are
included.
(Twice, it seems.. kind of strange..)
Also your dependencies are listed.

The only stuff that is appended by Eclipse are the eclipse jars..
Note that compilation and running tests in Eclipse is done by Eclipse
itself, not by Maven.

If your custom classloader uses the system classloader for delegation,
there is no way to catch the additional libararies.
Since the sourceode of the classloader is already in your project, you
might as well adjust it.
Try using the context classloader as a parent instead.

Cheers
Jo


DISCLAIMER
De informatie in deze e-mail is vertrouwelijk en uitsluitend bestemd voor
de geadresseerde. Indien u niet de geadresseerde bent, wordt u er hierbij op
gewezen, dat u geen recht heeft kennis te nemen van de rest van deze e-mail,
deze te gebruiken, te kopieren of te verstrekken aan andere personen dan de
geadresseerde. Indien u deze e-mail abusievelijk hebt ontvangen, brengt u
dan alstublieft de afzender op de hoogte, waarbij u bij deze gevraagd wordt
het originele bericht te vernietigen. Politie Amsterdam-Amstelland is niet
verantwoordelijk voor de inhoud van deze e-mail en wijst iedere
aansprakelijkheid af voor en/of in verband met alle gevolgen en/of schade
van een onjuiste of onvolledige verzending ervan. Tenzij uitdrukkelijk het
tegendeel blijkt, kunnen aan dit bericht geen rechten worden ontleend. Het
gebruik van Internet e-mail brengt zekere risicos met zich. Daarom wordt
iedere aansprakelijkheid voor het gebruik van dit medium door de Politie
Amsterdam-Amstelland van de hand gewezen.

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




Re: [M2] Creating internal remote repsistory for Oracle ADF project

2007-06-08 Thread Andrew Birchall

Yeah I mentioned that in a previous reply.
Thanks
Andy

On 08/06/07, Wayne Fay [EMAIL PROTECTED] wrote:

There's also a free PDF better Builds with Maven book from
Mergere.com which is a big help as well.

Wayne

On 6/8/07, Andrew Birchall [EMAIL PROTECTED] wrote:
 Thanks Vanja that looks pretty good, though even here, they don't seem
 to mention mvn:deploy much. The section on Wagon and Repositories
 looks pretty good though, I'll take a closer look at it later.
 Cheers
 Andy

 On 08/06/07, Vanja Petreski [EMAIL PROTECTED] wrote:
  Hi,
 
  try with this one: http://www.sonatype.com/book/index.html ;)
 
  Vanja
 
  On 6/8/07, Andrew Birchall [EMAIL PROTECTED] wrote:
  
   Thanks a lot Wayne, that's great help.
  
   It does seem a lot of work to do this for every jar file the project
   depends on but I guess I can write a script to do it.
  
   I feel that the documentation for Maven is not that good. Its not very
   clear or well structured, making it hard to find what you need,
   especially for people who are new to it.
  
   For example, the Introduction to Repositories page
   (
   
http://maven.apache.org/guides/introduction/introduction-to-repositories.html
   ),
   which talks about Internal Repositories, contains no information about
   using mvn deploy:deploy-file.
  
   There's also hardly anything on this in the Better Build with Maven
   book from Mergere.
  
   I think this is a gap in the Maven documentation. But I also feel that
   the Maven documentation is weakness in the Maven project generally and
   probably hinders it's adoption.
  
   Thanks very much
   Andy Birchall
  
   On 07/06/07, Wayne Fay [EMAIL PROTECTED] wrote:
mvn install:install-file and mvn deploy:deploy-file are your friends
-- and they are very well-documented [1] [2] including a FAQ [3].
Assuming you have oc4j.jar and want to push it into the shared
corporate repo:
   
mvn deploy:deploy-file -DgroupId=com.oracle.jdevelope​r
-DartifactId=oc4j -Dversion=10.1.3.2 -Dpackaging=jar -Dfile=oc4j.jar
-DgeneratePom=true -DrepositoryId=your_id
-Durl=file://somewhere/m2/repo
   
You will have to pick the groupId, artifactId, version for all your
jars. Also, you will need to follow the directions regarding setting
up the repositoryId in your settings.xml and of course get the right
file:// path. But that's it.
   
Wayne
   
[1] http://maven.apache.org/plugin​s/maven-install-plugin/usage.ht​ml
[2] http://maven.apache.org/plugin​s/maven-deploy-plugin/usage.htm​l
[3] http://maven.apache.org/guides​/mini/guide-deploying-3rd-party​-
   jars.html
   
On 6/7/07, Andrew Birchall [EMAIL PROTECTED] wrote:
 Hello,
 I am trying to Mavenize a multi-module J2EE Oracle ADF project that is
 currently built with several Ant scripts and developed in JDeveloper
 10.1.3.2

 One of the main problems I have is that the project depends on many
 Artifacts (jar files) distributed with JDeveloper.

 Thus, In order to build this project with Maven I have to set up an
 internal repository in our company with all the JDeveloper jar files.
 At the moment I am trying to do this with the file:// protocol on a
 network share.

 However I'm not really sure the way to go about this and I can't seem
 to find any good documentation on it. Non of the jars distributed with
 JDeveloper are versioned. Do I have to version all the jar files
 myself and put them in the correct package directories, in order to
 conform to the Maven repository layout convention? How do I know what
 version to re-name the jar files to?

 If I do have to do this its a BIG and tedious job because there's so
 many dependencies. And what about the pom files for each jar, how do
 these get created?

 I'd be very grateful to hear from anyone who can help
 Kind regards
 Andy Birchall


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


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




Re: m2 assembly confusion

2007-06-08 Thread Kohsuke Kawaguchi


Maybe this has something to do with process reusing. Can you run

  hudson.maven.ProcessCache.MAX_CACHE=0;

to see if that fixes the problem?

Nigel Magnay wrote:

I have a project that is buildig in Hudson, that uses the m2 assembly plugin.

In the project pom, it explicitly sets the version of that plugin to 2.1.

It builds correctly from the commandline, and it mostly builds
correctly in hudson, but occasionally (I suspect it might be an update
issue), it fails - and it seems to be using / including the 2.2-beta-1
plugin AND the 2.1.

I don't know if this is a m2 bug, or a hudson bug, or a combination
(m2 2.0.5, hudson 1.106); attached is the build output:


[INFO] [jar:jar]
[INFO] Building jar:
e:\tomcat-home\.hudson\jobs\KES\workspace\trunk\sample-publication\workflow-guide-package\target\workflow-guide-package-2.0-SNAPSHOT.jar
-
this realm = 
app0.child-container[org.apache.maven.plugins:maven-assembly-plugin]
urls[0] = file:/C:/Documents and
Settings/tomcat/.m2/repository/org/apache/maven/plugins/maven-assembly-plugin/2.2-beta-1/maven-assembly-plugin-2.2-beta-1.jar
urls[1] = file:/C:/Documents and
Settings/tomcat/.m2/repository/org/apache/maven/plugins/maven-assembly-plugin/2.1/maven-assembly-plugin-2.1.jar
urls[2] = file:/C:/Documents and
Settings/tomcat/.m2/repository/org/codehaus/plexus/plexus-archiver/1.0-alpha-6/plexus-archiver-1.0-alpha-6.jar
urls[3] = file:/C:/Documents and
Settings/tomcat/.m2/repository/org/apache/maven/maven-archiver/2.0.4/maven-archiver-2.0.4.jar
urls[4] = file:/C:/Documents and
Settings/tomcat/.m2/repository/org/apache/maven/shared/file-management/1.0/file-management-1.0.jar
Number of imports: 0


this realm = plexus.core.maven
urls[0] = 
file:/E:/XAMPP/xampp/tomcat/webapps/hudson/WEB-INF/lib/maven-interceptor-1.106.jar
urls[1] = file:/c:/maven/lib/commons-cli-1.0.jar
urls[2] = file:/c:/maven/lib/doxia-sink-api-1.0-alpha-7.jar
urls[3] = file:/c:/maven/lib/jsch-0.1.27.jar
urls[4] = file:/c:/maven/lib/jtidy-4aug2000r7-dev.jar
urls[5] = file:/c:/maven/lib/maven-artifact-2.0.5.jar
urls[6] = file:/c:/maven/lib/maven-artifact-manager-2.0.5.jar
urls[7] = file:/c:/maven/lib/maven-core-2.0.5-javadoc.jar
urls[8] = file:/c:/maven/lib/maven-core-2.0.5.jar
urls[9] = file:/c:/maven/lib/maven-error-diagnostics-2.0.5.jar
urls[10] = file:/c:/maven/lib/maven-model-2.0.5.jar
urls[11] = file:/c:/maven/lib/maven-monitor-2.0.5.jar
urls[12] = file:/c:/maven/lib/maven-plugin-api-2.0.5.jar
urls[13] = file:/c:/maven/lib/maven-plugin-descriptor-2.0.5.jar
urls[14] = file:/c:/maven/lib/maven-plugin-parameter-documenter-2.0.5.jar
urls[15] = file:/c:/maven/lib/maven-plugin-registry-2.0.5.jar
urls[16] = file:/c:/maven/lib/maven-profile-2.0.5.jar
urls[17] = file:/c:/maven/lib/maven-project-2.0.5.jar
urls[18] = file:/c:/maven/lib/maven-reporting-api-2.0.5.jar
urls[19] = file:/c:/maven/lib/maven-repository-metadata-2.0.5.jar
urls[20] = file:/c:/maven/lib/maven-settings-2.0.5.jar
urls[21] = file:/c:/maven/lib/plexus-interactivity-api-1.0-alpha-4.jar
urls[22] = file:/c:/maven/lib/wagon-file-1.0-beta-2.jar
urls[23] = file:/c:/maven/lib/wagon-http-lightweight-1.0-beta-2.jar
urls[24] = file:/c:/maven/lib/wagon-http-shared-1.0-beta-2.jar
urls[25] = file:/c:/maven/lib/wagon-provider-api-1.0-beta-2.jar
urls[26] = file:/c:/maven/lib/wagon-ssh-1.0-beta-2.jar
urls[27] = file:/c:/maven/lib/wagon-ssh-common-1.0-beta-2.jar
urls[28] = file:/c:/maven/lib/wagon-ssh-external-1.0-beta-2.jar
urls[29] = file:/c:/maven/lib/xml-apis-1.0.b2.jar
urls[30] = file:/C:/Documents and
Settings/tomcat/.m2/repository/ant/ant/1.5/ant-1.5.jar
Number of imports: 0


this realm = plexus.core
urls[0] = file:/c:/maven/core/plexus-container-default-1.0-alpha-9.jar
urls[1] = file:/c:/maven/core/plexus-utils-1.1.jar
Number of imports: 0
-
[HUDSON] Archiving
e:\tomcat-home\.hudson\jobs\KES\workspace\trunk\sample-publication\workflow-guide-package\pom.xml
[HUDSON] Archiving
e:\tomcat-home\.hudson\jobs\KES\workspace\trunk\sample-publication\workflow-guide-package\target\workflow-guide-package-2.0-SNAPSHOT.jar
[INFO] 
[ERROR] BUILD ERROR
[INFO] 
[INFO] Internal error in the plugin manager executing goal
'org.apache.maven.plugins:maven-assembly-plugin:2.2-beta-1:attached':
Unable to find the mojo
'org.apache.maven.plugins:maven-assembly-plugin:2.2-beta-1:attached'
in the plugin 'org.apache.maven.plugins:maven-assembly-plugin'
org/codehaus/plexus/archiver/ArchiveFileFilter
[INFO] 

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





--
Kohsuke Kawaguchi
Sun Microsystems   [EMAIL PROTECTED]


smime.p7s

Re: [m2] Multi-project dependency issue

2007-06-08 Thread Wayne Fay

Ian, you must be doing something weird/wrong, or you're doing
something more complex than you're describing here, or you've got
dependencies declared wrong. There are a lot of us doing exactly what
you're describing with absolutely no problems at all.

Tell us the packaging of the children and any plugins you're running
during the compilation phase.

Wayne

On 6/8/07, Orford, Ian [EMAIL PROTECTED] wrote:

Yes to both.
Not only that, in the parent pom, the modules are listed in the order I
want them built - ie A,B,C,D


 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On Behalf Of Vandermeeren, Jo
 Sent: 08 June 2007 14:21
 To: Maven Users List
 Subject: Re: [m2] Multi-project dependency issue

 On 6/8/07, Orford, Ian [EMAIL PROTECTED] wrote:
 
  P is the parent POM that has modules A, B, C and D.
  P defines A, B, C and D in dependencyManagement A has P
 as a parent
  and no dependencies at all.
  B has P as a parent and defines A in dependencies C has P as a
  parent and defines A and B in dependencies D has P as a
 parent and
  defines C in dependencies
 
  Mvn install compiles A, then B. The trouble starts because it then
  moves onto D. Since C hasn't been installed, it fails.



 Hi Ian,

 Are you building from the directory that contains the parent pom.xml?
 Are modules A,B,C,D listed as modules in the parent pom.xml?

 Cheers
 Jo



--
This e-mail is confidential and the information contained in it may be 
privileged.  It should not be read, copied or used by anyone other than the 
intended recipient.  If you have received it in error, please contact the 
sender immediately by telephoning +44 (0)20 7623 8000 or by return email, and 
delete the e-mail and do not disclose its contents to any person.  We believe, 
but do not warrant, that this e-mail and any attachments are virus free, but 
you must take full responsibility for virus checking.  Please refer to 
http://www.dresdnerkleinwort.com/disc/email/ and read our e-mail disclaimer 
statement and monitoring policy.

Dresdner Kleinwort is the trading name of the investment banking division of 
Dresdner Bank AG, and operates through Dresdner Bank AG, Dresdner Kleinwort 
Limited, Dresdner Kleinwort Securities Limited and their affiliated or 
associated companies.  Dresdner Bank AG is a company incorporated in Germany 
with limited liability and registered in England (registered no. FC007638, 
place of business 30 Gresham Street, London EC2V 7PG), and is authorised by the 
German Federal Financial Supervisory Authority and by the Financial Services 
Authority ('FSA') and regulated by the FSA for the conduct of designated 
business in the UK.  Dresdner Kleinwort Limited is a company incorporated in 
England (registered no. 551334, registered office 30 Gresham Street, London 
EC2V 7PG), and is authorised and regulated by the FSA.  Dresdner Kleinwort 
Securities Limited is a company incorporated in England (registered no. 
1767419, registered office 30 Gresham Street, London EC2V 7PG), and is 
authorised and regulated by the FSA.


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



Use declared dependencies instead of jdk provided libs

2007-06-08 Thread Rodrigo Gonçalves

Hi...


I'm declaring in my POM to use saaj 1.2, but java 6 already has this lib 
with the version 1.3.

How can I configure my app to use the right version of that lib?

Regards,
Rodrigo.

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



Re: [m2] Error running genInterface for JDeveloper with AntRun

2007-06-08 Thread Wayne Fay

From my reading of it, commandlineArgs is a single String, whereas

arguments is a List of argument nodes. So delete all the
/commandlineArgscommandlineArgs so its one big string, and try
again.

If it wasn't totally obvious, I'm just guessing here, I haven't had to
do this myself (yet) for any projects.

Wayne

On 6/7/07, Mick Knutson [EMAIL PROTECTED] wrote:

Did not work:

arguments

!--argument-classpath=C:/jdevstudio1013/webservices/lib/argument--
commandlineArgs-jar
C:/jdevstudio1013/webservices/lib/wsa.jar/commandlineArgs
commandlineArgs-genInterface/commandlineArgs
commandlineArgs-output
${basedir}\target\classes/commandlineArgs
commandlineArgs-wsdl
${basedir}\src\main\webapp\WEB-INF\wsdl\BusinessService1.wsdl/commandlineArgs
commandlineArgs-packageName org.delta.services
/commandlineArgs
!--classpath/--
/arguments




DEBUG] -- end configuration --
INFO] [exec:exec {execution: default}]
DEBUG] executable java not found in place, assuming it is in the PATH.
INFO] Could not create the Java virtual machine.
INFO] Unrecognized option: -jar C:/jdevstudio1013/webservices/lib/wsa.jar
INFO]







On 6/7/07, Wayne Fay [EMAIL PROTECTED] wrote:

 As I suspected... the problem is not Maven but rather the way the exec
 plugin is surrounding your args with quotes.

 Reading the documentation [1], perhaps try commandlineArgs rather than
 arguments.
 [1] http://mojo.codehaus.org/exec-maven-plugin/exec-mojo.html

 Wayne

 On 6/7/07, Mick Knutson [EMAIL PROTECTED] wrote:
  Arg.
  When I put the quotes I get:
 
  Could not create the Java virtual machine.
 
  I have googled that but am still looking into that.. Ideas?
 
 
 
 
  On 6/7/07, Wayne Fay [EMAIL PROTECTED] wrote:
  
   How does it run when you add the quotes like you've got in Maven? I
   imagine, not very well.
  
   Wayne
  
   On 6/7/07, Mick Knutson [EMAIL PROTECTED] wrote:
I put a bat file together in the main DIR that looks like this:
---start-
REM set
   
  
 
WSLIBPATH=C:\viewstore\esp_lynx_dap\esp\dap\src\main\resources\maven\repository\com\oracle\lib
set WSLIBPATH=C:\jdevstudio1013\webservices\lib
   
set
   PRJPATH=C:\viewstore\esp_lynx_dap\esp\dap\poc\AOPTest\BusinessService
   
REMset CLASSPATH=%WSLIBPATH%;%CLASSPATH%
   
REM set PATH=C:\jdevstudio1013\jdk\bin;%PATH%
   
REM cd %PRJPATH%\src
   
java -jar %WSLIBPATH%/wsa.jar -genInterface -output
   %PRJPATH%/target/classes
-wsdl %PRJPATH%/src/main/webapp/WEB-INF/wsdl/BusinessService1.wsdl
-packageName org.delta.services
   
REM java -jar C:/jdevstudio1013/webservices/lib/wsa.jar -cp
C:/jdevstudio1013/webservices/lib -genInterface -output
 ./target/classes
-wsdl %PRJPATH%/src/main/webapp/WEB-INF/wsdl/BusinessService1.wsdl
-packageName org.delta.services
   
   
set /p status=Please hit ENTER to close window
---end
   
And it generates the files fine.
   
   
   
   
On 6/7/07, Wayne Fay [EMAIL PROTECTED] wrote:

 What happens when you run this manually from the same directory?

 java -jar
 C:/jdevstudio1013/webservices/lib/wsa.jar -cp
 C:/jdevstudio1013/webservices/lib -genInterface -output


  
 C:\viewstore\esp_lynx_dap\esp\dap\poc\AOPTest\BusinessService/target/classes
 -wsdl C:\viewstore\esp_lynx_dap\esp\dap\poc\AOPTest\Bu
 sinessService/src/main/webapp/WEB-INF/wsdl/BusinessService1.wsdl
 -packageName org.delta.services

 I would generally suspect that your problem is from the huge
 string
 encapsulate in quotes due to the single argument tag you've
 specific, and that you need to break that argument up a bit ie:
 arguments
 argument-jar/argument
 argumentC:/jdevstudio1013/webservices/lib/wsa.jar/argument
 argument-cp/argument
 etc

 Wayne

 On 6/7/07, Mick Knutson [EMAIL PROTECTED] wrote:
  Here is my declaration:
 
  plugin
  groupIdorg.codehaus.mojo/groupId
  artifactIdexec-maven-plugin/artifactId
  executions
  execution
  phasegenerate-sources/phase
  goals
  goalexec/goal
  /goals
  /execution
  /executions
  configuration
  executablejava/executable
  arguments
  argument-jar
  C:/jdevstudio1013/webservices/lib/wsa.jar -cp
  C:/jdevstudio1013/webservices/lib -genInterface -output
  ${basedir}/target/classes -wsdl
  ${basedir}/src/main/webapp/WEB-INF/wsdl/BusinessService1.wsdl

Re: .NET Frameworks support through Maven

2007-06-08 Thread Wendy Smoak

On 6/8/07, LP [EMAIL PROTECTED] wrote:


I am new to Maven . I am just trying to see whether I can use Maven to build
.NET Applications build on .NET FW 2.0/3.0 ?
Any Pointers will help .


You're in luck!  Work on that is under way over in the incubator:
http://incubator.apache.org/nmaven/

--
Wendy

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



Maven and Hibernate EntityManager

2007-06-08 Thread André Salvati

Hi,

I've tried to execute my unit tests with Maven an Maven 2.0.6 and 
Hibernate EntityManager and got problems.


I have two projects (project1 and project2). Project1 depends on project2.

It seems, for some reason, Maven doesn't find classes at 
*target/classes*. So, EntityManager doesn't detect these classes.


When I copy project1 and project2 classes to *target/test-classes* it 
works fine.


Am I doing something wrong?

I get an *org.hibernate.MappingException: Unknown entity: 
com.xpto.empresa.model.Empresa exception*


EntityManager's log:

13:58:52,796 INFO Version:15 - Hibernate EntityManager 3.2.1.GA
13:58:52,828 INFO Version:15 - Hibernate Annotations 3.2.1.GA
13:58:52,843 INFO Environment:509 - Hibernate 3.2.3
13:58:52,859 INFO Environment:542 - hibernate.properties not found
13:58:52,859 INFO Environment:676 - Bytecode provider name : cglib
13:58:52,875 INFO Environment:593 - using JDK 1.4 java.sql.Timestamp 
handling
13:58:53,015 DEBUG Ejb3Configuration:199 - Look up for persistence unit: 
empire
13:58:53,093 DEBUG DTDEntityResolver:38 - trying to resolve system-id 
[http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd]
13:58:53,093 DEBUG EJB3DTDEntityResolver:49 - recognized EJB3 ORM 
namespace; attempting to resolve on classpath under org/hibernate/ejb
13:58:53,093 DEBUG EJB3DTDEntityResolver:58 - located 
[http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd] in classpath
13:58:53,171 DEBUG Ejb3Configuration:544 - Detect class: true; detect 
hbm: false
*13:58:53,187 DEBUG JarVisitor:206 - Searching mapped entities in 
jar/par: file:/C:/workspace/empire/EmpresaEJB/target/test-classes

13:58:53,187 DEBUG JarVisitor:246 - Filtering: com.xpto.EmpresaTest
13:58:53,234 DEBUG Ejb3Configuration:544 - Detect class: true; detect 
hbm: false
13:58:53,234 DEBUG JarVisitor:206 - Searching mapped entities in 
jar/par: file:Agenda-1.0-SNAPSHOT.jar
13:58:53,234 WARN ExplodedJarVisitor:38 - Exploded jar does not exists 
(ignored): file:Agenda-1.0-SNAPSHOT.jar*


Thanks for any help.

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



Re: Programmatically finding dependencies

2007-06-08 Thread Roland Asmann
Thanks. I tried it, but unfortunately it resolves the transitive dependencies 
as well... So, I'm afraid I'll have to stick with my original solution.


On Tuesday 05 June 2007 21:30, Rune Flobakk wrote:
 I have recently been struggling with what I think is the same as you
 want. I am developing a plugin which in the plugin code I want to
 retrieve the plugin's, not the current project's, dependencies.

 I found the parameter expression I was after in this FAQ:
 http://docs.codehaus.org/display/MAVENUSER/FAQs-1#FAQs-1-HowdoIgetaplugin%2
7sdependenciesfromaMojo%3F


 This gives me the plugin's dependencies:

  /**
   * @parameter expression=${plugin.artifacts}
   * @required
   */
  protected ListArtifact pluginDependencyArtifacts;


 This gives me the local repository paths to each dependency:

  for( Artifact artifact : pluginDependencyArtifacts )
  getLog( artifact.getFile().getAbsolutePath() );


 Hope this is what you're after :)


 Rune



 --
 Thanks for the numerous replies.

  ${project.dependencies} ?

 The ${project.dependencies} is not the correct one, since it gives me the
 dependencies of the project, not the plugin! Also, it resolves the
 dependencies transitively!

   ArtifactoryFactory : interface
   ArtifactResolver : interface
  
   Where can we find the implementations? I already have a list of
   dependencies, just need resolve the full path for each dependency.
  
Use the information in the dependency list and an ArtifactFactory to
create
an Artifact with , then use an ArtifactResolver to resolve them fully.
Afterwards, you can call getFile(), to get the File objet.

 When using those interfaces, add something similar to these lines in your
 MOJO:

  /**
   * @component
 role=org.apache.maven.artifact.resolver.ArtifactResolver
   * @required
   * @readonly
   */
  private ArtifactResolver artifactResolver;

 Now, you can use

 artifactResolver.resolve(artifact)

 for you artifact (if it has not been resolved already), after which you can
 ask the artifact

 artifact.getFile()

 which will give you the full path to the JAR/POM/whatever file of this
 artifact.



 For my situation though (dependencies of the plugin), I use the following
 code:

 for (Object object : this.project.getPluginArtifacts()) {
  Artifact artifact = (Artifact) object;
  if (my.group.id.equals(artifact.getGroupId())
  myArtifactId.equals(artifact.getArtifactId())) {
  for (Object object2 :
 this.artifactMetadataSource.retrieve(artifact,
 this.localRepository,
 this.project.getRemoteArtifactRepositories()).getArtifacts()) {
  Artifact artifact2 = (Artifact) object2;
  this.artifactResolver.resolve(artifact2,
 this.project.getRemoteArtifactRepositories(), this.localRepository);
  JarFile jarFile = new JarFile(artifact2.getFile());
  JarEntry workflow = null;
  for (EnumerationJarEntry jarEntries = jarFile.entries();
 workflow == null  jarEntries.hasMoreElements();) {
  JarEntry jarEntry = jarEntries.nextElement();
  if (jarEntry.getName() != null 
 jarEntry.getName().endsWith(filename.extension)) {
  workflow = jarEntry;
  }
  }
  if (workflow != null) {
  workflowFiles.add(workflow.getName());
  }
  }
  }
 }

 In short, this code runs through the plugins until it finds the one I'm
 looking for (my.group.id  myArtifactId). It then retrieves this
 artifact
 from the repository and gets its dependencies.
 Those are resolved (to make sure all properties have been initialized -- eg
 fileName doesn't work without it) and opened as JAR-files (atm I'm sure
 they are JARs, but need to change this code to make sure it doesn't fail if
 they're not).
 I then iterate over the JAR to look for a specific file
 (filename.extension)
 and save the full names of the entry in a Map.

 This works like a charm for me, you just need to make sure you add all the
 right components in the MOJO.

 If anybody needs some more info/help, feel free to ask!

-- 
Roland Asmann

CFC Informationssysteme Entwicklungsgesellschaft m.b.H
Bäckerstrasse 1/2/7
A-1010 Wien
FN 266155f, Handelsgericht Wien

Tel.: +43/1/513 88 77 - 27
Fax.: +43/1/513 88 62
Email: [EMAIL PROTECTED]
Web: www.cfc.at

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



.NET Frameworks support through Maven

2007-06-08 Thread LP

Hi ,

I am new to Maven . I am just trying to see whether I can use Maven to build
.NET Applications build on .NET FW 2.0/3.0 ?
Any Pointers will help .

Thanks
LP


Re: [m2] Error running genInterface for JDeveloper with AntRun

2007-06-08 Thread Mick Knutson

Ive gotten a bit further, but still need some help

Here is what I have:

   plugin
   groupIdorg.codehaus.mojo/groupId
   artifactIdexec-maven-plugin/artifactId
   executions
   execution
   phasegenerate-sources/phase
   goals
   goaljava/goal
   /goals
   /execution
   /executions
   configuration
   executablejava/executable
   mainClassoracle.j2ee.ws.tools.wsa.Main/mainClass
   workingDirectory${basedir}/workingDirectory
   commandlineArgs
   -genInterface -output
${basedir}/target/gen-classes-wsdl
${basedir}/src/main/webapp/WEB-INF/wsdl/BusinessService1.wsdl -packageName
org.delta.services
   /commandlineArgs
   classpath/
   /configuration
   /plugin


Now when I run this, I get the following errors (slashes (/) seem to be
removed from ${basedir}

[DEBUG] Setting accessibility to true in order to invoke main().
Error: Specified file/directory
C:viewstoreesp_lynx_dapespdappocAOPTestBusinessService/src/main/webapp/WEB-INF/wsdl/BusinessService1.wsdldoes
not exist.

Any ideas why?






On 6/8/07, Wayne Fay [EMAIL PROTECTED] wrote:


From my reading of it, commandlineArgs is a single String, whereas
arguments is a List of argument nodes. So delete all the
/commandlineArgscommandlineArgs so its one big string, and try
again.

If it wasn't totally obvious, I'm just guessing here, I haven't had to
do this myself (yet) for any projects.

Wayne

On 6/7/07, Mick Knutson [EMAIL PROTECTED] wrote:
 Did not work:

 arguments

 !--argument-classpath=C:/jdevstudio1013/webservices/lib/argument--
 commandlineArgs-jar
 C:/jdevstudio1013/webservices/lib/wsa.jar/commandlineArgs
 commandlineArgs-genInterface/commandlineArgs
 commandlineArgs-output
 ${basedir}\target\classes/commandlineArgs
 commandlineArgs-wsdl

${basedir}\src\main\webapp\WEB-INF\wsdl\BusinessService1.wsdl/commandlineArgs
 commandlineArgs-packageName org.delta.services
 /commandlineArgs
 !--classpath/--
 /arguments




 DEBUG] -- end configuration --
 INFO] [exec:exec {execution: default}]
 DEBUG] executable java not found in place, assuming it is in the PATH.
 INFO] Could not create the Java virtual machine.
 INFO] Unrecognized option: -jar
C:/jdevstudio1013/webservices/lib/wsa.jar
 INFO]
 






 On 6/7/07, Wayne Fay [EMAIL PROTECTED] wrote:
 
  As I suspected... the problem is not Maven but rather the way the exec
  plugin is surrounding your args with quotes.
 
  Reading the documentation [1], perhaps try commandlineArgs rather than
  arguments.
  [1] http://mojo.codehaus.org/exec-maven-plugin/exec-mojo.html
 
  Wayne
 
  On 6/7/07, Mick Knutson [EMAIL PROTECTED] wrote:
   Arg.
   When I put the quotes I get:
  
   Could not create the Java virtual machine.
  
   I have googled that but am still looking into that.. Ideas?
  
  
  
  
   On 6/7/07, Wayne Fay [EMAIL PROTECTED] wrote:
   
How does it run when you add the quotes like you've got in Maven?
I
imagine, not very well.
   
Wayne
   
On 6/7/07, Mick Knutson [EMAIL PROTECTED] wrote:
 I put a bat file together in the main DIR that looks like this:
 ---start-
 REM set

   
 
WSLIBPATH=C:\viewstore\esp_lynx_dap\esp\dap\src\main\resources\maven\repository\com\oracle\lib
 set WSLIBPATH=C:\jdevstudio1013\webservices\lib

 set
   
PRJPATH=C:\viewstore\esp_lynx_dap\esp\dap\poc\AOPTest\BusinessService

 REMset CLASSPATH=%WSLIBPATH%;%CLASSPATH%

 REM set PATH=C:\jdevstudio1013\jdk\bin;%PATH%

 REM cd %PRJPATH%\src

 java -jar %WSLIBPATH%/wsa.jar -genInterface -output
%PRJPATH%/target/classes
 -wsdl
%PRJPATH%/src/main/webapp/WEB-INF/wsdl/BusinessService1.wsdl
 -packageName org.delta.services

 REM java -jar C:/jdevstudio1013/webservices/lib/wsa.jar -cp
 C:/jdevstudio1013/webservices/lib -genInterface -output
  ./target/classes
 -wsdl
%PRJPATH%/src/main/webapp/WEB-INF/wsdl/BusinessService1.wsdl
 -packageName org.delta.services


 set /p status=Please hit ENTER to close window
 ---end

 And it generates the files fine.




 On 6/7/07, Wayne Fay [EMAIL PROTECTED] wrote:
 
  What happens when you run this manually from the same
directory?
 
  java -jar
  C:/jdevstudio1013/webservices/lib/wsa.jar -cp
  C:/jdevstudio1013/webservices/lib -genInterface -output
 
 
   
 
C:\viewstore\esp_lynx_dap\esp\dap\poc\AOPTest\BusinessService/target/classes
  

Is there a plugin to generate launch scripts (.bat, .sh, etc.)

2007-06-08 Thread Jerome Thibaud

Hi All,
Is there a plugin to generate launch scripts (.bat, .sh, etc.)

regards

Jerome T.


Re: filtering issues in assembly plugin

2007-06-08 Thread Karan Malhi

**--nudge--**

On 6/8/07, Karan Malhi [EMAIL PROTECTED] wrote:

I have a module named assembly. I am using the assembly plugin 2.1 .
if i run maven from the parent project, then resources are not
filtered. if i run maven from the assembly module itself, resources
are filtered properly.
Any ideas why this would be happening?

--
Karan Malhi




--
Karan Malhi

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



[m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Mick Knutson

I have java and xml files being generated and I want to know where to put
them in order for them to be compiled and included into my war?

--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---


Re: Maven, CVS, Eclipse, and Continuum

2007-06-08 Thread Patrick Moore

Hi -

I have wondered this myself about Eclipse. Ideally, I would like to have
just one project and eclipse:eclipse create a single project in the top
level parent directory that combined all of the module dependencies into a
single .classpath file.

-Pat


Re: Is there a plugin to generate launch scripts (.bat, .sh, etc.)

2007-06-08 Thread Kaare Nilsen


On Jun 8, 2007, at 9:43 PM, Jerome Thibaud wrote:


Hi All,
Is there a plugin to generate launch scripts (.bat, .sh, etc.)


Check http://mojo.codehaus.org/appassembler/appassembler-maven-plugin/

But just be aware that the latest snapshot is very different from the  
released alpha, and there will be (in the somewhat near) future new  
documentation and release available




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



Re: Is there a plugin to generate launch scripts (.bat, .sh, etc.)

2007-06-08 Thread Mick Knutson

Im doing that now. genInterface.bat is in the root DIR:


   plugin
   groupIdorg.codehaus.mojo/groupId
   artifactIdexec-maven-plugin/artifactId
   executions
   execution
   phasegenerate-sources/phase
   goals
   goalexec/goal
   /goals
   /execution
   /executions
   configuration
   executablegenInterface.bat/executable
   /configuration
   /plugin





On 6/8/07, Kaare Nilsen [EMAIL PROTECTED] wrote:



On Jun 8, 2007, at 9:43 PM, Jerome Thibaud wrote:

 Hi All,
 Is there a plugin to generate launch scripts (.bat, .sh, etc.)

Check http://mojo.codehaus.org/appassembler/appassembler-maven-plugin/

But just be aware that the latest snapshot is very different from the
released alpha, and there will be (in the somewhat near) future new
documentation and release available



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





--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---


Re: [m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Jason van Zyl


On 8 Jun 07, at 4:27 PM 8 Jun 07, Mick Knutson wrote:

I have java and xml files being generated and I want to know where  
to put

them in order for them to be compiled and included into my war?



It's not where you put, but telling Maven there are new sources and  
new resources:


From the Antlr plugin:

  if ( project != null )
{
// Add resources
projectHelper.addResource( project,  
outputDirectory.getAbsolutePath(), Collections

.singletonList( **/**.txt ), new ArrayList() );

// Add source root
project.addCompileSourceRoot( outputDirectory.getAbsolutePath() );
}

Reference: http://svn.apache.org/repos/asf/maven/plugins/trunk/maven- 
antlr-plugin/src/main/java/org/apache/maven/plugin/antlr/ 
AbstractAntlrMojo.java


Typically you put generated sources in ${project.build.directory}/ 
generated-sources/short-plugin-id


So for the Antlr plugin this is target/generated-sources/antlr



--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---


Thanks,

Jason

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




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



Re: [m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Mick Knutson

Well, I added the source to ./target/generated-sources/*

With adding the includes to my compiler like this:

   plugin
   groupIdorg.apache.maven.plugins/groupId
   artifactIdmaven-compiler-plugin/artifactId
   configuration
   compilerVersion1.5/compilerVersion
   source1.5/source
   target1.5/target
   debug${compiler.debug}/debug
   showDeprecation${showDeprecation}/showDeprecation
   showWarnings${showWarnings}/showWarnings
   optimize${optimize}/optimize

   meminitial${meminitial}/meminitial
   maxmem${maxmem}/maxmem

   includes
   include${basedir}/src/main/java/include
   include${basedir}/src/test/java/include

include${basedir}/target/generated-sources/include
   /includes

   /configuration
   /plugin




I start getting test compilation errors.




On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:



On 8 Jun 07, at 4:27 PM 8 Jun 07, Mick Knutson wrote:

 I have java and xml files being generated and I want to know where
 to put
 them in order for them to be compiled and included into my war?


It's not where you put, but telling Maven there are new sources and
new resources:

From the Antlr plugin:

   if ( project != null )
 {
 // Add resources
 projectHelper.addResource( project,
outputDirectory.getAbsolutePath(), Collections
 .singletonList( **/**.txt ), new ArrayList() );

 // Add source root
project.addCompileSourceRoot( outputDirectory.getAbsolutePath()
);
 }

Reference: http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-
antlr-plugin/src/main/java/org/apache/maven/plugin/antlr/
AbstractAntlrMojo.java

Typically you put generated sources in ${project.build.directory}/
generated-sources/short-plugin-id

So for the Antlr plugin this is target/generated-sources/antlr


 --
 ---
 Thanks,
 Mick Knutson

 http://www.baselogic.com
 http://www.blincmagazine.com
 http://www.djmick.com
 http://www.myspace.com/mickknutson
 http://www.myspace.com/djmick_dot_com
 http://www.myspace.com/sexybeotches
 http://www.thumpradio.com
 ---

Thanks,

Jason

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




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





--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---


Re: [m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Jason van Zyl


On 8 Jun 07, at 5:02 PM 8 Jun 07, Mick Knutson wrote:


Well, I added the source to ./target/generated-sources/*



Look at the example I showed you. This will not work and is not  
recommended. Your plugin that generates the sources must use the  
reference of the MavenProject and add the resources and sources  
programmatically. You do not want to make everyone using your plugin  
have to configure this. Look at the Antlr plugin, which is the way  
you should be doing it.



With adding the includes to my compiler like this:

   plugin
   groupIdorg.apache.maven.plugins/groupId
   artifactIdmaven-compiler-plugin/artifactId
   configuration
   compilerVersion1.5/compilerVersion
   source1.5/source
   target1.5/target
   debug${compiler.debug}/debug
   showDeprecation${showDeprecation}/ 
showDeprecation

   showWarnings${showWarnings}/showWarnings
   optimize${optimize}/optimize

   meminitial${meminitial}/meminitial
   maxmem${maxmem}/maxmem

   includes
   include${basedir}/src/main/java/include
   include${basedir}/src/test/java/include

include${basedir}/target/generated-sources/include
   /includes

   /configuration
   /plugin




I start getting test compilation errors.




On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:



On 8 Jun 07, at 4:27 PM 8 Jun 07, Mick Knutson wrote:

 I have java and xml files being generated and I want to know where
 to put
 them in order for them to be compiled and included into my war?


It's not where you put, but telling Maven there are new sources and
new resources:

From the Antlr plugin:

   if ( project != null )
 {
 // Add resources
 projectHelper.addResource( project,
outputDirectory.getAbsolutePath(), Collections
 .singletonList( **/**.txt ), new ArrayList() );

 // Add source root
project.addCompileSourceRoot 
( outputDirectory.getAbsolutePath()

);
 }

Reference: http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-
antlr-plugin/src/main/java/org/apache/maven/plugin/antlr/
AbstractAntlrMojo.java

Typically you put generated sources in ${project.build.directory}/
generated-sources/short-plugin-id

So for the Antlr plugin this is target/generated-sources/antlr


 --
 ---
 Thanks,
 Mick Knutson

 http://www.baselogic.com
 http://www.blincmagazine.com
 http://www.djmick.com
 http://www.myspace.com/mickknutson
 http://www.myspace.com/djmick_dot_com
 http://www.myspace.com/sexybeotches
 http://www.thumpradio.com
 ---

Thanks,

Jason

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




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





--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---


Thanks,

Jason

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




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



Re: [m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Mick Knutson

But all I am doing is calling Oracle's  genInterface via a bat file




On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:



On 8 Jun 07, at 5:02 PM 8 Jun 07, Mick Knutson wrote:

 Well, I added the source to ./target/generated-sources/*


Look at the example I showed you. This will not work and is not
recommended. Your plugin that generates the sources must use the
reference of the MavenProject and add the resources and sources
programmatically. You do not want to make everyone using your plugin
have to configure this. Look at the Antlr plugin, which is the way
you should be doing it.

 With adding the includes to my compiler like this:

plugin
groupIdorg.apache.maven.plugins/groupId
artifactIdmaven-compiler-plugin/artifactId
configuration
compilerVersion1.5/compilerVersion
source1.5/source
target1.5/target
debug${compiler.debug}/debug
showDeprecation${showDeprecation}/
 showDeprecation
showWarnings${showWarnings}/showWarnings
optimize${optimize}/optimize

meminitial${meminitial}/meminitial
maxmem${maxmem}/maxmem

includes
include${basedir}/src/main/java/include
include${basedir}/src/test/java/include

 include${basedir}/target/generated-sources/include
/includes

/configuration
/plugin




 I start getting test compilation errors.




 On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:


 On 8 Jun 07, at 4:27 PM 8 Jun 07, Mick Knutson wrote:

  I have java and xml files being generated and I want to know where
  to put
  them in order for them to be compiled and included into my war?
 

 It's not where you put, but telling Maven there are new sources and
 new resources:

 From the Antlr plugin:

if ( project != null )
  {
  // Add resources
  projectHelper.addResource( project,
 outputDirectory.getAbsolutePath(), Collections
  .singletonList( **/**.txt ), new ArrayList() );

  // Add source root
 project.addCompileSourceRoot
 ( outputDirectory.getAbsolutePath()
 );
  }

 Reference: http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-
 antlr-plugin/src/main/java/org/apache/maven/plugin/antlr/
 AbstractAntlrMojo.java

 Typically you put generated sources in ${project.build.directory}/
 generated-sources/short-plugin-id

 So for the Antlr plugin this is target/generated-sources/antlr


  --
  ---
  Thanks,
  Mick Knutson
 
  http://www.baselogic.com
  http://www.blincmagazine.com
  http://www.djmick.com
  http://www.myspace.com/mickknutson
  http://www.myspace.com/djmick_dot_com
  http://www.myspace.com/sexybeotches
  http://www.thumpradio.com
  ---

 Thanks,

 Jason

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




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




 --
 ---
 Thanks,
 Mick Knutson

 http://www.baselogic.com
 http://www.blincmagazine.com
 http://www.djmick.com
 http://www.myspace.com/mickknutson
 http://www.myspace.com/djmick_dot_com
 http://www.myspace.com/sexybeotches
 http://www.thumpradio.com
 ---

Thanks,

Jason

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




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





--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---


Re: Is there a plugin to generate launch scripts (.bat, .sh, etc.)

2007-06-08 Thread Wayne Fay

Mick, he said generate not execute. ;-)

Wayne

On 6/8/07, Mick Knutson [EMAIL PROTECTED] wrote:

Im doing that now. genInterface.bat is in the root DIR:


plugin
groupIdorg.codehaus.mojo/groupId
artifactIdexec-maven-plugin/artifactId
executions
execution
phasegenerate-sources/phase
goals
goalexec/goal
/goals
/execution
/executions
configuration
executablegenInterface.bat/executable
/configuration
/plugin





On 6/8/07, Kaare Nilsen [EMAIL PROTECTED] wrote:


 On Jun 8, 2007, at 9:43 PM, Jerome Thibaud wrote:

  Hi All,
  Is there a plugin to generate launch scripts (.bat, .sh, etc.)

 Check http://mojo.codehaus.org/appassembler/appassembler-maven-plugin/

 But just be aware that the latest snapshot is very different from the
 released alpha, and there will be (in the somewhat near) future new
 documentation and release available



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




--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---



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



Re: Is there a plugin to generate launch scripts (.bat, .sh, etc.)

2007-06-08 Thread Mick Knutson

oops. Sorry bout that

On 6/8/07, Wayne Fay [EMAIL PROTECTED] wrote:


Mick, he said generate not execute. ;-)

Wayne

On 6/8/07, Mick Knutson [EMAIL PROTECTED] wrote:
 Im doing that now. genInterface.bat is in the root DIR:


 plugin
 groupIdorg.codehaus.mojo/groupId
 artifactIdexec-maven-plugin/artifactId
 executions
 execution
 phasegenerate-sources/phase
 goals
 goalexec/goal
 /goals
 /execution
 /executions
 configuration
 executablegenInterface.bat/executable
 /configuration
 /plugin





 On 6/8/07, Kaare Nilsen [EMAIL PROTECTED] wrote:
 
 
  On Jun 8, 2007, at 9:43 PM, Jerome Thibaud wrote:
 
   Hi All,
   Is there a plugin to generate launch scripts (.bat, .sh, etc.)
 
  Check http://mojo.codehaus.org/appassembler/appassembler-maven-plugin/
 
  But just be aware that the latest snapshot is very different from the
  released alpha, and there will be (in the somewhat near) future new
  documentation and release available
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 


 --
 ---
 Thanks,
 Mick Knutson

 http://www.baselogic.com
 http://www.blincmagazine.com
 http://www.djmick.com
 http://www.myspace.com/mickknutson
 http://www.myspace.com/djmick_dot_com
 http://www.myspace.com/sexybeotches
 http://www.thumpradio.com
 ---


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





--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---


Re: [m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Wayne Fay

You should make a real plugin. Its really simple. Then you can use
the add source root bit.

Wayne

On 6/8/07, Mick Knutson [EMAIL PROTECTED] wrote:

But all I am doing is calling Oracle's  genInterface via a bat file




On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:


 On 8 Jun 07, at 5:02 PM 8 Jun 07, Mick Knutson wrote:

  Well, I added the source to ./target/generated-sources/*
 

 Look at the example I showed you. This will not work and is not
 recommended. Your plugin that generates the sources must use the
 reference of the MavenProject and add the resources and sources
 programmatically. You do not want to make everyone using your plugin
 have to configure this. Look at the Antlr plugin, which is the way
 you should be doing it.

  With adding the includes to my compiler like this:
 
 plugin
 groupIdorg.apache.maven.plugins/groupId
 artifactIdmaven-compiler-plugin/artifactId
 configuration
 compilerVersion1.5/compilerVersion
 source1.5/source
 target1.5/target
 debug${compiler.debug}/debug
 showDeprecation${showDeprecation}/
  showDeprecation
 showWarnings${showWarnings}/showWarnings
 optimize${optimize}/optimize
 
 meminitial${meminitial}/meminitial
 maxmem${maxmem}/maxmem
 
 includes
 include${basedir}/src/main/java/include
 include${basedir}/src/test/java/include
 
  include${basedir}/target/generated-sources/include
 /includes
 
 /configuration
 /plugin
 
 
 
 
  I start getting test compilation errors.
 
 
 
 
  On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:
 
 
  On 8 Jun 07, at 4:27 PM 8 Jun 07, Mick Knutson wrote:
 
   I have java and xml files being generated and I want to know where
   to put
   them in order for them to be compiled and included into my war?
  
 
  It's not where you put, but telling Maven there are new sources and
  new resources:
 
  From the Antlr plugin:
 
 if ( project != null )
   {
   // Add resources
   projectHelper.addResource( project,
  outputDirectory.getAbsolutePath(), Collections
   .singletonList( **/**.txt ), new ArrayList() );
 
   // Add source root
  project.addCompileSourceRoot
  ( outputDirectory.getAbsolutePath()
  );
   }
 
  Reference: http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-
  antlr-plugin/src/main/java/org/apache/maven/plugin/antlr/
  AbstractAntlrMojo.java
 
  Typically you put generated sources in ${project.build.directory}/
  generated-sources/short-plugin-id
 
  So for the Antlr plugin this is target/generated-sources/antlr
 
 
   --
   ---
   Thanks,
   Mick Knutson
  
   http://www.baselogic.com
   http://www.blincmagazine.com
   http://www.djmick.com
   http://www.myspace.com/mickknutson
   http://www.myspace.com/djmick_dot_com
   http://www.myspace.com/sexybeotches
   http://www.thumpradio.com
   ---
 
  Thanks,
 
  Jason
 
  --
  Jason van Zyl
  Founder and PMC Chair, Apache Maven
  jason at sonatype dot com
  --
 
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
  --
  ---
  Thanks,
  Mick Knutson
 
  http://www.baselogic.com
  http://www.blincmagazine.com
  http://www.djmick.com
  http://www.myspace.com/mickknutson
  http://www.myspace.com/djmick_dot_com
  http://www.myspace.com/sexybeotches
  http://www.thumpradio.com
  ---

 Thanks,

 Jason

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




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




--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---



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



Re: [m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Mick Knutson

if this utility is putting my gen'd source into ./target/generated-source
then why do I need to create a plugin just to have maven compiler pick it
up?


On 6/8/07, Wayne Fay [EMAIL PROTECTED] wrote:


You should make a real plugin. Its really simple. Then you can use
the add source root bit.

Wayne

On 6/8/07, Mick Knutson [EMAIL PROTECTED] wrote:
 But all I am doing is calling Oracle's  genInterface via a bat file




 On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:
 
 
  On 8 Jun 07, at 5:02 PM 8 Jun 07, Mick Knutson wrote:
 
   Well, I added the source to ./target/generated-sources/*
  
 
  Look at the example I showed you. This will not work and is not
  recommended. Your plugin that generates the sources must use the
  reference of the MavenProject and add the resources and sources
  programmatically. You do not want to make everyone using your plugin
  have to configure this. Look at the Antlr plugin, which is the way
  you should be doing it.
 
   With adding the includes to my compiler like this:
  
  plugin
  groupIdorg.apache.maven.plugins/groupId
  artifactIdmaven-compiler-plugin/artifactId
  configuration
  compilerVersion1.5/compilerVersion
  source1.5/source
  target1.5/target
  debug${compiler.debug}/debug
  showDeprecation${showDeprecation}/
   showDeprecation
  showWarnings${showWarnings}/showWarnings
  optimize${optimize}/optimize
  
  meminitial${meminitial}/meminitial
  maxmem${maxmem}/maxmem
  
  includes
  include${basedir}/src/main/java/include
  include${basedir}/src/test/java/include
  
   include${basedir}/target/generated-sources/include
  /includes
  
  /configuration
  /plugin
  
  
  
  
   I start getting test compilation errors.
  
  
  
  
   On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:
  
  
   On 8 Jun 07, at 4:27 PM 8 Jun 07, Mick Knutson wrote:
  
I have java and xml files being generated and I want to know
where
to put
them in order for them to be compiled and included into my war?
   
  
   It's not where you put, but telling Maven there are new sources and
   new resources:
  
   From the Antlr plugin:
  
  if ( project != null )
{
// Add resources
projectHelper.addResource( project,
   outputDirectory.getAbsolutePath(), Collections
.singletonList( **/**.txt ), new ArrayList() );
  
// Add source root
   project.addCompileSourceRoot
   ( outputDirectory.getAbsolutePath()
   );
}
  
   Reference:
http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-
   antlr-plugin/src/main/java/org/apache/maven/plugin/antlr/
   AbstractAntlrMojo.java
  
   Typically you put generated sources in ${project.build.directory}/
   generated-sources/short-plugin-id
  
   So for the Antlr plugin this is target/generated-sources/antlr
  
  
--
---
Thanks,
Mick Knutson
   
http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---
  
   Thanks,
  
   Jason
  
   --
   Jason van Zyl
   Founder and PMC Chair, Apache Maven
   jason at sonatype dot com
   --
  
  
  
  
  
-
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  
  
   --
   ---
   Thanks,
   Mick Knutson
  
   http://www.baselogic.com
   http://www.blincmagazine.com
   http://www.djmick.com
   http://www.myspace.com/mickknutson
   http://www.myspace.com/djmick_dot_com
   http://www.myspace.com/sexybeotches
   http://www.thumpradio.com
   ---
 
  Thanks,
 
  Jason
 
  --
  Jason van Zyl
  Founder and PMC Chair, Apache Maven
  jason at sonatype dot com
  --
 
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 


 --
 ---
 Thanks,
 Mick Knutson

 http://www.baselogic.com
 http://www.blincmagazine.com
 http://www.djmick.com
 http://www.myspace.com/mickknutson
 http://www.myspace.com/djmick_dot_com
 http://www.myspace.com/sexybeotches
 http://www.thumpradio.com
 ---


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

Re: [m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Tom Huybrechts

Or use the build-helper plugin

http://mojo.codehaus.org/build-helper-maven-plugin/howto.html

On 6/8/07, Wayne Fay [EMAIL PROTECTED] wrote:

You should make a real plugin. Its really simple. Then you can use
the add source root bit.

Wayne

On 6/8/07, Mick Knutson [EMAIL PROTECTED] wrote:
 But all I am doing is calling Oracle's  genInterface via a bat file




 On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:
 
 
  On 8 Jun 07, at 5:02 PM 8 Jun 07, Mick Knutson wrote:
 
   Well, I added the source to ./target/generated-sources/*
  
 
  Look at the example I showed you. This will not work and is not
  recommended. Your plugin that generates the sources must use the
  reference of the MavenProject and add the resources and sources
  programmatically. You do not want to make everyone using your plugin
  have to configure this. Look at the Antlr plugin, which is the way
  you should be doing it.
 
   With adding the includes to my compiler like this:
  
  plugin
  groupIdorg.apache.maven.plugins/groupId
  artifactIdmaven-compiler-plugin/artifactId
  configuration
  compilerVersion1.5/compilerVersion
  source1.5/source
  target1.5/target
  debug${compiler.debug}/debug
  showDeprecation${showDeprecation}/
   showDeprecation
  showWarnings${showWarnings}/showWarnings
  optimize${optimize}/optimize
  
  meminitial${meminitial}/meminitial
  maxmem${maxmem}/maxmem
  
  includes
  include${basedir}/src/main/java/include
  include${basedir}/src/test/java/include
  
   include${basedir}/target/generated-sources/include
  /includes
  
  /configuration
  /plugin
  
  
  
  
   I start getting test compilation errors.
  
  
  
  
   On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:
  
  
   On 8 Jun 07, at 4:27 PM 8 Jun 07, Mick Knutson wrote:
  
I have java and xml files being generated and I want to know where
to put
them in order for them to be compiled and included into my war?
   
  
   It's not where you put, but telling Maven there are new sources and
   new resources:
  
   From the Antlr plugin:
  
  if ( project != null )
{
// Add resources
projectHelper.addResource( project,
   outputDirectory.getAbsolutePath(), Collections
.singletonList( **/**.txt ), new ArrayList() );
  
// Add source root
   project.addCompileSourceRoot
   ( outputDirectory.getAbsolutePath()
   );
}
  
   Reference: http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-
   antlr-plugin/src/main/java/org/apache/maven/plugin/antlr/
   AbstractAntlrMojo.java
  
   Typically you put generated sources in ${project.build.directory}/
   generated-sources/short-plugin-id
  
   So for the Antlr plugin this is target/generated-sources/antlr
  
  
--
---
Thanks,
Mick Knutson
   
http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---
  
   Thanks,
  
   Jason
  
   --
   Jason van Zyl
   Founder and PMC Chair, Apache Maven
   jason at sonatype dot com
   --
  
  
  
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  
  
   --
   ---
   Thanks,
   Mick Knutson
  
   http://www.baselogic.com
   http://www.blincmagazine.com
   http://www.djmick.com
   http://www.myspace.com/mickknutson
   http://www.myspace.com/djmick_dot_com
   http://www.myspace.com/sexybeotches
   http://www.thumpradio.com
   ---
 
  Thanks,
 
  Jason
 
  --
  Jason van Zyl
  Founder and PMC Chair, Apache Maven
  jason at sonatype dot com
  --
 
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 


 --
 ---
 Thanks,
 Mick Knutson

 http://www.baselogic.com
 http://www.blincmagazine.com
 http://www.djmick.com
 http://www.myspace.com/mickknutson
 http://www.myspace.com/djmick_dot_com
 http://www.myspace.com/sexybeotches
 http://www.thumpradio.com
 ---


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





Re: Is there a plugin to generate launch scripts (.bat, .sh, etc.)

2007-06-08 Thread Jerome Thibaud

Thanks for the pointers, I'll be trying it out.

regards

J.T.

On 6/8/07, Mick Knutson [EMAIL PROTECTED] wrote:


oops. Sorry bout that

On 6/8/07, Wayne Fay [EMAIL PROTECTED] wrote:

 Mick, he said generate not execute. ;-)

 Wayne

 On 6/8/07, Mick Knutson [EMAIL PROTECTED] wrote:
  Im doing that now. genInterface.bat is in the root DIR:
 
 
  plugin
  groupIdorg.codehaus.mojo/groupId
  artifactIdexec-maven-plugin/artifactId
  executions
  execution
  phasegenerate-sources/phase
  goals
  goalexec/goal
  /goals
  /execution
  /executions
  configuration
  executablegenInterface.bat/executable
  /configuration
  /plugin
 
 
 
 
 
  On 6/8/07, Kaare Nilsen [EMAIL PROTECTED] wrote:
  
  
   On Jun 8, 2007, at 9:43 PM, Jerome Thibaud wrote:
  
Hi All,
Is there a plugin to generate launch scripts (.bat, .sh, etc.)
  
   Check
http://mojo.codehaus.org/appassembler/appassembler-maven-plugin/
  
   But just be aware that the latest snapshot is very different from
the
   released alpha, and there will be (in the somewhat near) future new
   documentation and release available
  
  
  
  
-
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
 
  --
  ---
  Thanks,
  Mick Knutson
 
  http://www.baselogic.com
  http://www.blincmagazine.com
  http://www.djmick.com
  http://www.myspace.com/mickknutson
  http://www.myspace.com/djmick_dot_com
  http://www.myspace.com/sexybeotches
  http://www.thumpradio.com
  ---
 

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




--
---
Thanks,
Mick Knutson

http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---



Re: [m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Jason van Zyl

Perfect.

On 8 Jun 07, at 5:46 PM 8 Jun 07, Tom Huybrechts wrote:


Or use the build-helper plugin

http://mojo.codehaus.org/build-helper-maven-plugin/howto.html

On 6/8/07, Wayne Fay [EMAIL PROTECTED] wrote:

You should make a real plugin. Its really simple. Then you can use
the add source root bit.

Wayne

On 6/8/07, Mick Knutson [EMAIL PROTECTED] wrote:
 But all I am doing is calling Oracle's  genInterface via a bat file




 On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:
 
 
  On 8 Jun 07, at 5:02 PM 8 Jun 07, Mick Knutson wrote:
 
   Well, I added the source to ./target/generated-sources/*
  
 
  Look at the example I showed you. This will not work and is not
  recommended. Your plugin that generates the sources must use the
  reference of the MavenProject and add the resources and sources
  programmatically. You do not want to make everyone using your  
plugin
  have to configure this. Look at the Antlr plugin, which is the  
way

  you should be doing it.
 
   With adding the includes to my compiler like this:
  
  plugin
  groupIdorg.apache.maven.plugins/groupId
  artifactIdmaven-compiler-plugin/artifactId
  configuration
  compilerVersion1.5/compilerVersion
  source1.5/source
  target1.5/target
  debug${compiler.debug}/debug
  showDeprecation${showDeprecation}/
   showDeprecation
  showWarnings${showWarnings}/showWarnings
  optimize${optimize}/optimize
  
  meminitial${meminitial}/meminitial
  maxmem${maxmem}/maxmem
  
  includes
  include${basedir}/src/main/java/ 
include
  include${basedir}/src/test/java/ 
include

  
   include${basedir}/target/generated-sources/include
  /includes
  
  /configuration
  /plugin
  
  
  
  
   I start getting test compilation errors.
  
  
  
  
   On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:
  
  
   On 8 Jun 07, at 4:27 PM 8 Jun 07, Mick Knutson wrote:
  
I have java and xml files being generated and I want to  
know where

to put
them in order for them to be compiled and included into  
my war?

   
  
   It's not where you put, but telling Maven there are new  
sources and

   new resources:
  
   From the Antlr plugin:
  
  if ( project != null )
{
// Add resources
projectHelper.addResource( project,
   outputDirectory.getAbsolutePath(), Collections
.singletonList( **/**.txt ), new  
ArrayList() );

  
// Add source root
   project.addCompileSourceRoot
   ( outputDirectory.getAbsolutePath()
   );
}
  
   Reference: http://svn.apache.org/repos/asf/maven/plugins/ 
trunk/maven-

   antlr-plugin/src/main/java/org/apache/maven/plugin/antlr/
   AbstractAntlrMojo.java
  
   Typically you put generated sources in $ 
{project.build.directory}/

   generated-sources/short-plugin-id
  
   So for the Antlr plugin this is target/generated-sources/antlr
  
  
--
---
Thanks,
Mick Knutson
   
http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---
  
   Thanks,
  
   Jason
  
   --
   Jason van Zyl
   Founder and PMC Chair, Apache Maven
   jason at sonatype dot com
   --
  
  
  
  

-

   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  
  
   --
   ---
   Thanks,
   Mick Knutson
  
   http://www.baselogic.com
   http://www.blincmagazine.com
   http://www.djmick.com
   http://www.myspace.com/mickknutson
   http://www.myspace.com/djmick_dot_com
   http://www.myspace.com/sexybeotches
   http://www.thumpradio.com
   ---
 
  Thanks,
 
  Jason
 
  --
  Jason van Zyl
  Founder and PMC Chair, Apache Maven
  jason at sonatype dot com
  --
 
 
 
 
   
-

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


 --
 ---
 Thanks,
 Mick Knutson

 http://www.baselogic.com
 http://www.blincmagazine.com
 http://www.djmick.com
 http://www.myspace.com/mickknutson
 http://www.myspace.com/djmick_dot_com
 http://www.myspace.com/sexybeotches
 http://www.thumpradio.com
 ---


-
To 

Re: [m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Mick Knutson

I am trying that, but get an artifact error:


[0] inside the definition for plugin: 'build-helper-maven-plugin'specify the
following:

configuration
 ...
 artifactsVALUE/artifacts
/configuration.


Here is what I used:

   plugin
   groupIdorg.codehaus.mojo/groupId
   artifactIdbuild-helper-maven-plugin/artifactId
   executions
   execution
   idadd-source/id
   phasegenerate-sources/phase
   goals
   goaladd-source/goal
   /goals
   configuration
   sources

source${basedir}/target/generated-sources/source
   /sources
   /configuration
   /execution
   /executions
   /plugin




On 6/8/07, Tom Huybrechts [EMAIL PROTECTED] wrote:


Or use the build-helper plugin

http://mojo.codehaus.org/build-helper-maven-plugin/howto.html

On 6/8/07, Wayne Fay [EMAIL PROTECTED] wrote:
 You should make a real plugin. Its really simple. Then you can use
 the add source root bit.

 Wayne

 On 6/8/07, Mick Knutson [EMAIL PROTECTED] wrote:
  But all I am doing is calling Oracle's  genInterface via a bat file
 
 
 
 
  On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:
  
  
   On 8 Jun 07, at 5:02 PM 8 Jun 07, Mick Knutson wrote:
  
Well, I added the source to ./target/generated-sources/*
   
  
   Look at the example I showed you. This will not work and is not
   recommended. Your plugin that generates the sources must use the
   reference of the MavenProject and add the resources and sources
   programmatically. You do not want to make everyone using your plugin
   have to configure this. Look at the Antlr plugin, which is the way
   you should be doing it.
  
With adding the includes to my compiler like this:
   
   plugin
   groupIdorg.apache.maven.plugins/groupId
   artifactIdmaven-compiler-plugin/artifactId
   configuration
   compilerVersion1.5/compilerVersion
   source1.5/source
   target1.5/target
   debug${compiler.debug}/debug
   showDeprecation${showDeprecation}/
showDeprecation
   showWarnings${showWarnings}/showWarnings
   optimize${optimize}/optimize
   
   meminitial${meminitial}/meminitial
   maxmem${maxmem}/maxmem
   
   includes
   include${basedir}/src/main/java/include
   include${basedir}/src/test/java/include
   
include${basedir}/target/generated-sources/include
   /includes
   
   /configuration
   /plugin
   
   
   
   
I start getting test compilation errors.
   
   
   
   
On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:
   
   
On 8 Jun 07, at 4:27 PM 8 Jun 07, Mick Knutson wrote:
   
 I have java and xml files being generated and I want to know
where
 to put
 them in order for them to be compiled and included into my war?

   
It's not where you put, but telling Maven there are new sources
and
new resources:
   
From the Antlr plugin:
   
   if ( project != null )
 {
 // Add resources
 projectHelper.addResource( project,
outputDirectory.getAbsolutePath(), Collections
 .singletonList( **/**.txt ), new ArrayList()
);
   
 // Add source root
project.addCompileSourceRoot
( outputDirectory.getAbsolutePath()
);
 }
   
Reference:
http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-
antlr-plugin/src/main/java/org/apache/maven/plugin/antlr/
AbstractAntlrMojo.java
   
Typically you put generated sources in ${project.build.directory
}/
generated-sources/short-plugin-id
   
So for the Antlr plugin this is target/generated-sources/antlr
   
   
 --
 ---
 Thanks,
 Mick Knutson

 http://www.baselogic.com
 http://www.blincmagazine.com
 http://www.djmick.com
 http://www.myspace.com/mickknutson
 http://www.myspace.com/djmick_dot_com
 http://www.myspace.com/sexybeotches
 http://www.thumpradio.com
 ---
   
Thanks,
   
Jason
   
--
Jason van Zyl
Founder and PMC Chair, Apache Maven
jason at sonatype dot com
--
   
   
   
   
   
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
   
   
   
   
--
---
Thanks,
Mick Knutson
   

Re: [m2] where to put gen-src so it will get compiles and packaged...???

2007-06-08 Thread Mick Knutson

A bit further as I have the java files being compiled and added, but not my
xml file:

   plugin
   groupIdorg.codehaus.mojo/groupId
   artifactIdbuild-helper-maven-plugin/artifactId
   executions
   execution
   idadd-source/id
   phasegenerate-sources/phase
   goals
   goaladd-source/goal
   /goals
   configuration
   sources

source${basedir}/target/generated-sources/source
   /sources
   artifacts
 artifact
   file*/file
   typejava/type
   classifieroptional/classifier
 /artifact
   /artifacts
   /configuration
   /execution
   /executions
   /plugin



I have the following that need to be added to my war:

.\target\generated-sources\BusinessService1-java-wsdl-mapping.xml
.\target\generated-sources\org\delta\services\BusinessService1_PortType.java




On 6/8/07, Mick Knutson [EMAIL PROTECTED] wrote:


I am trying that, but get an artifact error:


[0] inside the definition for plugin: 'build-helper-maven-plugin'specify
the following:

configuration
  ...
  artifactsVALUE/artifacts
/configuration.


Here is what I used:

plugin
groupIdorg.codehaus.mojo/groupId
artifactIdbuild-helper-maven-plugin/artifactId
executions
execution
idadd-source/id
phasegenerate-sources/phase
goals
goaladd-source/goal
/goals
configuration
sources

source${basedir}/target/generated-sources/source
/sources
/configuration
/execution
/executions
/plugin




On 6/8/07, Tom Huybrechts [EMAIL PROTECTED] wrote:

 Or use the build-helper plugin

 http://mojo.codehaus.org/build-helper-maven-plugin/howto.html

 On 6/8/07, Wayne Fay  [EMAIL PROTECTED] wrote:
  You should make a real plugin. Its really simple. Then you can use
  the add source root bit.
 
  Wayne
 
  On 6/8/07, Mick Knutson  [EMAIL PROTECTED] wrote:
   But all I am doing is calling Oracle's  genInterface via a bat file
  
  
  
  
   On 6/8/07, Jason van Zyl  [EMAIL PROTECTED] wrote:
   
   
On 8 Jun 07, at 5:02 PM 8 Jun 07, Mick Knutson wrote:
   
 Well, I added the source to ./target/generated-sources/*

   
Look at the example I showed you. This will not work and is not
recommended. Your plugin that generates the sources must use the
reference of the MavenProject and add the resources and sources
programmatically. You do not want to make everyone using your
 plugin
have to configure this. Look at the Antlr plugin, which is the way
you should be doing it.
   
 With adding the includes to my compiler like this:

plugin
groupIdorg.apache.maven.plugins /groupId
artifactIdmaven-compiler-plugin/artifactId
configuration
compilerVersion 1.5/compilerVersion
source1.5/source
target1.5/target
debug${ compiler.debug}/debug
showDeprecation${showDeprecation}/
 showDeprecation
showWarnings${showWarnings}/showWarnings
optimize${optimize}/optimize

meminitial${meminitial}/meminitial
maxmem${maxmem}/maxmem

includes
   
 include${basedir}/src/main/java/include
   
 include${basedir}/src/test/java/include

 include${basedir}/target/generated-sources/include
/includes

/configuration
/plugin




 I start getting test compilation errors.




 On 6/8/07, Jason van Zyl [EMAIL PROTECTED] wrote:


 On 8 Jun 07, at 4:27 PM 8 Jun 07, Mick Knutson wrote:

  I have java and xml files being generated and I want to know
 where
  to put
  them in order for them to be compiled and included into my
 war?
 

 It's not where you put, but telling Maven there are new sources
 and
 new resources:

 From the Antlr plugin:

if ( project != null )
  {
  // Add resources
  projectHelper.addResource( project,
 outputDirectory.getAbsolutePath(), Collections
  

[site plugin]: How can i set the content of index?

2007-06-08 Thread CasMeiron

I want set (using apt, fml or xdoc) the content of index site, i tried a lot
of things but no success. Ive create folder named src/site/xdoc/index.xml
with the content for index and nothing.

How can i do that?
And, another question about site plugin, i have a multi-modules project,
when i run site:site in parent, all modules goes in modules section, its
ok, but the link for each module point to index.html (parent index), why? I
need declare each module pointing to moduleName/index.html ?

Tkz guys.

--
Paulo Cesar Silva Reis
---
Powered by GMAIL


Naming of SNAPSHOT artifacts

2007-06-08 Thread Vasil Benov

Hi all,

I would like to ask does anybody knows how maven names SNAPSHOT artifacts.

It sometimes names them SNAPSHOT, e.g. mylibrary-1.0-SNAPSHOT.jar, in
other occasions it names them
with the fully qualified snapshot name (if one can say so) , e.g. 
mylibrary-1.0-20070213.174414.jar.

This is extremely undesirable, in cases where one needs to do btach
processing and reference the jar
for example in a MANIFEST.MF file


Regards, Vasil


Re: Naming of SNAPSHOT artifacts

2007-06-08 Thread Wendy Smoak

On 6/8/07, Vasil Benov [EMAIL PROTECTED] wrote:


I would like to ask does anybody knows how maven names SNAPSHOT artifacts.

It sometimes names them SNAPSHOT, e.g. mylibrary-1.0-SNAPSHOT.jar, in
other occasions it names them
with the fully qualified snapshot name (if one can say so) , e.g. 
mylibrary-1.0-20070213.174414.jar.

This is extremely undesirable, in cases where one needs to do btach
processing and reference the jar
 for example in a MANIFEST.MF file


It's controlled by the uniqueVersion element in distributionManagement.

--
Wendy

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