noflo / noflo-ui

NoFlo Development Environment
https://app.flowhub.io
MIT License
767 stars 173 forks source link

Runtime registry #70

Closed jonnor closed 10 years ago

jonnor commented 10 years ago

NoFlo UI / Flowhub can communicate with several different runtimes, but currently one has to specify which in form of an URL. Runtimes should instead be able to register themselves dynamically with Flowhub.

This should also enable users to use a central Flowhub instance with their own custom runtime instances (possibly on/with specialized hardware, and on a private network).

It should be easy to host ones own registry in combination with a Flowhub UI. It should be possible to change the registry to connect to, both systemwide and for one specific runtime (std precedence: commandline arg/API, envvar, user config, sys config). Default could be flowhub.io (for a particular user) For such public use, the protocol needs to be encrypted and authenticated.

When inside a project the runtime card (top-right) should show a list of currently available runtimes (of compatible type?). When in frontpage, a list of available runtimes should be available. Both should be fully dynamic, responding to availability.

Related: #64

bergie commented 10 years ago

There are two separate use cases for the runtime registry, both of which should be considered:

bergie commented 10 years ago

The runtime registry is a web service provided by Flowhub. Runtimes can register themselves there so that they become visible in user's NoFlo UI.

We collect the following information for each runtime:

Additionally we track the time the runtime has been last seen. Runtimes can "ping" the registry to know they're still alive.

bergie commented 10 years ago

With the Flowhub Registry library it is now easy to register and list runtimes.

bergie commented 10 years ago

screenshot 2014-02-17 at 21 32 32

Now we need easy explanation how to register the typical runtime types (NoFlo on Node.js, MicroFlo), and then we can start caching components here, as well as replace the old runtime address handler in the graph view:

screenshot 2014-02-17 at 21 34 34

jonnor commented 10 years ago

Initial implementation in MicroFlo: https://github.com/jonnor/microflo/commit/92ccf0827677675b1afa37749e369f268d5af5a2

bergie commented 10 years ago

For Node.js runtimes, we have a helper called noflo-nodejs for setting up and running server-side NoFlo runtimes so that they communicate with Flowhub.

screenshot 2014-02-18 at 21 48 29 screenshot 2014-02-18 at 21 48 17

bergie commented 10 years ago

We now have a simple info popup on how to register runtimes:

screenshot 2014-02-20 at 19 30 32

bergie commented 10 years ago

And now connection settings are handled by selecting a runtime:

screenshot 2014-02-20 at 21 16 08