Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(jans-cedarling): Make SparKV use generics, and update MemoryLogger to use those. #10593

Merged
merged 24 commits into from
Jan 15, 2025

Conversation

djellemah
Copy link
Contributor

@djellemah djellemah commented Jan 13, 2025

Prepare

Depends on #10013


Description

Target issue

#10554

closes #10554

Implementation Details

Make SparKV use a generic to specify the type to be stored.

Update MemoryLogger to make use of SparKV with generics.

Provide a drain iterator for a fast implementation of MemoryLogger::pop_logs.

Update LogStorage and LogWriter to use serde_json::Value internally.


Test and Document the changes

  • Static code analysis has been run locally and issues have been fixed
  • Relevant unit and integration tests have been added/updated
  • Relevant documentation has been updated if any (i.e. user guides, installation and configuration guides, technical design docs etc)

Please check the below before submitting your PR. The PR will not be merged if there are no commits that start with docs: to indicate documentation changes or if the below checklist is not selected.

  • I confirm that there is no impact on the docs due to the code changes in this PR.

@djellemah djellemah linked an issue Jan 13, 2025 that may be closed by this pull request
@djellemah djellemah self-assigned this Jan 13, 2025
@djellemah djellemah added comp-jans-cedarling Touching folder /jans-cedarling kind-feature Issue or PR is a new feature request labels Jan 13, 2025
@mo-auto mo-auto added area-documentation Documentation needs to change as part of issue or PR comp-docs Touching folder /docs labels Jan 13, 2025
@djellemah djellemah force-pushed the jans-cedarling-10554 branch 2 times, most recently from 05137be to ff8f658 Compare January 13, 2025 13:17
…or more efficient pop_logs

Signed-off-by: John Anderson <[email protected]>
@djellemah djellemah force-pushed the jans-cedarling-10554 branch from ff8f658 to bbbb1c5 Compare January 13, 2025 13:19
@djellemah djellemah marked this pull request as ready for review January 13, 2025 13:42
@djellemah djellemah requested a review from olehbozhok January 13, 2025 13:42
@djellemah djellemah changed the title Make SparKV use generics, and update MemoryLogger to use those. feat(jans-cedarling): Make SparKV use generics, and update MemoryLogger to use those. Jan 13, 2025
nynymike
nynymike previously approved these changes Jan 13, 2025
Copy link
Contributor

@nynymike nynymike left a comment

Choose a reason for hiding this comment

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

Cool!

Copy link
Contributor

@olehbozhok olehbozhok left a comment

Choose a reason for hiding this comment

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

I would like you to use cargo fmt formatter

cargo fmt -p sparkv

abaghinyan
abaghinyan previously approved these changes Jan 13, 2025
@djellemah djellemah dismissed stale reviews from abaghinyan and nynymike via 927ffc9 January 15, 2025 13:56
@djellemah
Copy link
Contributor Author

I would like you to use cargo fmt formatter

cargo fmt -p sparkv

cargo fmt changes in #927ffc #5cad82

Copy link
Contributor

@olehbozhok olehbozhok left a comment

Choose a reason for hiding this comment

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

I think fallback logger no need initialize every time. But in current context it doesn't really matter.

@djellemah djellemah merged commit 25c7a49 into main Jan 15, 2025
21 of 24 checks passed
@djellemah djellemah deleted the jans-cedarling-10554 branch January 15, 2025 17:55
@djellemah djellemah mentioned this pull request Jan 16, 2025
11 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-documentation Documentation needs to change as part of issue or PR comp-docs Touching folder /docs comp-jans-cedarling Touching folder /jans-cedarling kind-feature Issue or PR is a new feature request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat (jans-cedarling): Update sparkv to use Generics
6 participants