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

Pause/Resume #29

Open
peervm opened this issue Aug 7, 2017 · 3 comments
Open

Pause/Resume #29

peervm opened this issue Aug 7, 2017 · 3 comments

Comments

@peervm
Copy link

peervm commented Aug 7, 2017

Hi,

The pause/resume behaviour is not functioning as I expect. Can you confirm the behaviour please.

Assuming that all subscriptions are paused, and this logic was used;
pyrfa.marketPriceResume(ric)
pyrfa.dispatchEventQueue()

I am expecting only the resumed ric to return updates, whereas it actually returns updates for the entire subscribed universe.

Thanks,
Peer


Python 3.6
PyRFA 8.1.0
Windows (Win Server 2012)

@wiwat-tharateeraparb
Copy link
Contributor

wiwat-tharateeraparb commented Aug 7, 2017

Hi Peer,

You should get resumed updates for for that specific ric only. Maybe you need to call dispatchEventQueue() before calling pauseAll() to make sure that all updates are dispatched from event queue?

@peervm
Copy link
Author

peervm commented Aug 8, 2017

That is my current implementation, but I will experiment with calling dispatchEventQueue() before and after the pause to see what happens.

FYI, the reason I asked this question is that after a resuming a single ric, the dispatchEventQueue() returned ~150`000 updates and the call took almost 5minutes to return. This makes me believe that all of the subscribed universe of ~1000 rics was resumed rather than a single ric.

Thanks,
Peer

@wiwat-tharateeraparb
Copy link
Contributor

I have checked it our lab again. The marketPriceResume() acts as expected. I suspected that you didn't dispatch updates our from event queue right after calling pauseAll(). If you have 1000 subscription list, then it is most likely to receive some updates between last update dispatching and before calling pauseAll().

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

No branches or pull requests

2 participants