Project

General

Profile

Bug #48369

notification: get/delete of specific notification does not work

Added by Yuval Lifshitz 10 months ago. Updated 6 months ago.

Status:
Fix Under Review
Priority:
Low
Target version:
-
% Done:

0%

Source:
Development
Tags:
notification
Backport:
octopus, nautilus
Regression:
No
Severity:
4 - irritation
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

note that this is an extension to the AWS API, for the next steps to work, follow the instructions here:
https://github.com/ceph/ceph/tree/master/examples/boto3

to reproduce:
(1) start a vstart cluster
(2) create 2 topics:

aws --endpoint-url http://localhost:8000 sns create-topic --name fishtopic --attributes='{"push-endpoint": "amqp://127.0.0.1:5672", "amqp-exchange": "ex1", "amqp-ack-level": "broker"}'

(3) create a bucket:

aws --endpoint-url http://localhost:8000 s3 mb s3://fish

(4) create 2 notifications on that bucket:

aws --region=default --endpoint-url http://localhost:8000 s3api put-bucket-notification-configuration --bucket fish --notification-configuration='{"TopicConfigurations": [{"Id": "creation-notif", "TopicArn": "arn:aws:sns:default::fishtopic", "Events": ["s3:ObjectCreated:*"]}]}'

aws --region=default --endpoint-url http://localhost:8000 s3api put-bucket-notification-configuration --bucket fish --notification-configuration='{"TopicConfigurations": [{"Id": "deletion-notif", "TopicArn": "arn:aws:sns:default::fishtopic", "Events": ["s3:ObjectRemoved:*"]}]}'

(5) try to get a specific notification:

aws --region=default --endpoint-url http://localhost:8000 s3api get-bucket-notification-configuration --bucket fish --notification "creation-notif" 

expected result:

{
    "TopicConfigurations": [
        { 
            "Id": "creation-notif",
            "TopicArn": "arn:aws:sns:default::fishtopic", "Events": ["s3:ObjectCreated:*"]
        }
    ]
}

actual result:

{
    "TopicConfigurations": [
        { 
            "Id": "creation-notif",
            "TopicArn": "arn:aws:sns:default::fishtopic",
            "Events": ["s3:ObjectCreated:*"]
        },
        {
            "Id": "deletion-notif", 
            "TopicArn": "arn:aws:sns:default::fishtopic",
            "Events": ["s3:ObjectRemoved:*"]
        }
    ]
}

(6) try to delete a specific notification:

aws --region=default --endpoint-url http://localhost:8000 s3api delete-bucket-notification-configuration --bucket fish --notification "creation-notif" 

(7) fetch notifications and expect to see only "deletion-notif"
actual results: both notifications are deleted

History

#1 Updated by Yuval Lifshitz 10 months ago

  • Priority changed from Normal to Low
  • Severity changed from 3 - minor to 4 - irritation

this is working and tested: https://github.com/ceph/ceph/blob/master/src/test/rgw/rgw_multi/tests_ps.py#L953

failing only when used via aws CLI. since this is a non-standard extension it may not be possible to make it work, but needs more investigation.
maybe doable via modification to: https://github.com/ceph/ceph/blob/master/examples/boto3/service-2.sdk-extras.json

#2 Updated by Yuval Lifshitz 6 months ago

  • Status changed from New to Fix Under Review
  • Pull request ID set to 39945

Also available in: Atom PDF