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

[leo_storage] replicator/5 can receive messages generated by gen_server:call/cast #713

Closed
mocchira opened this issue Apr 20, 2017 · 0 comments

Comments

@mocchira
Copy link
Member

Background

Problem

No problem when handling online tasks.
The problem can happen when handling offline tasks because a caller process is a gen_server so calling erlang:receive can receive messages unintentionally generated by gen_server:call/cast.

Solution

We are going to add a tag (in order to receive messages ONLY we are using in leo_storage_replicator) into all messages.

Reference

How the gen_server manages send/receive messages.

@mocchira mocchira added this to the 1.3.3 milestone Apr 20, 2017
@mocchira mocchira self-assigned this Apr 20, 2017
mocchira added a commit to mocchira/leofs that referenced this issue Apr 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant