Re: How finding jar when knowing class from Maven ??
If you use Eclipse, you can press Ctrl + Shit + T, and type the class name. Of course, Eclipse must be aware of your jars. 2009/2/12 Mick Knutson mickknut...@gmail.com: http://javacio.us/subscribers/classes/org.apache.maven.MavenUtilstag=maven --- Thank You… Mick Knutson, President BASE Logic, Inc. Enterprise Architecture, Design, Mentoring Agile Consulting p. (866) BLiNC-411: (254-6241-1) f. (415) 685-4233 Website: http://baselogic.com Linked IN: http://linkedin.com/in/mickknutson Twitter: http://twitter.com/mickknutson Vacation Rental: http://tahoe.baselogic.com --- On Thu, Feb 12, 2009 at 12:23 PM, Mick Knutson mickknut...@gmail.comwrote: http://letmegooglethatforyou.com/?q=http%3A%2F%2Fjavacio.us%2Fsearch%3Fcx%3D014543831828880571631%253Alhbnm247enc%26cof%3DFORID%253A9%26channel%3D2700477483%26ie%3Diso-8859-1%26q%3DMavenUtils%2B%26sa%3DSearch%231310 I could not resist. ;-) --- Thank You… Mick Knutson, President BASE Logic, Inc. Enterprise Architecture, Design, Mentoring Agile Consulting p. (866) BLiNC-411: (254-6241-1) f. (415) 685-4233 Website: http://baselogic.com Linked IN: http://linkedin.com/in/mickknutson Twitter: http://twitter.com/mickknutson Vacation Rental: http://tahoe.baselogic.com --- On Thu, Feb 12, 2009 at 12:18 PM, Pommier, Stephane stephane.pomm...@capgemini.com wrote: Hi Users ! I'm wondering how I can getting a jar when I know which class I want. For example, I want to use MavenUtils class but I don't where to find it... I'm just getting crazy when searching on the web ! Thanks in advance. Stéphane Pommier Capgemini Ouest / Brest Tel : +33 (0)2.98.33.32.35 / Fax: +33 (0)2.98.33.32.57 E-mail : stephane.pomm...@capgemini.com mailto: stephane.pomm...@capgemini.com 10, quai Commandant Malbert - 29200 Brest Together: the Collaborative Business Experience _ P Pensez à l'environnement et n'imprimez pas ce message à moins de nécessité absolue. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: M2Eclipse Plugin Seems can't resolve workspace dependency during build
Maven2 was unable to find http://repo1.maven.org/maven2/com/ocpsoft/ocpsoft-base/1.0.0/ocpsoft-base-1.0.0.pom In short, your artifact with : groupId com.ocpsoft artifactId ocpsoft-base version 1.0.0 doesn't exist in maven's public repository (if you try accessing the URL in the error message, you'll get 404 errors. BUT, you can download the jar file manually from here : http://prettyfaces.googlecode.com/files/ocpsoft-pretty-faces-1.0.0.jar save it on your disk, then install it manually by running : mvn install:install-file -DgroupId=com.ocpsoft -DartifactId=ocpsoft-base -Dversion=1.0.0 -Dpackaging=jar -Dfile=/path/to/file Should now compile. Hope this helps. Yves 2009/2/7 Lincoln Baxter, III lincolnbax...@gmail.com: Hi All, I am trying to run a build without installing my workspace dependencies into the local repository, however, I get this exception, and the build fails: How can I fix this? All projects required are in my workspace. I'm using Eclipse 3.4. Thanks, Lincoln [INFO] Scanning for projects... [INFO] [INFO] Building Hibernate Data Base Package [INFO] [INFO] Id: com.ocpsoft:ocpsoft-data:jar:1.0.0 [INFO] task-segment: [package] [INFO] [INFO] [resources:resources] [INFO] Using default encoding to copy filtered resources. url = http://repo1.maven.org/maven2 Downloading: http://repo1.maven.org/maven2/com/ocpsoft/ocpsoft-base/1.0.0/ocpsoft-base-1.0.0.pom url = http://repo1.maven.org/maven2 Downloading: http://repo1.maven.org/maven2/com/ocpsoft/ocpsoft-base/1.0.0/ocpsoft-base-1.0.0.pom url = http://repo1.maven.org/maven2 Downloading: http://repo1.maven.org/maven2/com/ocpsoft/ocpsoft-base/1.0.0/ocpsoft-base-1.0.0.jar [ERROR] Transitive dependency resolution for scope: compile has failed for your project. Error message: Missing: -- 1) com.ocpsoft:ocpsoft-base:jar:1.0.0 Try downloading the file manually from the project website. Then, install it using the command: mvn install:install-file -DgroupId=com.ocpsoft -DartifactId=ocpsoft-base -Dversion=1.0.0 -Dpackaging=jar -Dfile=/path/to/file Alternatively, if you host your own repository you can deploy the file there: mvn deploy:deploy-file -DgroupId=com.ocpsoft -DartifactId=ocpsoft-base -Dversion=1.0.0 -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id] Path to dependency: 1) com.ocpsoft:ocpsoft-data:jar:1.0.0 2) com.ocpsoft:ocpsoft-base:jar:1.0.0 -- 1 required artifact is missing. for artifact: com.ocpsoft:ocpsoft-data:jar:1.0.0 from the specified remote repositories: central (http://repo1.maven.org/maven2) Group-Id: com.ocpsoft Artifact-Id: ocpsoft-data Version: 1.0.0 From file: /gentoo/home/lb3/Projects/ocpsoft-data/pom.xml [INFO] [INFO] For more information, run with the -e flag [INFO] [INFO] BUILD FAILED [INFO] [INFO] Total time: 2 seconds [INFO] Finished at: Sat Feb 07 16:48:04 EST 2009 [INFO] Final Memory: 5M/80M [INFO] - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Execution sequence of three plugins on the same phase: process-classes
Hi. I've had the same problem. Finaly I ended up splitting it into subprojects. See also here : http://jira.codehaus.org/browse/MNG-2258 http://www.mail-archive.com/users@maven.apache.org/msg93651.html 2009/2/4 Thiago Moreira (timba) tmoreira2...@gmail.com: Hi there, I have three plugins that must be executed on the same phase (process-classes). How can I set the sequence on each one will be executed? Thanks in advance! Thiago Moreira - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Including project's sources in the same war file. Best practise?
Hi. I've been asked to include a project's sources into the same war (it is a war webapp). Where the best place to put the sources in the war file? What's the best way to do this ? - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Web library project archive conflicts with another archive also mapped to the WEB-INF/lib folder.
Hi, another error in the web project (in Eclipse) : Web library project archive commons-lang-1.0.1.jar conflicts with another archive also mapped to the WEB-INF/lib folder. I join a screenshot of the java Build Path window. All the libs after commons-lang are missing. What's going on ? - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: How do i use maven in my development environment
First, re-arrange your project like this : http://maven.apache.org/guides/introduction/introduction-to-the-standard-directory-layout.html Then, you write your pom.xml (either look for examples, or let Maven generate your project with the command) : mvn archetype:generate Choose : 18: internal - maven-archetype-webapp (A simple Java web application) enter any groupId, artifactID, version (1.0-SNAPSHOT). And you'll get a simple project set up (with an pom.xml example). 2009/1/29 MacMohan manmohanaror...@gmail.com: Hi, i m new to maven and have been asked to set up new development environment in my office. Mine is a small office of 8-10 developers. Till now we have CVS on one of remote servers and app servers(TOMCAT 5.x) running on individual developer machine. we use Eclipse 3.3 as Java IDE. Al the developers commit their work respective works from their machines and we create WAR file of the application manually through ANT using build.xml file. Our application is a non-EJB application with the following folder structure. myApplication |-- CSS(folder) |-- images |-- java scripts(folder) |-- JSP(folder) |-- WEB_INF(folder) ||-- classes ||-- lib ||-- src || |-- com || |-- companyName || |-- applicationName || |-- Java files in their respective folders || || ||--struts-config.xml | |--build.xm |--build.properties In the new development environment, we need CVS on a remote server, and Maven doing the ANT thing automatically on week-ends. We need Maven to compile our project and package it to WAR file and deploy it at a specific location on the server. I have been reading Maven 2.0.9 documentation and other helping material from last 3-4 days, but couldn't figure out how to use it practically. Where to put my applications JAVA files, lib folder, JSP's, etc. Please help. -- View this message in context: http://www.nabble.com/How-do-i-use-maven-in-my-development-environment-tp21722621p21722621.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 - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: create war and jar files at same time.
Okay. You can't define two packaging types (I think, not 100% sure). But, you can attach other plugins to the package phase. I did this. Something like this in your plugins section. Example: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-war-plugin/artifactId version2.1-alpha-1/version configuration !-- your war plugin conf here (see http://maven.apache.org/plugins/maven-war-plugin/war-mojo.html ) -- /configuration /plugin Forget about adding one more submodule :) Regards, 2009/1/27 Yves Dessertine yvesd.pub...@gmail.com: Okay. You can't define two packaging types (I think, not 100% sure). But, you can attach other plugins to the package phase. I did this. Something like this in your plugins section. Example: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-war-plugin/artifactId version2.1-alpha-1/version configuration !-- your war plugin conf here (see http://maven.apache.org/plugins/maven-war-plugin/war-mojo.html ) -- /configuration /plugin Forget about adding one more submodule :) Regards, Yves 2009/1/27 Minhaj minhaj...@gmail.com: thanks for your reply, but the problem is i want to create jar and war for the same module like we can do in ant...we can specify goals for creating jar and war separately and then execute by command prompt ant war or ant jar Tx Minhaj On Tue, Jan 27, 2009 at 2:57 PM, Yves Dessertine yvesd.pub...@gmail.com wrote: Is it an acceptable solution for you, to create one more subproject generating a jar. And then make the war-project depend on your jar ? PS : don't crosspost on dev and users (this questions has nothing to do with dev, don't ?) Yves 2009/1/27 Minhaj minhaj...@gmail.com: Hi, i am working on maven;s multi module project i have three modules with three pom.xml files all of them generating war files successfully and i want to generate a jar file as well for one of the module. i am confuse that how can we define two times the packaging tag in same pom.xml file. it can be done with Profiles?? Tx Minhajkk - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Sharing (big) parts of source across projects
Hi. I have an (Ant) project which generates a JAR, plus a WAR for webservices, to port to maven. I have a question about the best practises: 1) I created a subproject for the webservices, ok like this? 2) The Webservices uses lots of source from my main project what's the best approach ? Déclare two source path (ws + parent) ? Make the WS subproject depend on the parent project ? Thanks, Yves Dessertine - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Sharing (big) parts of source across projects
2009/1/26 Geoffrey Wiseman geoffrey.wise...@gmail.com: The WAR is your web services? What do you use the JAR for? Based on the limited understanding I have of your project, I'd say that basically, you want: myproject (pom project, no real implementation other than the two modules) - myproject-jar -- whatever this project is for; common? library? domain? JAR packaging. - myproject-web-services -- depends on myproject-jar as a JAR, WAR packaging. Thank you Geoffrey for your answer. Yes, that's what I want. It now compiles, thank you. The WAR contains the web services, and the JAR is a common lib, that we need to distribute. But, a new problem now pops up : can we build two versions of the JAR ? One light version to use with the Web services, and another, heavy version to distribute and full-featured ? While it works as it's now, the JAR included in the war, is much more heavy than before (where an Ant task picked up a few files to generate the lightweight jar). The few files are shared across the lightweight and the heavy jar... What to do now ? Put them in a seperate sub project ? - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Sharing (big) parts of source across projects
Well, this code is an enterprise project, which is quite complicated. the common are the bare minimum classes for the web services to work. The heavy is the programm which is deployed as part of a proprietary framework. Thanks for the answer, it's the solution we've adopted! 2009/1/26 Kent Närling kent.narl...@seamless.se: What is the reason for the heavy part for the full featured? More functionality? it has an UI? It seems you probably might to create something like: - myproject - myproject-common (jar) - myproject-heavy (jar) - myproject-webservices (war) 2009/1/26 Yves Dessertine yvesd.pub...@gmail.com 2009/1/26 Geoffrey Wiseman geoffrey.wise...@gmail.com: The WAR is your web services? What do you use the JAR for? Based on the limited understanding I have of your project, I'd say that basically, you want: myproject (pom project, no real implementation other than the two modules) - myproject-jar -- whatever this project is for; common? library? domain? JAR packaging. - myproject-web-services -- depends on myproject-jar as a JAR, WAR packaging. Thank you Geoffrey for your answer. Yes, that's what I want. It now compiles, thank you. The WAR contains the web services, and the JAR is a common lib, that we need to distribute. But, a new problem now pops up : can we build two versions of the JAR ? One light version to use with the Web services, and another, heavy version to distribute and full-featured ? While it works as it's now, the JAR included in the war, is much more heavy than before (where an Ant task picked up a few files to generate the lightweight jar). The few files are shared across the lightweight and the heavy jar... What to do now ? Put them in a seperate sub project ? - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org -- Kent Närling System Architect SEAMLESS Dalagatan 100, 8 tr, 113 43 Stockholm, Sweden Phone: +46 8 5648 7800, fax: +46 8 5648 7823 Mobile: +46 70 836 9925 Mail: kent.narl...@seamless.se www.seamless.se - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Dependent jars not included in package
Would something like this work for you ? for plugin jar:jar configuration includes include[PATH_TO_JARS]/include /includes /configuration 2009/1/22 jude.prak...@wipro.com Hi All, I have a java project which has dependencies on few jars. I have included those jars as dependencies. It works fine till unit testing and it refers the dependent jars. But while creating package(jar) the dependent jars are not getting included. Please let me know how to include the dependent jars in the package. Regards Jude Please do not print this email unless it is absolutely necessary. The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain proprietary, confidential or privileged information. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments. WARNING: Computer viruses can be transmitted via email. The recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email. www.wipro.com