Server side encryption migrations should not be reported as an object… - #6292
SylvainSenechal wants to merge 2 commits into
Conversation
Hello sylvainsenechal,My role is to assist you with the merge of this Available options
Available commands
Status report is not available. |
Codecov Report❌ Patch coverage is
Additional details and impacted files
@@ Coverage Diff @@
## development/9.5 #6292 +/- ##
================================================
Coverage 86.54% 86.55%
================================================
Files 213 213
Lines 14615 14614 -1
================================================
Hits 12649 12649
+ Misses 1966 1965 -1
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
bdebe28 to
9814e36
Compare
Waiting for approvalThe following approvals are needed before I can proceed with the merge:
|
| // oplog driven logic (CRR, bucket notifications). | ||
| // eslint-disable-next-line no-param-reassign | ||
| objMD.originOp = 's3:ObjectCreated:Copy'; | ||
| // Copy should be tested for 9.5 in INTGR-1038 |
There was a problem hiding this comment.
@BourgoisMickael On this old ticket : https://scality.atlassian.net/browse/INTGR-1038
you wrote a comment "It will trigger new bucket notification, but it will not trigger a replication for CRR"
With this change, it will not trigger bucket notif anymore. But I think you have integration tests that may expect it, so I'm letting you know you may have to update your tests
There was a problem hiding this comment.
I did that to follow the AWS way of updating the encryption: you do a copy of the object on itself while changing the encryption in metadata.
This is an internal operation but follows the way a user would do.
I can't find that actionUpdateObjectEncryption in the bucket notification documentation.
|
Adding Maha as you kinda created the ticket from the discussion on the bb pr, and Mickael which may be affected on the Ring tests |
Issue: CLDSRV-990
Taking a look at the ticket :
We have this updateObjectEncryption function setting
objMD.originOp = 's3:ObjectCreated:Copy';
all the time which is indeed problematic as it sends bucket notifications (although this is debatable, sending a notif is not exactly a P0..), and also can trigger transition (which is more problematic and the reason why this ticket was created scality/backbeat#2830 (comment))
But, upon looking, the function is called from 5 paths :
objectPut
objectCopy
initMpu
objectGet
objectHead
The first 3 are writes, which calls updateEncryption with a flag, so that the originOp rewrite path is not even exercised at all (because these 3 writes will have their own logic to set origin op)
Only the 2 reads get/head can make a call that would wrongly set originOp to copy. But even then, this only happens in the even of a sse migration.
So I'm making a change on the originOp to use something that will not trigger bucket notif/transition
2 remarks :