sqoop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jar...@apache.org
Subject svn commit: r1373131 - in /sqoop/branches/sqoop2: connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/ spi/src/main/java/org/apache/sqoop/job/etl/
Date Tue, 14 Aug 2012 21:52:57 GMT
Author: jarcec
Date: Tue Aug 14 21:52:56 2012
New Revision: 1373131

URL: http://svn.apache.org/viewvc?rev=1373131&view=rev
Log:
SQOOP-532. Define intefaces for connector-defined execution classes.

(Bilung Lee via Jarek Jarcec Cecho)

Modified:
    sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportDestroyer.java
    sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportInitializer.java
    sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportLoader.java
    sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportDestroyer.java
    sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportExtractor.java
    sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportInitializer.java
    sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportPartitioner.java
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Destroyer.java
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Extractor.java
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Initializer.java
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Loader.java
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Partitioner.java

Modified: sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportDestroyer.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportDestroyer.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportDestroyer.java
(original)
+++ sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportDestroyer.java
Tue Aug 14 21:52:56 2012
@@ -17,8 +17,14 @@
  */
 package org.apache.sqoop.connector.jdbc;
 
+import org.apache.sqoop.job.etl.Context;
 import org.apache.sqoop.job.etl.Destroyer;
 
 public class GenericJdbcExportDestroyer extends Destroyer {
 
+  @Override
+  public void run(Context context) {
+    // TODO Auto-generated method stub
+  }
+
 }

Modified: sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportInitializer.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportInitializer.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportInitializer.java
(original)
+++ sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportInitializer.java
Tue Aug 14 21:52:56 2012
@@ -17,8 +17,14 @@
  */
 package org.apache.sqoop.connector.jdbc;
 
+import org.apache.sqoop.job.etl.MutableContext;
 import org.apache.sqoop.job.etl.Initializer;
 
 public class GenericJdbcExportInitializer extends Initializer {
 
+  @Override
+  public void run(MutableContext context) {
+    // TODO Auto-generated method stub
+  }
+
 }

Modified: sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportLoader.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportLoader.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportLoader.java
(original)
+++ sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcExportLoader.java
Tue Aug 14 21:52:56 2012
@@ -17,8 +17,16 @@
  */
 package org.apache.sqoop.connector.jdbc;
 
+import org.apache.sqoop.job.etl.Context;
 import org.apache.sqoop.job.etl.Loader;
+import org.apache.sqoop.job.io.DataReader;
+import org.apache.sqoop.job.io.DataWriter;
 
 public class GenericJdbcExportLoader extends Loader {
 
+  @Override
+  public void run(Context context, DataReader reader) {
+    // TODO Auto-generated method stub
+  }
+
 }

Modified: sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportDestroyer.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportDestroyer.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportDestroyer.java
(original)
+++ sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportDestroyer.java
Tue Aug 14 21:52:56 2012
@@ -17,8 +17,14 @@
  */
 package org.apache.sqoop.connector.jdbc;
 
+import org.apache.sqoop.job.etl.Context;
 import org.apache.sqoop.job.etl.Destroyer;
 
 public class GenericJdbcImportDestroyer extends Destroyer {
 
+  @Override
+  public void run(Context context) {
+    // TODO Auto-generated method stub
+  }
+
 }

Modified: sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportExtractor.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportExtractor.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportExtractor.java
(original)
+++ sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportExtractor.java
Tue Aug 14 21:52:56 2012
@@ -17,8 +17,16 @@
  */
 package org.apache.sqoop.connector.jdbc;
 
+import org.apache.sqoop.job.etl.Context;
+import org.apache.sqoop.job.etl.Partition;
 import org.apache.sqoop.job.etl.Extractor;
+import org.apache.sqoop.job.io.DataWriter;
 
 public class GenericJdbcImportExtractor extends Extractor {
 
+  @Override
+  public void run(Context context, Partition partition, DataWriter writer) {
+    // TODO Auto-generated method stub
+  }
+
 }

Modified: sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportInitializer.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportInitializer.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportInitializer.java
(original)
+++ sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportInitializer.java
Tue Aug 14 21:52:56 2012
@@ -17,8 +17,14 @@
  */
 package org.apache.sqoop.connector.jdbc;
 
+import org.apache.sqoop.job.etl.MutableContext;
 import org.apache.sqoop.job.etl.Initializer;
 
 public class GenericJdbcImportInitializer extends Initializer {
 
+  @Override
+  public void run(MutableContext context) {
+    // TODO Auto-generated method stub
+  }
+
 }

Modified: sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportPartitioner.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportPartitioner.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportPartitioner.java
(original)
+++ sqoop/branches/sqoop2/connector/connector-generic-jdbc/src/main/java/org/apache/sqoop/connector/jdbc/GenericJdbcImportPartitioner.java
Tue Aug 14 21:52:56 2012
@@ -17,8 +17,18 @@
  */
 package org.apache.sqoop.connector.jdbc;
 
+import java.util.List;
+
+import org.apache.sqoop.job.etl.Context;
+import org.apache.sqoop.job.etl.Partition;
 import org.apache.sqoop.job.etl.Partitioner;
 
 public class GenericJdbcImportPartitioner extends Partitioner {
 
+  @Override
+  public List<Partition> run(Context context) {
+    // TODO Auto-generated method stub
+    return null;
+  }
+
 }

Modified: sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Destroyer.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Destroyer.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Destroyer.java (original)
+++ sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Destroyer.java Tue Aug
14 21:52:56 2012
@@ -23,4 +23,6 @@ package org.apache.sqoop.job.etl;
  */
 public abstract class Destroyer {
 
+  public abstract void run(Context context);
+
 }

Modified: sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Extractor.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Extractor.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Extractor.java (original)
+++ sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Extractor.java Tue Aug
14 21:52:56 2012
@@ -17,10 +17,15 @@
  */
 package org.apache.sqoop.job.etl;
 
+import org.apache.sqoop.job.io.DataWriter;
+
 /**
  * This allows connector to extract data from a source system
  * based on each partition.
  */
 public abstract class Extractor {
 
+  public abstract void run(Context context,
+      Partition partition, DataWriter writer);
+
 }

Modified: sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Initializer.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Initializer.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Initializer.java (original)
+++ sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Initializer.java Tue
Aug 14 21:52:56 2012
@@ -23,4 +23,6 @@ package org.apache.sqoop.job.etl;
  */
 public abstract class Initializer {
 
+  public abstract void run(MutableContext context);
+
 }

Modified: sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Loader.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Loader.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Loader.java (original)
+++ sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Loader.java Tue Aug 14
21:52:56 2012
@@ -17,9 +17,13 @@
  */
 package org.apache.sqoop.job.etl;
 
+import org.apache.sqoop.job.io.DataReader;
+
 /**
  * This allows connector to load data into a target system.
  */
 public abstract class Loader {
 
+  public abstract void run(Context context, DataReader reader);
+
 }

Modified: sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Partitioner.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Partitioner.java?rev=1373131&r1=1373130&r2=1373131&view=diff
==============================================================================
--- sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Partitioner.java (original)
+++ sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Partitioner.java Tue
Aug 14 21:52:56 2012
@@ -17,10 +17,14 @@
  */
 package org.apache.sqoop.job.etl;
 
+import java.util.List;
+
 /**
  * This allows connector to define how input data to be partitioned.
  * The number of data partitions also determines the degree of parallelism.
  */
 public abstract class Partitioner {
 
+  public abstract List<Partition> run(Context context);
+
 }



Mime
View raw message