maven-2

Maven artifacts could not be resolved

有些话、适合烂在心里 提交于 2019-12-08 12:41:57
问题 I added the spring and jboss repositories to my pom.xml like below: <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <name>MyProject</name> <url>http://www.myproject.com</url> <modelVersion>4.0.0</modelVersion> <groupId>com.myproject</groupId> <artifactId>myproject</artifactId> <version>1.0-SNAPSHOT</version> <packaging>war</packaging>

yui compressor maven: A required class is missing: org.mozilla.javascript.ErrorReporter

蹲街弑〆低调 提交于 2019-12-08 12:13:50
问题 I am not able to use yui-compressor maven plugin in my web app. When I run maven I get following error [INFO] Internal error in the plugin manager executing goal 'net.sf.alchim:yuicompressor-maven-plugin:0.7.1:compress': Unable to load the mojo 'net.sf.alchim: yuicompressor-maven-plugin:0.7.1:compress' in the plugin 'net.sf.alchim:yuicompressor-maven-plugin'. A required class is missing: org.mozilla.javascript.ErrorReporter Later I found that rhino js plugin contains this class org.mozilla

Issue in executing Spring Web project in Eclipse on Tomcat server

纵饮孤独 提交于 2019-12-08 12:03:39
问题 I have a Spring web project that uses Maven to compile/build. There is no issue in building the project. I am trying to run the project in Eclipse (3.3.2) on Tomcat (v6) server. As part of Spring project, I have a spring-servlet.xml file in WEB-INF directory. This file includes another resource xml file that has datasource configuration. <import resource="classpath:${datasourceInclude}.xml"/> Now when the project is compiled using Maven, it resolves the variable ${datasourceInclude} and set

mvn package command doesn't run successfully after mvn clean command if done from command prompt

爱⌒轻易说出口 提交于 2019-12-08 11:19:03
问题 Hi I get a weird error when I run mvn package command from the command line after executing mvn clean command. The error is a compilation failure error. This is a trace: annotations are not supported in -source 1.3 06.04.2011 17.06.59 (use -source 5 or higher to enable annotations) 06.04.2011 17.06.59 @Override at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:715) 06.04.2011 17.06.59 at org.apache.maven.lifecycle.DefaultLifecycleExecutor

Spliting Front-end from Back-office on Maven

淺唱寂寞╮ 提交于 2019-12-08 09:01:42
问题 I've a java ecommerce web-based app. It is written using Spring Roo, so it follows the Domain Driven Design paradigm. The application has two UI. The first is front-end, based on plain jsp/jstl/tiles, it is stable, changes rarely and HAVE to STAY UP and RUNNING. The second is built on Vaadin/GWT, it changes frequently (on Custemer requerements). My question is how to best structure Maven project such as: Allow deploy (on tomcat) only back-office or front-end UI; Do not duplicate Domain Logic

How can I make Maven set up (and keep up to date) the build path for my Eclipse project?

给你一囗甜甜゛ 提交于 2019-12-08 08:01:55
问题 I define the dependencies for compiling, testing and running my programs in the pom.xml files. But Eclipse still has a separately configured build path, so whenever I change either, I have to manually update the other. I guess this is avoidable? How? 回答1: Use either m2eclipse or IAM (formerly Q4E). Both provide (amongst other features) a means to recalculate the Maven dependencies whenever a clean build is performed and presents the dependencies to Eclipse as a classpath container. See this

Maven clean install fails with connection timed out:connect error

跟風遠走 提交于 2019-12-08 07:48:46
问题 I tried maven clean install on my project and I every time I get the following error Maven version 2.2.1 JDK 1.7 F:\Wealth>"C:\Program Files\apache-maven-2.2.1\bin\mvn.bat" cl ean install -U [INFO] Scanning for projects... [INFO] ------------------------------------------------------------------------ [INFO] Building polo [INFO] task-segment: [clean, install] [INFO] ------------------------------------------------------------------------ Downloading: http://maven.apps.com/maven2/org/apache

Working with Maven

橙三吉。 提交于 2019-12-08 06:26:08
问题 I downloaded Java source code of some project that works with Maven. After checking out the code to Eclipse, and then building it from the command line, I followed the instructions and imported it from Eclipse as: File > Import > Maven Projects. Now I have the core source code and many additional sub projects that seem to have the same thing like the core, just separated. Could anyone please explain me what are these sub projects? why I need them? and on which code I need to work now if I

deploying maven jar files and SNAPSHOT dependencies

微笑、不失礼 提交于 2019-12-08 05:47:02
问题 We currently use SNAPSHOT modifier in development so that project dependencies are linked to the most current build of its dependencies. So when we build a project we get all the jars with various time SNAPSHOTS. Regardless of a code change. This proves to be an issue when the end user wants to download a new release. For example there is a big jar file that is rarely updated. We would like for that particular jar file to be referred to as it version number 1.4 as supposed to 1.4-SNAPSHOT

What are the best methods for deploying java code to production?

你。 提交于 2019-12-08 05:43:55
问题 Currently we have a Java Restlet API with dependencies controlled via Maven. When we update the API we run maven assembly:assembly which does the unit tests etc and produces a single jar file. We then upload this to the production server and run it using nohup. Is there a better or more automated way of doing this? Is this where something like Hudson would come in? Thanks 回答1: My experience goes with webapp-deployment. But same should hold true here. Use Maven, Cargo, Nexus (or Artifactory),