Skip to content

[Prism] Drain behavior  #30250

@damondouglas

Description

@damondouglas

What needs to happen?

Under #29669

The following uses an example driven approach via gherkin syntax to describe drain behavior.

Scenario: pipeline reads from Pub/Sub

Given pipeline reads from Pub/Sub subscription
  And more messages remain in the subscription
 When I trigger a drain
 Then no more mesages are read from the Pub/Sub subscription
  And the pipeline processes remaining messages read before the drain was triggered

Scenario: pipeline reads from file system

Given pipeline reads from a filesystem
  And more files are yet to be read by the pipeline
 When I trigger a drain
 Then the remaining files are read by the pipeline

Scenario: pipeline reads from Pub/Sub and reads from file system into a side input

Given pipeline reads from Pub/Sub subscription
  And more messages remain in the subscription
 When I trigger a drain
 Then no more mesages are read from the Pub/Sub subscription
  And the remaining files are read by the pipeline into the side input
  And the pipeline processes remaining messages read before the drain was triggered

Scenario: pipeline writes to Pub/Sub topic

Given pipeline writes to Pub/Sub topic
 When I trigger a drain
 Then the pipeline continues writing to the topic until it proceses all remaining in-flight elements in the pipeline

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions