Question
· Oct 10, 2023

Intermittent connection from Node.js to IRIS

I'm using a customised IRIS Community Edition Docker Container: Node.js has been added and the Native API for Node.js directory moved to a node_modules folder in /home/irisowner.  I've changed the _SYSTEM password using the Management Portal (which connects to IRIS just fine)

If I shell into the running container and try to connect with a JS script file containing this:

        const IRISNative = require('intersystems-iris-native');

        let connectionInfo = {

          host: 'localhost',

          port: 1972,

          ns: 'USER',

          user: '_SYSTEM',

          pwd: 'secret',

          sharedmemory: true,

          timeout: 5,

          logfile: './mylogfile.log'

        }; 

        const conn = IRISNative.createConnection(connectionInfo);

 

...then sometimes it will connect OK, but many times it will give me an ERROR_SERVER_TIMEOUT error

Anyone know what the problem might be? Why would I get such an intermittent network connection to IRIS?

Discussion (2)2
Log in or sign up to continue