Replies: 2 comments
-
Because the plugin is not started each time a query happens, an ID will be used to identify which query is the result belong to. Furthermore, the plugin will need to handle the cancellation/multithread/async by itself because they will be designed as a single-process model in this way. |
Beta Was this translation helpful? Give feedback.
-
execute long task as in a task that takes a while to return result or a long task in terms of string passed to python plugin? does this method also have a restriction of 1s response wait time? i dont know the second solution so not sure which is better |
Beta Was this translation helpful? Give feedback.
-
The current jsonrpc plugin communication model is one time argument pass, one time result back from standard output. Therefore, it will be impossible for json rpc plugin to execute long task, and it will be hard to them to call flow API except through results.
A potential solution is to reuse the redirected standard input/output to allow back and forward communication.
Wox-launcher/Wox#2010
Another solution is use socket/ipc/pipeline as interprocess communication between flow and plugin.
Beta Was this translation helpful? Give feedback.
All reactions