This is a coding example working on IRIS 2020.2 It will not be kept in sync with new versions It is also NOT serviced by InterSystems Support !
Using the IRIS native API for Node.JS was the oportunity to present a MicroService operating in a Docker container.
_My demo video is now also available to watch the demo in operation.
This WebSocketClient Service runs in an own container checking for messages to be submitted using IRIS native API for Node.JS.
The service operates with 3 Globals (Run/Stop WSserver, Input, Output)
Data are fetched from IRIS and sent to an external WebSocket Echo Service and reply is written back to IRIS.
All information is provided from IRIS.
To visiualize operation the containr should run interactive.
Control / Input / Output is all managed from a interactive utility in IRIS.
Make sure you have native Docker or Docker Desktop installed.
Pull and init the demo:
Detailed description: https://github.com/rcemper/WSockClientMicroSV/blob/master/READMEwindows.MD
Run first a Docker exec session for the Control / In-Out utility in IRIS
docker run --name iris1 --init --rm -d -p 52773:52773 -p 51773:51773 -v vol1:/external store/intersystems/iris-community:2020.2.0.204.0 -b /external/pre.copy
Next start the Service process
docker run --name rcc1 --init -it --rm rcemper/rcc:demoJS /usr/bin/node /rcc/nodejs/WSockIris.js 172.17.0.2
And start the control program for IRIS in a new command / terminal session
docker exec -it iris1 iris session iris ZSocket