ZipFile Write

ZipFile Write

In this article

Overview

You can use this Snap to read binary data passed as binary objects from its input view and create a .zip file at a specified file destination.

The archive format is automatically detected by examining the file header.  The supported formats are PKZIP and 7-Zip. 

Snap Type

The ZipFile Write Snap is a Write-type Snap that writes files from archive files.

Prerequisites

IAM Roles for Amazon EC2

The 'IAM_CREDENTIAL_FOR_S3' feature is used to access S3 files from EC2 Groundplex, without Access-key ID and Secret key in the AWS S3 account in the Snap. The IAM credential stored in the EC2 metadata is used to gain access rights to the S3 buckets. To enable this feature, the following line should be added to global.properties, and the jcc (node) restarted: jcc.jvm_options = -DIAM_CREDENTIAL_FOR_S3=TRUE

Please note this feature is supported in the EC2-type Groundplex only.

For more information on IAM Roles, see http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html


Support for Ultra Pipelines

 Does not support Ultra Pipelines

Limitations

This Snap does not create an output file when using the input from SAS Generator Snap configured with only the DELETE SAS permission. This is not the case when the target file exists.

Known Issues

Snap Views

Type

Format

Number of Views

Examples of Upstream and Downstream Snaps

Description

Type

Format

Number of Views

Examples of Upstream and Downstream Snaps

Description

Input 

Binary

 

 

  • Min: 1

  • Max: ∞

  • File Writer

  • Binary Router

  • JSON Parser

  • JSON Formatter

  • Document to Binary

This Snap accepts binary data passed as binary objects. It reads from the source specified in the File property with header information about the binary stream.

Output

Document

 

 

  • Min: 0

  • Max: 1

  • File Writer

  • Binary Router

  • JSON Parser

When the snap successfully writes the zip file, it generates output containing:

  • Status of the write operation

  • File name information

  • File action status (for example, OVERWRITE if Overwrite is selected as File action).

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.

Account

This Snap uses account references created on the Accounts page of SnapLogic Manager to handle access to this endpoint. This Snap supports a Basic auth account, an AWS S3 auth account, SSH Auth account, SMB account, or no account. See Configuring Binary Accounts for information on setting up accounts that work with this Snap.

Account types supported by each protocol are as follows:

Protocol

 Account types

Protocol

 Account types

sldb

no account

s3

AWS S3

ftp

Basic Auth

sftp

Basic Auth, SSH Auth 

ftps

Basic Auth

hdfs

no account

http

no account

https

no account

smb

SMB

wasb

Azure Storage

wasbs

Azure Storage

gs

Google Storage