Skip to content

Reset Adapter

You can reset an adapter in Flowcore using the Flowcore CLI to run from a set moment in time.

Reset Adapter

To reset an adapter, you can use the flowcore reset adapter command. This command will reset the specified adapter, to a specified moment in time. You can think of it as a rewind button for your adapter, allowing you to rewind to a specific point in time, and replay all the events that have occurred since then.

Terminal window
flowcore reset adapter adapter-name-or-id -s scenario-name -t tenant-name -b bucket-name -e event-id

If you wish to use the adapter id, you can read about how to obtain your adapter id here.

Flags

argumentabbreviationrequireddescription
--scenario-sYesThe scenario the adapter resides in. You can obtain all your scenarios within a tenant here.
--tenant-tYesTenant. e.g my-tenant. Meaning, the name of your organization. Which you can find by visiting flowcore.io
--bucket-bNoTime bucket (YYYYMMDDHHmmss, first, or last). This correlates to Year (YYYY), Month (MM), Day (DD), Hour (HH), Minute (mm), Second (ss). Use first for earliest available data, last for most recent data.
--eventId-eNoTime UUID. This is the UUID of the event you wish to reset to.

Examples

To reset an adapter with a specific tenant and scenario:

Terminal window
flowcore reset adapter adapter-name -t tenant-name -s scenario-name -b 20240718110000

To reset an adapter using the first time bucket:

Terminal window
flowcore reset adapter adapter-name -t tenant-name -s scenario-name -b first

To reset an adapter using the last time bucket:

Terminal window
flowcore reset adapter adapter-name -t tenant-name -s scenario-name -b last

To reset an adapter using a specific event ID:

Terminal window
flowcore reset adapter adapter-name -t tenant-name -s scenario-name -e 9cb35da2-ba64-4bb5-86d6-ef20ebc62ab7

Time Bucket Options

The --bucket parameter offers three different reset strategies:

first

  • Resets the adapter to the earliest available time bucket
  • Useful when you want to replay all historical data from the beginning
  • The adapter will process all events chronologically from the start

last

  • Resets the adapter to the most recent time bucket
  • Automatically discovers and uses the latest available time bucket across all relevant event types
  • Ideal for resuming processing from the most current data point
  • Eliminates the need to manually lookup the latest time bucket

Specific Time Bucket (YYYYMMDDHHmmss)

  • Resets to an exact point in time using the format: Year-Month-Day-Hour-Minute-Second
  • Provides precise control over the reset point
  • Example: 20240718110000 = July 18, 2024 at 11:00:00

When to Use Each Option

OptionUse CaseExample Scenario
firstComplete data reprocessingFixing a bug that affected all historical data
lastResume from latest dataRecovering from a temporary outage or deployment
Specific timeTargeted replayReprocessing data from when a specific issue occurred