rools icon indicating copy to clipboard operation
rools copied to clipboard

Should be used sync function in when ?

Open love8587 opened this issue 2 years ago • 3 comments

I'm trying rules engine to implement evaludate articles to accept automatically.

I researched rules enginer and rools module looks good for me.

However, there is a part that has been hesitating.

I think when conditions could be async functions. Is it should be compose of sync functions ?

love8587 avatar Oct 05 '21 06:10 love8587

yes, premises (when) are always working synchronously on the facts.

frankthelen avatar Oct 05 '21 19:10 frankthelen

Thanks for your answer. Can I get a some refference to understand the reason why Promises are always working synchronously ?

love8587 avatar Oct 06 '21 13:10 love8587

Thanks for the question. The answer is probably for performance reasons and because I was thinking that it is not required. But why not. Let me think about it.

frankthelen avatar Oct 11 '21 12:10 frankthelen