Configuring Event Notification

You can use Simple Message Notification (SMN) to send alarms and notifications, and trigger workflows.

Procedure

  1. Log in to OBS Console.
  2. In the bucket list, click the target bucket to go to the Summary page.
  3. Click Event.
  4. Click Add, as shown in Figure 1.

    Figure 1 Adding an event
    Table 1 describes the system event parameters.
    Table 1 Parameter description

    Parameter

    Description

    Name

    Name of the event. The event name is self-defined. If the event name is left blank, the system will automatically generate a unique ID as the event name.

    Event

    Event type. OBS supports event notification for the following event types:

    • ObjectCreated: indicates all involved operations when creating an object, including put, post, and copy of objects, as well as the merging of parts.
    • Put: Use the PUT method to upload an object.
    • Post: Use the POST method to upload an object.
    • Copy: Use tools, such as S3curl, to copy an object.
    • ObjectRemoved: indicates the operations of invoking the APIs for deletion and de-multiparting.
    • CompleteMultipartUpload: Merge parts.
    • Delete: Delete an object by version ID.
    • DeleteMarkerCreated: Delete an object not by version ID.

    Multiple event types are applicable to the same object. For example, if you have selected PutCopy, and Delete in the Event check box for the same object, an event will be sent to you when you upload an object to, copy an object to, or delete an object from the bucket where the object resides. ObjectCreated contains PutPostCopy, and CompleteMultipartUpload, If you select ObjectCreated, you cannot select PutPostCopy or CompleteMultipartUpload. Similarly, if you select ObjectRemoved, you cannot select Delete or DeleteMarkerCreated.

    Prefix

    Specifies the prefix of the object to which the event applies.

    Events with overlapping event types cannot apply to an object selected by prefix and suffix at the same time. For example, a Put event and another event containing Put cannot apply to the same object testobject which is selected by its prefix and suffix at the same time.

    Suffix

    Specifies the suffix of the object to which the event applies.

    Events with overlapping event types cannot apply to an object selected by prefix and suffix at the same time. For example, a Put event and another event containing Put cannot apply to the same object testobject which is selected by its prefix and suffix at the same time.

    Topic

    Project: Select the project of the SMN topic.

    Projects are used to manage and classify cloud resources, including SMN topics. Each project corresponds to different SMN topics. Select a project before selecting a topic.

    Topic: specifies the SMN topic that authorizes OBS to publish messages. The SMN topic is created on the SMN page.
    NOTE:

    After SMN topics are configured, do not perform the following operations unless necessary:

    • Delete any topic related to OBS Console events.
    • Cancel the authorization of the topic related to OBS Console events to OBS.

    If the topic related to OBS Console events is deleted, or the authorization of the topic to OBS is canceled, the following conditions may occur:

    1. The subscriber of the topic cannot receive messages.
    2. The configurations of the unavailable topics will be automatically cleared when the event configuration of the bucket is modified.

    The following procedure describes how to quickly get started with SMN:

    1. Create an SMN topic.
    2. Add subscription.
    3. Modify the topic policy. Select OBS under Services that can publish messages on the Modify Topic Policy page.

    For details, see sections "Creating a Topic", "Adding a Subscription to the Topic", and "Configuring a Topic Policy" in the Simple Message Notification User Guide.

  5. Click OK.

Follow-up Procedure

To modify the configuration of an event, click Edit of the event. To delete an event, click Delete of the event.

Registration