Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.

rgw/sfs: init bucket mtime and store it #236

Merged
merged 1 commit into from
Nov 15, 2023

Conversation

jecluis
Copy link
Member

@jecluis jecluis commented Oct 22, 2023

Fixes: aquarist-labs/s3gw-tools#174

Signed-off-by: Joao Eduardo Luis <[email protected]>

@jecluis jecluis added kind/enhancement Change that positively impacts existing code area/rgw-sfs RGW & SFS related labels Oct 22, 2023
@jecluis jecluis requested review from irq0 and 0xavi0 October 22, 2023 16:55
@jecluis jecluis added this to the v0.23.0 milestone Oct 22, 2023
@@ -223,6 +227,9 @@ TEST_F(TestSFSBucket, UserCreateBucketCheckGotFromCreate) {
}

EXPECT_EQ(bucket_from_create->get_acl(), arg_aclp);
EXPECT_TRUE(
bucket_from_create->get_modification_time().time_since_epoch().count() > 0
Copy link
Member

@irq0 irq0 Oct 23, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think real_clock::is_zero(ts) is the canonical way to check that the timestamp is not zero.
Suggest replacing with EXPECT_NE(real_clock::is_zero(bucket_from_create->get_modification_time()))

@jecluis jecluis self-assigned this Nov 13, 2023
@jecluis jecluis force-pushed the wip-sfs-fix-bucket-mtime branch from c1352f0 to fabb8c2 Compare November 14, 2023 22:53
@jecluis jecluis force-pushed the wip-sfs-fix-bucket-mtime branch from fabb8c2 to e26d9a7 Compare November 14, 2023 23:01
@jecluis
Copy link
Member Author

jecluis commented Nov 15, 2023

@irq0 please take another look. I'd love to put this one behind us :)

@jecluis jecluis merged commit 1d41c30 into aquarist-labs:s3gw Nov 15, 2023
5 checks passed
@jecluis jecluis deleted the wip-sfs-fix-bucket-mtime branch November 15, 2023 12:01
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area/rgw-sfs RGW & SFS related kind/enhancement Change that positively impacts existing code
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

rgw/sfs: The mtime field of buckets is not populated
2 participants