https://tracker.ceph.com/https://tracker.ceph.com/favicon.ico2022-03-04T20:30:53ZCeph rgw - Feature #54476: rgw: allow S3 delete-marker behavior to be restored via confighttps://tracker.ceph.com/issues/54476?journal_id=2115072022-03-04T20:30:53ZJ. Eric Ivancichivancich@redhat.com
<ul></ul><p>I thought I'd see if anyone knows why this is S3's behavior and can think of any adverse behavior that would result from not creating a delete-marker on top of another delete-marker.</p> rgw - Feature #54476: rgw: allow S3 delete-marker behavior to be restored via confighttps://tracker.ceph.com/issues/54476?journal_id=2115082022-03-04T20:31:33ZJ. Eric Ivancichivancich@redhat.com
<ul><li><strong>Subject</strong> changed from <i>rgw: optionally diverge from S3's delete-marker behavior</i> to <i>rgw: optionally diverge from S3's "stacked" delete-marker behavior</i></li></ul> rgw - Feature #54476: rgw: allow S3 delete-marker behavior to be restored via confighttps://tracker.ceph.com/issues/54476?journal_id=2115682022-03-07T17:20:39ZCasey Bodleycbodley@redhat.com
<ul><li><strong>Related to</strong> <i><a class="issue tracker-1 status-3 priority-4 priority-default closed" href="/issues/40393">Bug #40393</a>: Lifecycle expiration action generates delete marker continuously</i> added</li></ul> rgw - Feature #54476: rgw: allow S3 delete-marker behavior to be restored via confighttps://tracker.ceph.com/issues/54476?journal_id=2115702022-03-07T17:45:24ZCasey Bodleycbodley@redhat.com
<ul></ul><p>J. Eric Ivancich wrote:</p>
<blockquote>
<p>I thought I'd see if anyone knows why this is S3's behavior and can think of any adverse behavior that would result from not creating a delete-marker on top of another delete-marker.</p>
</blockquote>
<p>i'm not exactly sure. but one consideration is that the s3 delete op returns the version ID of the delete marker it creates, allowing the client to delete that particular delete marker later. in this way, a client can temporarily 'hide' the presence of an object</p>
<p>and given the current design, several clients could coordinate this way, such that the object is only visible if <strong>no</strong> client is currently hiding it. that behavior might be useful in some application</p>
<blockquote>
<p>We're aware that some users of RGW have hundreds of thousands of consecutive delete-markers, likely due to tooling that issues deletes ("just in case"?).</p>
</blockquote>
<p>i was under the impression that these cases were specific to a lifecycle bug, fixed in <a class="external" href="https://tracker.ceph.com/issues/40393">https://tracker.ceph.com/issues/40393</a>. it might be useful to distinguish these two cases (lifecycle expirations vs. s3 deletes) in this discussion</p>
<p>regarding lifecycle, i believe it gives sufficient control over what happens to delete markers through <a class="external" href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_NoncurrentVersionExpiration.html">https://docs.aws.amazon.com/AmazonS3/latest/API/API_NoncurrentVersionExpiration.html</a> and the ExpiredObjectDeleteMarker field of <a class="external" href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_LifecycleExpiration.html">https://docs.aws.amazon.com/AmazonS3/latest/API/API_LifecycleExpiration.html</a></p>
<blockquote>
<p>Secondarily, other than external scripting, should Ceph RGW offer any support for this? `radosgw-admin bucket check --fix...` does clean up bucket indices, but should it handle a situation such as this as well?</p>
</blockquote>
<p>in the case of 'bucket check' tooling, i don't think we can distinguish between the delete markers that were created by that lifecycle bug vs. those created intentionally via s3 deletes</p>
<p>but i think it's much easier to choose a sensible default in this tooling, than it is to change how delete markers work globally. i think it'd be fine for 'bucket check --fix' to remove all but the most recent delete marker</p> rgw - Feature #54476: rgw: allow S3 delete-marker behavior to be restored via confighttps://tracker.ceph.com/issues/54476?journal_id=2136352022-03-29T18:28:06ZSoumya Koduri
<ul></ul><p>I do not see this behaviour in the latest master. I tested using both s3 delete and by setting below lifecycle policy -<br /><LifecycleConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/"><br /><Rule><br /><ID>id1</ID><br /><Prefix>s</Prefix><br /><Status>Enabled</Status><br /><Expiration><br /><Date>2022-01-01</Date><br /></Expiration><br /><ExpiredObjectDeleteMarker>true</ExpiredObjectDeleteMarker><br /></Rule><br /></LifecycleConfiguration></p>
<p>(or)</p>
<p><?xml version="1.0" ?><br /><LifecycleConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/"><br /><Rule><br /><ID>id1</ID><br /><Prefix>s</Prefix><br /><Status>Enabled</Status><br /><Expiration><br /><ExpiredObjectDeleteMarker>true</ExpiredObjectDeleteMarker><br /></Expiration><br /><NoncurrentVersionExpiration><br /><NoncurrentDays>1</NoncurrentDays><br /></NoncurrentVersionExpiration><br /></Rule><br /></LifecycleConfiguration></p>
<p>Probably fixed by bug#40393?</p> rgw - Feature #54476: rgw: allow S3 delete-marker behavior to be restored via confighttps://tracker.ceph.com/issues/54476?journal_id=2139492022-04-01T20:11:18ZJ. Eric Ivancichivancich@redhat.com
<ul><li><strong>Subject</strong> changed from <i>rgw: optionally diverge from S3's "stacked" delete-marker behavior</i> to <i>rgw: allow S3 delete-marker behavior to be restored via config</i></li><li><strong>Backport</strong> changed from <i>yes, tbd</i> to <i>quincy,pacific,octopus</i></li><li><strong>Pull request ID</strong> set to <i>45754</i></li></ul> rgw - Feature #54476: rgw: allow S3 delete-marker behavior to be restored via confighttps://tracker.ceph.com/issues/54476?journal_id=2139502022-04-01T20:13:39ZJ. Eric Ivancichivancich@redhat.com
<ul></ul><p>After reading feedback and discussing with Matt, decided to make this configurable.</p>
<p>Note: commit 69d7589fb1305b7d202ffd126c3c835e7cd0dda3 added the behavior to diverge from S3 documented behavior. This tracker/PR allows config to restore S3 documented behavior.</p> rgw - Feature #54476: rgw: allow S3 delete-marker behavior to be restored via confighttps://tracker.ceph.com/issues/54476?journal_id=2139512022-04-01T20:13:51ZJ. Eric Ivancichivancich@redhat.com
<ul><li><strong>Status</strong> changed from <i>Need More Info</i> to <i>Fix Under Review</i></li></ul> rgw - Feature #54476: rgw: allow S3 delete-marker behavior to be restored via confighttps://tracker.ceph.com/issues/54476?journal_id=2139522022-04-01T20:14:59ZJ. Eric Ivancichivancich@redhat.com
<ul></ul><p>Soumya Koduri wrote:</p>
<blockquote>
<p>I do not see this behaviour in the latest master. I tested using both s3 delete and by setting below lifecycle policy -</p>
</blockquote>
<p>I just tested it using the s3cmd client and it was working, Soumya. I'm not sure why it wouldn't be working under lifecycle.</p>