Configuring and Importing a Sample Project
Prerequisites
Ensure that the time difference between a local computer and the MRS cluster is less than 5 minutes. Time of the MRS cluster can be viewed in the upper right corner on the MRS Manager page.
Procedure
- Obtain the HBase sample project in Obtaining a Sample Project.
- In the root directory of the HBase sample project, that is, the pom.xml directory of the HBase sample project, open the CLI and run the mvn install command to compile the project.
- In the cmd window opened in 2, run the mvn eclipse:eclipse command to create an Eclipse project.
- Configure the Eclipse development environment.
1. On the Eclipse menu bar, choose Window > Preferences.
The Preferences window is displayed.
2. Choose General > Workspace from the navigation tree. In the Text file encoding area, select Other, set the value to UTF-8, click Apply.
For details, see Figure 2.
3. In the navigation tree on the left, choose Maven > User Settings. On the User Settings page, click Browse to import the settings.xml file of the Maven, click Apply, and then click OK.
See Figure 3. - In the application development environment, import the sample project to the Eclipse development environment.
- Choose File > Import > General > Existing Projects into Workspace > Next > Browse.
The Browse Folder dialog box is displayed.
- Select the sample project folder, and click Finish.
- Choose File > Import > General > Existing Projects into Workspace > Next > Browse.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.