Some preliminary understandings about Maven:1, the word maven can be translated as: "Accumulation of knowledge", "experts", professionals, etc.;2, one of the uses of MAVEN is to build, it is a powerful build tool that can help us to automate the build process, from cleaning, compiling, testing, to generating reports, to packaging and deploying, we don't have to k
MAVEN is a project management tool, and if we don't tell it what version of the JDK our code is going to compile with, it will be processed with the default JDK version of Maven-compiler-plugin, which makes it prone to version mismatches. Problems that could lead to a compilation that does not pass. For example, if a new feature of jdk1.7 is used in the code, but Maven
Learning notes: Maven constructs the version number to solve the browser cache problem, learning notes mavenProblems to be Solved
During WEB system development, in order to improve the performance, the browser's cache function will be used. In fact, even if the explicit declarative cache is not used, modern browsers will apply static files (js, css, images, and so on) cache. But it is also because of this problem that the cache logic of resources some
One: Build a maven project using MyEclipse1. Select Menu File, new, and other2. Select Maven Project3, the default selection, direct next4. Filter by entering WebApp in filter, then select Maven-archetype-webapp, then next5. Enter the group ID and Artifact ID. The group ID is the organization identity, the package name, the Artifact ID is the project name version
Automatically download all required dependent libraries with the help of Maven dependency mechanism and keep the version upgrade.Case analysisLet's look at a case study to see how it works. Suppose you want to use log4j as the log for the project. What are you going to do here?1. In the traditional way
Visit http://logging.apache.org/log4j/
Download the jar library for Log4 J
Copy jar to project Classpath
To manually include it in
Maven is a cross-platform tool. It is not only a build tool, but also a tool for managing dependencies.It eliminates duplicates of components and provides a central repository, which can help us automatically download components.---------------------------------------------------------------------Any component in the world can be uniquely identified by Maven coordinates.Groudid: defines the actual project t
Error One:1.eclipse, when Maven test, error:-dmaven.multimoduleprojectdirectory= $M 2_home)2. Workaround:You can set up an environment variable m2_home point to your MAVEN installation directory m2_home=d:\apps\apache-maven-3.3.1 and then in window->preference->java->installed Jres->edit Setting the-dmaven.multimoduleprojectdirectory= $M in the default VM argumen
people down.4 " Proficient in Hibernate:java object persistence technology detailed"Star:Suitable objects: Beginner, Intermediate, advancedIntroduction: Hibernate necessary reference books, also written by the Chinese, rare a good book, and the author is a mm.5 "Struts 2.1 authoritative Guide"Star:Suitable for: Beginner, IntermediateDescription: A good book written by a native of Struts2, but the name seem
, namely Jar and Test-jar, which run through MAVEN's built-in bindings in the package phase of the default life cycle, with the behavior of packaging the project master code. The latter does not have a built-in binding, so the plug-in configuration above shows that the target is declared to package the test code. By querying the plug-in's specific information, you can see that the default binding declaration period for Test-jar is the package, so when you run MVN clean, you can expect two target
Modular maven project and mavenPreface
The modularization of the project facilitates the division of tasks, post-maintenance, and easy expansion. modules can also be independently deployed as services;Create a parent project with the packaging type POM
The maven plug-in I used is m2e. I believe most people installed m2e plug-ins in eclipse. If you don't talk nonsense, start directly:
Select create
When using Maven to create a project module, the directory created by default archetype template, and the default Unit test tool for JUnit 3.8.1, and some commonly used resource files directory, configuration file (for example: log4j configuration file, Web page development commonly used template file style files, etc. need to be created manually, copy, then how to customize a suitable for their own habits of the archetype?The
In the security and other reasons, some enterprise internal network is not allowed to access the external network, but the project is built within the MAVEN architecture, so that the enterprise in the internal network to build their own MAVEN warehouse services, Furthermore, some of the more distinct enterprise-developed components of large enterprises or in-house modular components will need to use the
Goal: There is a basic understanding of the build life cycle (build lifecycle), MAVEN Warehouse (repositories), dependency management (dependency management), and project object model. Currently not ready to delve into Maven so use tool Ideaj to help with learning, Create a default Maven project with idea, with the following structure: Related commands: Packagi
Importing a Maven project from Git, right-clicking the jar package that you want to update the MAVEN reference, and discovering that the right-click menu does not have a MAVEN menu item at all. What to do? Very simple, follow these steps:After importing from Git, right-click the project without the "Maven" menu item:Ju
The error is as follows in the packaging process:No compiler is provided in this environment. Perhaps running on a JRE rather than a JDK[INFO] Scanning for projects ... [INFO] [INFO] Using the builder Org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread Count of 1[info] [INFO]-------------------------- ----------------------------------------------[INFO] Building firstspringbootexample 0.0.1-snapshot[info]-------- ----------------------------------------
1. Download maven3.3.1 http://maven.apache.org/2. Unzip and put into the specified directory D:\eclipsetools\apache-maven-3.3.13. Setting the MAVEN environment variableBefore configuring the MAVEN environment, be sure to configure the JDK environmentmaven_home=d:\eclipsetools\apache-maven-3.3.1Path=%maven_home%\bin4, s
Maven command Download source code and JavadocsWhen using Maven in the IDE, if you want to see the source code and Javadoc of the classes in the referenced jar package need to download the source code through the MAVEN command and then introduce it, it is easy to achieve this with the MVN command:
mvn dependency:sources
mvn Dependency:resolve-dclass
what maven is.
A: Maven is a tool for project management and integration. MAVEN provides a complete set of build lifecycle frameworks for developers. The development team does not have to spend much time automating the infrastructure configuration of the project, because MAVEN uses a standard directory structure and a
Now the latest Eclipse Luna Release has built-in Maven plugin, which makes our work a lot more concise, as long as the project directly into the can, regardless of the plug-in problems, but after the import of the project can be deployed in Tomcat can also be deployed on the jetty server , the following is the debugging process.I. Development environmentJava:jdk7Eclipse:eclipse Java EE IDE for Web developers, Version:luna Release (4.4.0)
, advancedIntroduction: Hibernate necessary reference books, also written by the Chinese, rare a good book, and the author is a mm.5 "Struts 2.1 authoritative Guide"Star:Suitable for: Beginner, IntermediateDescription: A good book written by a native of Struts2, but the name seems a little bigger. The authoritative guide should only be called by the author.6 "Maven
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.