From reviews-return-1577-archive-asf-public=cust-asf.ponee.io@iotdb.apache.org Tue May 7 08:55:35 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id B2D3718064C for ; Tue, 7 May 2019 10:55:34 +0200 (CEST) Received: (qmail 98762 invoked by uid 500); 7 May 2019 08:55:34 -0000 Mailing-List: contact reviews-help@iotdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: reviews@iotdb.apache.org Delivered-To: mailing list reviews@iotdb.apache.org Received: (qmail 98750 invoked by uid 99); 7 May 2019 08:55:34 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 May 2019 08:55:34 +0000 From: GitBox To: reviews@iotdb.apache.org Subject: [GitHub] [incubator-iotdb] fanhualta commented on a change in pull request #152: Cluster read Message-ID: <155721932902.15828.14908011488692317851.gitbox@gitbox.apache.org> Date: Tue, 07 May 2019 08:55:29 -0000 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit fanhualta commented on a change in pull request #152: Cluster read URL: https://github.com/apache/incubator-iotdb/pull/152#discussion_r281533733 ########## File path: cluster/src/main/java/org/apache/iotdb/cluster/query/reader/querynode/ClusterBatchReaderByTimestamp.java ########## @@ -0,0 +1,86 @@ +/** + * 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.iotdb.cluster.query.reader.querynode; + +import java.io.IOException; +import java.util.List; +import org.apache.iotdb.db.query.reader.merge.EngineReaderByTimeStamp; +import org.apache.iotdb.tsfile.file.metadata.enums.TSDataType; +import org.apache.iotdb.tsfile.read.common.BatchData; + +/** + * BatchReader by timestamp for cluster which is used in query node. + */ +public class ClusterBatchReaderByTimestamp extends IClusterBatchReader { + + /** + * Reader + */ + private EngineReaderByTimeStamp readerByTimeStamp; + + /** + * Data type + */ + private TSDataType dataType; + + public ClusterBatchReaderByTimestamp( + EngineReaderByTimeStamp readerByTimeStamp, + TSDataType dataType) { + this.readerByTimeStamp = readerByTimeStamp; + this.dataType = dataType; + } + + @Override + public boolean hasNext() throws IOException { + return readerByTimeStamp.hasNext(); + } + + @Override + public BatchData nextBatch() throws IOException { + throw new IOException( + "nextBatch() in ClusterBatchReaderByTimestamp is an empty method."); + } + + + @Override + public void close() throws IOException { Review comment: The same reason as above. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: users@infra.apache.org With regards, Apache Git Services