PlatformManage

Function Pausing

Inngest allows you to pause a function indefinitely. This is a powerful feature that can be useful, for example, if you are planning a maintenance window or if a user reports a bug and you want to stop processing events until you've fixed it.

When a function is paused

It's important to understand what happens when a function is paused.

No data will be lost. Inngest will continue receiving and storing your events, but the events will not trigger the paused function. The function will be marked as "skipped" on the event's page in Inngest Cloud.

You can resume the function at any time. No deployment or sync is required to resume your function. After you resume the function, new events will trigger it as usual.

Events received while the function was paused will not be reprocessed automatically after you resume the function. Use Replay to process events that were received while the function was paused.

Paused functions do not count toward your plan's concurrency limit. Note that events received while a function is paused are still subject to your plan's history limit.

How to pause a function

Navigate to the function's page in Inngest Cloud, and click the Pause button near the top right corner:

Pause button in Inngest Cloud.

Handling running invocations

When you pause a function, no new events will trigger it. You can choose what to do with any currently-running invocations of the function:

  • "Pause immediately, then cancel after 7 days:" No further steps will be executed while the function is paused. If you resume the function within 7 days, these invocations will continue with the next step. Otherwise, they will be canceled. (This is the default behavior.)
  • "Cancel immediately:" All currently-running invocations of the function will be canceled. They will not continue running or restart when you resume the function.

In both cases, all running invocations will complete their current step before being paused or canceled. Inngest cannot interrupt your function mid-step.

Options for handling running invocations when pausing a function.

Resuming a function

To resume a paused function, navigate to the function's page in Inngest Cloud, and click the Resume button near the top right corner:

Resume button in Inngest Cloud.

The function will immediately begin processing events received after you resume it.

Replaying skipped events

After resuming a paused function, you may wish to replay the runs for that function that would otherwise have run while it was paused. To do so:

  1. Navigate to the function's Replay tab.
  2. Click the New Replay button to create a new replay.
  3. Select an appropriate date window and enable the "Skipped" status.
  4. If you wish to replay runs that were canceled when you paused the function, select the "Canceled" status as well.

You'll see a preview of the number of runs to be replayed:

Creating a replay for skipped function runs.

Remember that your plan's history limit still applies to events received while a function is paused. This means that if, for example, you're using Inngest's free plan, you will only be able to replay events from the last 3 days, regardless of how long your function was paused.

See our Replay guide for more information.