Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 

Understanding JET Interaction with Junos OS

 

The Juniper Extension Tookit (JET) provides tools to developers to create applications that extend the functionality of Junos OS. For example, a JET application might extend the Junos CLI by adding a new operational command to show application-specific states.

JET applications can run on devices running Junos OS or run on another type of device in your system and connect over the network to a device running Junos OS.

The JET development environment consists of a virtual machine (VM), an integrated development environment (IDE), and APIs. Click here to see the rest of the JET documentation.

This guide covers how to deploy and use applications that were developed using JET on Junos OS.

JET applications interact with Junos OS via the following two services:

  • Request-response—An application issues a request and synchronously waits for the response from Junos OS.

  • Notifications—An application receives asynchronous notifications of events happening on Junos OS.

The request-response service is included in the JET service process (jsd), which runs on Junos OS. Whenever a request arrives on the TCP port, jsd creates a separate thread to service the JET application request. The session remains established as long as the client and server are both up and able to communicate with each other. Over the lifetime of a session, jsd can execute any number of APIs, and it can execute APIs from multiple sessions in parallel. A maximum of 8 client sessions can be active at any given time.

The notification service uses a publish-subscribe-based messaging protocol and notification broker. JET applications register with the notification broker and inform the broker about the topics for which they are interested in receiving messages. The broker is responsible for distributing messages to the interested clients based on the topic of a message. Junos OS daemons publishing the events (such as eventd) connect to the broker as a publisher and publish the events.