Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 43 additions & 15 deletions src/data/navigation/sections/events.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,55 @@ module.exports = [
path: "/events/index.md"
},
{
title: "Tutorial",
title: "Tutorials",
path: "/events/tutorial/index.md",
pages: [
{
title: "Use events and App Builder to extend Adobe Commerce",
title: "Eventing",
path: "/events/tutorial/index.md",
},
{
title: "Project setup and deployment",
path: "/events/tutorial/deployment.md"
},
{
title: "Set up event providers",
path: "/events/tutorial/event-providers.md"
pages: [
{
title: "Use events and App Builder to extend Adobe Commerce",
path: "/events/tutorial/index.md"
},
{
title: "Project setup and deployment",
path: "/events/tutorial/deployment.md"
},
{
title: "Set up event providers",
path: "/events/tutorial/event-providers.md"
},
{
title: "Debugging and development tips",
path: "/events/tutorial/debugging.md"
}
]
},
{
title: "Debugging and development tips",
path: "/events/tutorial/debugging.md"
}
]
},
title: "Journaling",
path: "/events/journaling-tutorial/index.md",
pages: [
{
title: "Integrate with Adobe I/O Events Journaling API",
path: "/events/journaling-tutorial/index.md"
},
{
title: "Register and validate your journaling integration",
path: "/events/journaling-tutorial/registration-journaling-events.md"
},
{
title: "Code development and deployment",
path: "/events/journaling-tutorial/runtime-action-code-journaling-api.md"
},
{
title: "Validate journaling events processing",
path: "/events/journaling-tutorial/validating-journaling-integration.md"
}
]
}
]
},
{
title: "Create an App Builder project",
path: "/events/project-setup.md",
Expand Down
35 changes: 35 additions & 0 deletions src/pages/events/journaling-tutorial/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
---
title: Integrate events with Adobe I/O Events Journaling API
description: Learn how to configure and build event-driven integrations between Adobe Commerce and Adobe App Builder using Journaling API.
edition: saas
keywords:
- Extensibility
- Events
---

# Integrate Adobe Commerce events with App Builder using Adobe I/O Events Journaling API

When integrating Adobe I/O Events with App Builder, developers often configure event registrations to directly invoke a _runtime action_. While this approach works for lightweight use cases, it has an important limitation: runtime actions must complete within **60 seconds**. If the action does not return a response within this time, Adobe I/O Runtime will terminate it. This makes direct event-to-runtime invocation unsuitable for **long-running** or **blocking** operations.

To address this, Adobe IO Events provides event journaling as an alternative. Journaling captures incoming events and stores them for up to seven days, allowing developers to:

- Fetch events asynchronously.
- Process them in bulk at their own pace.
- Avoid runtime execution timeouts.

## How it works

Adobe I/O Events Journaling provides a reliable way to consume events asynchronously without requiring direct delivery to a webhook or runtime action. Journaling stores events temporarily in a dedicated endpoint, allowing applications to pull events at their own pace. This approach supports batch processing, error recovery, and ensures that events are not lost when a consumer is temporarily unavailable. [Adobe I/O Events Journaling Guide](https://developer.adobe.com/events/docs/guides/journaling-intro) provides an overview of journaling concepts and benefits.

Consider a use case where a product is deleted from the Adobe Commerce catalog. At that point, an event is emitted asynchronously and sent to Adobe I/O Events. An event provider must first be created. The provider defines the supported event types, such as product deletions or inventory changes, and ensures proper routing. The Adobe I/O Events for Adobe Commerce module enables Adobe Commerce to subscribe to this provider.

When a product deletion event is emitted, Adobe I/O Events stores it in a journaling endpoint. The endpoint holds events for a period of seven days. making them available for consumption. Consumers gain access to the journal URL during event registration.

In this integration, an events registration is created with the provider, which returns a journal URL. The App Builder application is then configured with this journal URL so that a runtime action can use the Events SDK to poll and retrieve events from the journal. A runtime action then uses the Events SDK to poll the journal. During each execution, the action:

- Retrieves the last saved position (cursor) from state storage using `aio-lib-state`.
- Calls the journaling API to fetch all new events since that position.
- Processes and logs event payloads, such as product identifiers and metadata related to the deletion.
- Updates the stored position so the next execution continues from the correct point in the journal.

For more details on journaling behavior, see the [Adobe I/O Events Journaling FAQ](https://developer.adobe.com/events/docs/support/faq#journaling-faq).
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
title: Register your integration with the Journaling API
description: Learn how to register Adobe Commerce events for journaling and validate that the integration is functioning correctly.
edition: saas
keywords:
- Extensibility
- Events
---

# Register and validate your integration with the Journaling API

This topic guides you through registering Adobe Commerce events for journaling and validating that the integration is functioning correctly.

## Prerequisite setup

Before configuring journaling, ensure that you've completed the standard setup for Adobe Commerce Events and App Builder.

- To create and configure an Event Provider in Adobe Commerce, follow the steps outlined in [Setting up Event Provider in Adobe Commerce](../tutorial/event-providers.md#set-up-event-providers/) up to the section "Sync event metadata with App Builder.

- To set up your App Builder project, follow the steps in [Set up the Adobe Developer Console and App Builder project locally](../tutorial/deployment.md#set-up-the-adobe-developer-console-and-app-builder-project-locally) up to the section "Set up your local App Builder environment using the CLI".

## Register Commerce Events in Adobe Developer Console for Journaling

Define which Commerce events to subscribe to and register them within the Adobe Developer Console project. Return to the project workspace in the Developer Console, open the **Add Service** menu, and select **Event**. On the Add Events page, choose **Commerce Events** and select **Next**.

**Insert Image**

In the Configure Event Registration step, select the event provider created earlier in Adobe Commerce. Select **Next** and review the events available from the provider. For journaling, do not choose any specific delivery method or runtime action. The Journaling API renders by default for the integration.

**Insert Image**

On the final screen, update the **Event Registration Name** and **Description** fields. Save the configuration. After saving, the journaling endpoint (journal URL) generates automatically and becomes available for the App Builder application to poll events at its own pace.

## Validate your integration

Validate that events from Adobe Commerce reach the journaling endpoint.

1. In Adobe Commerce, delete a product from the catalog.

1. Open the Adobe Developer Console and navigate to the event browser in the project workspace.

1. Confirm that the product deletion event appears in the event browser.

1. Click the **Go to Start** button. The event browser provides a visual preview of events and includes basic metadata such as event ID, timestamp, and provider.
Loading