Skip to the main content.

Did you know?

 

RTI is the world’s largest DDS supplier and Connext is the most trusted software framework for critical systems.

Success-Plan-Services-DSSuccess-Plan Services

Our Professional Services and Customer Success teams bring extensive experience to train, problem-solve, mentor, and accelerate customer success.

Learn more

Developers

From downloads to Hello World, we've got you covered. Find all of the tutorials, documentation, peer conversations and inspiration you need to get started using Connext today.

Try the Connectivity Selection Tool ⇢

Resources

RTI provides a broad range of technical and high-level resources designed to assist in understanding industry applications, the RTI Connext product line and its underlying data-centric technology.

Company

RTI is the infrastructure software company for smart-world systems. The company’s RTI Connext product is the world's leading software framework for intelligent distributed systems.

Contact Us

News & Events
Cooperation

2 min read

Connecting Your DDS Apps to Web Services Using Javascript and Node.js

Connecting Your DDS Apps to Web Services Using Javascript and Node.js

One of the benefits of the Industrial Internet for manufacturers and OEM's is the access to live data for more and more applications. This data availability enables performance analytics, more robust business metrics, predictive maintenance analysis, and various other capabilities to be realized by end users and equipment manufacturers alike. In the enterprise, Web Services dominate the typical access to data. On the manufacturing floor or in deployed systems, real-time data delivery is a requirement. DDS is one of the primary infrastructures used to share large amounts of data in very low latency delivery times.

Typical solutions for data analysis and visualization rely on protocol libraries and heavyweight client applications to receive/process the data. Today, in the enterprise, the distribution of these proprietary client applications is cumbersome and time-consuming. This results in a reduction of the utilization an organization can get from available live data. Thus, there is a need to enable applications to leverage technologies that can be found on everyone's desk. Just about every computer, tablet or handheld available today have browsers like Internet Explorer, Firefox, Safari, Chrome and others. Through the use of standard web technologies like Javascript, JQuery, Node.js and Websockets, it is quite trivial to interface browser based user applications with live data. The problem, however, is how to connect live DDS data up inside these thin client browser based applications. As we know, access to DDS data requires the use of DDS libraries to interact with the DDS RTPS protocol.

To solve this problem, we have created a lightweight connector technology that enables DDS data to be accessed with Javascript, Node.js server side applications. This solution provides the ability to have a single server process interact bidirectionally with DDS data while serving up html pages that leverage standard WebSockets for communication to the server for data. Take a look at the following diagram showing how the Javascript connector enables the flow of data between DDS and browser based applications.

dds-connector-data-flow.jpg

Taking this a step further, and now that there is an integration with Node.js, we have the ability to create useable object nodes in NodeRed. NodeRed is a visual programming environment for Node.js applications. This development environment, which itself runs on Node.js, can be used in any browser. NodeRed provides many building blocks for typical items used in Industrial Internet applications such as: WebSockets, HTTP, custom TCP, custom UDP, MQTT, custom function blocks, email, twitter, XMPP, and many others. As you can see in the following diagram we are using several of these blocks to subscribe to DDS data (Square, ShapeType) and publish data on MQTT, then with a separate flow, subscribe to the MQTT server and output the data to a debug window.

NodeRed Development diagram

At RTI, we are constantly working on creating components that are useful and beneficial for your Industrial Internet applications. This latest solution gives a developer quick and easy access to live data in many different forms depending on their specific application requirements. The ability to present live data in a thin client browser based application provides a great deal of flexibility for creating and distributing applications to better leverage data that is already available in the system.

Information regarding NodeRed can be found at http://www.nodered.org. If you are are interested in connecting up your live data to backend enterprise applications and thin client browser based applications, please contact us via email (rtiblogs@rti.com) or leave a comment in the comments section.

UPDATE: 3/31/15 An experimental version of the connector is now available on the community developer site for RTI. This connector includes the Javascript Node.js connector as well as a Python connector. You can find it here:

https://community.rti.com/downloads/experimental/rticonnextdds-connector