Review Board 1.7.22


SQOOP-999: Support bulk load from HDFS to PostgreSQL using COPY ... FROM

Review Request #12048 - Created June 22, 2013 and updated

Masatake Iwasaki
trunk
SQOOP-999
Reviewers
Sqoop
sqoop-trunk
Export with PostgreSQL Copy API can be realized in a straitforward way. Attached file is not complete patch but sample implementation without tests and consideration for corner cases.
Though this code resolves dependency for PostgreSQL JDBC by ivy, is it acceptable for the project?

 
ivy.xml
Revision 750adfc New Change
[20] 179 lines
[+20]
180
    <dependency org="org.apache.hcatalog" name="hcatalog-core"
180
    <dependency org="org.apache.hcatalog" name="hcatalog-core"
181
      rev="${hcatalog.version}" conf="hcatalog->default">
181
      rev="${hcatalog.version}" conf="hcatalog->default">
182
      <artifact name="hcatalog-core" type="jar"/>
182
      <artifact name="hcatalog-core" type="jar"/>
183
    </dependency>
183
    </dependency>
184

    
   
184

   

    
   
185
    <dependency org="org.postgresql" name="postgresql"

    
   
186
      rev="${postgresql.version}" conf="common->default" />

    
   
187

   
185
    <exclude org="org.apache.hadoop" module="avro"/>
188
    <exclude org="org.apache.hadoop" module="avro"/>
186
    <exclude org="commons-daemon" module="commons-daemon" />
189
    <exclude org="commons-daemon" module="commons-daemon" />
187
    <exclude type="pom" />
190
    <exclude type="pom" />
188

    
   
191

   
189
  </dependencies>
192
  </dependencies>
190
</ivy-module>
193
</ivy-module>
ivy/libraries.properties
Revision 430d554 New Change
 
src/java/org/apache/sqoop/manager/DirectPostgresqlManager.java
Revision c085218 New Change
 
src/java/org/apache/sqoop/mapreduce/postgresql/PostgreSQLCopyExportJob.java
New File
 
src/java/org/apache/sqoop/mapreduce/postgresql/PostgreSQLCopyExportMapper.java
New File
 
src/test/com/cloudera/sqoop/manager/DirectPostgreSQLExportManualTest.java
New File
 
  1. ivy.xml: Loading...
  2. ivy/libraries.properties: Loading...
  3. src/java/org/apache/sqoop/manager/DirectPostgresqlManager.java: Loading...
  4. src/java/org/apache/sqoop/mapreduce/postgresql/PostgreSQLCopyExportJob.java: Loading...
  5. src/java/org/apache/sqoop/mapreduce/postgresql/PostgreSQLCopyExportMapper.java: Loading...
  6. src/test/com/cloudera/sqoop/manager/DirectPostgreSQLExportManualTest.java: Loading...