testStream
Create connection to event stream hosted by MATLAB with schema processing applied
This object requires Streaming Data Framework for MATLAB® Production Server™.
Description
The testStream
function creates a
TestStream
object, which you can use to test reading from and writing to
event streams hosted by MATLAB. TestStream
objects store events in MATLAB variables, which are exported to event streams based on the data type values
specified by the ExportOptions
property. TestStream
applies the standard configurable schema processing when reading and writing timetable data.
Use this object to test your schema management before deployment, without requiring a
streaming service host. The data in a TestStream
object disappears when you
exit MATLAB.
Use TestStream
to develop your streaming analytic function without having
to connect to or consume resources from a streaming service such as Kafka®. TestStream
stores data using MATLAB memory space, so use this object with finite-size data sets. Because the data is
stored in MATLAB, TestStream
objects typically stream data faster than streams
that have data stored on a network or file system.
Creation
Description
ts = testStream
creates an object connected to an event stream
hosted by MATLAB.
ts = testStream(
specifies event
stream options using one or more Name=Value
)Name=Value
arguments.
Name
can also be a property name,
with Value
as the corresponding value. You can specify several
name-value arguments in any order as
Name1
=Value1
,...,NameN
=ValueN
.
Input Arguments
Properties
Object Functions
readtimetable | Read timetable from event stream |
writetimetable | Write timetable to event stream |
seek | Set read position in event stream |
preview | Preview subset of events from event stream |
identifyingName | Event stream name |
detectImportOptions | Create import options based on event stream content |
detectExportOptions | Create export options based on event stream content |
Examples
Version History
Introduced in R2022b