Re: JDK sources
The JDK sources are provided as a ZIP with your JDK and should be detetcted by eclipse when you configure your installed JDK JEE sources depends on which API you consider. Some recent SUN official Jars have sources attached in maven repo, some simply are not available de to licensing restriction. You could then use genonimo ones that come with sources. Cheers, Nicolas 2009/7/2 Peter Horlock > Hi, > > I've asked that question before, yet as I didn't get an answer, I'll try > again: > I configured The Eclipse plugin so that it downloads all sources, and adds > them to my eclipse > project configuration, so that I can click on third Party classes in my > code > and see it's source code - > that way I don't need to read it's api any longer - VERY handy. > How can that be done with the JDK source and J2EE sources? I know where to > download them, > but I don't want to add them manually - whenever I reimport a project I > would have to do it anew. > Isn't there an easy, Maven way? > > Thanks in advance, > > Peter >
Horton, Iain is out of the office.
I will be out of the office starting 07/02/2009 and will not return until 07/07/2009. I will respond to your message when I return. Important news about email communications: If our business rules identify sensitive information, you will receive a ZixMail Secure Message with a link to view your message. First-time recipients will be asked to create a password before they are granted access. To learn more about ZixMail, ZixCorp Secure Email Message Center, and other ZixCorp offerings, please go to http://userawareness.zixcorp.com/secure4/index.php The information contained in this communication may be confidential, and is intended only for the use of the recipient(s) named above. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication, or any of its contents, is strictly prohibited. If you have received this communication in error, please return it to the sender immediately and delete the original message and any copy of it from your computer system. If you have any questions concerning this message, please contact the sender. Unencrypted, unauthenticated Internet e-mail is inherently insecure. Internet messages may be corrupted or incomplete, or may incorrectly identify the sender. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
JDK sources
Hi, I've asked that question before, yet as I didn't get an answer, I'll try again: I configured The Eclipse plugin so that it downloads all sources, and adds them to my eclipse project configuration, so that I can click on third Party classes in my code and see it's source code - that way I don't need to read it's api any longer - VERY handy. How can that be done with the JDK source and J2EE sources? I know where to download them, but I don't want to add them manually - whenever I reimport a project I would have to do it anew. Isn't there an easy, Maven way? Thanks in advance, Peter
Re: maven-antrun-plugin: Java classes don't compile after an Ant task
you need to use buildhelper-maven-plugin to attach the generated-sources directory. Maven does not know that you've generated additional sources. Most/all of the source generator maven plugins will add the generated-sources/pluginname folder as an additional source path... buildhelper is there to allow you to achieve the same from outside of a plugin. also, the convention would be to put your code in ${project.build.directory}/generated-sources/xtc/ and not ${project.build.directory}/generated-sources/main/java/ It's no biggie, and it probably will not cause any issues.. unless you hit the maximum path lengths of windows 2009/7/2 Christopher L Conway > My project generates source code using the XTC parser generator > (http://cs.nyu.edu/rgrimm/xtc/). XTC doesn't have a Maven plugin that > I'm aware of, so I'm trying to build the parser using an Ant Java > task, like so: > > >maven-antrun-plugin > > >generate-sources > > > dir="${project.build.directory}/generated-sources/main/java/" /> > > > > > > > >${project.build.directory}/generated-sources/main/java > > > > run > > > > > > The details of what XTC does aren't important: the end result is that > the above generates Dot.java and places it in > target/generated-sources/main/java. It works fine. > > The problem is that, with this plugin element in my pom.xml, none of > the Java files in the project get compiled. In a project generated > using "mvn archetype:create -DgroupId=foo -DartifactId=bar", if I run > "mvn compile" without the plugin element, I get: > > $ mvn compile > [INFO] Scanning for projects... > [INFO] > > [INFO] Building bar > [INFO]task-segment: [compile] > [INFO] > > [INFO] [resources:resources] > [INFO] Using default encoding to copy filtered resources. > [INFO] [compiler:compile] > [INFO] Compiling 1 source file to > /home/chris/src/tests/maven/project1/bar/target/classes > [INFO] > > [INFO] BUILD SUCCESSFUL > [INFO] > > [INFO] Total time: 1 second > [INFO] Finished at: Wed Jul 01 18:57:08 EDT 2009 > [INFO] Final Memory: 6M/67M > [INFO] > > > Whereas with the plugin element invoking XTC, I get (after a "mvn clean"): > > $ mvn compile > [INFO] Scanning for projects... > [INFO] > > [INFO] Building bar > [INFO]task-segment: [compile] > [INFO] > > [INFO] [antrun:run {execution: default}] > [INFO] Executing tasks >[mkdir] Created dir: > /home/chris/src/tests/maven/project1/bar/target/generated-sources/main/java > Rats! Parser Generator, v. 1.14.2, (C) 2004-2008 Robert Grimm > Processing /home/chris/src/tests/maven/project1/bar/src/main/java/Dot.rats > ... > > The XTC process is not failing, AFAICT. > > I've tried other kinds of Ant tasks and they don't interfere with Java > compilation. For example, if I replace the task element above with an > echo task > > > dir="${project.build.directory}/generated-sources/main/java/" /> > file="${project.build.directory}/generated-sources/main/java/Dot.java"> > public class Dot { } > > > > I get > > $ mvn compile > [INFO] Scanning for projects... > [INFO] > > [INFO] Building bar > [INFO]task-segment: [compile] > [INFO] > > [INFO] [antrun:run {execution: default}] > [INFO] Executing tasks > [INFO] Executed tasks > [INFO] Registering compile source root > /home/chris/src/tests/maven/project1/bar/target/generated-sources/main/java > [INFO] [resources:resources] > [INFO] Using default encoding to copy filtered resources. > [INFO] [compiler:compile] > [INFO] Compiling 2 source files to > /home/chris/src/tests/maven/project1/bar/target/classes > [INFO] > > [INFO] BUILD SUCCESSFUL > [INFO] > > [INFO] Total time: 2 seconds > [INFO] Finished at: Wed Jul 01 19:03:34 EDT 2009 > [INFO] Final Memory: 7M/79M > [INFO] > > > Obviously there's somethin
Re: artifact not found?
Have you got the correct MD5 and SHA1 sums in the remote repository? 2009/7/2 Mark Bartel > I'm new to maven (and to this mailing list), so forgive me if I'm > missing the obvious. I'm defining maven builds for several libraries. > I'm trying to create my own internal "remote" repository (accessible > via HTTP) and have dependent libraries retrieved from there. Maven > seems to retrieve the dependencies (it tells me how much it downloaded > and the values make sense) but then it errors out due to "Failed to > resolve artifact". This makes no sense: it finds it, downloads it, > and then complains it wasn't found! > > I have attached the pom.xml and the log (names have been changed in > the pom and log due to policies about unreleased codenames ). > > Maven version: 2.0.9 > Java version: 1.5.0_17 > OS name: "linux" version: "2.6.26-2-amd64" arch: "amd64" Family: "unix" > > Now, of course I can just place the dependencies in my local > repository (or just mvn install on the dependency) on my local machine > and indeed I am doing that to move forward, but in the end I need the > remote repository to work. > > Help! > > -Mark > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org >
Re: ERROR: Cannot override read-only parameter: packaging in goal: install:install
Move the configuration to inside the execution. The packaging parameter is read-only for install:install but not for install:install-file... therefore you want your configuration to apply to the install-file execution only. -Stephen P.S. your approach will have many problems. While you are installing the file into the local repository, it is not attached as part of the reactor, so it will not get deployed, and you will be unable to run the "clean verify" goals whenever the versions have been changed, or on a system which has never ran the install goal for the current project version... this essentially will cause problems with the release plugin. I normally use two techniques to work around these issues: 1. create a dummy pom for the jar I want to add with packaging pom and use buildhelper to attach the jar to the project... 2. create a dummy pom for the jar I want to add with packaging jar and use antrun to copy the jar over the built jar between the package and install phases #1 is quicker, but #2 gives you a pom with the correct packaging 2009/7/2 hhuynh > > Hi all, > > I've configured install plugin to install additional file (created by the > assembly plugin from the same project). Settings is as below. However, the > very last step of installing the main artifact, I got this error > > ERROR: Cannot override read-only parameter: packaging in goal: > install:install > > Any idea why and how to work around it? > > Thanks, > > Hung- > > > >org.apache.maven.plugins >maven-install-plugin >2.3 > > target/${standalone-jar-name}.jar > jar > org.terracotta.hibernate-cache > ${standalone-jar-name} > ${project.version} > > > >install-standalone >install > > install-file > > > > > -- > View this message in context: > http://www.nabble.com/ERROR%3A-Cannot-override-read-only-parameter%3A-packaging-in-goal%3A-install%3Ainstall-tp24299872p24299872.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 > >
[ANN] Cobertura Maven Plugin 2.3
The Mojo team is pleased to announce the release of the Cobertura Maven Plugin 2.3. http://mojo.codehaus.org/cobertura-maven-plugin/. Release notes : ** Bug * [MCOBERTURA-88] - Cobertura runs mess up project classpath * [MCOBERTURA-96] - Jar classpath ordering issue during test execution ** Improvement * [MCOBERTURA-81] - Add support for i18n to report mojo * [MCOBERTURA-100] - Add metrics to the xml report generated by the goal dump-datafile * [MCOBERTURA-104] - Upgrade to Cobertura 1.9.2 More details can be found at http://jira.codehaus.org/browse/MCOBERTURA/fixforversion/13926. Regards The Mojo team - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
maven error: can not create the java virtual machine
Hi, I am a newbie to maven, this morning I followed maven install documentation step by step and complete the maven install. System: windows XP Professional sp2 Java Version: jdk1.6.0_02 Maven Version: 2.2.0 at first installed, under command line, I can run: mvn --version, it seems Ok, and output like: Java home: D:\Program Files\Java\jdk1.6.0_02\jre System os Windows Xp and blablabla... no error, no warn However after a while, I change my command line path to another disk F, and run mvn --version again, it appears imcompatible initial and maximum heap sizes sepcified error. I follew this mail: http://www.nabble.com/Incompatible-initial-and-maximum-heap-sizes-specified-td23284917.html then changed my MAVEN_OPTS to this: "-Xms256m -Xmx256m" run mvn --version again, then it output: invalid initail heap size: -Xms256m -Xmx256m can not create the java virtual machine this is my environment variable setting, is there some wrong in it? == System environment variable: path -- D:\Program Files\ActiveState Komodo Edit 5\;D:\Perl\site\bin;D:\Perl\bin;C:\windows\system32\;C:\windows;C:\windows\system32\Wbem;D:\Program Files\Java\jdk1.6.0_02\bin;D:\Tools\Tools\svn-win32-1.4.5\bin;D:\Program Files\apache-ant-1.7.1\bin;D:\Tools\tomcat5.5.26\bin;D:\Program Files\apache-maven-2.2.0\bin; == user environment varialbe: Path %JAVA_HOME%\bin;%M2_HOME%\bin; JAVA_HOME D:\Program Files\Java\jdk1.6.0_02 M2_HOME D:\Program Files\apache-maven-2.2.0 M2%M2_HOME%\bin MAVEN_OPTS "-Xms256m -Xmx256m" == Should I go back to install old maven version as 2.1.0? I like to use the latest version of software, and my classmate says it is not a good habit, because the latest version means unstable performance. Who can give me some suggestion, please? Thanks a lot! ps: please forgive my poor english vocabulary -- Best regards! yutinglv - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
maven-antrun-plugin: Java classes don't compile after an Ant task
My project generates source code using the XTC parser generator (http://cs.nyu.edu/rgrimm/xtc/). XTC doesn't have a Maven plugin that I'm aware of, so I'm trying to build the parser using an Ant Java task, like so: maven-antrun-plugin generate-sources ${project.build.directory}/generated-sources/main/java run The details of what XTC does aren't important: the end result is that the above generates Dot.java and places it in target/generated-sources/main/java. It works fine. The problem is that, with this plugin element in my pom.xml, none of the Java files in the project get compiled. In a project generated using "mvn archetype:create -DgroupId=foo -DartifactId=bar", if I run "mvn compile" without the plugin element, I get: $ mvn compile [INFO] Scanning for projects... [INFO] [INFO] Building bar [INFO]task-segment: [compile] [INFO] [INFO] [resources:resources] [INFO] Using default encoding to copy filtered resources. [INFO] [compiler:compile] [INFO] Compiling 1 source file to /home/chris/src/tests/maven/project1/bar/target/classes [INFO] [INFO] BUILD SUCCESSFUL [INFO] [INFO] Total time: 1 second [INFO] Finished at: Wed Jul 01 18:57:08 EDT 2009 [INFO] Final Memory: 6M/67M [INFO] Whereas with the plugin element invoking XTC, I get (after a "mvn clean"): $ mvn compile [INFO] Scanning for projects... [INFO] [INFO] Building bar [INFO]task-segment: [compile] [INFO] [INFO] [antrun:run {execution: default}] [INFO] Executing tasks [mkdir] Created dir: /home/chris/src/tests/maven/project1/bar/target/generated-sources/main/java Rats! Parser Generator, v. 1.14.2, (C) 2004-2008 Robert Grimm Processing /home/chris/src/tests/maven/project1/bar/src/main/java/Dot.rats ... The XTC process is not failing, AFAICT. I've tried other kinds of Ant tasks and they don't interfere with Java compilation. For example, if I replace the task element above with an echo task public class Dot { } I get $ mvn compile [INFO] Scanning for projects... [INFO] [INFO] Building bar [INFO]task-segment: [compile] [INFO] [INFO] [antrun:run {execution: default}] [INFO] Executing tasks [INFO] Executed tasks [INFO] Registering compile source root /home/chris/src/tests/maven/project1/bar/target/generated-sources/main/java [INFO] [resources:resources] [INFO] Using default encoding to copy filtered resources. [INFO] [compiler:compile] [INFO] Compiling 2 source files to /home/chris/src/tests/maven/project1/bar/target/classes [INFO] [INFO] BUILD SUCCESSFUL [INFO] [INFO] Total time: 2 seconds [INFO] Finished at: Wed Jul 01 19:03:34 EDT 2009 [INFO] Final Memory: 7M/79M [INFO] Obviously there's something I'm not understanding about how Maven executes the java task. Is there something simple that I'm doing wrong? Is there an alternative way to accomplish this task that I should try (perhaps a more "Maven-native" way)? The full pom.xml is attached. Regards, Chris 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";> 4.0.0 foo bar jar 1.0-SNAPSHOT bar http://maven.apache.org junit junit 3.8.1 test xtc xtc 1.14.2 system ${basedir}/lib/xtc.jar maven-antrun-plugin generate-sources ${project.build.directory}/generated-sources/main/java
artifact not found?
I'm new to maven (and to this mailing list), so forgive me if I'm missing the obvious. I'm defining maven builds for several libraries. I'm trying to create my own internal "remote" repository (accessible via HTTP) and have dependent libraries retrieved from there. Maven seems to retrieve the dependencies (it tells me how much it downloaded and the values make sense) but then it errors out due to "Failed to resolve artifact". This makes no sense: it finds it, downloads it, and then complains it wasn't found! I have attached the pom.xml and the log (names have been changed in the pom and log due to policies about unreleased codenames ). Maven version: 2.0.9 Java version: 1.5.0_17 OS name: "linux" version: "2.6.26-2-amd64" arch: "amd64" Family: "unix" Now, of course I can just place the dependencies in my local repository (or just mvn install on the dependency) on my local machine and indeed I am doing that to move forward, but in the end I need the remote repository to work. Help! -Mark + Error stacktraces are turned on. Maven version: 2.0.9 Java version: 1.5.0_17 OS name: "linux" version: "2.6.26-2-amd64" arch: "amd64" Family: "unix" [DEBUG] Building Maven user-level plugin registry from: '/home/mbartel/.m2/plugin-registry.xml' [DEBUG] Building Maven global-level plugin registry from: '/usr/share/maven2/conf/plugin-registry.xml' [INFO] Scanning for projects... [INFO] [INFO] Building Unnamed - ca.foo.common:foo-common:jar:1.0 [INFO]task-segment: [compile] [INFO] [DEBUG] Retrieving parent-POM: org.apache.maven.plugins:maven-plugins::1 for project: null:maven-resources-plugin:maven-plugin:2.2 from the repository. [DEBUG] Retrieving parent-POM: org.apache.maven:maven-parent::1 for project: org.apache.maven.plugins:maven-plugins:pom:1 from the repository. [DEBUG] Retrieving parent-POM: org.apache:apache::1 for project: org.apache.maven:maven-parent:pom:1 from the repository. [DEBUG] Retrieving parent-POM: org.apache.maven.plugins:maven-plugins::8 for project: null:maven-compiler-plugin:maven-plugin:2.0.2 from the repository. [DEBUG] Retrieving parent-POM: org.apache.maven:maven-parent::5 for project: org.apache.maven.plugins:maven-plugins:pom:8 from the repository. [DEBUG] Retrieving parent-POM: org.apache:apache::3 for project: org.apache.maven:maven-parent:pom:5 from the repository. [DEBUG] Plugin dependencies for: org.apache.maven.plugins:maven-resources-plugin:2.2 are: org.apache.maven:maven-plugin-api:jar:2.0:runtime org.apache.maven:maven-project:jar:2.0:runtime org.apache.maven:maven-model:jar:2.0:runtime org.codehaus.plexus:plexus-utils:jar:1.1:runtime [DEBUG] org.apache.maven.plugins:maven-resources-plugin:maven-plugin:2.2:runtime (selected for runtime) [DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project: org.apache.maven:maven-plugin-api:jar:2.0 from the repository. [DEBUG] Adding managed dependencies for org.apache.maven:maven-plugin-api [DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8 [DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4 [DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5 [DEBUG] org.apache.maven:maven-plugin-api:jar:2.0:runtime (selected for runtime) [DEBUG] Adding managed dependencies for unknown:maven-project [DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8 [DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4 [DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5 [DEBUG] org.apache.maven:maven-project:jar:2.0:runtime (selected for runtime) [DEBUG] Adding managed dependencies for unknown:maven-profile [DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8 [DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4 [DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5 [DEBUG] org.apache.maven:maven-profile:jar:2.0:runtime (selected for runtime) [DEBUG] Adding managed dependencies for org.apache.maven:maven-model [DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8 [DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4 [DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5 [DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5 [DEBUG]
ERROR: Cannot override read-only parameter: packaging in goal: install:install
Hi all, I've configured install plugin to install additional file (created by the assembly plugin from the same project). Settings is as below. However, the very last step of installing the main artifact, I got this error ERROR: Cannot override read-only parameter: packaging in goal: install:install Any idea why and how to work around it? Thanks, Hung- org.apache.maven.plugins maven-install-plugin 2.3 target/${standalone-jar-name}.jar jar org.terracotta.hibernate-cache ${standalone-jar-name} ${project.version} install-standalone install install-file -- View this message in context: http://www.nabble.com/ERROR%3A-Cannot-override-read-only-parameter%3A-packaging-in-goal%3A-install%3Ainstall-tp24299872p24299872.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Is there a way to run a program (a trigger) before packaging a program?
On Wed, Jul 1, 2009 at 11:37 AM, JavaGeek wrote: > I wrote a maven plugin. I want to run a program that writes a file in the > plugin's source code before the plugin is packaged. ... before the *project* is packaged, I assume? > How can I do that? Make your plugin execute in a phase that precedes the 'package' phase. The 'generate-sources' phase sounds like it would be appropriate. http://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html If you did mean before packaging the plugin, then recurse. :) Write a plugin that runs this program, (or just use the exec plugin) and execute it in a phase that precedes... -- Wendy - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Is there a way to run a program (a trigger) before packaging a program?
Hello All, I wrote a maven plugin. I want to run a program that writes a file in the plugin's source code before the plugin is packaged. How can I do that? Thanks, Steven -- View this message in context: http://www.nabble.com/Is-there-a-way-to-run-a-program-%28a-trigger%29-before-packaging-a-program--tp24295016p24295016.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
POLL: Which Maven version do you primarily use?
Hi, I realise this may not be completely balanced sample, but I'd like to satisfy my curiosity. IIRC, it has been about 12 months since this question was last asked here. If you are interested, drop a vote on this poll page: http://brettporter.wordpress.com/2009/07/02/poll-what-version-of-maven-do-you-use/ (Please don't reply here for a straight answer, I don't intend to drown the list in that sort of traffic). Cheers, Brett - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
org.codehaus.mojo:axistools-maven-plugin
I'm having a problem with the axis plugin. I was able to do the build in Ant, but when trying to use Maven, I get the following issue: INFO] [INFO] Building aimwebservices.war [INFO]task-segment: [compile] [INFO] [INFO] [axistools:wsdl2java {execution: default}] [INFO] about to add compile source root [INFO] Nothing to generate. All WSDL files are up to date. [INFO] [build-helper:add-source {execution: add-wsdl-source}] [INFO] Source directory: /home/dweintraub/builds/adinventory-trunk/aimwebservices.war/target/generated-sources/axistools/wsdl2java added. [INFO] [resources:resources] [WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent! [INFO] Copying 3 resources [INFO] [compiler:compile] [INFO] Compiling 10 source files to /home/dweintraub/builds/adinventory-trunk/aimwebservices.war/target/classes [INFO] [ERROR] BUILD FAILURE [INFO] [INFO] Compilation failure /home/dweintraub/builds/adinventory-trunk/aimwebservices.war/src/main/java/com/solbright/aimwebservices/client/InventoryAvailsCommandExecutor.java:[53,81] incompatible types found : com.solbright.aimwebservices.SolbrightInventoryService_PortType required: com.solbright.aimwebservices.SolbrightInventoryService For some reason, the _PortType is being appended to my generated Java file. Another question is whether or not I need to specify the org.codehaus.mojo:build-helper-maven-plugin, so that Maven can find the generated wsdl2java sources. It appears to work in my project without the need for this plugin, but another project seems to need this plugin. Here's my pom.xml 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";> 4.0.0 com.solbright.adinventory aimwebservices war 2.1.2-SNAPSHOT com.solbright adinventory 2.1.2-SNAPSHOT aimwebservices.war http://maven.apache.org org.codehaus.mojo axistools-maven-plugin 1.2 solbright_inventory_service.wsdl com.solbright.aimwebservices false false wsdl2java org.codehaus.mojo build-helper-maven-plugin add-wsdl-source generate-sources add-source ${project.build.directory}/generated-sources/axistools/wsdl2java org.apache.maven.plugins maven-compiler-plugin 1.6 1.6 org.apache.maven.plugins maven-surefire-plugin 2.4.2 org.apache.maven.plugins maven-war-plugin
Swing - EJB Client
I'm migrating an Ant Swing application to Maven. This application make an lookup in a EJB Container (Glassfish), but I've an strange exception when trying to use the InitialContext. Code snipet: Properties props = new Properties(); props.setProperty("java.naming.factory.initial", "com.sun.enterprise.naming.SerialInitContextFactory"); props.setProperty("java.naming.factory.url.pkgs", "com.sun.enterprise.naming"); props.setProperty("java.naming.factory.state", "com.sun.corba.ee.impl.presentation.rmi.JNDIStateFactoryImpl"); props.setProperty("org.omg.CORBA.ORBInitialHost", "192.168.254.10"); props.setProperty("org.omg.CORBA.ORBInitialPort", "3700"); try { InitialContext ctx = new InitialContext(props); } catch (NamingException ex) { ex.printStackTrace(); } Error stacktrace: Exception in thread "main" java.lang.ClassFormatError: Absent Code attribute in method that is not native or abstract in class file javax/security/jacc/PolicyContextException at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:621) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124) at java.net.URLClassLoader.defineClass(URLClassLoader.java:260) at java.net.URLClassLoader.access$000(URLClassLoader.java:56) at java.net.URLClassLoader$1.run(URLClassLoader.java:195) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:307) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:252) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320) at com.sun.enterprise.security.SSLUtils.(SSLUtils.java:102) at com.sun.enterprise.iiop.IIOPSSLSocketFactory.(IIOPSSLSocketFactory.java:182) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at java.lang.Class.newInstance0(Class.java:355) at java.lang.Class.newInstance(Class.java:308) at com.sun.corba.ee.impl.orb.ParserTable$4.operate(ParserTable.java:696) at com.sun.corba.ee.impl.orb.NormalParserAction.apply(NormalParserAction.java:58) at com.sun.corba.ee.spi.orb.PropertyParser.parse(PropertyParser.java:81) at com.sun.corba.ee.spi.orb.ParserImplBase.init(ParserImplBase.java:81) at com.sun.corba.ee.impl.orb.ORBDataParserImpl.(ORBDataParserImpl.java:481) at com.sun.corba.ee.impl.orb.ORBImpl.postInit(ORBImpl.java:587) at com.sun.corba.ee.impl.orb.ORBImpl.set_parameters(ORBImpl.java:701) at org.omg.CORBA.ORB.init(ORB.java:337) at com.sun.enterprise.util.ORBManager.initORB(ORBManager.java:546) at com.sun.enterprise.util.ORBManager.getORB(ORBManager.java:278) at com.sun.enterprise.naming.SerialInitContextFactory.getInitialContext(SerialInitContextFactory.java:178) at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:667) at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288) at javax.naming.InitialContext.init(InitialContext.java:223) at javax.naming.InitialContext.(InitialContext.java:197) I've added in client some glassfish libraries: *appserv-admin * appserv-deployment-client * appserv-ext *appserv-rt This code works correctly in the Ant application. (The EJB has recently migrated from the ant to maven too, this works well) -- Serhmatica visite: www.serhmatica.com.br Esta mensagem foi verificada pelo sistema de antivírus e acredita-se estar livre de perigo. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Deprecated in compiler plugin
Hello all, if I read the description of the maven-compiler-plugin 2.0.2 every option is marked deprecated $ mvn help:describe -Dplugin=org.apache.maven.plugins:maven-compiler-plugin -Ddetail ... source The -source argument for the Java compiler. Deprecated. No reason given ... Why is that? What should I use instead? Regards, Kai - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Build gets extra dependencies.
It turns out that the spring-2.0.6.jar was a transitive dependency. The really strange part is that by simply deleting my local repository and letting it rebuild as the build proceeded, that dependency magically vanished. That, I don't get. Unfortunately, I don't have much time to "play" with it, right now. I'll just have to accept that we're in good shape (for now) and move on. Weird! Jörg Schaible wrote: > David C. Hicks wrote at Mittwoch, 1. Juli 2009 00:18: > > >> I've got an automated build that runs on Hudson that is producing a WAR >> that cannot load and run. It appears that it is picking up extra >> dependencies during the build process. One of those is >> spring-2.0.6.jar. I believe this is causing my load/run problem because >> the error I get is related to loading the Spring context. My question >> is simply this... >> >> Can anyone tell me why a Maven build would pick up extra dependencies if >> everything appears to be the same between two machines. Same JDK, same >> version of Maven, same settings.xml in .m2, same build command ("mvn >> clean install"). Yet, the automated build ends up with 5 extra jars in >> the WEB-INF/lib directory. I'm stumped, and this is causing us a world >> of problems. >> > > The artifacts of your repository might have been loaded from different > repos. Repo at java.net and JBoss tend to have sometimes different POMs for > artifacts that are also available on Maven central or (at least java.net) > redeploys already released artifacts ;-/ > > Therefore ensure that you setup a mirror for anything in settings.xml and > use a proxy/archive manager with a well-defined sequence for the repos to > search for artifacts. > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Using custom assembly descriptor
This will give you an executable war file, i.e. java -jar foo.war which does what you want http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"; xmlns="http://maven.apache.org/POM/4.0.0"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";> 4.0.0 war maven-war-plugin your.package.JettyMain maven-dependency-plugin generate-resources unpack-dependencies jar ${project.build.directory}/${project.build.finalName} 2009/7/1 olip : > > Hi everyone! > Maybe you can help me out with this. > > I want to build a executable jar file which must contain a war file within > (because I have included a jetty server runner in it). Problem is if I use > the predefined assembly descriptor to build it: > jar-with-dependencies in my main pom > > the war file will not get copied into it. > > If I write my own descriptor e.g.: > --- > > jar-with-all-dependencies > > jar > > false > > > true > runtime > > > > > *:war > > > > > > > false > runtime > > *:war:* > > > > > > > > > ${project.build.outputDirectory} > > > > > -- > the war file gets included but if I try to run the jar it cant find the main > class so if I extract it the directory structure is messed up e.g. > executable class is not in root folder but in target/classes > > Also if I use the standard jar-with-dependencies descriptor code seen here: > http://maven.apache.org/plugins/maven-assembly-plugin/descriptor-refs.html > > which is: > -- > > jar-with-dependencies > > jar > > false > > > true > runtime > > > > > ${project.build.outputDirectory} > > > > - > > it cant find the main class also it should be the same result as just using > jar-with-dependencies > > in my main pom. > > I am using maven2. > > Thank you for your help > -- > View this message in context: > http://www.nabble.com/Using-custom-assembly-descriptor-tp24290434p24290434.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: antrun does not do anything
I tried using antrun recently, too. I have a different problem, but have gotten a little further than this. Do you have your snippet in the block? Mine looks like this (some content omitted for clarity): run -Greg On Tue, 2009-06-30 at 14:25 -0500, Qiner Yang wrote: > attached are the pom.xml and build.xml files. > run ant, generates the abc2 folder, but > run mvn antrun:run, generates nothing. > > - Original Message - > From: Qiner Yang > To: users@maven.apache.org > Sent: Tuesday, June 30, 2009 11:36 AM > Subject: help: antrun does not do anything > > > Because some functions not available or not easily > accomplishable in maven, so I turned to the antrun in maven. > But I can never get the antrun working, please help me out. > > I read the Maven AntRun Plugnin page, > http://maven.apache.org/plugins/maven-antrun-plugin/, and > followed all the instructions and tried all the examples in > the examples section, > > http://maven.apache.org/plugins/maven-antrun-plugin/examples/classpaths.html. > But nothing is generated from the antrun. I tried a very simple ant command, > , or an ant task > > > > between the maven . The ant "test target" is to make a > directory, which works fine when issuing "ant test", but > nothing happen in mvn. Strange, the mvn command shows > execution successful, see below: > [INFO] Scanning for projects... > [INFO] > > > [INFO] Building RTJDBC > [INFO]task-segment: [antrun:run] > [INFO] > > > [INFO] [antrun:run] > [INFO] Executing tasks > [INFO] Executed tasks > [INFO] > > > [INFO] BUILD SUCCESSFUL > [INFO] > > > [INFO] Total time: 1 second > [INFO] Finished at: Tue Jun 30 11:04:56 PDT 2009 > [INFO] Final Memory: 2M/5M > [INFO] > > > > I tried removing the antrun plugin from the pom.xml, the mvn > antrun output is exactly the same as above. Got confused. > thanks for any help. > > Qiner > > > ___ > > Inbound Email has been scanned by Nexa Technologies Email Security > Systems. > ___ - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
RE: Corporate firewall not maven-friendly
if the general duties of a FA Admin are to safeguard from protential viruses,phising and DOS attacks then you would want to be aware of the rules the Firewall admin imposes one way for maven to handle access to potentially insecure sites is maven-proxy maven-proxy would ensure unauthenticated port80 requests would have to use some means of authentication other requests (such as pre-authenticated SSL sites) would flow thru using (some manner of) SSL tunnel http://maven-proxy.codehaus.org/Configuration If you're actively involved in a Software Project the better way is thru Software Control Management process where you would need a SCM plugin http://maven.apache.org/scm/plugins/index.html this way the SCM has knowledge of whats going in and out of the repository and can track according to supplied username,password credentials it would also handle who is working on which version and branch splits and merges HTH Martin Gainty __ Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen. Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le destinataire prévu, nous te demandons avec bonté que pour satisfaire informez l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci est interdite. Ce message sert à l'information seulement et n'aura pas n'importe quel effet légalement obligatoire. Étant donné que les email peuvent facilement être sujets à la manipulation, nous ne pouvons accepter aucune responsabilité pour le contenu fourni. > Date: Wed, 1 Jul 2009 23:55:03 +0930 > From: st...@atulos.com > To: users@maven.apache.org > Subject: Corporate firewall not maven-friendly > > Hi. > > This is my first post. Please be gentle if I break any rules. > > At work, my PC sits behind a Trend internet filter which itself sits > behind a firewall. The problem is that the trend filter runs something > called Applet Trap which infects any incoming unsigned jar files with > its filth. The result is that the jar files fail md5 validation and, > even worse, get sandboxed such that any access outside the sandbox > causes a dialog with the title "Applet Alert" to pop up and ask me if I > want to allow, deny or abort. As you can imagine, I have to sit there > with the mouse clicking Allow thousands of times. > > Unfortunately this is one of those large corporations and, well, let's > just say it's too political for me to go requesting the exceptions in > the filter. > > Does anyone know of some way to bypass the filter by making it think > it's not downloading jar files? I could perform some sort of tunnelling > using a VPS that i'm renting, but the problem is that I'm already using > port 80 for the apache server. The corporate firewall blocks anything > outgoing that isn't http, https or (maybe) ftp. > > Steve > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > _ Windows Live™: Keep your life in sync. http://windowslive.com/explore?ocid=TXT_TAGLM_WL_BR_life_in_synch_062009
Re: bug? strange resolution of commons-logging dependency
2009/7/1 Ceki Gulcu : > Using Maven 2.2.0, the behavior remains the same as with Maven > 2.0.9. Moreover, if you remove the dependency on > net.sf.ehcache:ehcache:1.6.0 from the pom file for "htmlunitbug", then > the test passes (with the original pom files for hibernate-ehcache > hibernate-parent referencing commons-logging version 99). > > In summary, there is strong evidence that common-logging 99 is not the > culprit here. > > Can it be that the various dependencies, some in test scope and some > in runtime scope, are confusing Maven's dependency resolution > mechanism? It has been known.. http://jira.codehaus.org/browse/MNG-4134 Have you got the dependency tree filtered for commons-logging handy? Mark - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Using parent POMs effectively
Yes, I agree that a skin would produce the desired results; maybe I shouldn't avoid that solution ;-) My question simply put is this: Should the site plugin inherit resources from a parent POM or not? It seems that other plugins (e.g., CheckStyle, JXR, etc.) do inherit same quite nicely. Is this a bug in the site plugin? Thanks, Tom j.t.halli...@flagstar.com From: Tom Bollwitt To: "Maven Users List" Date: 07/01/2009 08:52 AM Subject: Re: Using parent POMs effectively We created a maven site skin and then added a site.xml in the project that is used for our parent "super pom". All our projects eventually inherit from this "global" super pom so the site.xml is also inherited. If you need info on creating a skin then check here... http://maven.apache.org/plugins/maven-site-plugin/examples/creatingskins.html example site.xml http://maven.apache.org/DECORATION/1.0.0"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation=" http://maven.apache.org/DECORATION/1.0.0 http://maven.apache.org/xsd/decoration-1.0.0.xsd "> com.mersoft maven-mersoft-skin 0.0.1 ... ... I hope this helps. Regards, Tom Bollwitt SYSTEMS ENGINEER Mersoft 9300 W. 110th St. Building 55, Suite 350 Overland Park, KS 66210 913-871-6200 tlbollw...@mersoft.com On Jun 30, 2009, at 10:45 AM, j.t.halli...@flagstar.com wrote: > I've created a parent POM, in which to house a few common > dependencies, > but mostly to set up how a site is built: > >* CheckStyle rules, >* JavaDoc stylesheet, >* JXR stylesheet, >* site stylesheet. > > But the latter site.css is not being picked up: It lives in > src/site/resources/css/site.css > under the parent project. If I put site.css under the child > project, it > is copied to > target/site/css just fine. > > Should I be able to put such resources under the parent POM's project? > I've even tried specifying the following in the parent POM: > > > > > >org.apache.maven.plugins >maven-site-plugin > > > ${env.FSB_PROJECTS_HOME}/fsb-master-pom/src/site/resources/css/ > site.css > > > > ... > > It'd be nice to specify such things once in the parent project to be > used > by all child projects. > > Ideas? > > Tom > j.t.halli...@flagstar.com > > > This e-mail may contain data that is confidential, proprietary or > non-public personal information, as that term is defined in the > Gramm-Leach-Bliley Act (collectively, Confidential Information). The > Confidential Information is disclosed conditioned upon your > agreement that you will treat it confidentially and in accordance > with applicable law, ensure that such data isn't used or disclosed > except for the limited purpose for which it's being provided and > will notify and cooperate with us regarding any requested or > unauthorized disclosure or use of any Confidential Information. > By accepting and reviewing the Confidential information, you agree > to indemnify us against any losses or expenses, including attorney's > fees that we may incur as a result of any unauthorized use or > disclosure of this data due to your acts or omissions. If a party > other than the intended recipient receives this e-mail, he or she is > requested to instantly notify us of the erroneous delivery and > return to us all data so delivered. > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Corporate firewall not maven-friendly
Hi. This is my first post. Please be gentle if I break any rules. At work, my PC sits behind a Trend internet filter which itself sits behind a firewall. The problem is that the trend filter runs something called Applet Trap which infects any incoming unsigned jar files with its filth. The result is that the jar files fail md5 validation and, even worse, get sandboxed such that any access outside the sandbox causes a dialog with the title "Applet Alert" to pop up and ask me if I want to allow, deny or abort. As you can imagine, I have to sit there with the mouse clicking Allow thousands of times. Unfortunately this is one of those large corporations and, well, let's just say it's too political for me to go requesting the exceptions in the filter. Does anyone know of some way to bypass the filter by making it think it's not downloading jar files? I could perform some sort of tunnelling using a VPS that i'm renting, but the problem is that I'm already using port 80 for the apache server. The corporate firewall blocks anything outgoing that isn't http, https or (maybe) ftp. Steve - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: custom deployment cycle
On Wed, Jul 1, 2009 at 7:16 AM, olip wrote: > Thanks Wendy, > Can you give me an example what do you mean by "attached" goals in my > assembly plugin configuration. Sorry but I am a total newbie. See http://maven.apache.org/plugins/maven-assembly-plugin/usage.html and scroll down to Building an Assembly as Part of the Build Lifecycle . (We really need to get anchors on that page, or split it up...) -- Wendy - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: custom deployment cycle
Thanks Wendy, Can you give me an example what do you mean by "attached" goals in my assembly plugin configuration. Sorry but I am a total newbie. Thank you for your help Oli Wendy Smoak-3 wrote: > > On Wed, Jul 1, 2009 at 6:58 AM, olip wrote: > >> I can do this by typing: >> four commands on the command line: >> mvn install >> mvn assembly:assembly >> mvn site >> mvn deploy > > You should be able to get it down to "mvn site deploy" if you change > your assembly plugin configuration to one of the 'attached' goals that > runs automatically as part of the build. > > deploy implies (is later in the lifecycle than) install, so you don't need > both. > > -- > Wendy > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > > > -- View this message in context: http://www.nabble.com/custom-deployment-cycle-tp24290266p24290567.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
Using custom assembly descriptor
Hi everyone! Maybe you can help me out with this. I want to build a executable jar file which must contain a war file within (because I have included a jetty server runner in it). Problem is if I use the predefined assembly descriptor to build it: jar-with-dependencies in my main pom the war file will not get copied into it. If I write my own descriptor e.g.: --- jar-with-all-dependencies jar false true runtime *:war false runtime *:war:* ${project.build.outputDirectory} -- the war file gets included but if I try to run the jar it cant find the main class so if I extract it the directory structure is messed up e.g. executable class is not in root folder but in target/classes Also if I use the standard jar-with-dependencies descriptor code seen here: http://maven.apache.org/plugins/maven-assembly-plugin/descriptor-refs.html which is: -- jar-with-dependencies jar false true runtime ${project.build.outputDirectory} - it cant find the main class also it should be the same result as just using jar-with-dependencies in my main pom. I am using maven2. Thank you for your help -- View this message in context: http://www.nabble.com/Using-custom-assembly-descriptor-tp24290434p24290434.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: custom deployment cycle
On Wed, Jul 1, 2009 at 6:58 AM, olip wrote: > I can do this by typing: > four commands on the command line: > mvn install > mvn assembly:assembly > mvn site > mvn deploy You should be able to get it down to "mvn site deploy" if you change your assembly plugin configuration to one of the 'attached' goals that runs automatically as part of the build. deploy implies (is later in the lifecycle than) install, so you don't need both. -- Wendy - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
custom deployment cycle
Hi everyone! I am a total newbie to Maven and cant seem to figure out the following. I want to use one maven command to do the following thing: 1.build a war file out of my project and install it in the local repository 2.build an executable jar file which includes the war file (I have written a jetty class to load it within the jar) 3.make a project site 4.deploy everything I can do this by typing: four commands on the command line: mvn install mvn assembly:assembly mvn site mvn deploy how can I do several different maven things with one maven command, can I do this with goals tags? Thank you for our help Oliver -- View this message in context: http://www.nabble.com/custom-deployment-cycle-tp24290266p24290266.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
maven-metadata and lastUpdated field
Hi, Can someone explain me why sometimes maven set wrong lastUpdated date? This is not couple of minutes but couple of years:) -- View this message in context: http://www.nabble.com/maven-metadata-and-lastUpdated-field-tp24289910p24289910.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: OutOfMemoryError when deploying large files
Rakesh: We are experiencing this very same issue. Would you mind emailing me a pom snippet for the dav config you used to get around this? Your assistance would be most appreciated. Regards, Ryan On 6/30/09, Rakesh Arora wrote: > We have resolved the problem by using dav:http protocol instead of http > protocol. > > I have raised a jira against wagon-http-lightweight: > http://jira.codehaus.org/browse/WAGON-272 > > -Rakesh > > > >> -Original Message- >> From: Arora, Rakesh (CAR:9S00) >> Sent: Friday, June 26, 2009 4:19 PM >> To: users@maven.apache.org >> Subject: OutOfMemoryError when deploying large files >> >> When deploying a large artifact we get the OutOfMemoryError >> (please check the attached stack trace). This is similar to >> error reported here: >> http://www.mail-archive.com/users@maven.apache.org/msg99157.html >> >> We traced the issue to wagon-http-lightweight using >> PosterOutputStream/ByteArrayOutputStream.write(). This method >> consumes lot of memory when dealing with large files as reported here: >> https://issues.alfresco.com/jira/browse/ETHREEOH-974 >> >> In our case, we are trying to deploy a around 600M file and >> have set the maximum heap space to 1024M (-Xmx1024m). We are >> still running out of memory. We are using maven 2.0.8 but had >> the same issue when tried with 2.1.0 version. >> >> Is there a way to use another Wagon provider (wagon-http ?) >> that can deal better with large files? If yes, how can we >> configure this? >> >> Should I raise a jira for this (against which component >> maven-deploy-plugin or wagon-http-lightweight)? >> >> Thanks, >> -Rakesh >> >> >> >> ;-STACK TRACE- >> [DEBUG] -- end configuration -- [INFO] [deploy:deploy-file] >> Uploading: http:foo/1.0/foo-1.0.zip >> [INFO] >> -- >> -- >> [ERROR] FATAL ERROR >> [INFO] >> -- >> -- >> [INFO] Java heap space >> [INFO] >> -- >> -- >> [DEBUG] Trace >> java.lang.OutOfMemoryError: Java heap space >> at java.util.Arrays.copyOf(Arrays.java:2786) >> at >> java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:94) >> at >> sun.net.www.http.PosterOutputStream.write(PosterOutputStream.java:61) >> >> at >> org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:338) >> >> at >> org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:305) >> >> at >> org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:267) >> >> at >> org.apache.maven.wagon.AbstractWagon.putTransfer(AbstractWagon.java:2 >> 38) >> at >> org.apache.maven.wagon.StreamWagon.put(StreamWagon.java:143) >> at >> org.apache.maven.wagon.providers.http.LightweightHttpWagon.put(Lightw >> eightHttpWagon.java:148) >> at >> org.apache.maven.artifact.manager.DefaultWagonManager.putRemoteFile(D >> efaultWagonManager.java:237) >> at >> org.apache.maven.artifact.manager.DefaultWagonManager.putArtifact(Def >> aultWagonManager.java:153) >> at >> org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(Def >> aultArtifactDeployer.java:80) >> at >> org.apache.maven.plugin.deploy.DeployFileMojo.execute(DeployFileMojo. >> java:240) >> at >> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPlugi >> nManager.java:447) >> at >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa >> ultLifecycleExecutor.java:539) >> at >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandalone >> Goal(DefaultLifecycleExecutor.java:493) >> at >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defau >> ltLifecycleExecutor.java:463) >> at >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan >> dleFailures(DefaultLifecycleExecutor.java:311) >> at >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen >> ts(DefaultLifecycleExecutor.java:224) >> at >> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi >> fecycleExecutor.java:143) >> at >> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:333) >> at >> org.apache.maven.DefaultMaven.execute(DefaultMaven.java:126) >> at org.apache.maven.cli.MavenCli.main(MavenCli.java:282) >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >> at >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. >> java:39) >> at >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces >> sorImpl.java:25) >> at java.lang.reflect.Method.invoke(Method.java:597) >> at >> org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) >> at org.codehaus.classworlds.Launcher.lau
Re: Using parent POMs effectively
We created a maven site skin and then added a site.xml in the project that is used for our parent "super pom". All our projects eventually inherit from this "global" super pom so the site.xml is also inherited. If you need info on creating a skin then check here... http://maven.apache.org/plugins/maven-site-plugin/examples/creatingskins.html example site.xml http://maven.apache.org/DECORATION/1.0.0"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation="http://maven.apache.org/DECORATION/1.0.0 http://maven.apache.org/xsd/decoration-1.0.0.xsd "> com.mersoft maven-mersoft-skin 0.0.1 ... ... I hope this helps. Regards, Tom Bollwitt SYSTEMS ENGINEER Mersoft 9300 W. 110th St. Building 55, Suite 350 Overland Park, KS 66210 913-871-6200 tlbollw...@mersoft.com On Jun 30, 2009, at 10:45 AM, j.t.halli...@flagstar.com wrote: I've created a parent POM, in which to house a few common dependencies, but mostly to set up how a site is built: * CheckStyle rules, * JavaDoc stylesheet, * JXR stylesheet, * site stylesheet. But the latter site.css is not being picked up: It lives in src/site/resources/css/site.css under the parent project. If I put site.css under the child project, it is copied to target/site/css just fine. Should I be able to put such resources under the parent POM's project? I've even tried specifying the following in the parent POM: org.apache.maven.plugins maven-site-plugin ${env.FSB_PROJECTS_HOME}/fsb-master-pom/src/site/resources/css/ site.css ... It'd be nice to specify such things once in the parent project to be used by all child projects. Ideas? Tom j.t.halli...@flagstar.com This e-mail may contain data that is confidential, proprietary or non-public personal information, as that term is defined in the Gramm-Leach-Bliley Act (collectively, Confidential Information). The Confidential Information is disclosed conditioned upon your agreement that you will treat it confidentially and in accordance with applicable law, ensure that such data isn't used or disclosed except for the limited purpose for which it's being provided and will notify and cooperate with us regarding any requested or unauthorized disclosure or use of any Confidential Information. By accepting and reviewing the Confidential information, you agree to indemnify us against any losses or expenses, including attorney's fees that we may incur as a result of any unauthorized use or disclosure of this data due to your acts or omissions. If a party other than the intended recipient receives this e-mail, he or she is requested to instantly notify us of the erroneous delivery and return to us all data so delivered. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: bug? strange resolution of commons-logging dependency
Using Maven 2.2.0, the behavior remains the same as with Maven 2.0.9. Moreover, if you remove the dependency on net.sf.ehcache:ehcache:1.6.0 from the pom file for "htmlunitbug", then the test passes (with the original pom files for hibernate-ehcache hibernate-parent referencing commons-logging version 99). In summary, there is strong evidence that common-logging 99 is not the culprit here. Can it be that the various dependencies, some in test scope and some in runtime scope, are confusing Maven's dependency resolution mechanism? Ceki Gulcu wrote: Lucas Bergman wrote: Dennis Lundberg wrote: That is your problem. What this does is mess the dependency-tree. It removes commons-logging from the dependency tree because that version "99.0-..." is larger than the latest current release of commons-logging. The "99.0-..." version should *never ever* reach end users. It can *only* be used by internal project. Thanks for the input. Are you saying that the dependency of the hibernate-ehcache POM on commons-logging 99.0-does-not-exist is a bug? I'm sympathetic to that view, but I just want to be sure. To be sure, it seems foolish for the Hibernate developers to put something like this in a library's POM, since it would seem to impose their kludge on the programmer using the library. Of course, we fixed our particular problem by adding an for commons-logging from our hibernate-ehcache dependency. Hello, I was able to reproduce the dependency resolution issue with the help of a small test project called "htmlunitbug" as supplied by Lucas Bergman in his message [1] dated "26 Jun 2009 11:46:32 -0500". However, I appears that commons-logging version 99 is not the culprit as it is *not* involved in the resolution of commons-logging within "htmlunitbug", the test application supplied by Lucas. At least, the output of "mvn -X test" never mentions version 99. As further proof, I have removed any references to version 99 in the pom files for hibernate-ehcache and hibernate-parent, with the same results. Just as importantly, the pom files for hibernate-ehcache and hibernate-parent reference commons-logging version 99 in *scope* *test*. Given that the test scope is not transitive, and given that even after removing references to version 99, "htmlunitbug" still fails, it would be premature to incriminate version 99. Something else is afoot here. [1] http://tinyurl.com/nfw332 -- Lucas -- Ceki Gülcü Logback: The reliable, generic, fast and flexible logging framework for Java. http://logback.qos.ch - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: bug? strange resolution of commons-logging dependency
I forgot to mention that my tests were conducted using Maven 2.0.9. I will redo the tests with Maven 2.2.0. Ceki Gulcu wrote: Lucas Bergman wrote: Dennis Lundberg wrote: That is your problem. What this does is mess the dependency-tree. It removes commons-logging from the dependency tree because that version "99.0-..." is larger than the latest current release of commons-logging. The "99.0-..." version should *never ever* reach end users. It can *only* be used by internal project. Thanks for the input. Are you saying that the dependency of the hibernate-ehcache POM on commons-logging 99.0-does-not-exist is a bug? I'm sympathetic to that view, but I just want to be sure. To be sure, it seems foolish for the Hibernate developers to put something like this in a library's POM, since it would seem to impose their kludge on the programmer using the library. Of course, we fixed our particular problem by adding an for commons-logging from our hibernate-ehcache dependency. Hello, I was able to reproduce the dependency resolution issue with the help of a small test project called "htmlunitbug" as supplied by Lucas Bergman in his message [1] dated "26 Jun 2009 11:46:32 -0500". However, I appears that commons-logging version 99 is not the culprit as it is *not* involved in the resolution of commons-logging within "htmlunitbug", the test application supplied by Lucas. At least, the output of "mvn -X test" never mentions version 99. As further proof, I have removed any references to version 99 in the pom files for hibernate-ehcache and hibernate-parent, with the same results. Just as importantly, the pom files for hibernate-ehcache and hibernate-parent reference commons-logging version 99 in *scope* *test*. Given that the test scope is not transitive, and given that even after removing references to version 99, "htmlunitbug" still fails, it would be premature to incriminate version 99. Something else is afoot here. [1] http://tinyurl.com/nfw332 -- Lucas -- Ceki Gülcü Logback: The reliable, generic, fast and flexible logging framework for Java. http://logback.qos.ch - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: bug? strange resolution of commons-logging dependency
Lucas Bergman wrote: Dennis Lundberg wrote: That is your problem. What this does is mess the dependency-tree. It removes commons-logging from the dependency tree because that version "99.0-..." is larger than the latest current release of commons-logging. The "99.0-..." version should *never ever* reach end users. It can *only* be used by internal project. Thanks for the input. Are you saying that the dependency of the hibernate-ehcache POM on commons-logging 99.0-does-not-exist is a bug? I'm sympathetic to that view, but I just want to be sure. To be sure, it seems foolish for the Hibernate developers to put something like this in a library's POM, since it would seem to impose their kludge on the programmer using the library. Of course, we fixed our particular problem by adding an for commons-logging from our hibernate-ehcache dependency. Hello, I was able to reproduce the dependency resolution issue with the help of a small test project called "htmlunitbug" as supplied by Lucas Bergman in his message [1] dated "26 Jun 2009 11:46:32 -0500". However, I appears that commons-logging version 99 is not the culprit as it is *not* involved in the resolution of commons-logging within "htmlunitbug", the test application supplied by Lucas. At least, the output of "mvn -X test" never mentions version 99. As further proof, I have removed any references to version 99 in the pom files for hibernate-ehcache and hibernate-parent, with the same results. Just as importantly, the pom files for hibernate-ehcache and hibernate-parent reference commons-logging version 99 in *scope* *test*. Given that the test scope is not transitive, and given that even after removing references to version 99, "htmlunitbug" still fails, it would be premature to incriminate version 99. Something else is afoot here. [1] http://tinyurl.com/nfw332 -- Lucas -- Ceki Gülcü Logback: The reliable, generic, fast and flexible logging framework for Java. http://logback.qos.ch - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Maven Surefire Plugin suiteXmlFiles config in parent pom doesn't seem to work
Hi, I'm trying to get a single test configuration for all projects and as such I'm trying to put this piece of config in a parent pom: src/test/testng.xml But it doesn't seem to be recognize in child project. It works only if the config is included in child's pom. Is that a known shortcoming? -- View this message in context: http://n2.nabble.com/Maven-Surefire-Plugin-suiteXmlFiles-config-in-parent-pom-doesn%27t-seem-to-work-tp3188027p3188027.html Sent from the maven users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: maven assembly plugin problem.
Thanks. It's work :)! Mohan KR schrieb: Did you try the outputFileNameMapping in the dependencySet descriptor for assembly? ${artifact.artifactId}-${artifact.baseVersion}${dashC lassifier?}.${artifact.extension} Notice the version it is ${artifact.baseVersion} and *not* ${artifact.version} Thanks, mohan kr -Original Message- From: Alexander Vaysberg [mailto:w...@vaisberg.de] Sent: Wednesday, July 01, 2009 2:42 AM To: Maven Users List Subject: maven assembly plugin problem. Hi, I have a problem with assembly plugin. I have a standalone application and I make for this app a jar with manifest. In manifest set I a Main-Class and all dependencies for this app with jar plugin. That work fine. Than, I create with assembly the zip and get the all dependencies in lib. But I have a problem with SNAPSHOT jars. I have 5 SNAPSHOT jars. 3-Jars copy the assembly as so:- db-1.0.0-SNAPSHOT.jar, but for 2 -jars so same as: - firm-db-data-0.0.122-20090623.122812-2.jar. That is a date and time. For Deploying use I the Archiva. The jar plugin write in Manifest firm-db-data-0.0.122-SNAPSHOT. But the assembly put the dependency as firm-db-data-0.0.122-20090623.122812-2. I need the solution for this problem. Alexander Vaysberg - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: How force Maven to compile each project/module even if there are no changes
Run a clean before your compile, thus "mvn clean compile" or "mvn clean install". This will clean out the target directory of each project before compiling. The skipped java files is not really a maven issue, it is the java compiler which detect which files are changed. Hth, Nick Stolwijk ~Java Developer~ Iprofs BV. Claus Sluterweg 125 2012 WS Haarlem www.iprofs.nl On Wed, Jul 1, 2009 at 10:41 AM, Nafter wrote: > > How can I force Maven to compile each project/module even if there are no > changes. > > Because Maven automatically calculates the order in which the various > projects/modules have to be compiled. This is done by checking the module > dependencies. > > For instance this is the order: > > - project D; > - project A; > - project C; > - project B; > > In the above example project D is not dependendent on an other project. But > for instance project B is dependent on project D, A and C. > > Now let's say we change an interface method within project A. An implementor > of this interface is located for instance in project B. > > But now we only commit the change of the interface in project A and we > forget to commit the change of the implementor in project B. > > Now when Maven builds the WAR it says for project B there is nothing to > compile -all classes are up to date. > So nothing is done here. > > However we do have a compilation error now!!! And Maven did not detect it. > So I would like Maven to always do a complete compile of each project. > > Does anyone know how to accomplish this? > Thanks in advance. > -- > View this message in context: > http://www.nabble.com/How-force-Maven-to-compile-each-project-module-even-if-there-are-no-changes-tp24286239p24286239.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
How force Maven to compile each project/module even if there are no changes
How can I force Maven to compile each project/module even if there are no changes. Because Maven automatically calculates the order in which the various projects/modules have to be compiled. This is done by checking the module dependencies. For instance this is the order: - project D; - project A; - project C; - project B; In the above example project D is not dependendent on an other project. But for instance project B is dependent on project D, A and C. Now let's say we change an interface method within project A. An implementor of this interface is located for instance in project B. But now we only commit the change of the interface in project A and we forget to commit the change of the implementor in project B. Now when Maven builds the WAR it says for project B there is nothing to compile -all classes are up to date. So nothing is done here. However we do have a compilation error now!!! And Maven did not detect it. So I would like Maven to always do a complete compile of each project. Does anyone know how to accomplish this? Thanks in advance. -- View this message in context: http://www.nabble.com/How-force-Maven-to-compile-each-project-module-even-if-there-are-no-changes-tp24286239p24286239.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
RE: maven assembly plugin problem.
Did you try the outputFileNameMapping in the dependencySet descriptor for assembly? ${artifact.artifactId}-${artifact.baseVersion}${dashC lassifier?}.${artifact.extension} Notice the version it is ${artifact.baseVersion} and *not* ${artifact.version} Thanks, mohan kr -Original Message- From: Alexander Vaysberg [mailto:w...@vaisberg.de] Sent: Wednesday, July 01, 2009 2:42 AM To: Maven Users List Subject: maven assembly plugin problem. Hi, I have a problem with assembly plugin. I have a standalone application and I make for this app a jar with manifest. In manifest set I a Main-Class and all dependencies for this app with jar plugin. That work fine. Than, I create with assembly the zip and get the all dependencies in lib. But I have a problem with SNAPSHOT jars. I have 5 SNAPSHOT jars. 3-Jars copy the assembly as so:- db-1.0.0-SNAPSHOT.jar, but for 2 -jars so same as: - firm-db-data-0.0.122-20090623.122812-2.jar. That is a date and time. For Deploying use I the Archiva. The jar plugin write in Manifest firm-db-data-0.0.122-SNAPSHOT. But the assembly put the dependency as firm-db-data-0.0.122-20090623.122812-2. I need the solution for this problem. Alexander Vaysberg - 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
maven assembly plugin problem.
Hi, I have a problem with assembly plugin. I have a standalone application and I make for this app a jar with manifest. In manifest set I a Main-Class and all dependencies for this app with jar plugin. That work fine. Than, I create with assembly the zip and get the all dependencies in lib. But I have a problem with SNAPSHOT jars. I have 5 SNAPSHOT jars. 3-Jars copy the assembly as so:- db-1.0.0-SNAPSHOT.jar, but for 2 -jars so same as: - firm-db-data-0.0.122-20090623.122812-2.jar. That is a date and time. For Deploying use I the Archiva. The jar plugin write in Manifest firm-db-data-0.0.122-SNAPSHOT. But the assembly put the dependency as firm-db-data-0.0.122-20090623.122812-2. I need the solution for this problem. Alexander Vaysberg - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org