-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Salt python client "get_full_returns" seems return data from incorrect jid #50927
Comments
is the program B producing the same JID as program A? |
I checked the JID by looking into the debug log from salt and I believe no, they don't have the same JID. This problem occurs quite often in my situation, as program B is sending out cmd at the frequence around 90calls/2min. In program A each time I call BTW, there's also a program C, which is also sending out cmds
And program C works just fine. Therefore this problem seems only occur when using |
thanks for clearing that up. I was able to replicate this and here was my test case:
I then ran programb like so: I believe I was able to narrow it down to the only thing it does with the jid is check if it exists here:https://github.com/saltstack/salt/blob/v2018.3.3/salt/client/__init__.py#L1677 and then we just try to get the event off of the event bus, which would make sense as to why you sometimes see the return from program b, because i'm not seeing any sort of jid filtering here. ping @saltstack/team-core does anyone know why we wouldn't try to filter on jid here? If not i'll submit a PR to fix this issue. |
Yes, we should filter on the jid, that is at least how I remember originally writing it |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. If this issue is closed prematurely, please leave a comment and we will gladly reopen the issue. |
Thank you for updating this issue. It is no longer marked as stale. |
3 similar comments
Thank you for updating this issue. It is no longer marked as stale. |
Thank you for updating this issue. It is no longer marked as stale. |
Thank you for updating this issue. It is no longer marked as stale. |
Versions:
salt-master: 2018.3.2
salt-minion: 2015.5.10 (not sure if this old version of minion is causing this problem)
python salt client: 2018.3.0 (pip install salt==2018.3.0)
Problem:
Seems like when I call "get_full_returns" when sending out async cmd(cmd_async) I got some return data not from the jid I was given by the cmd_async call.
Steps:
Let's say I have two Python program running individually, using different Python venv, program A and program B.
They are both sending cmd to three servers, server 1, 2, and 3.
Program A sends out cmd by using async cmd
Program B just sends out cmd using list mode
Assuming program A is running job on server 1 with jid 100, program B is running job on server 1, 2, 3.
When I call something like
rv = client.get_full_returns(100, ['server 1'], timeout=180)
in program A, I got return from job triggered by program B on server 1.Any idea is this due to the old version of salt-minion or misuse of the client call or is it a bug?
I have checked the release note from 2018.3.1 to 2018.3.3 and did't find something that seems related to this problem.
The text was updated successfully, but these errors were encountered: