Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Snap type:

...

Format

...

Description:

...

This Snap serializes incoming SnapLogic document objects into Avro-formatted data.

  • Expected upstream SnapsA Mapper Snap must be used in front of this Snap to map the fields present in .avsc schema file.
  • Expected downstream SnapsAny binary output processing Snap can be used downstream.
  • Expected input: The input for this Snap must be created through the upstream Mapper Snap.
  • Expected outputThe output of this Snap should be a serialized binary stream that contains data and its schema.

...

[None]

...

Accounts are not used with this Snap.

...

This Snap has exactly one document input view.

...

In this article

Table of Contents
maxLevel2
excludeOlder Versions|Additional Resources|Related Links|Related Information

Overview

You can use this Snap to serialize the incoming SnapLogic document objects into Avro-formatted data.

...

Snap Type

Avro Formatter Snap is a FORMAT-type Snap that formats data to Avro-formatted data.

Prerequisites

None.

Support for Ultra Pipelines

Does not support Ultra Pipelines

Limitations and Known Issues

None.

Snap Views

Type

Format

Number of Views

Examples of Upstream and Downstream Snaps

Description

Input 

Document

  • Min: 1

  • Max: 1

  • Mapper

This Snap exposes the avsc schema in its input view. You must use

...

a Mapper Snap in front of this Snap to map the fields present in

...

.

...

avsc schema file.

Output

...

Settings

Label

...

Document

  • Min: 1

  • Max: 1

  • Binary

Any serialized binary stream output processing Snap that contains data and its schema.

Error

Error handling is a generic way to handle errors without losing data or failing the Snap execution. You can handle the errors that the Snap might encounter while running the Pipeline by choosing one of the following options from the When errors occur list under the Views tab. The available options are:

  • Stop Pipeline Execution: Stops the current Pipeline execution when the Snap encounters an error.

  • Discard Error Data and Continue: Ignores the error, discards that record, and continues with the rest of the records.

  • Route Error Data to Error View: Routes the error data to an error view without stopping the Snap execution.

Learn more about Error handling in Pipelines.

Snap Settings

Info
  • Asterisk (*): Indicates a mandatory field.

  • Suggestion icon ((blue star)): Indicates a list that is dynamically populated based on the configuration.

  • Expression icon ((blue star)): Indicates whether the value is an expression (if enabled) or a static value (if disabled). Learn more about Using Expressions in SnapLogic.

  • Add icon ((blue star) ): Indicates that you can add fields in the field set.

  • Remove icon ((blue star)): Indicates that you can remove fields from the field set.

Field Name

Type

Description

Label*

Default ValueAvro Formatter
ExampleAvro_Formatter

String

Specify the name for the Snap. You can modify this to be more specific, especially if you have more than one of the same Snap in your

...

Pipeline.

Schema

...

File*

Default Value[None]
Examplesldb:///foo/bar/schema.avsc

String/Expression

Specify the path to the schema file in .avsc format

Ignore empty stream

Default value

...

Multiexcerpt include macro
nameSnap Execution
pageAnaplan Read

...

Multiexcerpt include macro
nameSnap_Execution_Introduced
pageAnaplan Read

...

: Deselected
ExampleSelected

Checkbox

Select the checkbox to specify an action that the Snap must take if the input view contains empty documents. If selected, the Snap does not write anything to the output if no documents are received in the input. Else, the Snap writes an empty array in the output view if no documents are received in the input view. 

Default value: Not selected

Snap Execution

Default value: Validate & Execute
ExampleDisabled

Dropdown list

Select one of the three modes in which the Snap executes. Available options are:

  • Validate & Execute: Performs limited execution of the Snap, and generates a data preview during Pipeline validation. Subsequently, performs full execution of the Snap (unlimited records) during Pipeline runtime.

  • Execute only: Performs full execution of the Snap during Pipeline execution without generating preview data.

  • Disabled: Disables the Snap and all Snaps that are downstream from it.

Examples

Transforming CSV data to Avro format

This example pipeline demonstrates how to convert CSV data to Avro format as per the specified schema and transform it to generate reports or update a database. The output is the transformed and formatted data ready for further processing.

...

Download this pipeline.

  1. Configure the File Reader Snap to read the leads.csv file. On validation, the Snap displays the data in binary format.

Image Added

Image Added

2. Configure the CSV Parser Snap to parse the binary input of the leads.csv file. On validation, the Snap displays the structured data.

Image Added

Image Added

3. Configure the Avro Formatter Snap to convert the CSV data to Avro format as per the defined Schema file. On validation, the Snap displays the Avro-formatted data.

Image AddedImage Added

4. Configure the Avro Parser Snap to parse the Avro-formatted data. On validation, the Snap displays the deserialized data.

Image Added

Image Added

5. Configure the Mapper Snap to extract the data. On validation, the Snap displays the output based on the specified mappings.

Image Added

Image Added

Downloads

Attachments
patterns*.slp, *.zip
sortByname

Snap Pack History