Java EE Development Environment configuration

Source: Internet
Author: User
Tags svn client tortoisesvn


Java EE Development Environment configuration

Download and installation of Tomcat

1. Log in to the Tomcat site and download the latest version of Tomcat
http://tomcat.apache.org/
Windows platform download Zip package, Linux platform download tar package, download installation file is not recommended because the installation file

Tomcat does not see the boot, and the output from the runtime console is not conducive to the developer's use.

2. Unzip the downloaded compressed package to the specified directory: G:software\tomcat

3. Configure the environment variable classpath, and Java_home
Java_home:
C:\Program files\java\jdk1.8.0_92
Classpath
.; C:\Program Files\java\jdk1.8.0_92\lib\dt.jar; C:\Program Files\java\jdk1.8.0_92\lib\tools.jar; C:\Program Files\java\jdk1.8.0_92\lib\mysql-connector-java-5.1.30-bin.jar; G:\software\Tomcat\apache-tomcat-9.0.2\lib\jsp-api.jar; G:\software\Tomcat\apache-tomcat-9.0.2\lib\servlet-api.jar
Add the Jsp-api.jar and Servlet-api.jar two jar files under Lib for the Tomcat installation path to the CLASSPATH environment variable.

4. To start Tomcat, for Windows platforms, simply double-click the Startup.bat file in the bin directory under the Tomcat installation path.

5. After launching Tomcat, open the browser, enter http://localhost:8080 in the Address bar, and then enter, the browser appears the following interface, that is, the Tomcat installation is successful.

——————————————————————————————————————
Installation and use of Eclipse

The Eclipse platform is a development framework that IBM donates to the open source community, allowing new tools to augment the eclipse's capabilities.
These new tools are the Eclipse plug-in.

Eclipse IDE for Java EE developers download and install

1. Login http://www.eclipse.org/home/index.php, download eclipse IDE for Java EE developers

2. Extract the compressed package to any path (recommended: G:\software\eclipse_for_javaEE)

3. Go to the Eclipse folder, right click Eclipse.exe, click "Run as Administrator"

4. The following dialog box appears, specify the working space (recommended: Manually modified to: G:\eclipse_java_projects), click Launch to enter the next step

5. The following interface appears, indicating that the ECLIPSE_FOR_JAVAEE installation was successful

Tips:
Eclipse IDE for Java EE developers is an IDE tool that eclipse has prepared for Java EE developers
"Pure" eclipse, with the integration of some Eclipse plug-ins, allowing developers to Java without the need to add plugins
EE development.

————————————————————————————————————

Online installation _ Upgrade Eclipse Plugin
The integrity of the plug-in can be guaranteed and the latest version can be freely selected.
1. Click on the eclipse's Help menu and select "Install New software menu item"
2. Click the "Add ..." button, enter the name of the plugin in the "Name" text box, and enter the installation address of the plugin in the "Location" text box.
(The installation address of the Eclipse plugin needs to be queried from the official site of each plugin)

Upgrade:
1. "Work with" drop-down list box, you can select the plug-in that Eclipse has installed, select the specified plug-in project,
A list of all updatable items for the plugin will be listed below the dialog box.
2. Tick the plug-in item you want to update and click "Next".

——————————————————————————————

Installing a plug-in from a local compressed package

1. Download the local compressed package from each plugin website

2. Click on the eclipse's Help menu and select "Install New software menu item"
3. Click the "Add ..." button, click the "Archive ..." button, select the specified plug-in compression package,
You will see that the location text box is populated with the plug-in compression package, and click the OK button.


Enter the name of the plug-in in the Name text box, and enter the installation address of the plug-in in the Location text box.
(The installation address of the Eclipse plugin needs to be queried from the official site of each plugin)

——————————————————————————————————

Install the Eclipse plugin manually

Extended Installation
1. Create a new links path under the Eclipse installation path (that is, the Links folder)
2. Create a Xxx.link file within the Links folder (it is usually recommended that the file's primary filename is the same as the plugin name and the filename suffix is. link)
3. Edit the contents of the Xxx.link,
Path=<pluginpath>
Path= is a fixed,<pluginpath> that is the extension of the plugin installation path.
4. Create a new Eclipse folder in the <pluginPath> path in the Xxx.link file and create a plugins within the Eclipse folder
and the Features folder.
5. Copy the contents of the plugins and features folders contained in the plugin into the plugins and features folders created above.
Restart Eclipse to complete the installation.
The extended installation method allows each plugin to be placed in a separate folder, so the structure is very clear. If you need to uninstall a plugin, simply add the plugin
The corresponding link file can be deleted.

——————————————————————————————————————————

Installation and use of ant

Ant is a Java-based build tool, so it has cross-platform capabilities, and the Ant tool uses XML files to write build files,
Therefore, it has better adaptability.
Because Ant has cross-platform features, you may lose some flexibility when writing ant makefile. To compensate
This deficiency, Ant "exec" core task, this task allows the execution of commands on a particular operating system.

In effect, it is somewhat similar to the Make tool in C-programming (Unix/linux), which often uses the make tool to manage
Compilation, generation of the entire project.
Make uses shell commands to define build tasks and define dependencies between tasks so that they are always executed in the necessary order.
The Make tool's generated file format is more rigorous and prone to errors.

The Make tool has the following two defects
The essence of the 1.Make tool is still dependent on the UNIX platform's shell language, so make tools cannot cross-platform
The 2.Make tool's generated file format is more rigorous and prone to errors

This shows that ant is the Make tool in the Java World, and this tool is cross-platform and has simple, easy-to-use features.

Ant's Download and installation

1. Log in to the http://ant.apache.org/bindownload.cgi site to download the latest ant version
Recommended Windows platform Download *.zip compressed package

2. Compress the downloaded compressed file to (G:software\ant1_9)
It is recommended that you rename the Ant folder to Ant199 to make it easier to find.

The 3.Ant operation requires the following two environment variables
Java_home
Ant_home: The environment variable should point to the ant installation path
G:\software\Ant1_9\Ant199

4. Allow the operating system to recognize the Ant.bat command under the%ant_home%\bin path
Add the%ant_home%\bin path to the operating system's path,

5. Start the Command Line window, enter the Ant.bat command, if prompted by the following, the ant installation is successful

C:\users\fek>ant.bat
Buildfile:build.xml does not exist!
Build failed

——————————————————————————————————

Installation and use of MAVEN

MAVEN is a more advanced project management tool than Ant, which employs a "Convention better than configuration (COC)"
Policies to manage the project. It is used not only to construct the source code into a project that can be published (including compiling, packaging, testing
and distribution), you can also generate reports, generate Web sites, and so on. In some ways, maven is superior to ant, so
Many companies are starting to use MAVEN.

Download and install Maven

1. Log in to the http://maven.apache.org/download.cgi site to download Maven's latest version.
Recommended Windows platform Download *.zip compressed package

2. Unzip the downloaded compressed file to any path (recommended: G:\software\Maven3_5)

3. Rename the apache-maven-3.5.2 to Maven352

The 4.Mavern operation requires the following two environment variables
Java_home: The installation path to the JDK
M2_home: Point to Maven installation path G:\software\Maven3_5\Maven352

The key command for the 5.Maven tool is the Mvn.vat command under the%m2_home%/bin path, if the reader wants the operating system to recognize the
command, you can also add the%m2_home%/bin path to the operating system's PATH environment variable. 6 Start the Command Line window and enter the following command: MVN help:system

6. If you can see that Maven is constantly downloading various files from the network and then finally displaying the following information, the MAVEN installation is successful

[INFO]------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO]------------------------------------------------------------------------
[INFO] Total Time:01:19 min
[INFO] Finished at:2017-12-26t10:16:40+08:00
[INFO] Final memory:13m/166m
[INFO]------------------------------


——————————————————————————————————————————

Use SVN for collaborative development:

SVN server Download and installation

1. Login http://subversion.apache.org/packages.html

On this page you can see the service side of SVN for various operating systems, and clicking on the WIN32SVN link will navigate to the SourceForge.net WIN32SVN project


2. Click on the downloaded installation file to start installing the SVN server (it is recommended to put the installation file to G:\software\SVN1817, but cannot specify the installation directory)

Once the installation is complete, you can see that the system PATH environment variable is C:\Subversion\bin, which indicates that the installer has added the bin path under the SVN installation path to the PATH environment variable, which allows the developer
The command line window uses commands such as svn,svnadmin under the bin path.



_______________________________________________________________________________________________________________ _



Download and install the SVN client

For ordinary developers, it is common to choose to use TORTOISESVN as the client,

1. Log in to Http://tortoisesvn.net/downloads, download the latest version

2. After the download is complete, get a Tortoisesvn-1.9.7.27907-x64-svn-1.8.9.msi file (recommended to place the installation file to: G:\software\SVN_Client_197)

Double-click the file to start the installation, after the installation is complete, the TORTOISESVN installer may require a restart of the computer, restart the computer as required to complete the TORTOISESVN installation.

Tips:
TORTOISESVN does not provide any windows to perform versioning operations, it is just a shell extension, it has been integrated into Windows Explorer, so just right-click
Click any folder, file, and you can see the TortoiseSVN menu in the popup shortcut menu.

Java EE Development Environment configuration

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.