Polywrap Project Types: Node & NodeRunner

As the Polywrap toolchain continues to be used for building nodes (ex: Persistence Node, Gelato Node), I think it might be a good ideal to introduce 2 new Project Types:

  • NodeRunner - Minimum viable server-side application that runs Polywrap Nodes. This node runner application would implement an external RPC for interacting with it, have a robust run-time that runs nodes in isolated threads, and provides system-level access to the node wrappers through special plugins.
  • Node - A wrapper project that’s tailored for building “node” modules. There would probably be a special interfaces that’s needed here.

These 2 new projects would be added to the existing list of projects:
Wrapper, Interface, Plugin App

Imagine being able to type polywrap create node rust, and begin implementing server-side applications running on the “NodeRunner” application.

Here’s an example of what NodeRunner applications would be pre-setup to do:

1 Like

I’m fully on board with this, with a few timeline caveats.

  1. Normally, I like to wait for at least 2-3 similar implementations before implementing a generic solution. This would mean having the persistence node, verification node and some other node. In this case, though, I think we can accelerate the process. As soon as the persistence node and wrapper ipfs gateway reach a more mature state, we can start turning the node into a rust wrapper and implementing a node runner.
  2. For the node runner, I think it’d be great if we could implement it in rust, but we need a rust client for that.
  3. In the future, I’m sure we would have NodeRunner project templates for each language the client is in, but we should prioritize a single one for now.

Additional note: I think the “NodeRunner” name is a bit verbose, ideally it’d be a single word, IMO

2 Likes

Amazing feedback, couldn’t agree more!

One important thing to decide is having a single client for all nodes or a client per node.
I’ve always assumed the latter.

1 Like

I’m not a native English speaker, so these subtleties escape me, but I like NodeRunner : )

It reminds me the Hope Runner by Simon de la Rouviere…

2 Likes

Agreed, having 1 client per 1 node makes sense IMO. The client would probably run in a separate thread as well.