Node-red unresponsive while sqlite node is working

Well,... sometimes I can't stop tinkering. I implemented a custom exec async node that uses node.js childProcess and stream libraries to start a process and pipe text to its stdin.

This custom node is used in a custom sqlite read async node to spawn a niced (to decrease process priority) sqlite3 cli process which opens a sqlite db with the -readonly -json flags.

This works quite nicely. Note that you have to have the nice and sqlite3 programs on your path in order for this to work. The sqlite file path cannot contain ~ as the path is put in double quotes, but you can use the $HOME env variable.

Gist for custom sqlite read async node.

1 Like