Skip to content

Elastic Input

Before you start...

Before using...

The show node prints useful information on whatever data it receives. In particular if it receives datasets, it will print out a quick view of datasets columns and the associated schema. You can control the output format, regular spark-like dataset dumps, i.e.:

+---+-------+
| id|clicked|
+---+-------+
|  4|    1.6|
|  8|    3.9|
+---+-------+

root
|-- id: integer (nullable = false)
|-- clicked: double (nullable = false)

Pyspark ->

Spark ->

Examples

Use-cases

Our "hello world" punchline configuration.

beginner_use_case.punchline

{
  type: punchline
  version: "6.0"
  runtime: spark
  tenant: default
  dag: [
    {
        type: show
        component: show
        settings: {
            // optional title
            title: INPUT

            // Optional you can select some specific columns 
            // of your input dataset
            // select: [ "features", "label" ]

            // Optional. Default if false
            json_format: false

            // Optional, default is true. Only relevant for json
            // output format. 
            pretty: true

            // Optional, set to false to not truncate long row values
            truncate: true

            // Optional set to true, prints out rows vertically
            vertical: false

            // Optional, default is 10
            num_rows: 10

            // Optional, also show the schema
            show_schema: true
        }
        subscribe: [
            {
                component: input
                stream: data
            }
        ]
    }
  ]
}

let's excute it with the command below:

CONF=intermediate_use_case.punchline
punchlinectl start -p $CONF

Comming soon

Comming soon

Parameters

Common Settings

Name Type mandatory Default value Description
json_format Boolean false false Output dataset as json
pretty Boolean false false use this when json_format is set to true
truncate Boolean false false trucante column size if values are too big
vertical Boolean false false Output dataset in vertical
num_rows Integer false 3 limit the number of rows to display
show_schema Boolean false true prints to stdout the dataset schema

Advanced Settings

No advanced settings