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

Add the support of the BF.INSERT command #1768

Merged
merged 5 commits into from
Sep 22, 2023

Conversation

zncleon
Copy link
Contributor

@zncleon zncleon commented Sep 19, 2023

This PR:

  1. Introduce the bloom BF.INSERT command
  2. Change the parameter parser error return to unified and explicit msg (e.g. "Bad capacity")

[1] https://redis.io/commands/bf.insert/

@zncleon
Copy link
Contributor Author

zncleon commented Sep 19, 2023

The reasons Why I change the msg are:

  1. If I direct parse (e.g. capacity) in BF.Reserve and use parser's take and GET_OR_RET in BF.INSERT, the error msg would be differentiated.
  2. In this patch, the parse error msg is the same as the RedisBloom.

Copy link
Member

@mapleFU mapleFU left a comment

Choose a reason for hiding this comment

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

I'm a little busy today, I'll take a look carefully tonight

src/commands/cmd_bloom_filter.cc Outdated Show resolved Hide resolved
Copy link
Member

@mapleFU mapleFU left a comment

Choose a reason for hiding this comment

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

Looks ok, just some advices

src/commands/cmd_bloom_filter.cc Outdated Show resolved Hide resolved
src/commands/cmd_bloom_filter.cc Outdated Show resolved Hide resolved
src/commands/cmd_bloom_filter.cc Outdated Show resolved Hide resolved
@PragmaTwice PragmaTwice requested a review from mapleFU September 21, 2023 14:02
Copy link
Member

@mapleFU mapleFU left a comment

Choose a reason for hiding this comment

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

I catch a cold these two days, sorry for late reply...

Other looks ok to me

src/commands/cmd_bloom_filter.cc Outdated Show resolved Hide resolved
@PragmaTwice PragmaTwice merged commit 723829f into apache:unstable Sep 22, 2023
26 checks passed
@PragmaTwice
Copy link
Member

Thank you for your contribution!

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