Executor with multiple executions

Hi

Is there a way to put Executor in something scheduled? In other words, I need to execute one file with different arguments, then put results in one collection and use it after it’s done. Now I achieved unstable results with ForEach and Cache, but feel like it can work better if use something like Task. Some piece of advice?

i think you need to add more details, on how exactly your foreach looks right now

at this point I achieved most stable result with this setup, but anyway it fails to process all files in unpredictable way

изображение

in the middle there is a “processing” stuff that not related to the issue

изображение

For example, this not working at all. Can somebody explain why?

изображение

I made an experimental patch to explore observable behaviour with asynchronous computations and there are very strange side effects that I didn’t expect. Can anyone look at this?

ObservableExample.vl
ObservableExample_asyncTask.vl

Also, it only works correctly with the second try since the patch started. With “time to wait” araound 100ms in Executor it shows nothing at first time.

Finally, it’s works (almost) ideal for me
There are many strange behaviours across Observables

изображение

@yar it looks like your patch doesn’t run async, unless there is a ToBackground node in the observable graph. observables are not async by default. however, the operators are threadsafe, so they can be used in async/threading scenarios. so try ToBackground after ToObservable.

@tonfilm that explains a lot, big thanks!

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.