Hortonworks Docs
»
DataFlow 3.3.0
»
Building a SAM Application
Building a SAM Application
Also available as:
Building an Application
Launch the Stream Builder UI
Add a New Stream Application
Add a Source
Connect Components
Join Multiple Streams
Filter Events in a Stream
Use Aggregate Functions over Windows
Deploying a Stream App
Configure Deployment Settings
Deploy the App
Building an Application
Prerequisites
You have integrated SAM
You have set up appropriate environments and service pools
Launch the Stream Builder UI
Add a New Stream Application
Add a Source
As described in the
HDF Overview
, Stream Builder offers four types of builder components: sources, processors, sinks, and custom components. Start building your application by adding a source.
Connect Components
Once you have added and configured your source, add additional processors and sinks to the canvas. To pass a stream of events from one component to the next, create a connection between the two components. In addition to defining data flow, connections allow you to pass a schema from one component to another.
Join Multiple Streams
Joining multiple streams is an important SAM capability. You accomplish this by adding the
Join
processor to your stream application.
Filter Events in a Stream
You can use SAM to filter events in the stream. You accomplish this by using
Rule
processor, which translates rules into SQL queries that operate on the stream of data.
Use Aggregate Functions over Windows
Windowing is the ability to split an unbounded stream of data into finite sets based on specified criteria such as time or count, so that you can perform aggregate functions (such as sum or average) on the bounded set of events. In SAM, you accomplish this using the
Aggregate
processor. The
Aggregate
processor supports two window types, tumbling and sliding windows. You can create a window based on time or count.
Deploying a Stream App
© 2012–2019, Hortonworks, Inc.
Document licensed under the
Creative Commons Attribution ShareAlike 4.0 License
.
Hortonworks.com
|
Documentation
|
Support
|
Community