Implementing the Middleware to Process Messages

Learn how to implement and use the ZeroMQ middleware framework.

Now that we’ve implemented our Middleware Manager, we can create our first pair of middleware functions to demonstrate how to process inbound and outbound messages. As we said, one of the goals of our middleware infrastructure is to have a filter that serializes and deserializes JSON messages. So, let’s create a new middleware to take care of this. In a new jsonMiddleware.js named module, let’s include the following code:

Get hands-on with 1400+ tech skills courses.