ai4eu / generic-parallel-orchestrator

Orchestrator with support for streaming, RPC, and seamless conversion between the two, based on a queued multithreading architecture.
Apache License 2.0
0 stars 0 forks source link

Parallel Orchestrator Management #2

Closed emiliocimino closed 2 years ago

emiliocimino commented 2 years ago

Good evening,

Thanks for the project you set up, it is a very nice idea to make available AI in a "drag 'n drop" fashion. I'm a developer trying to use the AI4EU platform as contributor, however I had problems in understanding the orchestrator. I was trying to use the AI4EU platform, deploying a custom simple model composed by two components: one "broker" sending two numbers from a file and one "consumer" receiving and summing them with output. The example is trivial, however I found difficulties in managing the orchestrator queues: in few words, since the input is an empty message, the orchestrator (who runs infinitely) simply calls the whole queue without the possibility to decide when to send those numbers. I tried also to deploy two of the available solutions on the catalog, the Sentiment Analysis (with databroker) and the Sudoku Tutorial; the first one worked like my solution (after a correction of the databroker image url which has two columns) while the sudoku one was able to "pause" the orchestrator to wait an input from the GUI. I don't know if a tutorial or guide on the parallel orchestrator management is available anywhere, but if not, can I suggest a video tutorial to show not only how to use the platform and deploy but also how to build a custom solution with orchestrator queue management? For example, if I want a databroker to send data when a particular API is called, how can I manage the orchestrator to wait for that API to execute the whole queue?

Thanks, Best regards,

Emilio

emiliocimino commented 2 years ago

Solved: To allow the orchestrator to wait for an input I used a queue, calling the get method with blocking state and putting something in the queue when the external input arrives.