Re: Need a separate jar from war in assembly

2009-08-28 Thread Wendy Smoak
Yes, it's common to have the code in a separate module from the webapp. It makes it easier to do unit testing of the code separately from integration testing the webapp. I'm not sure how that relates to your original question though. I see the jar module and the war module... where is the assemb

plugin not reading finalName correctly?

2009-08-28 Thread James Russo
Hello, Trying to use buildnumber and tomcat:deploy. In my parent-pom, I've defined buildnumber. In my application-webapp (war), I define the tomcat deploy configuration. However, when tomcat deploy tries to install it, for some reason the "buildnumber" variable comes across as null. [INFO

Re: inject version into source?

2009-08-28 Thread James Russo
Stephen, Thanks. I can honestly say I was not aware of that. I guess I hadn't been bitten by that one yet. Makes sense though.. -jr Stephen Connolly wrote: the spec for javac allows directly including public static final constants *by value* if they are one of the 8 primitives, or String

Re: inject version into source?

2009-08-28 Thread Stephen Connolly
the spec for javac allows directly including public static final constants *by value* if they are one of the 8 primitives, or String. so if another class (Foo.java) references Version.VERSION javac is allowed to *copy* the string at *compile* time. if you subsequently modify Version.java, b

Re: Need a separate jar from war in assembly

2009-08-28 Thread James Russo
Hello, So, the recommended way is to have something like this, correct? xx-weblogic (all code for web-application) xx-webapp (the actual war, containing src/main/webapp, src/main/resources, but no src/main. Code is really included though .jar files in lib). -jr Wendy Smoak wrote:

Re: inject version into source?

2009-08-28 Thread James Russo
Stephen, Thanks. I think I will take this route. Not sure what you mean about "partial build" though. If the .java file was updated each time, it would be compiled each time. Right now, I can't seem to get the build-version maven module to fail if my local directory has modified code. doc

Re: Need a separate jar from war in assembly

2009-08-28 Thread Wendy Smoak
On Fri, Aug 28, 2009 at 1:06 PM, Jim Collings wrote: > So I have a jar that needs to be in an assembly but not in the war > file. It's a jdbc driver for the appserver. > How can I get it into the compressed archive but outside of the *.war file? How is your project structured now? Are you trying

Need a separate jar from war in assembly

2009-08-28 Thread Jim Collings
So I have a jar that needs to be in an assembly but not in the war file. It's a jdbc driver for the appserver. How can I get it into the compressed archive but outside of the *.war file? - To unsubscribe, e-mail: users-unsubscr...

Re: inject version into source?

2009-08-28 Thread Stephen Connolly
another way is to store the version in the manifest and then retrieve the manifest from the classloader for the class you are loading... of course the downside is that if somebody makes an uberjar you'll have the version of the uberjar and nit the version of the code that was uberjarred (wh

Re: inject version into source?

2009-08-28 Thread Stephen Connolly
turn on filtering for a specific resource (e.g. com/foo/bar/ Version.properties) have this file with the contents version=${project.version} replace your com.foo.bar.Version.java with code like so public static String getVersion() { InputStream is = Version.class.getResource("Version.proper

Re: javadoc:aggregate Problem

2009-08-28 Thread Joerg Hohwiller
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 FYI: http://jira.codehaus.org/browse/MJAVADOC-245 > Hi there, > > I want to have javadoc-reports per module as well as one aggregated javadoc > for > the project. Is this possible at all with a single site:stage call? > > I tried > http://maven.ap

Re: Best practice - for multiple config files per environment

2009-08-28 Thread Joerg Hohwiller
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi Rick, > I know this must be a common question, and I've been googling for the best > practice for using a different configuration file (say a different > hibernate.cfg.xml file) for different profiles (based on a profile, local, > itr, etc.) > > N

Re: Maven2 plugin execution sequence

2009-08-28 Thread Dan Tran
file a jira so that people can vote on it On Fri, Aug 28, 2009 at 6:55 AM, claus437 wrote: > > :o( - ok thnaks i will do... > > > Dan Tran wrote: >> >> not possible at moment, you may want to file a request to add "pre-deploy" >> phase >> >> -D >> >> On Thu, Aug 27, 2009 at 8:52 AM, claus437 wrote

Re: inject version into source?

2009-08-28 Thread James Russo
Dana, Thanks. That is fine. I am fine with just injecting the value of the pom, but I need it accessible to my application. Current scheme for this is to have it in a Version.java file as a static string which is referenced for display in the application. Still trying to get my head arou

RE: inject version into source?

2009-08-28 Thread Lacoste, Dana (TSG Software San Diego)
So, basically, you use a "wrapper" to get around maven? I do something similar: I use a .properties file, then run an ant script to update the maven pom.xml files. Very predictable, very manageable, and bypasses the maven-release-plugin which caused ALL KINDS of headaches because it doesn't work

Re: inject version into source?

2009-08-28 Thread David C. Hicks
I have done this by setting up a properties file that gets filtered at build time. Then, I use that properties file in a Spring PlaceholderConfigurer to get the value injected where I need it. James Russo wrote: > Hello, > >New maven user here. Really am liking it, just trying to get > projec

inject version into source?

2009-08-28 Thread James Russo
Hello, New maven user here. Really am liking it, just trying to get project back online and running after switching from ant.. Is there any standard maven way to inject maven variables (like version) into source code, prior to compile? Is this maybe were I should just leverage my existing

Re: Force versions plugin to remove snapshots

2009-08-28 Thread Stephen Connolly
versions:set -DnewVersion=7.8.9 2009/8/28 Lewis, Eric > Hi > > With our build, we have a top-down approach to our releases: We have a > hierarchy of POMs, and the one closest to the project contains all versions > of all our projects. > Now, to release that, we have to remove the -SNAPSHOT from

Force versions plugin to remove snapshots

2009-08-28 Thread Lewis, Eric
Hi With our build, we have a top-down approach to our releases: We have a hierarchy of POMs, and the one closest to the project contains all versions of all our projects. Now, to release that, we have to remove the -SNAPSHOT from the versions. I wanted to do this with the versions plugin, but i

Re: basic doubts

2009-08-28 Thread Stephen Connolly
nexus is GPL. is that open source enough for you ;-) nexus pro is the non open source version of nexus (dual license) Sent from my [rhymes with myPod] ;-) On 28 Aug 2009, at 12:43, Stuff_Me wrote: Andres, So the steps i have added are correct way to resolve my problem, come to Nexus(repo

M2Plugin put the test resources in jar.

2009-08-28 Thread Alexander Vaysberg
Hi, I have a problem with maven. If I use the M2 Plugin with Resolve dependencies from Workspace projects, than include the maven in jar the test resources. Why? I want the jar without test resources, so same as in repository. M2 Plugin is 0.9.8. Alexander Vaysberg.

Re: How do I get Maven to package ejb dependencies in the ear?

2009-08-28 Thread Wayne Fay
> Or is there a configuration setting for the war plugin that will tell it to > package dependencies in the ear? Check the Maven Users Wiki for "Skinny War" or just Google for "Maven skinny war". This topic is also discussed on this list now and then so search the archives at Nabble.com. Wayne -

Re: How do I get Maven to package ejb dependencies in the ear?

2009-08-28 Thread Jörg Schaible
Hi David, David Sharp wrote at Freitag, 28. August 2009 15:40: >>I am not sure, I get your problem. By default your EJB will not contain >>any jars and if you declare your EJB as dependency for your EAR the latter >>will contain the EJB as well as all transitive dependencies of this EJB. > > You

Re: Maven2 plugin execution sequence

2009-08-28 Thread claus437
:o( - ok thnaks i will do... Dan Tran wrote: > > not possible at moment, you may want to file a request to add "pre-deploy" > phase > > -D > > On Thu, Aug 27, 2009 at 8:52 AM, claus437 wrote: >> >> Hi All >> >> I have created a little maven 2 plugin that i would like to run each time >> i >>

maven jar plugin not including all the jars in the manifest.mf

2009-08-28 Thread sudhi123
I am trying to build jar, where i would need all the classpath entries in the manifest.mf, but the manifest.mf is not inlcluding the jars in the classpath (like testng.jar ). is there anything wrong in my configuration ? org.apache.maven.plugins

Re: How do I get Maven to package ejb dependencies in the ear?

2009-08-28 Thread David Sharp
>I am not sure, I get your problem. By default your EJB will not contain any >jars and if you declare your EJB as dependency for your EAR the latter will >contain the EJB as well as all transitive dependencies of this EJB. You are right. I made an erroneous assumption that EJBs would be similar t

RE: FW: basic doubts

2009-08-28 Thread Siegmann Daniel, NY
Do not use maven-proxy! That is a dead project. Any of those mentioned in the link provided by Anders should be sufficient. They are all open source (Nexus also has a Pro version which costs money). I use and have been happy with Nexus, YMMV. ~Daniel -Original Message- From: Stuff_Me [ma

Re: site plugin requiring maven-changes-plugin:pom:2.2-SNAPSHOT

2009-08-28 Thread Lorenzo Bigagli
Thanks Olivier, the parent pom actually mentions the changes plugin twice: in the section, specifying version 2.1, and in the section, where the version was actually missing. Defining the version, the problem was fixed (thank you). I then got a similar problem concerning the javadoc plug

Re: Multiple executions of goals under generate-sources: How to avoid?

2009-08-28 Thread ZsJoska
Do you have a sample for doing that? It's your solution generic? I have a web services client application where I generate the artifact sources during the generate-sources phase. In order to import the latest version of the wsdl I try to kick-up a jetty server with the war produced by another modu

Re: (maven.)apache.org down

2009-08-28 Thread Arnaud HERITIER
Yes it's is down :http://monitoring.apache.org/status/ On Fri, Aug 28, 2009 at 11:28 AM, Juven Xu wrote: > hmm... I got this: > > *.apache.org is currently offline. No ETA for resumption of services > is available. > > > On Fri, Aug 28, 2009 at 5:24 PM, Stevo Slavić wrote: > > > Hello maven u

Re: FW: basic doubts

2009-08-28 Thread Stuff_Me
Andres, So the steps i have added are correct way to resolve my problem, come to Nexus(repository manager) i am looking for the open source and i hope MAVEN-PROXY is sufficient for my requirements ( mentioned in first mail) Hoping MAVEN-PROXY is also a repo manager. Pls suggest on the same

AW: AW: Executing Dependency pom.xml

2009-08-28 Thread Lewis, Eric
In that case you can just write a parent POM which contains both projects as , and Maven will figure out how to build them. Best regards, Eric > -Ursprüngliche Nachricht- > Von: bandrm [mailto:rajivband...@gmail.com] > Gesendet: Donnerstag, 27. August 2009 18:52 > An: users@maven.apach

Re: FW: basic doubts

2009-08-28 Thread Anders Hammar
There are better repository managers than that one. I strongly recommend Nexus by Sonatype, but there are others (Artifactory for instance). There is a comparison of repo managersonline here: http://docs.codehaus.org/display/MAVENUSER/Maven+Repository+Manager+Feature+Matrix /Anders On Fri, Aug 28

Re: FW: basic doubts

2009-08-28 Thread Stuff_Me
On browsing, i got that i have the following. Is this way a correct one? Is there any other better way? http://dotal.wordpress.com/2007/02/26/setup-internal-maven-repository/ Download maven-proxy from codehaus. Follow the instructions to setup a manual ins

Re: FW: basic doubts

2009-08-28 Thread Stuff_Me
Hi Everybody, My problems is some what similar one, new to maven and i have installed M2, create a projects with all its dependencies on a system which is having internet and it works fine. Now the problem my team members (does not have internet and) they have to point to the my local repository

bug on the m2 plugin

2009-08-28 Thread Alexander Vaysberg
Hi , i have in April the this problem between M2 Plugin and Maven:- http://www.nabble.com/M2-and-Eclipse-td23195404.html. Can you say, have you any changed? Re : Re : Re : Re : M2 and Eclipse Click to flag this post by Julien HENRY

Re: Maven If else

2009-08-28 Thread Renuka . Kale
Thanks, appreciate your inputs! Jörg Schaible Sent by: news 08/28/2009 03:14 PM Please respond to "Maven Users List" To users@maven.apache.org cc Subject Re: Maven If else Hi Renuka, renuka.k...@marsh.com wrote at Freitag, 28. August 2009 10:29: > Hi, > > Has anyone used con

Re: Maven If else

2009-08-28 Thread Jörg Schaible
Hi Renuka, renuka.k...@marsh.com wrote at Freitag, 28. August 2009 10:29: > Hi, > > Has anyone used conditional code with "if" "else" in maven scripts inside > I need to know the syntax. > > I tried using "" however it says - The type doesn't > support the nested "j:choose" element. Maybe yo

Re: (maven.)apache.org down

2009-08-28 Thread Juven Xu
hmm... I got this: *.apache.org is currently offline. No ETA for resumption of services is available. On Fri, Aug 28, 2009 at 5:24 PM, Stevo Slavić wrote: > Hello maven users, > > Is (maven.)apache.org down or is it just my network connectivity? > > Regards, > Stevo. > -- - juven

(maven.)apache.org down

2009-08-28 Thread Stevo Slavić
Hello maven users, Is (maven.)apache.org down or is it just my network connectivity? Regards, Stevo.

Re: maven commandline

2009-08-28 Thread Alexander
Look link I sent you. You could use profiles. 2009/8/28 > deploy / undeploy are just examples, basically I should be able to add > anything outside regular lifecycle the way ANT targets work > > > Thanks, > > Renuka Kale > > Desk : +91 20 6641 6341 > Cell: +91 9822824443 > > > > Anders Ham

Re: Maven If else

2009-08-28 Thread Nicolas Duminil
By using maven profiles you may obtain the same effect.

Maven If else

2009-08-28 Thread Renuka . Kale
Hi, Has anyone used conditional code with "if" "else" in maven scripts inside " however it says - The type doesn't support the nested "j:choose" element. Thanks, Renuka Kale

Re: maven commandline

2009-08-28 Thread Renuka . Kale
deploy / undeploy are just examples, basically I should be able to add anything outside regular lifecycle the way ANT targets work Thanks, Renuka Kale Desk : +91 20 6641 6341 Cell: +91 9822824443 Anders Hammar Sent by: anders.g.ham...@gmail.com 08/28/2009 12:31 PM Please respond to

Re: maven commandline

2009-08-28 Thread Anders Hammar
I guess you could use profiles for that. However, what I'm thinking is that you might be trying to force a ant behavior into Maven and by doing so missing the idea behind maven. What is that you really are trying to do? You want to deploy to a server and undeploy from that server? /Anders On Fr