I am developing custom connectivity nodes (database, AMQP and etc.). I am still struggling to understand what should be the best approach to connections reuse.
All of the packages I looked into are using "config" nodes just for config store and every (UI) node instance maintains its own connection to the external system. This sounds strange to me, since Node-Red is running in a single process, and it should not be an issue to store the connection object in the config node and reuse this connection across other (UI) nodes. This approach should be a lot more resource savvy (i.e. DB connection is considered to be highly resource-intensive on DB server).
Your thoughts are highly welcomed.