maven-2

Repository layout for large Maven projects

霸气de小男生 提交于 2019-12-03 12:43:06
问题 I have a large application (~50 modules) using a structure similar to the following: Application Communication modules Color communication module SSN communication module etc. communication module Router module Service modules Voting service module Web interface submodule for voting Vote collector submodule for voting etc. for voting Quiz service module etc. module I would like to import the application to Maven and Subversion. After some research I found that two practical approaches exists

How to extend/customize a WAR with another project

南楼画角 提交于 2019-12-03 12:34:41
问题 We have the following scenario with our project: A core web application packaged as a war file (call it Core project). The need to "customize" or "extend" the core app per customer (call it Customer project). This mostly includes new bean definitions (we're using Spring), ie. replacing service implementations in the core.war with customer-specific implementations. We want to develop the Core and Customer projects independently When the Customer project is developed, we need to be able to run

Maven repository for EJB 3.1 API

空扰寡人 提交于 2019-12-03 12:32:53
What Maven repository can I use for EJB 3.1 API dependency? This dependency from central worked. <dependency> <groupId>javax</groupId> <artifactId>javaee-api</artifactId> <version>6.0</version> <scope>provided</scope> </dependency> 来源: https://stackoverflow.com/questions/2429245/maven-repository-for-ejb-3-1-api

maven deploy changed artifacts only

只谈情不闲聊 提交于 2019-12-03 12:30:07
问题 I'm using maven 2.2 with nexus 1.4.0 Let's say I have a pom-structure like this (with corresponding versions) parentproj, v1.0.1 - childproj1, v1.0.2 - childproj2, v1.0.7 childproj1 and childproj2 represent different parts of the application (e g gui and backend) and I want to be able to keep their versions separate so that I can release a new version of the backend without having to release a new version of the gui. Now, to deploy this structure to Nexus it would be convenient to go to

Eclipse Maven web application - can not run on server anymore

房东的猫 提交于 2019-12-03 12:27:37
问题 I have an maven eclipse webapp project that I was able to right click and 'Run on server' and it would deploy on tomcat. I recently did a 'maven -> Update project conifgurations' and I now can NOT deploy and run the project as a webapp. Has anyone seen this before? The only output from tomcat is as follows - it doesnt even look like its trying to deploy the application. Apr 14, 2010 3:58:54 PM org.apache.catalina.core.AprLifecycleListener init INFO: The APR based Apache Tomcat Native library

Eclipse: Re-run Maven using the -X switch to enable full debug logging

﹥>﹥吖頭↗ 提交于 2019-12-03 12:19:26
问题 I have a Maven project I'm trying to build/run in Eclipse but I'm getting the error below. How do I do what the error suggests and add the -e or X switches to try to troubleshoot this? [ERROR] Failed to execute goal org.bsc.maven:maven-processor-plugin:2.0.5:process (process) on project glw-crm: Error executing: NullPointerException -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full

Setting the a Property to what maven.compile.classpath Contains WITHOUT Ant

不羁岁月 提交于 2019-12-03 12:09:26
I'd like to set a property in my pom to a classpath containing all the project's dependencies. The ant plugin does something like this, so I know it's definitely possible. I basically want to use ${maven.compile.classpath} wherever I like in my pom and have it 'just work'. I don't mind using plugins or anything else to achieve this. Many thanks, Nick I don't think that there's a way of doing this without writing your own maven plugin. That said, you can get at the classpath using dependency:build-classpath . Is that of use? yegor256 This is how it works: <plugin> <artifactId>maven-antrun

How to get Maven project BaseDir() from java Code [closed]

两盒软妹~` 提交于 2019-12-03 12:06:30
问题 It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 8 years ago . How to get Maven project basedir() from my Java code? 回答1: According to Codehaus, there's a maven property ${basedir} If you include a properties file in your resources, which has the ${basedir} placeholder, and

How do I stop Maven 2.x from trying to retrieve non-existent pom.xml files for dependencies every build?

[亡魂溺海] 提交于 2019-12-03 12:02:21
In my project, there are a number of dependencies that are transitively included from other dependencies that do not have pom.xml files available in any of our corporate repositories. These are internal jar-only libraries supported by various teams which have been uploaded into repositories for convenience from non-Maven teams, however these repositories are unfortunately not mine to play with. For these dependencies, Maven insists on trying to retrieve the poms from each of my repository list every time I run a build, or mvn dependency:list . This means maven tries to retrieve 8x pom files

Why does a dependency with scope “provided” hide transitive dependencies in Maven?

99封情书 提交于 2019-12-03 11:58:01
问题 I have three modules in my Maven project (this is slightly simplified): model contains JPA annotated entity classes persistence instantiates an EntityManager and calls methods on it application creates instances of the classes in model , sets some values and passes them to persistence model and persistence obviously depend on javax.persistence , but application shouldn't, I think. The javax.persistence dependency is moved to a top-level POM's dependencyManagement section because it occurs in