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

Update DirectConsumer option to ignore shutdown and other reasons #192

Merged
merged 7 commits into from
Mar 4, 2021

Conversation

ono
Copy link
Collaborator

@ono ono commented Mar 1, 2021

Follow up #184

@ono ono changed the title Direct consumer option ignore down Update DirectConsumer option to ignore shutdown and other reasons Mar 1, 2021
@ono
Copy link
Collaborator Author

ono commented Mar 1, 2021

@benonymus @haljin

Tweaked the options and made consumer pid matching explicit as before. Let me know if you have any feedback.

@benonymus
Copy link
Contributor

Hey @ono

Looks good to me, I like that this way the options are ready to be expanded.

I am not sure about the property named cascade, maybe something more explicit like ignore_all_reasons(would need to change it to do it if true), and then maybe change the ignore to ignore_reasons?

@ono
Copy link
Collaborator Author

ono commented Mar 3, 2021

Yeah, agreed. After a bit more thinking, I will go for a single option - ignore_consumer_down which takes boolean or list.

opts = [ignore_consumer_down: true] # ignore any reason
opts = [ignore_consumer_down: [:normal]] # ignore normal (default)
opts = [ignore_consumer_down: [:normal, :shutdown]] # ignore normal and shutdown

@ono ono merged commit dcefab5 into main Mar 4, 2021
@ono ono deleted the direct-consumer-option-ignore-down branch March 4, 2021 20:12
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.

2 participants