Skip to content

Conversation

@kinyoklion
Copy link
Member

@kinyoklion kinyoklion commented Jul 19, 2023

This adds an class for tracking expiration of "scoped" (DataKind) and "unscoped" (initialized) keys.

Time handling is left to the caller, and proactive eviction could be handled using the prune methods.

(If we end up wanting to encapsulate time, then we could add a layer that just calls steady_clock::now()


namespace launchdarkly::server_side::data_store {

/**
Copy link
Member Author

Choose a reason for hiding this comment

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

Moved this to its own file so it could be re-used.

@@ -0,0 +1,51 @@
#pragma once
Copy link
Member Author

Choose a reason for hiding this comment

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

I scaffolded this file, but have not started on implementation.

@@ -0,0 +1,37 @@
#pragma once
Copy link
Member Author

Choose a reason for hiding this comment

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

Moved from dependency_tracker.hpp

@kinyoklion kinyoklion marked this pull request as ready for review July 19, 2023 19:37
@kinyoklion kinyoklion requested a review from a team July 19, 2023 19:37
ExpirationTracker ttl_tracker_;
};

} // namespace launchdarkly::server_side::data_store::persistent No newline at end of file
Copy link
Member Author

Choose a reason for hiding this comment

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

Adding a blank line.

Base automatically changed from rlamb/add-persistent-core-interface to server-side July 19, 2023 20:34
@kinyoklion kinyoklion requested a review from cwaldren-ld July 19, 2023 21:08
@kinyoklion kinyoklion merged commit 30d2e21 into server-side Jul 19, 2023
@kinyoklion kinyoklion deleted the rlamb/add-expiration-tracker branch July 19, 2023 21:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants