Re: automate localhost deploy
Cargo would be your best bet...http://cargo.codehaus.org/ Cheers, Henry On 11/16/07, mitch [EMAIL PROTECTED] wrote: Hello, I'm using maven2 (and the m2eclipse integration plugin) and am able to use the deploy goal successfully to deploy to a remote repository. But I wonder what the easiest way is to automate my manual steps of deploying to my localhost tomcat (including stopping and starting the container). Any idea how I could automate these steps? The steps would be: - stop tomcat - delete old war and app in my tomcat/webapps - rename the new war in my eclipse project /target dir - deploy the new war from my eclipse project /target dir to my localhost tomcat/webapps dir - start tomcat Thx for any help!
Re: how to get the maven repository to local machine?
May I ask why you would want to do this? On 10/17/07, li frank [EMAIL PROTECTED] wrote: Hi all, I want to get the central repository using rsync from several mirrors,like *rsync -v -t -l -r mirrors.ibiblio.org::maven2*, but it give me message as following: receiving file list ... rsync: opendir /ch/hortis/sonar/sonar-web (in maven2) failed: Permission denied (13) rsync: opendir /ch/hortis/sonar/sonar-maven-plugin/1.0-beta (in maven2) failed : Permission denied (13) rsync: opendir /ch/hortis/sonar/sonar-commons/1.0-beta (in maven2) failed: Per mission denied (13) rsync: opendir /ch/hortis/sonar/sonar-application (in maven2) failed: Permissi on denied (13) rsync: opendir /ch/hortis/sonar/db-maven-plugin (in maven2) failed: Permission denied (13) rsync: opendir /ch/hortis/sonar/sonar/1.0-beta (in maven2) failed: Permission denied (13) rsync: opendir /ch/hortis/sonar/sonar-core (in maven2) failed: Permission deni ed (13) rsync: opendir /ch/hortis/sonar/sonar-db-embedder (in maven2) failed: Permissi on denied (13) why occor this problem? how can i get all the files in the maven central repository? i'm appreciate your help.
Re: Maven dependencies issues
This might prove helpful http://maven.apache.org/plugins/maven-dependency-plugin/ especially the copy-dependencies goal. HTH, Henry On 7/23/07, Dmitry [EMAIL PROTECTED] wrote: My application is a jar file and when I run mvn package it generates my jar ok. But I need to distribute my app with all the related jar dependencies so I wonder how could I do it with maven2.. Actually, I did an ant task that at package cycle copy my project depdenciens from mvnrepository to a lib folder inside target folder. It works well but force me to make the list of files to be copied by hand. I want to see maven doing this job automatically... Is this posible ? thanks in advance, Dmitry www.ejinz.com Search Engine Revolution news, categories, country - 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: Build failure out of the blue
ouch, is there something similar in Solaris? Jeff Mutonho wrote: On 7/18/07, Henry Isidro [EMAIL PROTECTED] wrote: Try changing your java alternative setting: sudo update-alternatives --config java HTH, Henry Hmmmit's running on a Solaris machine - 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: Build failure out of the blue
Try changing your java alternative setting: sudo update-alternatives --config java HTH, Henry Jeff Mutonho wrote: On 7/17/07, Maria Odea Ching [EMAIL PROTECTED] wrote: Hi, Try executing 'which java' from the command line and trace from this which java (the one displayed may be an alternate only) is being executed to verify if the java you're using is really 1.6. It might not exactly be a Maven problem :-) You're absolutely right.The output is : bash-2.05$ which java /usr/bin/java bash-2.05$ java -version java version 1.4.2_05 Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_05-b04) Java HotSpot(TM) Client VM (build 1.4.2_05-b04, mixed mode) bash-2.05$ The system wide java executable is pointing to that 1.4 runtime as there are other applications that are using 1.4.How can I override and force maven to use the 1.6 one? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Maven and Ant | Executing Ant script before downloading dependencies | Need Help
Hi Shinjan, You can separate the two. Place the ant project in its own project, configure the ant run plugin there. Then, in the maven project, add the ant project as a dependency. If you want this in one nice build, you can place both projects under one parent, this way, when you build the parent, it would build the ant project first, then the maven one. HTH, Henry shinjan sen wrote: Hi, I have a maven project which has a dependency on an ant project. To achieve this I have added a execution of the maven ant-run-plugin in my pom.xml as follows: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution phasepackage/phase configuration tasks echoDownload dependent jars/echo ant antfile=build.xml dir=. inheritAll=true inheritRefs=true /ant /tasks /configuration goals goalrun/goal /goals /execution /executions /plugin This ant script build.xml compiles the associated ant project and installs the same in the maven local repository. project basedir=. default=buildJar condition property=mvn.exec value=mvn.bat else=mvn os family=windows/ /condition target name=buildJar description=Builds ant project and copies jar to local repository ant antfile=build.xml dir=ant_common target=compile / exec executable=${mvn.exec} arg line=-D mvn install:install-file -Dfile=ant_common.jar -DgroupId=mytest -DartifactId=ant_common -Dversion=1.0 -Dpackaging=jar/ /exec /target /project My question is how do I add this ant project as a dependency in my pom.xml? if I add it as dependency groupIdmytest/groupId artifactIdant_common/artifactId version1.0/version /dependency my pom will try to download the same before executing the maven-antrun-plugin execution and will throw an error. I want to achieve the effect of installing the ant project and then referencing it as a dependency in one execution. Please advise. Thanks in advance. Regards, Shinjan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] best way to have an offline internal repository
Dário Luís Coneglian Oliveros wrote: Hi there, I've been reading several threads about having an offline internal repository and I wonder if there's any maven plugin or tool that can help on this matter as of now. I've heard of a repository builder, but could not find much information about it.FYI I use Proximity as my proxy/proactive mirror. Basically I want to create a package that encompasses a maven project and its repo so any user who uses it can build this project offline. Any suggestions ? Any help is appreciated. Dário Oliveros - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] I'm not sure if this would help but the assembly plugin could package a repository into a zip. You could try checking it out. HTH, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: invoke maven from java
?? wrote: Hi, everyone. Is there a way to invoking maven from java code? Thanks in advance. Hi ??, Continuum does something like that. You can check out the continuum code at https://svn.apache.org/repos/asf/maven/continuum/trunk. Then look at continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenTwoBuildExecutor.java HTH, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Requiring a specific version of maven to build a project?
I think there was talk of an enforcer plugin somewhere, you might want to search for that. HTH, Henry On 5/23/07, Alex Karasulu [EMAIL PROTECTED] wrote: Hi, Just wondering if there is a POM directive that I can use to enforce the use of a specific version of maven for it's modules to be built. Over at Apache Directory we have run into situations where users are trying to build old tagged releases with versions of maven that do not build properly. My aim is to make sure a specific maven version is enforced for the build. Thanks, Alex
Re: PreGoal ??
preGoal executes the scripts you specify before the goal named. For instance, preGoal name=java:compile ... /preGoal Anything between preGoal and /preGoal would execute first and then java:compile would be executed. Regards, Henry Zheng Wen Zhe wrote: Hi, I have a pregoal set up among some other goals within my maven.xml file. Why this pregoal could run automatically without being called? Is this the nature of PreGoal? Regards, Jason - 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: Ear file doesnt contain war and jar
Hi Karthik, Glad to hear that you've got it working. You can send artifacts to specific directories in your ear by using the bundleDir tag. More info at http://maven.apache.org/plugins/maven-ear-plugin/howto.html. HTH, Henry Karthik V wrote: I got it working finally, but dont understand how ... all i did was (in the ear projects pom) remove the parent reference to the parent pom project ... all jars i need are being included properly ... but i dont know the reason for this .. can someone explain? and also, how do i send the jars, wars etc. into specific directories inside the .ear? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] want advance about setting up multiple
Hi Mick, I assume you mean jars that were built from your project. In that case, you can install those jars manually. Please see http://maven.apache.org/guides/mini/guide-installing-3rd-party-jars.html and http://docs.codehaus.org/display/MAVENUSER/FAQs#FAQs-HowdoIinstallafileinmylocalrepositoryalongwithagenericPOM for more info. HTH, Henry Mick Knutson wrote: Ok, The reason I want is this. I have a project that ahs many modules and jars, included into 1 ear. I want to run idea:idea to create my Intellij project, but it is looking into ibbiblio for my common.jar etc So I am assuming that I need to install my jars into my repository right? Thanks Mick Knutson http://www.BASELogic.com http://www.MickKnutson.com MSN Messenger: [EMAIL PROTECTED] - Original Message - From: Maria Odea Ching [EMAIL PROTECTED] To: Maven Users List users@maven.apache.org Sent: Wednesday, January 18, 2006 5:54 PM Subject: Re: [m2] want advance about setting up multiple Hi Mick, You don't have to specify your local repository and the ibiblio repository in your pom. Maven automatically checks your local repository first, then the central repository (ibiblio) last. Thanks, Odea Mick Knutson wrote: I want to setup my local repository as my initial, then ibbiblio as the secondary repository. How do I do this?: repository idcentral/id nameMaven Repository Switchboard/name layoutdefault/layout urlC:\\Documents and Settings\\Owner\\.m2\\repository/url snapshots enabledfalse/enabled /snapshots /repository repository idbackup/id nameMaven Repository Switchboard/name layoutdefault/layout urlhttp://repo1.maven.org/maven2/url snapshots enabledfalse/enabled /snapshots /repository ?? Thanks Mick Knutson http://www.BASELogic.com http://www.MickKnutson.com MSN Messenger: [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: CLASSPATH?
Hi Lutz, Check out dependencies. Any artifacts declared as dependencies are placed on the classplath depending on the specified scope. This is placed in the build section of your pom.xml. dependencies dependency groupId/ artifactId/ version/ type/ /dependency /dependencies Also check out http://maven.apache.org/guides/introduction/introduction-to-dependency-mechanism.html for more info. HTH, Henry Lutz Fechner wrote: Hi together, I managed to tell Maven where my sources reside and where I want to put the compiled files: build sourceDirectorycode/sourceDirectory outputDirectorytarget/WEB-INF/classes/outputDirectory /build but how do I tell the Maven (or the compiler) where too look for libaries? Is there something like a classpath to set in maven? Bye Lutz Fechner LEGAL DISCLAIMER The information in this transmission is privileged and/or contains confidential information intended solely for the addressee! If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. You must not copy, distribute, disclose or take any action in reliance on or in relation to it. If you have received this communication in error, please delete all copies of the message and its attachments and notify the sender immediately. VIRUS ADVICE E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender therefore does not accept liability for any errors or omissions in the content of this message, which arise as a result of e-mail transmission. The contents of any attachment to this e-mail may contain software viruses wich could damage your own computer system. While we have taken every reasonable precaution to minimze this risk, we cannot rule out the possibility that attachments may contain software viruses. You should carry out your own virus check before opening the attachments. No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.1.371 / Virus Database: 267.14.19/231 - Release Date: 1/16/2006 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Where to place resources for unit tests?
Hi David, Try excluding them: testResources testResource ... excludes/ /testResource /testResources HTH, Henry [EMAIL PROTECTED] wrote: Hello, I need some config files/resources for unit test, so I place them insrc/test/resources, but I don't want to include them in generated jar. The description of testResource element of pom.xml states thatresources are used to complete the jar or to run unit test. How can use this resources in test phase, but not include them in jar ? Thanks. No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.1.371 / Virus Database: 267.14.19/231 - Release Date: 1/16/2006 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Ear file doesnt contain war and jar
Hi Karthik V, The properties tag for dependencies are no longer suppported. Can you post your pom so that we can see what you are actually doing? Regards, Henry Karthik V wrote: looks like things have changed :( ... the properties tag is not being recognized. On 1/17/06, Max Cooper [EMAIL PROTECTED] wrote: Note: this is for Maven 1 (1.0.2, 1.1-beta-2, I don't know if anything has changed for Maven 2) In the ear project where you specify the dependencies, you specify properties to tell the ear plugin what to do with your jars and wars. Here's an example: !-- ejb jar -- dependency groupIdmyproject/groupId artifactIdejb/artifactId version${pom.currentVersion}/version typeejb/type properties ear.bundletrue/ear.bundle /properties /dependency !-- war -- dependency groupIdmyproject/groupId artifactIdweb/artifactId version${pom.currentVersion}/version typewar/type properties ear.bundletrue/ear.bundle ear.appxml.war.context-root//ear.appxml.war.context-root /properties /dependency !-- utility jar -- dependency groupIdmyproject/groupId artifactIdutil/artifactId version${pom.currentVersion}/version typejar/type properties ear.moduletrue/ear.module /properties /dependency This is all described at the bottom of this page: http://maven.apache.org/maven-1.x/reference/plugins/ear/properties.html Note that the ear.bundle.dir property will allow you to control the directory (inside the ear file) where the dependency ends up. -Max On Tue, 2006-01-17 at 13:18 -0500, Karthik V wrote: when someone answers this question, please give a general answer to this question - how do I copy a jar file specified as dependency into the final artifact, inside the folder I want? On 1/17/06, Karthik V [EMAIL PROTECTED] wrote: I have an ear project that needs to pack 2 other projects artifacts (jar and war). In the ear project pom, I've added dependencies on both. However, the ear file produced doesnt contain these. How do I fix this problem? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.1.371 / Virus Database: 267.14.19/231 - Release Date: 1/16/2006 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [M2] Problem with maven-ear-plugin: Artifact[_:_:ejb] is not a dependency of the project.
Hi Stefan, Try adding typeejb/type in your dependency declarations. HTH, Henry Stefan Rademacher wrote: Hello, I have a problem, when I try creating an EAR file, that includes two EJB modules. Nobody else seems to have this issue, so there might be an easy solution... I have a project with packaging=ear and two projects with packaging=ejb. When I package the ejb projects separately, there are no errors. But when I want to package the ear-project (see pom below), I get the error Artifact[de.hhla.smd:hhla.smd.bwaclient:ejb] is not a dependency of the project. But I added the two ejb projects as dependencies of my ear project. Could anybody tell me, what I'm doing wrong? Thanks a lot for your help! Regards, Stefan POM of the EAR project: project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion groupIdde.hhla.smd/groupId artifactIdhhla.smd.provider/artifactId namehhla.smd.provider/name version1.0-beta-1-SNAPSHOT/version packagingear/packaging dependencies dependency groupIdde.hhla.smd/groupId artifactIdhhla.smd.aisclient/artifactId version1.0-beta-1-SNAPSHOT/version /dependency dependency groupIdde.hhla.smd/groupId artifactIdhhla.smd.bwaclient/artifactId version1.0-beta-1-SNAPSHOT/version /dependency /dependencies build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-ear-plugin/artifactId configuration modules ejbModule groupIdde.hhla.smd/groupId artifactIdhhla.smd.bwaclient/artifactId /ejbModule ejbModule groupIdde.hhla.smd/groupId artifactIdhhla.smd.aisclient/artifactId /ejbModule /modules /configuration /plugin /plugins /build /project - 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] outputDirectory
Hmmmtry configuring the jar plugin. There's an outputDirectory property there but I think this is still in SVN. The old version used basedir for this and was a readonly attribute but it was changed to outputDirectory to allow users to direct where the jar will be generated. You may have to grab it there and build it yourself. HTH, Henry Dmitry Beransky wrote: I guess I was too quick to declare victory. While the compiled classes do go into the newly configured directory, the jar file is still being placed into the default directory, which in my case, happens to be smack in the middle of the versioned source tree. So, how can I change the output directory for the package goal? Is there a universal way to divert output of any and all goals? Thanks Dmitry At 08:58 PM 1/10/2006, Henry Isidro wrote: Dmitry Beransky wrote: worked like a charm! I ended up putting the following into the profile section: properties buildDir${java.io.tmpDir}/maven/${pom.artifactId}/buildDir /properties now the settings file is portalble among different platforms. Very cool, indeed. Thanks Dmitry I was thinking in the lines of using profiles in settings.xml or profiles.xml where you specify a property which would be used in the pom, ie: - inside profiles.xml (which resides only in the system that is used): profiles profile idmyProfile/id properties myoutputc:\test\target/myoutput /properties /profile /profiles - inside pom.xml (which is portable): build outputDirectory${myoutput}/outputDirectory /build - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [PROBLEM SOLVED but is it a bug?] Re: [m2] remote repository artifact update / local repository for multiproject question
Loïc Lefèvre wrote: Hello Henry, first, thanks for your answer :o) NP :-) 2/ Yes, Remember: local repository defined ... repositories repository idXXX/id nameLocal repository for XXX builds./name urlfile://${basedir}/thirdparty/url layoutdefault/layout /repository /repositories ... but I get: Downloading: file://L:\projects\xxx\xxx-common/thirdparty/jgroups/jgroups-all/2.2.9/jgroups-all-2.2.9.pom [WARNING] Unable to get resource from repository XXX in fact following is what I tried without success: -1- urlfile://${basedir}/thirdparty/url -2- urlfile://./thirdparty/url -3- urlfile://../thirdparty/url Then I got a part of the answer, when I was using: urlfile://L:\project\XXX\thirdparty/url : it works with \ but not with / So the right answer is: urlfile://.\thirdparty/url But I wonder if I've discovered some bug... ^_^; Cheers, Loïc hso a '\' works and not a '/'? That's weird...maybe some of the devs can help as I'm not too familiar with the core. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: M2 - Help needed with profiles
Hi Sanjay, Can you post the errors you're getting? Regards, Henry Sanjay Choudhary wrote: I read the following on maven website Profiles specified in the POM can modify the following POM elements: - *repositories* - *pluginRepositories* - *dependencies* - *plugins* - *properties* (not actually available in the main POM, but used behind the scenes) - *modules* - *reporting* - *dependencyManagement* - *distributionManagement* - a subset of the *build* element, which consists of: - *defaultGoal* - *resources* - *testResources* - *finalName* *I am interested in creating two profiles to modify eclipse plugin in the parent POM. One profile is for EJB project and other one is for Java project. I guess this is not the right way of doing it as I get errors when I do so. Please help me in configuring the profile right way. This will save me from duplication the plugin in code in serveral projects.* ** profiles profile idjavaprojects/id activation property namepackage/name valuejar/value /property /activation build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-eclipse-plugin/artifactId configuration classpathContainers java.lang.String org.eclipse.jdt.launching.JRE_CONTAINER /java.lang.String java.lang.String com.ibm.wtp.server.java.core.container /com.ibm.etools.websphere.runtime.core.runtimeTarget.v50/was.base.v5 /java.lang.String /classpathContainers buildcommands java.lang.String org.eclipse.jdt.core.javabuilder /java.lang.String java.lang.String com.ibm.sse.model.structuredbuilder /java.lang.String java.lang.String com.ibm.etools.ctc.serviceprojectbuilder /java.lang.String /buildcommands projectnatures java.lang.String org.eclipse.jdt.core.javanature /java.lang.String java.lang.String com.ibm.etools.ctc.javaprojectnature /java.lang.String /projectnatures /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-jar-plugin/artifactId configuration archive indextrue/index manifest addClasspathtrue/addClasspath /manifest manifestEntries modedevelopment/mode url${pom.url}/url /manifestEntries /archive /configuration /plugin plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-compiler-plugin/artifactId configuration compilerVersion1.3/compilerVersion /configuration /plugin /plugins /build /profile profile idejbprojects/id activation property namepackage/name valueejb/value /property /activation plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution idWSEJBDEPLOY/id phasepackage/phase configuration tasks echo message=This is test message/ /tasks /configuration goals goalrun/goal /goals /execution execution phasecompile/phase configuration tasks copy todir=target/classes/META-INF fileset dir=ejbModule/META-INF include name=**.xm*/ /fileset /copy /tasks /configuration goals
Re: [m2] jboss plugin location? Not where it is suppose to be...
you need svn for that: http://subversion.tigris.org/ - Henry Mick Knutson wrote: How would I do that in wincvs? Or dos? --- Thank You Mick Knutson Sr. Java/J2EE Consultant BASE logic, inc. (415) 648-1804 (S.F., CA) http://www.BASELogic.com Washington Mutual (WAMU) (Emeryville, California) --- From: Ralf Quebbemann [EMAIL PROTECTED] Reply-To: Maven Users List users@maven.apache.org To: Maven Users List users@maven.apache.org Subject: Re: [m2] jboss plugin location? Not where it is suppose to be... Date: Thu, 12 Jan 2006 19:42:18 +0100 Mick, you have to check it out from svn (svn://svn.codehaus.org/mojo/scm/trunk/mojo/jboss-maven-plugin) Docs can be found here: http://mojo.codehaus.org/jboss-maven-plugin/ Ralf Mick Knutson wrote: I found the documentation on the mojo site, but I havce looked in the ibiblio and snapshot repositories, and can't seem to find jboss-maven-plugin. Shouldn't it be located: http://www.ibiblio.org/pub/packages/maven2/org/codehaus/mojo/ as defined: plugin groupIdorg.codehaus.mojo/groupId artifactIdjboss-maven-plugin/artifactId version1.0/version configuration jbossHomeC:/jboss-4.0.3SP1/jbossHome port9090/port /configuration /plugin --- Thank You Mick Knutson Sr. Java/J2EE Consultant BASE logic, inc. (415) 648-1804 (S.F., CA) http://www.BASELogic.com Washington Mutual (WAMU) (Emeryville, California) --- From: Mick Knutson [EMAIL PROTECTED] Reply-To: Maven Users List users@maven.apache.org To: users@maven.apache.org Subject: [m2] jboss plugin docs location? Date: Thu, 12 Jan 2006 09:32:13 -0800 I want to use the jboss plugin to deploy my ear, but I can't find the docs for it. Can someone please point me to the docs, or show an example of how to use this plugin? --- Thank You Mick Knutson Sr. Java/J2EE Consultant BASE logic, inc. (415) 648-1804 (S.F., CA) http://www.BASELogic.com Washington Mutual (WAMU) (Emeryville, California) --- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] remote repository artifact update / local repository for multiproject question
Hi Loïc, Please see inline answers. Questions: 1/ What is the process to (ask for) update on remote repository? I've found a broken link on the maven webpage: http://maven.apache.org/guides/introduction/introduction-to-repositories.html http://maven.apache.org/guides/guide/guide-ibiblio-upload.html%7DUploading%20to%20Ibiblio doesn't seem to work :o( Page Not Found Sorry, the page you requested was not found. This may because: * The page has moved, was outdated, or has not been created yet * You typed the address incorrectly * You following a link from another site that pointed to this page ... Check out this URL for guide: http://maven.apache.org/guides/mini/guide-ibiblio-upload.html 2/ Is the ${basedir} evaluation I speak of the normal behavior? If yes, could it be possible to add a property like for example: maven.reactor.basedir? Have you tried placing an absolute path in your POM? It may solve your basedir problems. HTH, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Global override of scope version
Hello Kees, Seems to be a transitive dependency issue. Check this out: http://docs.codehaus.org/display/MAVENUSER/FAQs#FAQs-CanIdisabletransitivedependencies%3F HTH, Henry Kees de Kooter wrote: I am packaging a war and amazingly it twice as large in size compared to the old ant build. I notice a couple of things: 1. a lot of jars (e.g. junit) are being packaged that really should only have provided or test scope. The reason is that some poms forgot to give junit test scope. 2. a lot of jars are present with different versions I would like to be *in charge* here. How can I set the actual scope of jars and how can I rule out different versions of jars? thanx -- Kees de Kooter - 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: EAR and non-repository libraries questions
Hi Ilya, Please see inline answers. Ilya Sterin wrote: Hello, I have two questions. First, I'm still trying to figure out how to generate an ear archive from a multi-module project. The site, nor google has any documentation on this, other than a listing of goals and/or how to customize the module. Also, most stuff on google refers to maven 1, and I'm using 2. In a multi-module project, you can have a submodule for the ear itself and separate submodules for the other artifacts that you want in your ear, ie: - parent - submodule 1 (can be a war, jar, ejb or anything) - submodule 2 (can be a war, jar, ejb or anything) - submodule n (ear) In the ear submodule, be sure to specify packaging as ear and place any of the submodules above it as dependencies. My second question is again, due to me not being able to find documentation. How do I use libraries that are not in the ibiblio repository, nor anywhere else. Is the only way to have them in a maven like repository? Can I point it to a directory/jar file somewhere on my local and/or remote drive? You can either ask for it to be uploaded to ibiblio, http://maven.apache.org/guides/mini/guide-ibiblio-upload.html or you can place it (install) in your local repository by: http://maven.apache.org/guides/mini/guide-installing-3rd-party-jars.html HTH, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Overwriting a goal in subproject
I mean try placing this in the child pom: plugin ... configuration inherited${inheritGoal}/inherited /configuration /plugin It might override the parent's setting. HTH, Henry Dixit, Sandeep (ProSource Solutions) wrote: No, I rather don't know how to override a phase:goal written using maven-antrun-plugin. Could you give me an example? Thanks, Sandeep -Original Message- From: Henry Isidro [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 10, 2006 6:45 PM To: Maven Users List Subject: Re: Overwriting a goal in subproject Dixit, Sandeep (ProSource Solutions) wrote: How would that allow selective on and off? Wouldn't it set one value for all (parent and child projects)? Thanks, Sandeep Yup, sorry about that, I didn't fully understand your question. Have you tried overriding the property in the child pom? - Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: compile - removing source files from target directory
Hi Sean, Can you explain what you mean by source files being copied to the target directory? AFAIK, this isn't the case, source files are never copied to the target directory. Regards, Henry Sean Clarkson wrote: Hi, I'm new to Maven 2 - I was wondering if there was any setting you could add to the compiler to prevent source files being copied to the target directory, or removing them automatically after compilation. Do I need to use the process-classes phase and do something there with an additional goal, or can I actually prevent the source being copied cheers Sean - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Overwriting a goal in subproject
oops make that: inheritedfalse/inherited -Henry Henry Isidro wrote: I mean try placing this in the child pom: plugin ... configuration inherited${inheritGoal}/inherited /configuration /plugin It might override the parent's setting. HTH, Henry Dixit, Sandeep (ProSource Solutions) wrote: No, I rather don't know how to override a phase:goal written using maven-antrun-plugin. Could you give me an example? Thanks, Sandeep -Original Message- From: Henry Isidro [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 10, 2006 6:45 PM To: Maven Users List Subject: Re: Overwriting a goal in subproject Dixit, Sandeep (ProSource Solutions) wrote: How would that allow selective on and off? Wouldn't it set one value for all (parent and child projects)? Thanks, Sandeep Yup, sorry about that, I didn't fully understand your question. Have you tried overriding the property in the child pom? - Henry - 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: Overwriting a goal in subproject
Dixit, Sandeep (ProSource Solutions) wrote: How would that allow selective on and off? Wouldn't it set one value for all (parent and child projects)? Thanks, Sandeep Yup, sorry about that, I didn't fully understand your question. Have you tried overriding the property in the child pom? - Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] outputDirectory
Dmitry Beransky wrote: Hi, I'm trying to migrate for the first time one of my projects to Maven2. In Maven 1, I used to have the following line in the user level configuration file: maven.build.dir=c:/temp/maven/${pom.artifactId} this was for Windows-based workstations; on a server, the build directory would be set to a different pattern. How do I achieve a similar effect with Maven 2? Please note that I don't want to specify the output directory inside a pom file, as this directory may changed with the system on which the project is compiled. Thanks Dmitry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Have you tried using profiles? http://maven.apache.org/guides/introduction/introduction-to-profiles.html Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] outputDirectory
Rinku wrote: I don't see an outputDirectory/ specified under build/ element for profile/ in the pom descriptor. http://maven.apache.org/maven-model/maven.html Not sure if its an 'error of omission' in online docs or if a profile does (or does not) supports overriding the build outputDirectory? You might want to give it a shot though - I'd be interested to know the result as well :-) TIA, Rahul I was thinking in the lines of using profiles in settings.xml or profiles.xml where you specify a property which would be used in the pom, ie: - inside profiles.xml (which resides only in the system that is used): profiles profile idmyProfile/id properties myoutputc:\test\target/myoutput /properties /profile /profiles - inside pom.xml (which is portable): build outputDirectory${myoutput}/outputDirectory /build Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] outputDirectory
Dmitry Beransky wrote: worked like a charm! I ended up putting the following into the profile section: properties buildDir${java.io.tmpDir}/maven/${pom.artifactId}/buildDir /properties now the settings file is portalble among different platforms. Very cool, indeed. Thanks Dmitry I was thinking in the lines of using profiles in settings.xml or profiles.xml where you specify a property which would be used in the pom, ie: - inside profiles.xml (which resides only in the system that is used): profiles profile idmyProfile/id properties myoutputc:\test\target/myoutput /properties /profile /profiles - inside pom.xml (which is portable): build outputDirectory${myoutput}/outputDirectory /build - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Glad to hear it worked! Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Overwriting a goal in subproject
Dixit, Sandeep (ProSource Solutions) wrote: I apologize. Error on my part... inheritedfalse/inherited did work. I have one more question: Project structure: -- LEVEL 1: GENRIC_PROJ: has app server deploy goal LEVEL 1: PROJ_PARENT: inherits GENRIC_PROJ and SHOULD NOT inherit the deploy goal LEVEL 2:PROJ_CHILD: inherits PROJ_PARENT and SHOULD NOT inherit the deploy goal LEVEL 2:PROJ_CHILD_2: inherits PROJ_PARENT and SHOULD inherit the deploy goal Can I achieve the above - selective on and off? Thanks, Sandeep You can try using properties. In your pom.xml, add the ff: properties inheritGoalfalse/inheritGoal !-- this will serve as the default value -- /properties In your plugin configuration, do this: configuration ... inherited${inheritGoal}/inherited /properties Then, when you want the goal to be inherited, you invoke maven by passing a value to the property: mvn -DinheritGoal=true install Let me know if this works. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] how to change maven-jar-plugin's basedir ?
Man-Chi Leung wrote: how can I change the generated jar location from default project_dir/target/ to project_dir/target/lib? plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-jar-plugin/artifactId configuration basedir/target/lib/basedir I want to do something like this. but ERROR! archive manifest addClasspathtrue/addClasspath mainClasscom.ever.beetles.SimpleJxtaApp/mainClass /manifest /archive /configuration /plugin [INFO] [ERROR] BUILD ERROR [INFO] [INFO] Error configuring: org.apache.maven.plugins:maven-jar-plugin. Reason: ERROR: Cannot override read-only parameter: basedir in goal: jar:jar [INFO] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] I looked at the jar plugin source and as expected, basedir is readonly. I don't think you can change it via this way unless you edit the jar plugin source. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] how to change maven-jar-plugin's basedir ?
Henry Isidro wrote: Man-Chi Leung wrote: how can I change the generated jar location from default project_dir/target/ to project_dir/target/lib? plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-jar-plugin/artifactId configuration basedir/target/lib/basedir I want to do something like this. but ERROR! archive manifest addClasspathtrue/addClasspath mainClasscom.ever.beetles.SimpleJxtaApp/mainClass /manifest /archive /configuration /plugin [INFO] [ERROR] BUILD ERROR [INFO] [INFO] Error configuring: org.apache.maven.plugins:maven-jar-plugin. Reason: ERROR: Cannot override read-only parameter: basedir in goal: jar:jar [INFO] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] I looked at the jar plugin source and as expected, basedir is readonly. I don't think you can change it via this way unless you edit the jar plugin source. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] I tried removing the readonly setting from the basedir property from the jar plugin source and I was able to change the basedir property using your configuration. I don't know why the basedir property is readonly. Maybe you should file a JIRA issue regarding this. Regards, henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Copy Jar?
Davis Ford wrote: Thanks Brian, I will check into dependency-maven-plugin. In the meantime, I had solved it. This seems to be anti-Maven, b/c it uses an environment variable, but it seems to work. I added these two goals to maven.xml goal name=check-props j:if test=${context.getVariable('geoserver.home') == null} j:if test=${context.getVariable('env.GEOSERVER_HOME') == null} failPlease set either env-var GEOSERVER_HOME or Maven var geoserver.home/fail /j:if echoSetting geoserver.home to ${env.GEOSERVER_HOME}/echo j:set var=geoserver.home value=${env.GEOSERVER_HOME}/ /j:if /goal goal name=geoserver prereqs=jar, check-props description=Copy the Diamond Jar to GeoServer echoGeoServer Home is = ${geoserver.home}/echo ant:copy file=${maven.build.dir}/${maven.final.name}.jar todir=${geoserver.home}\server\geoserver\WEB-INF\lib/ /goal You could also place the GEOSERVER_HOME variable in the project.properties file so you don't have to use context.getVariable(). This way, you just have to tell your developers to change the setting in their copy of the project.properties file. - Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: project.xml file
[EMAIL PROTECTED] wrote: Hello, I'm trying to compile a simple program using: mave java:compile command. build:start: java:prepare-filesystem: java:compile: [echo] Compiling to C:\repotest/target/classes [echo] No java source files to compile. BUILD SUCCESSFUL When I looked for the above command, I found that: The source code directory is specified in the build element of your project.xml file. So my question is the following: Should every project have his own project.xml file? Thank you for your reply. Leïla P.S: Happy new Year to everyone :-) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] I'm assuming you're working with Maven 1. The project.xml file contains information the maven uses in building your project. So, in short, yes you need a project.xml file for every project. :) - Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: IDE build and debugging
Sebastien Arbogast wrote: Is there a way to integrate Maven (1 or 2) into an IDE (IntelliJ or Eclipse) so that I can use the debugging capacities of my IDE : breakpoints, line-by-line execution, watchpoints, etc. ? -- Sébastien Arbogast Blog : http://www.sebastien-arbogast.com The Epseelon Project : http://www.epseelon.org Projet Phénix : http://phenix.netbios.fr Lens : http://www.squidoo.com/useful-computers/ No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.1.371 / Virus Database: 267.14.1/206 - Release Date: 12/16/2005 Hi Sebastien, For M1, take a look at http://mevenide.codehaus.org/. For M2, http://maven.apache.org/plugins/maven-eclipse-plugin/. HTH, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Is it possible to setup a backup repository?
Matt Raible wrote: Is it possible to check a mirror of ibiblio for dependency if ibiblio is down? If I put the following in my pom.xml, it checks this mirror first, rather than ibiblio. It seems like a better practice to check ibiblio first. repositories repository idplanetmirror/id namePlanet Mirror (backup central repository)/name urlhttp://public.planetmirror.com/pub/maven2/url /repository /repositories Thanks, Matt - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] I am not sure of this but I think that the repository with an id of 'central' is always checked last. Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: propoer Jelly doc + samples
Michael Niemaz wrote: Hi all, I'm looking for pointers to jelly documentation and samples, a part from the tab libraries documentation on maven. I'm kinda struggling to write scripts so I thought there would a place somewhere that would help me. thanx, --mike - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Hi Mike, Check these sites out: http://maven.apache.org/maven-1.x/reference/scripting.html http://maven.apache.org/maven-1.x/using/developing-plugins.html HTH, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] How du I use the latest versions of plugins?
Baard Johansen wrote: Hi, I installed the binary Maven 2.0 distribution, and was hoping that the latest version of plugins were to be used. This appears not to be so. For instance, for the maven-site-plugin my Maven use the 2.0-beta-2 version, instead of the latest 2.0-beta-4. How can I tell my maven installation (or the current project) to deploy the site using 2.0-beta-4? I run a corporate-wide maven-proxy, but I don't think that should cause this trouble. Thanks, -- Baard Johansen Cronus Engineering AS http://www.cronus.no - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Hi Baard, Try placing this in your pom: plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-site-plugin/artifactId version2.0-beta-4/version /plugin /plugins Hope this helps, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Questions on assembly plugin
Jochen Wiedmann wrote: Hi, I'd like to use the assembly plugin for creating distributions. After reading the documentation and doing some first attempts, I do have the following questions: - There are predefined ID's like bin and src. These are (to me) very welcome for reading as examples. However, they do not really meet my requirements. I'd like to override them. Is that possible? You can override them by creating an assembly descriptor and placing bin or src in the id tag. - In my project I will typically always use bin and src. It would be nice, if I could configure both into the POM, so that an invocation of mvn assembly:assembly will create these two files. However, it only seems possible to create a single file. Haven't tried this yet, but you can use executions to assemble a bin then an src. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Dependency on a non-maven project?Need advice
li pan wrote: Hi, If my project depends on another project which is neither writen by myself nor has a maven POM(there are tons of these type on www.sf.net), what is the best way to include it in my project? Thanks Maven dependencies are named: artifactId-version.package so the first to do would be to rename your dependency in that pattern (i.e. myproject-1.0.jar). Then you have to place this in your local repository. Have a look at http://maven.apache.org/guides/introduction/introduction-to-repositories.html and http://maven.apache.org/guides/mini/guide-installing-3rd-party-jars.html. HTH, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] assembly headache
Arnaud Bailly wrote: Hi, I have a project that contains a bunch of modules and I want to make a source distribution of each module. Do I need to configure assembly in each module ? What is the configuration ? I tried to copy verbatim what's on the FAQ but it doesn't work :-( Nothing gets done in the install phase... How can I aggregate everything in one single zip/targz ? Thanks, AFAIK, the assembly plugin is still not tied to any build lifecycle phase. You have to manually invoke it via the command line. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] Downloading source-code jar files ?
Christian Schulte wrote: Hi, how do I make maven fetch e.g. junit-3.8.1-sources.jar so that this file gets copied into the local repository ? I tried putting a dependency to it in the root pom like this dependencies dependency groupIdjunit/groupId artifactIdjunit/artifactId version3.8.1/version typesources.jar/type scopeprovided/scope /dependency /dependencies but it seems to be incorrect. Hi Christian, Try this: dependencies dependency groupIdjunit/groupId artifactIdjunit/artifactId version3.8.1-sources/version typejar/type scopeprovided/scope /dependency /dependencies HTH, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: M2 : How to add local NON-installed JARs to the build path for projects.
Matthew Wheaton wrote: Hello, I am an avid Maven fan, and am struggling to understand how to model my new projects based on my Maven 1.x experience. I have a number of Eclipse projects, one called csi_libs. csi_libs, contains all the compile time (and some deployment) 3rd party jars needed across all projects. In Maven 1.x, I simply had a simple Ant task that added all the jars to the classpath for builds, like so: goal name=build:SetClasspath description=Sets the classpath echo message=Setting the compile classpath . . . / ant:path id=all.libs.path !-- get all the deployment libs -- ant:fileset dir=${build.deployLibs} ant:include name=**/*.* / /ant:fileset !-- get all the compile only libs -- ant:fileset dir=${build.compileLibs} ant:include name=**/*.* / /ant:fileset /ant:path m:addPath id=maven.dependency.classpath refid=all.libs.path / /goal I'm struggling on how to replicate this behavior in Maven 2. Anyone out there who can assist ? Thank you. Sincerely, Matthew Wheaton One of Maven's strengths is its dependency handling mechanism. If you manually add your dependencies to the classpath, then you're not using Maven's full potential. Although this would work, (you could use the antrun plugin) it is better to register your dependencies in the pom and let Maven handle them. This entails placing your dependencies in your repository which organizes and centralizes the location of your artifacts. Check this link out for more info on the dependency mechanism of M2: http://maven.apache.org/guides/introduction/introduction-to-dependency-mechanism.html Regards, - Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How not to include all jar files from parent pom?
Stephane Nicoll wrote: Use the right scope. If you don't want them to be included, specify the scope of your dependency (compile / provided). Hope it helps, Stéphane Just to clarify things further, the compile scope includes the dependencies in the final package and the provided scope does not. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Dependencies
Markus M. May wrote: Also each component generates more then one artifact (one for the EJBs, one common and at least one for the client side, and sometimes one for the resources - this is needed for JWS). Would this be possible with Maven2 as well? I heard something about masks and filters -are they the right way to go? Greets Markus - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Though this can be done, it not recommended. Try splitting the component into several modules, one for EJB, one for client and so on. This will make it easier to manage the artifacts that you create. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[m2] maven-antrun-plugin classloading issues?
Hi. I'm trying to run an ant task from the antrun plugin. When I try to define some dependencies as provided so that the packaging won't include them, the build stops and complains that the ant task can't find classes found in those provided dependencies. Everything works fine if I specify compile but that includes the dependency in the package which is what I do not want. Is there a workaround to this or do I just have to live with the dependencies being bundled in with my package? Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: EJB with Maven2
Alexandre Poitras wrote: Just wanted to add, that you need a subproject C to produce the ear file and include jars A and B. It is quite easy to setup. Look in the guides on the Maven site but don't be shy to ask if you need any help! On 11/23/05, Alexandre Poitras [EMAIL PROTECTED] wrote: I had the same problem but it's quite easy to fix. What do you want is to add class-path entries in the manifest file of your ejb jar. Of course, Maven can do all of that for you. You just need to add this section to your B subproject pom file (I supposed the packaging specified for it is ejb) : project ... build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-ejb-plugin/artifactId configuration archive manifest addClasspathtrue/addClasspath /manifest /archive /configuration /plugin /plugins /build ... /project By the way, all those configuration options come from the jar plugin (wich ejb plugin extends). You can take a look at the following documentation for more details : http://maven.apache.org/guides/mini/guide-manifest.html It has fixed the problem in my case on Oracle oc4j but the way the classpath is contructed is standard so it should work without any problems on JBoss. Hope it's help. On 11/23/05, Duane Homick [EMAIL PROTECTED] wrote: I have a simple (hopefully) EJB question, but I couldnt find an answer on the website: I have a project that has two subprojects A B. Subproject A contains a message driven bean. Subproject B contains a utility library. Subproject A has a dependency on B since it uses that utility library. B has packaging of jar A has packaging of ejb How would I deploy this to an application server? If I do it now using the jboss:harddeploy of A, it will deploy the A-1.0.jar, but it will fail when running because B is not in the classpath (as expected). So, the question becomes 1) should B be packaged as part of A? 2) should B and A be packaged together in a third subproject called C that produces an ear? 3) some other option? Thanks Duane Homick Sandvine Incorporated - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Alexandre Poitras Québec, Canada -- Alexandre Poitras Québec, Canada - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] You could package the jar inside the ejb-jar but creating an EAR file with both jars inside it is the way to do it. Deploy that EAR to your container and everything should be fine. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: EJB with Maven2
Alexandre Poitras wrote: I think he also needs to add manifest entries so the ejb jar can loads class from the other jar. If you don't do that your A project won't be in your B project class path. Yup you're right there...I didn't mention it anymore since you already said something about it. Anyway, hope this clears things up. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: EJB with Maven2
Duane Homick wrote: Thanks Henry and Alex for the help. Based on your suggestions, I was able to get this setup and running in JBoss with very few further complications. However, there was one complication that I had when defining my ear project. I setup a dependency on the ejb-jar project which in turn created a dependency on the jar utility project. However, the application.xml file did NOT contain any modules in it. It wasn't until I set the dependency/type to ejb for my dependency on the ejb-jar file that it was able to realize it needed to add an ejb-module to my application.xml. Is this a bug? I figured Maven would be able to determine the dependency type itself without needing me to specify the type explicitly. Other than that, it works like a charm. Thanks for the help! -Original Message- From: Henry Isidro [mailto:[EMAIL PROTECTED] Sent: November 23, 2005 10:15 PM To: Maven Users List Subject: Re: EJB with Maven2 Alexandre Poitras wrote: I think he also needs to add manifest entries so the ejb jar can loads class from the other jar. If you don't do that your A project won't be in your B project class path. Yup you're right there...I didn't mention it anymore since you already said something about it. Anyway, hope this clears things up. Regards, Henry - 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] No porblem :-) Not sure about the dependency/type thingy though...I always specify the 'ejb' type :-) maybe brett or one of the devs can shed some light on this Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: about the maven-antrun-plugin phase!
[EMAIL PROTECTED] wrote: Dear All: who can tell me the all phase about maven-antrun-plugin and the detail description about every phase? thanks. plugin artifactIdmaven-antrun-plugin/artifactId executions execution phasepackage/phase what is the other phase except generate-sources? /plugin If any question, please contact with me. Thank you! Regards Jerry Tao ___ Hactl..Moving forward with you. Best Air Cargo Terminal - Asia 2005 Air Cargo Terminal of the Year 2002, 2003 2004 Web: http://www.hactl.com DISCLAIMER :- The information contained in this message, including any attachment, is confidential and may also be privileged. The information is intended only for the person or entity to which it is addressed. Any review, re-transmission, copying, storage, distribution or other use or disclosure of this information by persons or entities other than the intended recipient is prohibited. If you are not the intended recipient, please contact the sender immediately by return email and delete this message from your system. Thank you. __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Hi Jerry, Please take a look at this -- http://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html This explains the build life cycle and the phases you are looking for. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[Fwd: Re: [m2] RAR plugin]
Stephane Nicoll wrote: Well it should. Could you please show your POM and the structure of your project please? Thx, Stéphane On 11/21/05, Henry Isidro [EMAIL PROTECTED] wrote: I'm using the RAR plugin and I found out that it does not create a JAR file to include in the package. So, I invoked the JAR plugin and everything worked fine. Now, I tried using the install plugin to install the rar file into my local repository and what happened was the plugin installed the JAR file into my local repository renaming it as a RAR file! The generated RAR file was untouched. Here is what my POM looks like: project modelVersion4.0.0/modelVersion artifactIdmy-ra/artifactId packagingrar/packaging nameMy Resource Adapter/name build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-jar-plugin/artifactId version2.0/version executions execution idcreate-jar/id phasecompile/phase goals goaljar/goal /goals /execution /executions /plugin /plugins /build dependencies /project I called M2 by the command 'mvn install'. Any thoughts would be greatly appreciated. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- .::You're welcome ::. Hi Stephane, My pom looks like the one I wrote in my first post. My directory structure looks like this: my-ra src main java rar test java resources Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[m2] RAR plugin
I'm using the RAR plugin and I found out that it does not create a JAR file to include in the package. So, I invoked the JAR plugin and everything worked fine. Now, I tried using the install plugin to install the rar file into my local repository and what happened was the plugin installed the JAR file into my local repository renaming it as a RAR file! The generated RAR file was untouched. Here is what my POM looks like: project modelVersion4.0.0/modelVersion artifactIdmy-ra/artifactId packagingrar/packaging nameMy Resource Adapter/name build plugins plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-jar-plugin/artifactId version2.0/version executions execution idcreate-jar/id phasecompile/phase goals goaljar/goal /goals /execution /executions /plugin /plugins /build dependencies /project I called M2 by the command 'mvn install'. Any thoughts would be greatly appreciated. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] RAR plugin
Brett Porter wrote: That bug is fixed in SVN - however, I'm not sure that the exceution should be needed, but I don't quite understand what you are attempting - hopefully someone with more RAR experience than me (that's anyone :) will know the answers. - Brett There are two problems I encountered using M2 version 2.0. The first is that when I set packagingrar/packaging in my pom, M2 compiles my sources and creates a RAR file but my compiled sources which should be in a JAR file that should be included in the packaged RAR file is not created. I solved that problem by using the JAR plugin. The next problem is that when I try to install the RAR file, M2 copies the JAR file into my local repository and renames it into a RAR file. What should happen is that the RAR file (which contains the JAR file) is that one that should be copied. It seems that the artifact installer looks for a JAR file and copies it into the repository and just renames it into the required packaging. Hope this clears things up. Anyway, I'm going to try using the fixed version in SVN. This may solve my problems. Thanks! Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [M2] [M1] Multiproject dependencies question
Ballard, Ken wrote: This is a question for Maven 1 2, although I know that the answers will be different. Let's say that I have a multiproject with subprojects. Some build jars, one builds a war, a couple that build an ejb jar and an ejb client jar, and one builds an ear. Now let's say that I need the Spring jar in a jar subproject or two, the war subproject, an ejb subproject, and the ear subproject. When I upgrade to Spring 1.2.6, I need to go upgrade all the project.xml (M1) or pom.xml (M2) files. There's a good chance for missing something there. In M1, I could define custom property in the project.properties file like spring.jar.version. But would this be the best practice, or is there a better way? And what about M2, which doesn't use a project.properties file? Thanks, Ken - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Hi Ken, In M1, you have to go the property route. M2 handles it more gracefully. List your dependencies under the dependencyManagement tag in your parent pom and any child poms will inherit those versions automatically. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [m2] was5 plugin
Dion Gillard wrote: As the defacto maintainer of the maven 1 was5 plugin, and someone who isn't moving to m2 at this point, we've been asked this at sourceforge a couple of times, but it needs someone to step up and do the work. The antrun plugin probably couldn't be used (guessing here), as the was5+ ant tasks must be executed using a special ant launcher (ws_ant). I thought Cargo was supposed to do all this stuff, or does it not support WebSphere? On 11/17/05, Malcolm Wong Ho [EMAIL PROTECTED] wrote: Is there plans for websphere 5.1 plugin for maven2 ? Malcolm Wong Ho An investment in knowledge always pays the best interest. -- Benjamin Franklin This e-mail is sent on the Terms and Conditions that can be accessed by Clicking on this link http://www.vodacom.net/legal/email.aspx -- http://www.multitask.com.au/people/dion/ You are going to let the fear of poverty govern your life and your reward will be that you will eat, but you will not live. - George Bernard Shaw - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] I don't think Cargo supports websphere yethttp://cargo.codehaus.org/ Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to include dependencies when building/installing a .jar ???
Matthew L Daniel wrote: Is there an easy/built in way to include the dependency jar files when building a jar package? Or do I need to build my own plugin? Sounds suspiciously like an EAR to me. If you ignore the META-INF/application.xml, it's a zip file with all your jars packaged together. That said, if you're deploying to a server, chances are you would really want to use the actual deployed artifact type (war is another that will do this). My USD$0.02, -- /v\atthew - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] I agree...if you make a WAR, you can include the dependencies into the package by setting the war.bundle property of the dependency in the pom to true. - henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Component Descriptor Error Message
Simon McClenahan wrote: I'm running Maven under Windows, and I was unable to specify the drive letter. Conveniently I do everything on my C: drive, and I have ended up using the following: maven.repo.remote=file:///localhost/projects/online/trunk/,http://www.ib iblio.org/maven/ I know it doesn't seem right, but I figured this out by trial and error. I'm using Maven 1.0.2. - Simon If you're using Maven 1.0.2, you could just place the jars in your local repository and not go through the trouble of mirroring a remote repository on your machine. Maven checks the local repository first for dependencies before attempting to download from the remote repository. Usually, the local repository is found in ${maven.home.local}/repository where maven.home.local is ${user.home}/.maven. So if you're using Windows, and your user name is for example, User1, your local repository would be found in C:\Documents and Settings\User1\.maven. Hope this clears up a few things. Regards, Henry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Dependencies and the local repository
Jarrell, Maury wrote: Forgive me for asking what must be a very basic question. I've searched the Maven site and scoured the archives for this list and haven't found an answer. I have a simple java project defined in an Ant file. The dependencies for my current project are in jars in the ${basedir}/lib directory. I've configured Ant to include in the classpath whatever jars it finds in that lib directory. I'm trying to duplicate this functionality with Maven, and I've hit a roadblock. I have jars that don't conform to Maven's idea of a standard name. An example would be the mail.jar from Sun's site. I use it. I tried a dependency entry in my project.xml as follows: dependency groupIdmail/groupID artifactIdmail/artifactId version1.3/version jarmail.jar/jar /dependency I tried putting the jar in ${HOME}/.maven/repository/jars, but it wasn't found. Then I tried to follow the format in the repository and made a directory structure as follows: $HOME/.maven/repository/mail/jars/mail.jar That appears to work, but is that what Maven expects me to do for each jar file? This seems like a lot of work for jars that will never be downloaded from a remote repository anyway. This all brings me to the fact that I don't grasp the remote repository concept. Is there 1 remote repository and it's global to the world? I went to http://www.imbiblio.org/maven and looked at the repository there. It seems small if it's supposed to be the global parking spot for Maven projects world-wide. Please forgive my misunderstanding, Maury Hi. I don't know if this will help but if you already have a copy of the jar dependency that you need, you can override Maven trying to download it from the central repository by setting the property maven.jar.override to on. Then you can set explicit paths of the dependency by setting the property maven.jar.{artifactID} to the path of the jar. You can place this in a project.properties file or a build.properties file. Anyway, hope this helps. Henry S. Isidro - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]