sqoop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jar...@apache.org
Subject svn commit: r1373132 - in /sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job: etl/Context.java etl/MutableContext.java etl/Partition.java io/ io/DataReader.java io/DataWriter.java
Date Tue, 14 Aug 2012 21:53:53 GMT
Author: jarcec
Date: Tue Aug 14 21:53:53 2012
New Revision: 1373132

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

(Bilung Lee via Jarek Jarcec Cecho)

Added:
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Context.java
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/MutableContext.java
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Partition.java
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/DataReader.java
    sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/DataWriter.java

Added: sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Context.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Context.java?rev=1373132&view=auto
==============================================================================
--- sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Context.java (added)
+++ sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Context.java Tue Aug
14 21:53:53 2012
@@ -0,0 +1,27 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sqoop.job.etl;
+
+/**
+ * The context for getting configuration values.
+ */
+public interface Context {
+
+  public String getString(String key);
+
+}

Added: sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/MutableContext.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/MutableContext.java?rev=1373132&view=auto
==============================================================================
--- sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/MutableContext.java (added)
+++ sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/MutableContext.java Tue
Aug 14 21:53:53 2012
@@ -0,0 +1,29 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sqoop.job.etl;
+
+/**
+ * The context for getting and setting configuration values.
+ */
+public interface MutableContext extends Context {
+
+  public void setString(String key, String value);
+
+  public void setFieldNames(String[] names);
+
+}

Added: sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Partition.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Partition.java?rev=1373132&view=auto
==============================================================================
--- sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Partition.java (added)
+++ sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/etl/Partition.java Tue Aug
14 21:53:53 2012
@@ -0,0 +1,38 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sqoop.job.etl;
+
+import java.io.DataInput;
+import java.io.DataOutput;
+
+/**
+ * A part of the input data partitioned by the Partitioner.
+ */
+public interface Partition {
+
+  /**
+   * Deserialize the fields of this partition from input.
+   */
+  public void readFields(DataInput in);
+
+  /**
+   * Serialize the fields of this partition to output.
+   */
+  public void write(DataOutput out);
+
+}

Added: sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/DataReader.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/DataReader.java?rev=1373132&view=auto
==============================================================================
--- sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/DataReader.java (added)
+++ sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/DataReader.java Tue Aug
14 21:53:53 2012
@@ -0,0 +1,26 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sqoop.job.io;
+
+/**
+ * An intermediate layer for passing data from the MR framework
+ * to the ETL framework.
+ */
+public interface DataReader {
+
+}

Added: sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/DataWriter.java
URL: http://svn.apache.org/viewvc/sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/DataWriter.java?rev=1373132&view=auto
==============================================================================
--- sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/DataWriter.java (added)
+++ sqoop/branches/sqoop2/spi/src/main/java/org/apache/sqoop/job/io/DataWriter.java Tue Aug
14 21:53:53 2012
@@ -0,0 +1,26 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sqoop.job.io;
+
+/**
+ * An intermediate layer for passing data from the ETL framework
+ * to the MR framework.
+ */
+public interface DataWriter {
+
+}



Mime
View raw message