/
Google PubSub Acknowledge

Google PubSub Acknowledge

In this article

Overview

You can use this Snap to acknowledge the messages with ack IDs read by a Pubsub Subscriber used in the upstream Snap. This snap can also be used without the Subscriber Snap bypassing the acknowledgments directly from the input stream. This snap supports acknowledging for a single ack ID or for a batch of ack IDs.

google-pubsub-acknowledge.png

Snap Type

Acknowledge Snap is a Write type Snap.

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 

Document

 

  • Min: 0

  • Max: 1

  • Mapper

  • JSON Generator

  • CSV Parser

Each document contains data in the form of json..

Output

Document

  • Min: 0

  • Max: 1

  • JSON Generator

Each document contains corresponding response in the form of json.

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 when 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 remaining 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

  • Asterisk (*): Indicates a mandatory field.

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

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

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

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

Field Name

Field Type

Description

Field Name

Field Type

Description

Label*

 

Default Value: Google PubSub Acknowledge
Example: Google PubSub Acknowledge

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.

Subscription Name

Default Value: N/A
Example: my-topic-subscription

String/Expression

Specify the subscription name from which the messages are pulled. This property is suggestable and will retrieve available subscription names based on the project ID from the service account.

 

Acknowledgement ID


Default name:
Example: ACK-123abc456def789ghi

String/Expression

Specify the acknowledgment ID to be deleted from the PubSub queue. For a single message, the ack ID can be specified directly in this field.

Batch size

 

Default Value: 1
Example: 5

String/Expression

Specify the maximum time in seconds the Snap will wait for each fetching. A zero wait timeout indicates that fetching will be performed without waiting.

  • For batch messages, the ackIds can be given in JSON and mapped to the Acknowledgement Id.

  • If the batch size is greater than 1 and an acknowledgment in a batch fails, the batch will fail completely. The ackIds belonging to the failed batch will be sent to the error view.

Snap Execution

 

Default Value: Execute only
Example: Validate & Execute

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.

Snap Pack History