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

Sampling and async performEvent are incompatible #404

Open
mpickering opened this issue Mar 16, 2020 · 0 comments
Open

Sampling and async performEvent are incompatible #404

mpickering opened this issue Mar 16, 2020 · 0 comments

Comments

@mpickering
Copy link

The core of my application is built around a rule type which is essentially an IO action with the ability to sample dynamics. As the IO action runs it samples different dynamics depending on what the rule is.

Unfortunately all these actions have to run in the same thread as given the current implementation of performEventAsync the action must only be of type IO.

However, I believe it should be safe to sample a Dynamic from a different thread because sampling is just a read of the variable. This idea could already be implemented by sampling every dynamic in my program before passing a record of all the sampled values into the function. This is undesirable though and typically each rule is not using most of the Dynamics.

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

1 participant