org.apache.spark.sql.execution.streaming.sources
RatePerMicroBatchProvider
Companion object RatePerMicroBatchProvider
class RatePerMicroBatchProvider extends SimpleTableProvider with DataSourceRegister
A source that generates increment long values with timestamps. Each generated row has two columns: a timestamp column for the generated time and an auto increment long column starting with 0L.
This source supports the following options:
rowsPerMicroBatch(e.g. 100): How many rows should be generated per micro-batch.numPartitions(e.g. 10, default: Spark's default parallelism): The partition number for the generated rows.startTimestamp(e.g. 1000, default: 0): starting value of generated timeadvanceMillisPerMicroBatch(e.g. 1000, default: 1000): the amount of time being advanced in generated time on each micro-batch.
Unlike rate data source, this data source provides a consistent set of input rows per
micro-batch regardless of query execution (configuration of trigger, query being lagging, etc.),
say, batch 0 will produce 0~999 and batch 1 will produce 1000~1999, and so on. Same applies to
the generated time.
As the name represents, this data source only supports micro-batch read.
- Alphabetic
- By Inheritance
- RatePerMicroBatchProvider
- DataSourceRegister
- SimpleTableProvider
- TableProvider
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
- new RatePerMicroBatchProvider()
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
getTable(options: CaseInsensitiveStringMap): Table
- Definition Classes
- RatePerMicroBatchProvider → SimpleTableProvider
-
def
getTable(schema: StructType, partitioning: Array[Transform], properties: Map[String, String]): Table
- Definition Classes
- SimpleTableProvider → TableProvider
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
inferPartitioning(arg0: CaseInsensitiveStringMap): Array[Transform]
- Definition Classes
- TableProvider
-
def
inferSchema(options: CaseInsensitiveStringMap): StructType
- Definition Classes
- SimpleTableProvider → TableProvider
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
shortName(): String
The string that represents the format that this data source provider uses.
The string that represents the format that this data source provider uses. This is overridden by children to provide a nice alias for the data source. For example:
override def shortName(): String = "parquet"
- Definition Classes
- RatePerMicroBatchProvider → DataSourceRegister
- Since
1.5.0
-
def
supportsExternalMetadata(): Boolean
- Definition Classes
- TableProvider
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()