Logo

dev-resources.site

for different kinds of informations.

Client for WebSockets based on Node.js

Published at
8/31/2021
Categories
javascript
soap
ensemble
node
Author
intersystemsdev
Categories
4 categories in total
javascript
open
soap
open
ensemble
open
node
open
Author
15 person written this
intersystemsdev
open
Client for WebSockets based on Node.js

WebSockets as a communication technology wins increasing importance.

In the SAMPLES namespace, you find a nice example for running a WebSocket Server.

There is also a useful example for a Browser Client. JavaScript does most of the work. 

My point is:

How to consume the output of a WebSocket Server in your application?

You may take the engineering approach and use the available tools and classes to handle

everything around protocol switching, encoding, encryption, .... 

It is great if you are able to achieve this and if you are willing to invest the required time and find a sponsor to support it.

On the other hand, this is re-inventing the wheel. This works already in almost every browser.

e. g JavaScript has excellent and verified libraries to support what you need.

And there is the engine to run it without a browser: Node.js

And Caché, IRIS, Ensemble have meanwhile a well-established interface module ready.

So I took a closer look after managing to get the correct versions together.

Once the WsockDemo.js was assembled and tested you launch it over CPIPE or $ZF(....)

You provide control information from the server and get back the result to the server.

If you are used to JavaScript there are no big surprises. The major difference to accept and

understand is that yo operate in an almost total asynchronous environment and callback

methods and their interaction are probably the most important difference to traditional

programming.

I have placed the example here with more docs as an invitation to break out

(for most developers) of your traditional environment and find something new and useful.

 I have to admit that this was my first exercise into Node.js and I'm far from taking the best

and most advanced solution. But the result in relation to the effort was convincing.  

Remember:

This is a coding example working on Cache 2018.1.3  
 It will not be kept in synch with new versions      
 It is also NOT serviced by InterSystems Support !
soap Article's
30 articles in total
Favicon
REST VS SOAP
Favicon
OpenTelemetry Traces from IRIS implemented SOAP Web Services
Favicon
Top 6 SOAP API Documentation Tools to Streamline Your Development Process
Favicon
How to Turn Any SOAP Web Service into a REST API
Favicon
Getting hands dirty with SOAP
Favicon
Best Practices for Naming REST API Endpoints
Favicon
Choosing the Right API Protocol: GraphQL vs. REST vs. SOAP
Favicon
Mastering SOAP WSDL: Step-by-Step Tutorials and Examples
Favicon
SOAP Explained: With Javascript
Favicon
SOAP Integration in Salesforce
Favicon
Mastering Jakarta SOAP API: A Detailed Introduction for 2024
Favicon
Create SOAP Services Using ASP.NET Core
Favicon
How to use SOAP/WSDL APIs using SoapUI & Python Zeep
Favicon
Test SOAP Web Service using Postman tool
Favicon
🌟 Supercharge Your APIs with GraphQL! 🚀
Favicon
Debugging Web
Favicon
SOAP com TypeScript em pleno 2023
Favicon
XML Parsing em NodeJS com XMLBuilder2
Favicon
Comparing REST API and SOAP: Understanding the Key Differences
Favicon
Net::SAML2 0.60 TRIAL Released
Favicon
Error - Exception occurred during code generation for the WSDL
Favicon
How to call SOAP Services using REST
Favicon
Wednesday Links - Edition 2022-05-18
Favicon
Feign com SOAP: uma PoC
Favicon
Make a Soap call in React js by a webservice
Favicon
Implementando um Serviço com SOAP, (HTTP e XML).
Favicon
Client for WebSockets based on Node.js
Favicon
Validando o schema de arquivos XML com .Net e C#
Favicon
Signing and verifying SOAP messages with wss4j and Scala
Favicon
Contract First Web Service Development in .NET

Featured ones: