Re: ejb-jar plug-in - Can we add dependency jars to ejb-jar.jar

2009-12-17 Thread Michal Galet

A workaround that works for me is:

  build
plugins
  plugin
groupIdorg.apache.maven.plugins/groupId
artifactIdmaven-dependency-plugin/artifactId
executions
  execution
phaseprocess-resources/phase
goals
  goalcopy-dependencies/goal
/goals
  /execution
/executions
configuration
  outputDirectorytarget/classes/outputDirectory
  includeScoperuntime/includeScope
/configuration
  /plugin


rajendar.medishetty wrote:
 
 In my current project, they use ant and pack all the jars inside the
 ejb-jar.jar.
 Now, they are thinking of migrating to maven from ant, but still want to
 pack the jars inside ejb-jar.jar.
 
 Is there anyway to do this without exploding the dependencies into my jar.
 
 Other way is to keep the jars in ear lib directory. But I don't want to do
 this because these jars are being used only by one ejb project and other
 ejb and web modules doesn't need these jars.
 
 

-- 
View this message in context: 
http://old.nabble.com/ejb-jar-plug-in---Can-we-add-dependency-jars-to-ejb-jar.jar-tp26433953p26825196.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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



Profile activation

2009-12-17 Thread Lukas Fryc

Hi guys,

I'm solving issue with issue with Maven 2.1.X,

I want to activate profile when two conditions are satisfied...

- file is missing
- property containerId isn't set

I used this:

activation
activeByDefaultfalse/activeByDefault
file
missing${demo.location}/missing
/file
property
namecontainerId/name
valuejboss5x/value
/property
/activation

But profile is activated when I'm trying to do

$ mvn verify -Dtest=...

(without any parameters and that file is missing in ${project.directory})


Article 11.4 from
http://www.sonatype.com/books/maven-book/reference/profiles-sect-activation.html
says, that this is possible.
-- 
View this message in context: 
http://old.nabble.com/Profile-activation-tp26826008p26826008.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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



RE: Profile activation

2009-12-17 Thread Martin Gainty

i would use the not on the property's name e.g.

  property
name!containerId/name
  /propertyMartin Gainty 
__ 
Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité 

Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger 
sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung 
oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem 
Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung. 
Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung 
fuer den Inhalt uebernehmen.
Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le 
destinataire prévu, nous te demandons avec bonté que pour satisfaire informez 
l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci est 
interdite. Ce message sert à l'information seulement et n'aura pas n'importe 
quel effet légalement obligatoire. Étant donné que les email peuvent facilement 
être sujets à la manipulation, nous ne pouvons accepter aucune responsabilité 
pour le contenu fourni.




 Date: Thu, 17 Dec 2009 02:31:41 -0800
 From: lf...@redhat.com
 To: users@maven.apache.org
 Subject: Profile activation
 
 
 Hi guys,
 
 I'm solving issue with issue with Maven 2.1.X,
 
 I want to activate profile when two conditions are satisfied...
 
 - file is missing
 - property containerId isn't set
 
 I used this:
 
 activation
   activeByDefaultfalse/activeByDefault
   file
   missing${demo.location}/missing
   /file
   property
   namecontainerId/name
   valuejboss5x/value
   /property
 /activation
 
 But profile is activated when I'm trying to do
 
 $ mvn verify -Dtest=...
 
 (without any parameters and that file is missing in ${project.directory})
 
 
 Article 11.4 from
 http://www.sonatype.com/books/maven-book/reference/profiles-sect-activation.html
 says, that this is possible.
 -- 
 View this message in context: 
 http://old.nabble.com/Profile-activation-tp26826008p26826008.html
 Sent from the Maven - Users mailing list archive at Nabble.com.
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
 For additional commands, e-mail: users-h...@maven.apache.org
 
  
_
Hotmail: Powerful Free email with security by Microsoft.
http://clk.atdmt.com/GBL/go/171222986/direct/01/

RE: Profile activation

2009-12-17 Thread Lukas Fryc

Thanks Martin,

I tried all of the possible combinations in property name/value, like:

propertynamecontainerId/name/property
propertyname!containerId/name/property
propertynamecontainerId/namevalue/value/property
propertynamecontainerId/namevalue!/value/property


mgainty wrote:
 
 
 i would use the not on the property's name e.g.
 
   property
 name!containerId/name
   /propertyMartin Gainty 
 __ 
 Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité 
 
 Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene
 Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte
 Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht
 dient lediglich dem Austausch von Informationen und entfaltet keine
 rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von
 E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen.
 Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le
 destinataire prévu, nous te demandons avec bonté que pour satisfaire
 informez l'expéditeur. N'importe quelle diffusion non autorisée ou la
 copie de ceci est interdite. Ce message sert à l'information seulement et
 n'aura pas n'importe quel effet légalement obligatoire. Étant donné que
 les email peuvent facilement être sujets à la manipulation, nous ne
 pouvons accepter aucune responsabilité pour le contenu fourni.
 
 
 
 
 Date: Thu, 17 Dec 2009 02:31:41 -0800
 From: lf...@redhat.com
 To: users@maven.apache.org
 Subject: Profile activation
 
 
 Hi guys,
 
 I'm solving issue with issue with Maven 2.1.X,
 
 I want to activate profile when two conditions are satisfied...
 
 - file is missing
 - property containerId isn't set
 
 I used this:
 
 activation
  activeByDefaultfalse/activeByDefault
  file
  missing${demo.location}/missing
  /file
  property
  namecontainerId/name
  valuejboss5x/value
  /property
 /activation
 
 But profile is activated when I'm trying to do
 
 $ mvn verify -Dtest=...
 
 (without any parameters and that file is missing in ${project.directory})
 
 
 Article 11.4 from
 http://www.sonatype.com/books/maven-book/reference/profiles-sect-activation.html
 says, that this is possible.
 -- 
 View this message in context:
 http://old.nabble.com/Profile-activation-tp26826008p26826008.html
 Sent from the Maven - Users mailing list archive at Nabble.com.
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
 For additional commands, e-mail: users-h...@maven.apache.org
 
 
 _
 Hotmail: Powerful Free email with security by Microsoft.
 http://clk.atdmt.com/GBL/go/171222986/direct/01/
 

-- 
View this message in context: 
http://old.nabble.com/Profile-activation-tp26826008p26827323.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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



RE: Profile activation

2009-12-17 Thread Lukas Fryc

Sorry, thanks for reply, but this resolution wouldn't help me. :-)


Lukas Fryc wrote:
 
 Thanks Martin,
 
 I tried all of the possible combinations in property name/value, like:
 
 propertynamecontainerId/name/property
 propertyname!containerId/name/property
 propertynamecontainerId/namevalue/value/property
 propertynamecontainerId/namevalue!/value/property
 
 
 mgainty wrote:
 
 
 i would use the not on the property's name e.g.
 
   property
 name!containerId/name
   /propertyMartin Gainty 
 __ 
 Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité 
 
 Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene
 Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede
 unbefugte Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese
 Nachricht dient lediglich dem Austausch von Informationen und entfaltet
 keine rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit
 von E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen.
 Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas
 le destinataire prévu, nous te demandons avec bonté que pour satisfaire
 informez l'expéditeur. N'importe quelle diffusion non autorisée ou la
 copie de ceci est interdite. Ce message sert à l'information seulement et
 n'aura pas n'importe quel effet légalement obligatoire. Étant donné que
 les email peuvent facilement être sujets à la manipulation, nous ne
 pouvons accepter aucune responsabilité pour le contenu fourni.
 
 
 
 
 Date: Thu, 17 Dec 2009 02:31:41 -0800
 From: lf...@redhat.com
 To: users@maven.apache.org
 Subject: Profile activation
 
 
 Hi guys,
 
 I'm solving issue with issue with Maven 2.1.X,
 
 I want to activate profile when two conditions are satisfied...
 
 - file is missing
 - property containerId isn't set
 
 I used this:
 
 activation
 activeByDefaultfalse/activeByDefault
 file
 missing${demo.location}/missing
 /file
 property
 namecontainerId/name
 valuejboss5x/value
 /property
 /activation
 
 But profile is activated when I'm trying to do
 
 $ mvn verify -Dtest=...
 
 (without any parameters and that file is missing in
 ${project.directory})
 
 
 Article 11.4 from
 http://www.sonatype.com/books/maven-book/reference/profiles-sect-activation.html
 says, that this is possible.
 -- 
 View this message in context:
 http://old.nabble.com/Profile-activation-tp26826008p26826008.html
 Sent from the Maven - Users mailing list archive at Nabble.com.
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
 For additional commands, e-mail: users-h...@maven.apache.org
 

 _
 Hotmail: Powerful Free email with security by Microsoft.
 http://clk.atdmt.com/GBL/go/171222986/direct/01/
 
 
 

-- 
View this message in context: 
http://old.nabble.com/Profile-activation-tp26826008p26827348.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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



Re: How to deploy JiBX Maven project from Ant specifications

2009-12-17 Thread John Prystash
Glad you got a bit farther.  The exception cites line 51, which line is that 
from your method?  I agree there doesn't look like much to go on from the 
exception.
Could you get the XML the method is seeing logged perhaps, or the value of the 
src parameter?  Maybe inspect the cause and message of the exception in catch 
block?





From: Kenneth Henriksen phecda...@gmail.com
To: Maven Users List users@maven.apache.org
Sent: Wed, December 16, 2009 7:04:42 PM
Subject: Re: How to deploy JiBX Maven project from Ant specifications

Thank you for your answer John. I believe the TerrorMapping.xml is now
included.

I still get this error when deploying on ServiceMix though:

javax.jms.JMSException: Error sending JBI exchange
at
org.apache.servicemix.jms.endpoints.AbstractConsumerEndpoint.onMessage(AbstractConsumerEndpoint.java:575)
at
org.apache.servicemix.jms.endpoints.JmsConsumerEndpoint$1.onMessage(JmsConsumerEndpoint.java:505)
at
org.springframework.jms.listener.AbstractMessageListenerContainer.doInvokeListener(AbstractMessageListenerContainer.java:518)
at
org.springframework.jms.listener.AbstractMessageListenerContainer.invokeListener(AbstractMessageListenerContainer.java:479)
at
org.springframework.jms.listener.AbstractMessageListenerContainer.doExecuteListener(AbstractMessageListenerContainer.java:451)
at
org.springframework.jms.listener.AbstractPollingMessageListenerContainer.doReceiveAndExecute(AbstractPollingMessageListenerContainer.java:323)
at
org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveAndExecute(AbstractPollingMessageListenerContainer.java:261)
at
org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:982)
at
org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.executeOngoingLoop(DefaultMessageListenerContainer.java:974)
at
org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:876)
at java.lang.Thread.run(Thread.java:619)
Caused by: org.jibx.runtime.JiBXException: Error marshalling XML to Object
at terror.util.JiBXUtil.marshalDocument(JiBXUtil.java:51)
at
terror.util.TerrorJMSMarshaler.populateMessage(TerrorJMSMarshaler.java:19)
at
org.apache.servicemix.jms.endpoints.DefaultConsumerMarshaler.createExchange(DefaultConsumerMarshaler.java:99)
at
org.apache.servicemix.jms.endpoints.AbstractConsumerEndpoint.onMessage(AbstractConsumerEndpoint.java:544)
... 10 more

The queue I'm sending the TerrorTypeRequest1 object to is defined like
this:


   xmlns:fork=http://henriksenweb.com/FORK;

.

  jms:consumer service=fork:terrorReceiver
   endpoint=jmsEndpoint
   targetService=fork:terrorDSLRouter
   destinationName=terror.in
   connectionFactory=#connectionFactory
   marshaler=#TerrorJMSMarshaler/

/beans

The JiBXUtil.marshalDocument function is defined like this:

public static Source marshalDocument(Object src, String encoding) throws
JiBXException {
  Source result = null;
  try {
   ByteArrayOutputStream bOut = new ByteArrayOutputStream();
   IMarshallingContext ctx =
BindingDirectory.getFactory(src.getClass()).createMarshallingContext();
   ctx.marshalDocument(src, UTF-8, null, bOut);
   result = new StreamSource(new ByteArrayInputStream(bOut.toByteArray()));
  }
  catch (Exception e) {
   throw new JiBXException(Error marshalling XML to Object,e);
  }
  return result;
}

The relevant part of the TerrorMapping.xml:

mapping name=TerrorType1Request class=terror.model.TerrorType1Request
ns=http://henriksenweb.com/terror;
   namespace uri=http://henriksenweb.com/terror; default=elements/
value name=buildYear field=buildYear/
value name=carType field=carType/
value name=companyCar field=companyCar/
value name=numberPlate field=numberPlate/
value name=requestID field=requestID/
value name=startDate field=startDate
serializer=terror.util.DateJiBXSerializer.serialize
deserializer=terror.util.DateJiBXSerializer.deserialize/
/mapping

And finally the object I'm sending is an instance of the (simple) class
TerrorType1Request:


import java.io.Serializable;
import java.util.Date;

public class TerrorType1Request implements Serializable {

private static final long serialVersionUID = -507216273438778375L;
private String requestID;
private String numberPlate;
private String carType;
private int buildYear;
private boolean companyCar;
private Date startDate;

public String getRequestID() {
  return requestID;
}
public void setRequestID(String requestID) {
  this.requestID = requestID;
}
public String getNumberPlate() {
  return numberPlate;
}
public void setNumberPlate(String numberPlate) {
  this.numberPlate = numberPlate;
}
public String getCarType() {
  

Re: Profile activation

2009-12-17 Thread Dennis Lundberg
From a recently updated
http://maven.apache.org/guides/introduction/introduction-to-profiles.html

As of Maven 2.0.9, the tags exists and missing could be
interpolated. Supported variables are system properties like
${user.home} and enviroment variables like ${env.HOME}. Please note that
properties defined in the POM itself are not available for interpolation
here.

Is this what you are running into?

Lukas Fryc wrote:
 Hi guys,
 
 I'm solving issue with issue with Maven 2.1.X,
 
 I want to activate profile when two conditions are satisfied...
 
 - file is missing
 - property containerId isn't set
 
 I used this:
 
 activation
   activeByDefaultfalse/activeByDefault
   file
   missing${demo.location}/missing
   /file
   property
   namecontainerId/name
   valuejboss5x/value
   /property
 /activation
 
 But profile is activated when I'm trying to do
 
 $ mvn verify -Dtest=...
 
 (without any parameters and that file is missing in ${project.directory})
 
 
 Article 11.4 from
 http://www.sonatype.com/books/maven-book/reference/profiles-sect-activation.html
 says, that this is possible.


-- 
Dennis Lundberg

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



Re: maven install gives the following errors

2009-12-17 Thread veena pandit
Great!  Wayne thanks that fixed it.  Now could you please tell me how
I run the project.
If I right click on the project in eclipse and select run
configurations and try to run it on
Tomcat it is not deployed there.

Thanks,

Veena

On Wed, Dec 16, 2009 at 7:15 PM, Wayne Fay wayne...@gmail.com wrote:
 Where do I make the change?

 In your pom.xml file.

 And what about the other missing library?

 There was no other missing library in your log.

 Wayne

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



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



enforce dependency to be set to provided

2009-12-17 Thread Marco Beelen
Hello,

For my portal I'm going to write various web-application and I want them to 
reuse various libraries provided by my portal server. All the webapp project 
have the same parent. In order to prevent the webapps to include the dependency 
in the WEB-INF\lib, I wan't to configure a rule in the parent pom, where I ban 
some library (log4j:log4j). The webapp are allowed to use the dependency, but 
only when the scope is set to provided.

I tried the bannedDependency configuration like this:


bannedDependencies

  searchTransitivetrue/searchTransitive

  excludes

excludelog4j:log4j/exclude

  /excludes

  includes

includelog4j:log4j:*:provided/include

  /includes

/bannedDependencies


That doesn't work, because when I build a webapp with the log4j dependency on 
compile scope, the enforcer plugin doesn't cause my build to fail, which I 
would like it to.

Any suggestions how to handle this?

With kind regards,
Marco


Marco Beelen
Software-architect
+31(0)6 55 145 554

IPROFS
Claus Sluterweg 125
2012 WS Haarlem
www.iprofs.nlhttp://www.iprofs.nl/
+31 (0)23 547 6369





WAR/JAR sync deploy for GWT modules

2009-12-17 Thread Darren Hartford
Hi all,
I am building GWT modules. A GWT module may be used on it's own (as a WAR), and 
other times is a dependency for a larger project (as a binary JAR).

I've tried this approach here: 
http://communitygrids.blogspot.com/2007/11/maven-making-war-and-jar-at-same-time.html

Unfortunatley, it looks like the maven-metadata.xml, or something else in the 
repository world, doesn't recognize both a WAR and a JAR at the same time when 
we try to pull back from the repo.  When I go to the repo, the WAR and the JAR 
have different file date/times, which may or may not matter to the 
maven-metadata.xml -- this is all guessing at this point.

In any fashion, trying to search on how to solve this problem has been a 
nightmare in itself -- any guidance please?

thanks,
-D


  


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



Re: Transitive dependency omitted if prior dependency resolved first then subsquently omitted

2009-12-17 Thread egroesbeck

In the situation I outlined the transitive dependency should truly be
transitive, not direct.  However the transitive dependency is picked up
twice yet omitted because the first artifact where it is detected is
eventually omitted.  The fact that I can change the dependency order in
artifact A and get a different list of resolved artifacts leads me to
believe this is more likely to be a defect but I wanted to be sure I
understood the dependency resolution algorithm correctly first.  

dependency:analyze would flag artifact D as unused.  My understanding is the
the dependency to artifact E via artifact B should bring resolution to
artifact D.


Anders Hammar wrote:
 
 I don't understand. Are you saying you have a dependency on a transitive
 dependency? That's wrong! You should declare all your dependencies as
 dependencies; you shouldn't rely on transitive dependencies.
 
 Try
 mvn dependency:analyze
 and fix missing dependencies!
 
 /Anders
 
 On Wed, Dec 16, 2009 at 22:14, egroesbeck dre...@yahoo.com wrote:
 

 Problem: a transitive dependency is found in a graph multiple times but
 the
 first artifact that depends on it is omitted for a higher version which
 no
 longer has the transitive dependency.  This causes the final artifact
 list
 to no longer include the transitive dependency even it other dependencies
 depend on it.

 I've included the graph and results of dependency:tree as reference.
 Changing the dependency order in project A to depend on E then C resolves
 the issue as well as managing C to 2.0.0 (the version that eventually is
 resolved).  However as the graph grows larger this becomes burdensome.  I
 didn't find this situation described in the dependency mechanism
 documentation and managing all the dependencies to match the declared
 versions felt like overkill.  Is this behavior correct?

 Tested with Maven versions: 2.0.10, 2.2.1, 3.0-alpha-5

 Dependency graph:
 A-B-C-1.0.0-SNAPSHOT-D
 A-C-2.0.0-SNAPSHOT
 B-E-D

 Result of dependency:tree -Dverbose:
 [INFO] test.projects:projectA:jar:2.0.0-SNAPSHOT
 [INFO] +- test.projects:projectB:jar:1.0.0-SNAPSHOT:compile
 [INFO] |  +- (test.projects:projectC:jar:1.0.0-SNAPSHOT:compile - omitted
 for conflict with 2.0.0-SNAPSHOT)
 [INFO] |  \- test.projects:projectE:jar:1.0.0-SNAPSHOT:compile
 [INFO] | \- (test.projects:projectD:jar:1.0.0-SNAPSHOT:compile -
 omitted
 for duplicate)
 [INFO] \- test.projects:projectC:jar:2.0.0-SNAPSHOT:compile

 Result of dependency:tree -Dverbose -X:
 [INFO] [dependency:tree {execution: default-cli}]
 [DEBUG] Dependency tree resolution listener events:
 [DEBUG] testArtifact: artifact=test.projects:projectA:jar:2.0.0-SNAPSHOT
 [DEBUG] includeArtifact:
 artifact=test.projects:projectA:jar:2.0.0-SNAPSHOT
 [DEBUG] startProcessChildren:
 artifact=test.projects:projectA:jar:2.0.0-SNAPSHOT
 [DEBUG]   testArtifact:
 artifact=test.projects:projectB:jar:1.0.0-SNAPSHOT:compile
 [DEBUG]   includeArtifact:
 artifact=test.projects:projectB:jar:1.0.0-SNAPSHOT:compile
 [DEBUG]   startProcessChildren:
 artifact=test.projects:projectB:jar:1.0.0-SNAPSHOT:compile
 [DEBUG] testArtifact:
 artifact=test.projects:projectC:jar:1.0.0-SNAPSHOT:compile
 [DEBUG] includeArtifact:
 artifact=test.projects:projectC:jar:1.0.0-SNAPSHOT:compile
 [DEBUG] startProcessChildren:
 artifact=test.projects:projectC:jar:1.0.0-SNAPSHOT:compile
 [DEBUG]   testArtifact:
 artifact=test.projects:projectD:jar:1.0.0-SNAPSHOT:compile
 [DEBUG]   includeArtifact:
 artifact=test.projects:projectD:jar:1.0.0-SNAPSHOT:compile
 [DEBUG]   startProcessChildren:
 artifact=test.projects:projectD:jar:1.0.0-SNAPSHOT:compile
 [DEBUG]   endProcessChildren:
 artifact=test.projects:projectD:jar:1.0.0-SNAPSHOT:compile
 [DEBUG] endProcessChildren:
 artifact=test.projects:projectC:jar:1.0.0-SNAPSHOT:compile
 [DEBUG] testArtifact:
 artifact=test.projects:projectE:jar:1.0.0-SNAPSHOT:compile
 [DEBUG] includeArtifact:
 artifact=test.projects:projectE:jar:1.0.0-SNAPSHOT:compile
 [DEBUG] startProcessChildren:
 artifact=test.projects:projectE:jar:1.0.0-SNAPSHOT:compile
 [DEBUG]   testArtifact:
 artifact=test.projects:projectD:jar:1.0.0-SNAPSHOT:compile
 [DEBUG]   omitForNearer:
 omitted=test.projects:projectD:jar:1.0.0-SNAPSHOT:compile
 kept=test.projects:projectD:jar:1
 .0.0-SNAPSHOT:compile
 [DEBUG] endProcessChildren:
 artifact=test.projects:projectE:jar:1.0.0-SNAPSHOT:compile
 [DEBUG]   endProcessChildren:
 artifact=test.projects:projectB:jar:1.0.0-SNAPSHOT:compile
 [DEBUG]   testArtifact:
 artifact=test.projects:projectC:jar:2.0.0-SNAPSHOT:compile
 [DEBUG]   omitForNearer:
 omitted=test.projects:projectC:jar:1.0.0-SNAPSHOT:compile
 kept=test.projects:projectC:jar:2.0.0
 -SNAPSHOT:compile
 [DEBUG]   includeArtifact:
 artifact=test.projects:projectC:jar:2.0.0-SNAPSHOT:compile
 [DEBUG]   startProcessChildren:
 artifact=test.projects:projectC:jar:2.0.0-SNAPSHOT:compile
 [DEBUG]   endProcessChildren:
 

Re: WAR/JAR sync deploy for GWT modules

2009-12-17 Thread Justin Edelson
Since you're not actually describing the problem you're having, it's 
hard to say what the solution might be. But I do know that the URL you 
posted below describes a terribly convoluted non-solution. The only 
thing you need to do to create a JAR file containing the classes AND get 
it installed in your local repository AND get it deployed to the remote 
repository (at the appropriate lifecycle phases) is this:


plugin
artifactIdmaven-war-plugin/artifactId
configuration
attachClassestrue/attachClasses
/configuration
/plugin

Any time you're using install-file or deploy-file inside your pom, 
something is wrong.


HTH,
Justin


On 12/17/09 9:49 AM, Darren Hartford wrote:

Hi all,
I am building GWT modules. A GWT module may be used on it's own (as a WAR), and 
other times is a dependency for a larger project (as a binary JAR).

I've tried this approach here: 
http://communitygrids.blogspot.com/2007/11/maven-making-war-and-jar-at-same-time.html

Unfortunatley, it looks like the maven-metadata.xml, or something else in the 
repository world, doesn't recognize both a WAR and a JAR at the same time when 
we try to pull back from the repo.  When I go to the repo, the WAR and the JAR 
have different file date/times, which may or may not matter to the 
maven-metadata.xml -- this is all guessing at this point.

In any fashion, trying to search on how to solve this problem has been a 
nightmare in itself -- any guidance please?

thanks,
-D





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

   



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



Tomcat plugin doesn't seem to be using build final name for context (seems to always use artifactId)

2009-12-17 Thread Rick R
I'm confused here. The docs
http://mojo.codehaus.org/tomcat-maven-plugin/usage.html state that the
default context is
Context path of /${project.build.finalName} if no explicit one is given.

In my war pom I have:

artifactIddataselector-web/artifactId

but I later have

build
 finalNamedataselector/finalName

The war builds fine to the name dataselector.war and I can manually
deploy it just fine, yet when I try to use the tomcat plugin it tries
to deploy to the context dataselector-web which is the artificatId and
not the finalName.

What did I do wrong? I don't mind declaring the name in the tomcat
module config but all the examples I see show a hardcoded path for the
context. I dont' want to to hardcode that context path (eg
/Users/rick/tomcat/webapps/dataselector )


--
Rick R

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



RE: Tomcat plugin doesn't seem to be using build final name for context (seems to always use artifactId)

2009-12-17 Thread Martin Gainty

//AbstractDeployMojo details

package org.codehaus.mojo.tomcat;
/*
 * Licensed to the Apache Software Foundation (ASF) under one
 * or more contributor license agreements.  See the NOTICE file
 * distributed with this work for additional information
 * regarding copyright ownership.  The ASF licenses this file
 * to you under the Apache License, Version 2.0 (the
 * License); you may not use this file except in compliance
 * with the License.  You may obtain a copy of the License at
 *   http://www.apache.org/licenses/LICENSE-2.0
 * Unless required by applicable law or agreed to in writing,
 * software distributed under the License is distributed on an
 * AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 * KIND, either express or implied.  See the License for the
 * specific language governing permissions and limitations
 * under the License.
 */

import java.io.File;
import java.io.IOException;
import java.net.URL;
import org.apache.maven.plugin.MojoExecutionException;

/*** Deploy a WAR to Tomcat. 
 * @author Mark Hobson markhob...@gmail.com
 * @version $Id: AbstractDeployMojo.java 8855 2009-01-21 11:23:04Z olamy $
 */
public abstract class AbstractDeployMojo
extends AbstractWarCatalinaMojo
{
// --
// Mojo Parameters
// --

/**
 * The deployment mode to use. This must be either codewar/code to 
deploy the war, codecontext/code to
 * deploy the context XML file, or codeboth/code to deploy the war with 
the context XML file.
 * 
 * @parameter expression = ${maven.tomcat.mode} default-value = war
 * @required
 */
private String mode;

/**
 * The path of the Tomcat context XML file. This is not used for war 
deployment mode.
*
 * Question how does project.build.finalName get baked into this folder 
name???
 *
 * @parameter expression = 
${project.build.directory}/${project.build.finalName}/META-INF/context.xml
 */
private File contextFile;

/**
 * Whether Tomcat should automatically undeploy webapps that already exist 
when deploying.
 * 
 * @parameter expression = ${maven.tomcat.update} default-value = false
 * @required
 */
private boolean update;

/**
 * The Tomcat webapp tag name to use.
 * 
 * @parameter expression = ${maven.tomcat.tag}
 */
private String tag;

// --
// Protected Methods
// --

/**
 * {...@inheritdoc}
 */
@Override
public void invokeManager()
throws MojoExecutionException, TomcatManagerException, IOException
{
if ( war.equals( mode ) )
{
deployWar();
}
else if ( context.equals( mode ) )
{
deployContext();
}
else if ( both.equals( mode ) )
{
deployWarAndContext();
}
else
{
throw new MojoExecutionException( getMessage( 
AbstractDeployMojo.unknownMode, mode ) );
}
}

/**
 * Gets the Tomcat WAR file. This may be a file or a directory depending on 
the deployment mode.
 * 
 * @return the Tomcat WAR file.
 */
protected abstract File getWarFile();  //concrete class will need to 
override

/**
 * Ensures that the Tomcat WAR file exists and is the correct type for the 
deployment mode.
 * 
 * @throws MojoExecutionException if the WAR file does not exist or is not 
the correct type for the deployment mode
 */
protected abstract void validateWarFile()  //concrete class will need to 
override
throws MojoExecutionException;

/**
 * Gets the Tomcat context XML file.
 * 
 * @return the Tomcat context XML file.
 */
protected File getContextFile()
{
return contextFile;
}

/**
 * Ensures that the Tomcat context XML file exists and is indeed a file.
 * 
 * @throws MojoExecutionException if the context file does not exist or is 
not a file
 */
protected void validateContextFile()
throws MojoExecutionException
{
if ( !contextFile.exists() || !contextFile.isFile() )
{
throw new MojoExecutionException( getMessage( 
AbstractDeployMojo.missingContext, contextFile.getPath() ) );
}
}

/**
 * Gets whether Tomcat should automatically undeploy webapps that already 
exist when deploying.
 * 
 * @return whether Tomcat should automatically undeploy webapps that 
already exist when deploying
 */
protected boolean isUpdate()
{
return update;
}

/**
 * Gets the Tomcat webapp tag name to use.
 * @return the Tomcat webapp tag name to use
 */
protected String getTag()
{
return tag;
}

/**

Re: Tomcat plugin doesn't seem to be using build final name for context (seems to always use artifactId)

2009-12-17 Thread Olivier Lamy
Hi,
Please fill an issue here http://jira.codehaus.org/browse/MTOMCAT

2009/12/17 Martin Gainty mgai...@hotmail.com:

 //AbstractDeployMojo details

 package org.codehaus.mojo.tomcat;
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
  * distributed with this work for additional information
  * regarding copyright ownership.  The ASF licenses this file
  * to you under the Apache License, Version 2.0 (the
  * License); you may not use this file except in compliance
  * with the License.  You may obtain a copy of the License at
  *   http://www.apache.org/licenses/LICENSE-2.0
  * Unless required by applicable law or agreed to in writing,
  * software distributed under the License is distributed on an
  * AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  * KIND, either express or implied.  See the License for the
  * specific language governing permissions and limitations
  * under the License.
  */

 import java.io.File;
 import java.io.IOException;
 import java.net.URL;
 import org.apache.maven.plugin.MojoExecutionException;

 /*** Deploy a WAR to Tomcat.
  * @author Mark Hobson markhob...@gmail.com
  * @version $Id: AbstractDeployMojo.java 8855 2009-01-21 11:23:04Z olamy $
  */
 public abstract class AbstractDeployMojo
    extends AbstractWarCatalinaMojo
 {
    // --
    // Mojo Parameters
    // --

    /**
     * The deployment mode to use. This must be either codewar/code to 
 deploy the war, codecontext/code to
     * deploy the context XML file, or codeboth/code to deploy the war 
 with the context XML file.
     *
     * @parameter expression = ${maven.tomcat.mode} default-value = war
     * @required
     */
    private String mode;

    /**
     * The path of the Tomcat context XML file. This is not used for war 
 deployment mode.
    *
     * Question how does project.build.finalName get baked into this folder 
 name???
     *
     * @parameter expression = 
 ${project.build.directory}/${project.build.finalName}/META-INF/context.xml
     */
    private File contextFile;

    /**
     * Whether Tomcat should automatically undeploy webapps that already exist 
 when deploying.
     *
     * @parameter expression = ${maven.tomcat.update} default-value = false
     * @required
     */
    private boolean update;

    /**
     * The Tomcat webapp tag name to use.
     *
     * @parameter expression = ${maven.tomcat.tag}
     */
    private String tag;

    // --
    // Protected Methods
    // --

    /**
     * {...@inheritdoc}
     */
   �...@override
    public void invokeManager()
        throws MojoExecutionException, TomcatManagerException, IOException
    {
        if ( war.equals( mode ) )
        {
            deployWar();
        }
        else if ( context.equals( mode ) )
        {
            deployContext();
        }
        else if ( both.equals( mode ) )
        {
            deployWarAndContext();
        }
        else
        {
            throw new MojoExecutionException( getMessage( 
 AbstractDeployMojo.unknownMode, mode ) );
        }
    }

    /**
     * Gets the Tomcat WAR file. This may be a file or a directory depending 
 on the deployment mode.
     *
     * @return the Tomcat WAR file.
     */
    protected abstract File getWarFile();  //concrete class will need to 
 override

    /**
     * Ensures that the Tomcat WAR file exists and is the correct type for the 
 deployment mode.
     *
     * @throws MojoExecutionException if the WAR file does not exist or is not 
 the correct type for the deployment mode
     */
    protected abstract void validateWarFile()  //concrete class will need to 
 override
        throws MojoExecutionException;

    /**
     * Gets the Tomcat context XML file.
     *
     * @return the Tomcat context XML file.
     */
    protected File getContextFile()
    {
        return contextFile;
    }

    /**
     * Ensures that the Tomcat context XML file exists and is indeed a file.
     *
     * @throws MojoExecutionException if the context file does not exist or is 
 not a file
     */
    protected void validateContextFile()
        throws MojoExecutionException
    {
        if ( !contextFile.exists() || !contextFile.isFile() )
        {
            throw new MojoExecutionException( getMessage( 
 AbstractDeployMojo.missingContext, contextFile.getPath() ) );
        }
    }

    /**
     * Gets whether Tomcat should automatically undeploy webapps that already 
 exist when deploying.
     *
     * @return whether Tomcat should automatically undeploy webapps that 
 already exist when deploying
     */
    protected boolean isUpdate()
    {
        return update;
    }

    /**
     * Gets the 

Skip checking for parent pom using relativePath

2009-12-17 Thread Stevo Slavić
Hello maven-users,

Is there a way to configure project pom.xml or in any other way suggest
maven to skip checking for parent pom using relativePath? E.g. by setting
relativePath to _skip or something similar.

Regards,
Stevo.


Batch releasing many projects in Maven. Is it possible?

2009-12-17 Thread Paul Benedict
My work situation is similar to what I learned about Eclipse. There's
a release train in which 10-20 projects -- with dependencies on each
other -- have to be versioned, built, and deployed. It's extremely
tedious manually do this in the console. Can Maven provide any
alleviation? Ideally, I would write a project (type pom) with all the
projects as dependencies that I want to batch release, and let the
Maven Release Plugin take care of things.

Possible or a dream?

Paul

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



Re: Batch releasing many projects in Maven. Is it possible?

2009-12-17 Thread Stephen Connolly
depends on how your scm's are organised...

2009/12/17 Paul Benedict pbened...@apache.org

 My work situation is similar to what I learned about Eclipse. There's
 a release train in which 10-20 projects -- with dependencies on each
 other -- have to be versioned, built, and deployed. It's extremely
 tedious manually do this in the console. Can Maven provide any
 alleviation? Ideally, I would write a project (type pom) with all the
 projects as dependencies that I want to batch release, and let the
 Maven Release Plugin take care of things.

 Possible or a dream?

 Paul

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




Re: Batch releasing many projects in Maven. Is it possible?

2009-12-17 Thread Stephen Connolly
http://maven.apache.org/plugins/maven-release-plugin/prepare-mojo.html#commitByProject

might be a property that could help

2009/12/17 Stephen Connolly stephen.alan.conno...@gmail.com

 depends on how your scm's are organised...

 2009/12/17 Paul Benedict pbened...@apache.org

 My work situation is similar to what I learned about Eclipse. There's
 a release train in which 10-20 projects -- with dependencies on each
 other -- have to be versioned, built, and deployed. It's extremely
 tedious manually do this in the console. Can Maven provide any
 alleviation? Ideally, I would write a project (type pom) with all the
 projects as dependencies that I want to batch release, and let the
 Maven Release Plugin take care of things.

 Possible or a dream?

 Paul

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





Filtering a file in maven mojo

2009-12-17 Thread Gajo Csaba

Hello,

One of our custom mojos is generating a file, and the template for this 
file is stored in the jar file of the mojo. What is done is that the 
resource is read with getClass().getResourceAsStream(), and then printed 
into a real file line by line.


What I would like to do is, before writing the line, to process the line 
with maven's filter. I was looking at the source code of the resources 
plugin [1], and as far as I can see, it is using a 
MavenResourcesFiltering component for filtering. However, it doesn't 
explicitly filter line by line (which is a requirement for me, because 
we also do other stuff with it). How can I do this?


Thanks, Csaba

[1] - 
http://svn.apache.org/viewvc/maven/plugins/tags/maven-resources-plugin-2.4.1/src/main/java/org/apache/maven/plugin/resources/ResourcesMojo.java?view=markup




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



RE: Could not explode webapp

2009-12-17 Thread Hehl, Thomas
OK, had other issues and got sidetracked. Now back to this one:

I ran this with debug and got the following messages:

[DEBUG] dissociating all components from managed ClassRealm with id:
/plugins/org.apache.maven.plugins:maven-surefire-plugin:2@48/thread:
main
[ERROR] 

The following mojo encountered an error while executing:
Group-Id: org.apache.maven.plugins
Artifact-Id: maven-war-plugin
Version: 2.0
Mojo: war
brought in via: packaging: war

While building project:
Group-Id: com.acs.gs.juror
Artifact-Id: agilejury-frontend
Version: 0.5
From file: D:\juror\agilejury-frontend\pom.xml
Reason: Could not explode webapp...

java.io.FileNotFoundException: D:\juror\agilejury-service\target\classes
(Access is denied)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.init(FileInputStream.java:106)
at
org.codehaus.plexus.util.FileUtils.copyFile(FileUtils.java:796)
at
org.apache.maven.plugin.war.AbstractWarMojo.copyFileIfModified(AbstractW
arMojo.java:866)
at
org.apache.maven.plugin.war.AbstractWarMojo.buildWebapp(AbstractWarMojo.
java:508)
at
org.apache.maven.plugin.war.AbstractWarMojo.buildExplodedWebapp(Abstract
WarMojo.java:344)
at
org.apache.maven.plugin.war.WarMojo.performPackaging(WarMojo.java:167)
at org.apache.maven.plugin.war.WarMojo.execute(WarMojo.java:133)
at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginMa
nager.java:579)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandle
Failures(DefaultLifecycleExecutor.java:498)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmentFo
rProject(DefaultLifecycleExecutor.java:265)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(
DefaultLifecycleExecutor.java:191)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifec
ycleExecutor.java:149)
at
org.apache.maven.DefaultMaven.execute_aroundBody0(DefaultMaven.java:223)
at
org.apache.maven.DefaultMaven.execute_aroundBody1$advice(DefaultMaven.ja
va:304)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:1)
at
org.apache.maven.embedder.MavenEmbedder.execute_aroundBody2(MavenEmbedde
r.java:904)
at
org.apache.maven.embedder.MavenEmbedder.execute_aroundBody3$advice(Maven
Embedder.java:304)
at
org.apache.maven.embedder.MavenEmbedder.execute(MavenEmbedder.java:1)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:176)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:63)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav
a:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
Impl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launche
r.java:289)
at
org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:2
29)
at
org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launc
her.java:408)
at
org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:351
)
at org.codehaus.classworlds.Launcher.main(Launcher.java:31)



Error stacktrace:
org.apache.maven.lifecycle.LifecycleExecutionException: Internal error
in the plugin manager executing goal
'org.apache.maven.plugins:maven-war-plugin:2.0:war': Mojo execution
failed.
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandle
Failures(DefaultLifecycleExecutor.java:505)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmentFo
rProject(DefaultLifecycleExecutor.java:265)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(
DefaultLifecycleExecutor.java:191)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifec
ycleExecutor.java:149)
at
org.apache.maven.DefaultMaven.execute_aroundBody0(DefaultMaven.java:223)
at
org.apache.maven.DefaultMaven.execute_aroundBody1$advice(DefaultMaven.ja
va:304)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:1)
at
org.apache.maven.embedder.MavenEmbedder.execute_aroundBody2(MavenEmbedde
r.java:904)
at
org.apache.maven.embedder.MavenEmbedder.execute_aroundBody3$advice(Maven
Embedder.java:304)
at
org.apache.maven.embedder.MavenEmbedder.execute(MavenEmbedder.java:1)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:176)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:63)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav
a:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
Impl.java:25)
at 

Re: Batch releasing many projects in Maven. Is it possible?

2009-12-17 Thread Paul Benedict
Thanks Stephen. It looks like this feature isn't handled by Maven yet.
These aren't parent-child projects, so it appears I have to remain
doing it manually.

Paul

On Thu, Dec 17, 2009 at 12:28 PM, Stephen Connolly
stephen.alan.conno...@gmail.com wrote:
 http://maven.apache.org/plugins/maven-release-plugin/prepare-mojo.html#commitByProject

 might be a property that could help

 2009/12/17 Stephen Connolly stephen.alan.conno...@gmail.com

 depends on how your scm's are organised...

 2009/12/17 Paul Benedict pbened...@apache.org

 My work situation is similar to what I learned about Eclipse. There's
 a release train in which 10-20 projects -- with dependencies on each
 other -- have to be versioned, built, and deployed. It's extremely
 tedious manually do this in the console. Can Maven provide any
 alleviation? Ideally, I would write a project (type pom) with all the
 projects as dependencies that I want to batch release, and let the
 Maven Release Plugin take care of things.

 Possible or a dream?

 Paul

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





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



Re: Transitive dependency omitted if prior dependency resolved first then subsquently omitted

2009-12-17 Thread Wayne Fay
 eventually omitted.  The fact that I can change the dependency order in
 artifact A and get a different list of resolved artifacts leads me to
 believe this is more likely to be a defect but I wanted to be sure I

If you can build a (small) sample project that demonstrates the issue
very clearly, then someone can more easily look at it and potentially
resolve it, if it is in fact a bug.

Wayne

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



Re: maven install gives the following errors

2009-12-17 Thread Wayne Fay
 If I right click on the project in eclipse and select run
 configurations and try to run it on
 Tomcat it is not deployed there.

I have no idea how to run your project. Perhaps as on the M2Eclipse Users list?

Wayne

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



Re: Transitive dependency omitted if prior dependency resolved first then subsquently omitted

2009-12-17 Thread egroesbeck

No problem:

http://old.nabble.com/file/p26833532/omitted_dependency_example.zip
omitted_dependency_example.zip 



Wayne Fay wrote:
 
 eventually omitted.  The fact that I can change the dependency order in
 artifact A and get a different list of resolved artifacts leads me to
 believe this is more likely to be a defect but I wanted to be sure I
 
 If you can build a (small) sample project that demonstrates the issue
 very clearly, then someone can more easily look at it and potentially
 resolve it, if it is in fact a bug.
 
 Wayne
 
 -
 To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
 For additional commands, e-mail: users-h...@maven.apache.org
 
 
 

-- 
View this message in context: 
http://old.nabble.com/Transitive-dependency-omitted-if-prior-dependency-resolved-first-then-subsquently-omitted-tp26818594p26833532.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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



Re: WAR/JAR sync deploy for GWT modules

2009-12-17 Thread Darren Hartford
confirm, using a more recent war plugin with attachClasses and using the 
dependency classifier classifierclasses/classifier did allow the packing 
type WAR project to also deploy a binary JAR to my repos (so WAR and JARs are 
deploying to production. Now those jars are available as a dependency (so, for 
GWT purposes, can set dependencies with classifiers 'sources' and 'classes' to 
build up GWT modules).

thanks! -D
==
Example:

packagingwar/packaging
...
build
plugins
plugin
artifactIdmaven-war-plugin/artifactId
version2.1-beta-1/version
configuration
!-- make sure modern war-plugin version --
attachClassestrue/attachClasses 
...
==
then in other projects depending on jar binary (GWT class files as you 
integrate):
...
dependencies
dependency
...
classifierclasses/classifier
...









--- On Thu, 12/17/09, Justin Edelson justinedel...@gmail.com wrote:

 From: Justin Edelson justinedel...@gmail.com
 Subject: Re: WAR/JAR sync deploy for GWT modules
 To: Maven Users List users@maven.apache.org
 Date: Thursday, December 17, 2009, 10:06 AM
 Since you're not actually describing
 the problem you're having, it's 
 hard to say what the solution might be. But I do know that
 the URL you 
 posted below describes a terribly convoluted non-solution.
 The only 
 thing you need to do to create a JAR file containing the
 classes AND get 
 it installed in your local repository AND get it deployed
 to the remote 
 repository (at the appropriate lifecycle phases) is this:
 
 plugin
 artifactIdmaven-war-plugin/artifactId
 configuration
 attachClassestrue/attachClasses
 /configuration
 /plugin
 
 Any time you're using install-file or deploy-file inside
 your pom, 
 something is wrong.
 
 HTH,
 Justin
 
 
 On 12/17/09 9:49 AM, Darren Hartford wrote:
  Hi all,
  I am building GWT modules. A GWT module may be used on
 it's own (as a WAR), and other times is a dependency for a
 larger project (as a binary JAR).
 
  I've tried this approach here: 
  http://communitygrids.blogspot.com/2007/11/maven-making-war-and-jar-at-same-time.html
 
  Unfortunatley, it looks like the maven-metadata.xml,
 or something else in the repository world, doesn't recognize
 both a WAR and a JAR at the same time when we try to pull
 back from the repo.  When I go to the repo, the WAR and
 the JAR have different file date/times, which may or may not
 matter to the maven-metadata.xml -- this is all guessing at
 this point.
 
  In any fashion, trying to search on how to solve this
 problem has been a nightmare in itself -- any guidance
 please?
 
  thanks,
  -D
 
 
 
 
 
 
 -
  To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
  For additional commands, e-mail: users-h...@maven.apache.org
 
     
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
 For additional commands, e-mail: users-h...@maven.apache.org
 
 


   


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



Re: How to deploy JiBX Maven project from Ant specifications

2009-12-17 Thread Kenneth Henriksen
Hi again John,

Sorry for the late answer, I just made a new project which should be an
exact (Maven) copy of the Ant project I posted a link to. I did this to make
sure that I wasn't wasting you time with a renaming error from my part. I
got the same error though.

Line 51 is the exception itself:

catch (Exception e) {throw new JiBXException(Error marshalling XML to
Object,e);

 Could you get the XML the method is seeing logged perhaps, or the value
of the src parameter?  Maybe inspect the cause and message of the exception
in catch block?
These are good ideas, but I don't know how to do it. Java's println does
not work, so it is possible til write directly to the ServiceMix console, so
we can see the content of the variables we're interested in?

Kind regards
Kenneth H