All Products
Search
Document Center

EventBridge:Route events to Simple Log Service

Last Updated:May 09, 2024

This topic describes how to configure Simple Log Service as the sink of an event stream in the EventBridge console.

Prerequisites

Create an event stream

  1. Log on to the EventBridge console. In the left-side navigation pane, click Event Streams.

  2. In the top navigation bar, select a region and click Create Event Stream.

  3. On the Create Event Stream page, configure the Task Name and Description parameters and follow the on-screen instructions to configure other parameters. Then, click Save. The following section describes the parameters:

    • Task Creation

      1. In the Source, Filtering, and Transformation steps, specify the event source, filtering method, and transformation rule. Then, click Next Step. For information about the configurations of event transformation, see Use Function Compute to perform message cleansing.

      2. In the Sink step, set the Service Type parameter to Simple Log Service and configure the parameters. The following table describes the parameters.

        Parameter

        Description

        Example

        Project

        Select the Simple Log Service project that you created.

        test-project

        Logstore

        Select the Simple Log Service Logstore that you created.

        test-logstore

        Topic

        Specify the name of the Simple Log Service topic.

        test-topic

        Content

        Select the log content that you want to route to Simple Log Service. For more information, see Event transformation.

        Complete Event

        Role

        Specify the role that EventBridge can assume to read logs in Simple Log Service. For information about the permission policy of the role, see Route events to Log Service.

        testRole

    • Task Property

      Configure the retry policy and dead-letter queue for the event stream. For more information, see Retry policies and dead-letter queues.

  4. Go back to the Event Streams page and find the event stream that you created. Then, click Enable in the Actions column.

    Enabling an event stream requires 30 to 60 seconds to complete. You can view the progress in the Status column of the event stream on the Event Streams page.

Verify the result

  1. Log on to the Simple Log Service console.

  2. In the Projects section, click the project that you want to manage.

  3. On the Logstores page, click the Logstore that you want to manage.

  4. Click Search & Analyze to view the query result.

    sls