Review Board 1.7.22


Sqoop2: devguide: Document how to open project in Eclipse

Review Request #10324 - Created April 6, 2013 and updated

Vasanth kumar RJ
sqoop-939
Reviewers
Sqoop
sqoop-sqoop2
Developer guide for setting the development environment and setting eclipse
Done

Diff revision 2 (Latest)

1 2
1 2

  1. docs/src/site/sphinx/DevEnv.rst: Loading...
  2. docs/src/site/sphinx/index.rst: Loading...
docs/src/site/sphinx/DevEnv.rst
New File

    
   
1
.. Licensed to the Apache Software Foundation (ASF) under one or more

    
   
2
   contributor license agreements.  See the NOTICE file distributed with

    
   
3
   this work for additional information regarding copyright ownership.

    
   
4
   The ASF licenses this file to You under the Apache License, Version 2.0

    
   
5
   (the "License"); you may not use this file except in compliance with

    
   
6
   the License.  You may obtain a copy of the License at

    
   
7

   

    
   
8
       http://www.apache.org/licenses/LICENSE-2.0

    
   
9

   

    
   
10
   Unless required by applicable law or agreed to in writing, software

    
   
11
   distributed under the License is distributed on an "AS IS" BASIS,

    
   
12
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

    
   
13
   See the License for the specific language governing permissions and

    
   
14
   limitations under the License.

    
   
15

   

    
   
16

   

    
   
17
=====================================

    
   
18
Sqoop 2 Development Environment Setup

    
   
19
=====================================

    
   
20

   

    
   
21
This document describes you how to setup development environment for Sqoop 2.

    
   
22

   

    
   
23
System Requirement

    
   
24
==================

    
   
25

   

    
   
26
Java

    
   
27
----

    
   
28

   

    
   
29
Sqoop written in Java and using version 1.6. You can `download java <http://www.oracle.com/technetwork/java/javase/downloads/index.html>`_ and install. Locate JAVA_HOME to installed directroy, e.g. export JAVA_HOME=/usr/lib/jvm/jdk1.6.0_32.

    
   
30

   

    
   
31
Maven

    
   
32
-----

    
   
33

   

    
   
34
Sqoop uses Maven 3 for building the project. Download `Maven <http://maven.apache.org/download.cgi>`_ and its Installation instructions given in `link <http://maven.apache.org/download.cgi#Maven_Documentation>`_.

    
   
35

   

    
   
36
Eclipse Setup

    
   
37
=============

    
   
38

   

    
   
39
Steps for downloading source code is given in `Building Sqoop2 <BuildingSqoop2.html>`_

    
   
40

   

    
   
41
Sqoop 2 project has multiple modules where one module is depend on another module for e.g. sqoop 2 client module has sqoop 2 common module dependency. Follow below step for creating eclipse's project and classpath for each module.

    
   
42

   

    
   
43
::

    
   
44

   

    
   
45
  //Install all package into local maven repository

    
   
46
  mvn clean install -DskipTests

    
   
47

   

    
   
48
  //Adding M2_REPO variable to eclipse workspace

    
   
49
  mvn eclipse:configure-workspace -Declipse.workspace=<path-to-eclipse-workspace-dir-for-sqoop-2>

    
   
50

   

    
   
51
  //Eclipse project creation with optional parameters

    
   
52
  mvn eclipse:eclipse -DdownloadSources=true -DdownloadJavadocs=true

    
   
53

   

    
   
54
Alternatively, for manually adding M2_REPO classpath variable as maven repository path in eclipse-> window-> Java ->Classpath Variables ->Click "New" ->In new dialog box, input Name as M2_REPO and Path as $HOME/.m2/repository ->click Ok.

    
   
55

   

    
   
56
On successful execution of above maven commands, Then import the sqoop project modules into eclipse-> File -> Import ->General ->Existing Projects into Workspace-> Click Next-> Browse Sqoop 2 directory ($HOME/git/sqoop2) ->Click Ok ->Import dialog shows multiple projects (sqoop-client, sqoop-common, etc.) -> Select all modules -> click Finish.

    
   
57

   
docs/src/site/sphinx/index.rst
Revision 02dce33 New Change
 
  1. docs/src/site/sphinx/DevEnv.rst: Loading...
  2. docs/src/site/sphinx/index.rst: Loading...