Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 758CB200B9B for ; Wed, 12 Oct 2016 16:34:25 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 7417E160AD4; Wed, 12 Oct 2016 14:34:25 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id BB0C3160AD3 for ; Wed, 12 Oct 2016 16:34:24 +0200 (CEST) Received: (qmail 43643 invoked by uid 500); 12 Oct 2016 14:34:24 -0000 Mailing-List: contact issues-help@carbondata.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@carbondata.incubator.apache.org Delivered-To: mailing list issues@carbondata.incubator.apache.org Received: (qmail 43634 invoked by uid 99); 12 Oct 2016 14:34:24 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Oct 2016 14:34:24 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 7662E1A00A2 for ; Wed, 12 Oct 2016 14:34:23 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -7.019 X-Spam-Level: X-Spam-Status: No, score=-7.019 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-2.999] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id QHozcthqL04s for ; Wed, 12 Oct 2016 14:34:22 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with SMTP id 526FD5FB09 for ; Wed, 12 Oct 2016 14:34:21 +0000 (UTC) Received: (qmail 43595 invoked by uid 99); 12 Oct 2016 14:34:20 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Oct 2016 14:34:20 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 6EA3D2C0059 for ; Wed, 12 Oct 2016 14:34:20 +0000 (UTC) Date: Wed, 12 Oct 2016 14:34:20 +0000 (UTC) From: "ASF GitHub Bot (JIRA)" To: issues@carbondata.incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CARBONDATA-297) 2. Add interfaces for data loading. MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 12 Oct 2016 14:34:25 -0000 [ https://issues.apache.org/jira/browse/CARBONDATA-297?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15568888#comment-15568888 ] ASF GitHub Bot commented on CARBONDATA-297: ------------------------------------------- Github user jackylk commented on a diff in the pull request: https://github.com/apache/incubator-carbondata/pull/229#discussion_r83018479 --- Diff: processing/src/main/java/org/apache/carbondata/processing/newflow/DataLoadProcessorStep.java --- @@ -0,0 +1,40 @@ +package org.apache.carbondata.processing.newflow; + +import java.util.Iterator; + +import org.apache.carbondata.processing.newflow.exception.CarbonDataLoadingException; + +/** + * This base interface for data loading. It can do transformation jobs as per the implementation. + * + */ +public interface DataLoadProcessorStep { + + /** + * The output meta for this step. The data returns from this step is as per this meta. + * @return + */ + DataField[] getOutput(); + + /** + * Intialization process for this step. + * @param configuration + * @param child + * @throws CarbonDataLoadingException + */ + void intialize(CarbonDataLoadConfiguration configuration, DataLoadProcessorStep child) throws + CarbonDataLoadingException; + + /** + * Tranform the data as per the implemetation. + * @return Iterator of data + * @throws CarbonDataLoadingException + */ + Iterator execute() throws CarbonDataLoadingException; --- End diff -- I think `execute()` is called for every parallel unit of the input, right? For example, when using spark to load from dataframe, `execute()` is called for every spark partition (execute one task for one partition). When loading from CSV HDFS file, `execute()` is called for every HDFS block. So I do not think returning array of iterator is required. The loading process of carbon in every executor, some of the step can be parallelized, but sort step need to be synchronized (potential bottle net), since we need datanode-scope sorting. Am I correct? > 2. Add interfaces for data loading. > ----------------------------------- > > Key: CARBONDATA-297 > URL: https://issues.apache.org/jira/browse/CARBONDATA-297 > Project: CarbonData > Issue Type: Sub-task > Reporter: Ravindra Pesala > Assignee: Ravindra Pesala > Fix For: 0.2.0-incubating > > > Add the major interface classes for data loading so that the following jiras can use this interfaces to implement it. -- This message was sent by Atlassian JIRA (v6.3.4#6332)