Github user gvramana commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2328#discussion_r189778004
  
    --- Diff: 
integration/spark2/src/main/scala/org/apache/spark/sql/execution/command/stream/CarbonCreateStreamSourceCommand.scala
 ---
    @@ -0,0 +1,50 @@
    +/*
    + * 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.spark.sql.execution.command.stream
    +
    +import scala.collection.mutable
    +
    +import org.apache.spark.sql.{Row, SparkSession}
    +import org.apache.spark.sql.execution.command.{Field, MetadataCommand, 
TableNewProcessor}
    +import 
org.apache.spark.sql.execution.command.table.CarbonCreateTableCommand
    +import org.apache.spark.sql.parser.CarbonSpark2SqlParser
    +
    +/**
    + * This command is used to create Stream Source, which is implemented as a 
Carbon Table
    + */
    +case class CarbonCreateStreamSourceCommand(
    +    dbName: Option[String],
    +    tableName: String,
    +    fields: Seq[Field],
    +    tblProperties: Map[String, String]
    +) extends MetadataCommand {
    +  override def processMetadata(sparkSession: SparkSession): Seq[Row] = {
    +    val tableModel = new CarbonSpark2SqlParser().prepareTableModel(
    --- End diff --
    
    1) 'streaming'='source' need not be explicitly passed by user, for this ddl 
can internally always add.
    2) select * on stream src Table should fail.
    3) another ddl required to show stream source tables. As it is tough to 
identify streaming source tables from list of tables.
    4) Stream sink table DDL mentioned in description not required as 
carbondata already supports streaming ingestion.


---

Reply via email to