Versions Compared

Key

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

...

Limitations and Known Issues

None.

Snap Views

Type

Format

Number of Views

Examples of Upstream and Downstream Snaps

Description

Input 

Binary 

  • Min: 1

  • Max: 1

  • File Reader

  • Multi File Reader

  • Hdfs Reader

  • CSV Formatter

  • JSON Formatter

Any Snap with a binary output view.

Output

Document

 

  • Min: 1

  • Max: 1

  • Mapper

  • Any Snap with a document input view, typically a Snap which expects a binary data as a value of the "content" key in the input document data.

  • The output view provides the binary data as a byte array value to the "content" key in the output document data. If the input binary data contains header information, the meta data in the header will be present as a value to the key "original" in the output document data. For example, connect a Salesforce Create Snap as a downstream Snap to upload an attachment to an SObject record.

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.

...

Field Name

Field Type

Description

Label*

Default ValueBinary to Document
ExampleBinary_to_Document

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.

Encode or Decode*

Default value: ENCODE_BASE64
Example: BYTE_ARRAY 

Dropdown list

Select if the content should be encoded or decooded. The options are:

  • ENCODE_BASE64 - allows you to encode the content.

  • DECODE_BASE64 - allows you to decode the content.

Info

If the input "content" data has already been Base64-encoded and ENCODE_BASE64 is selected, the Snap does not encode the content again. In the same way, if the input "content" data has not been Base64-encoded and DECODE_BASE64 is selected, the Snap does not attempt to decode the content. 

  • DOCUMENT - allows you to serialize the document into a SnapLogic-specific JSON represenation, which allows you to deserialize types such as Dates when read back using a BinaryToDocument Snap

  • BYTE_ARRAY - allows you to pass raw binary data.  For example, a compressed .zip file can be created in many formats.  The safest way to convert such a file between binary and document is with BYTE_ARRAY.

  • NONE - allows you to use the Snaplex's default platform specific encoding. You can use thisfor string text such as a .xml or a .csv format.  Because this uses platform specific encoding, it can vary between Snaplexes; therefore it is not advised to use NONE when passing data between pipelines that may be running in Snaplexes which run different operating systems.

Info
  • This Snap can receive multiple binary streams. If you select BYTE_ARRAY in the Encode or Decode drop-down list, then the maximum limit for each input binary stream is 2GB. This limit is much lower for other options.

  • Depending on the input data, the encoded/decoded data can become larger than 2GB, even if the input data is smaller than 2GB.

Ignore empty stream

Default value: Deselected
Example: Selected

Checkbox

Select this checkbox to specify enable the Snap to do nothing ignore the incoming data stream when no document has been is received in the input view. If not selected,
Deselect this checkbox to enable the Snap writes to write empty binary data with a header in the output view when no document has been is received in the input view.

Snap Execution

Default ValueValidate & Execute
Example: Disabled

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.

...