Ending a Junos XML Protocol Session and Closing the Connection
In a Junos XML protocol session with a device running
Junos OS, when a client application is finished making requests, it
ends the session by emitting the
<request-end-session/> tag within an
<rpc> tag element:
In response, the Junos XML protocol server emits the
<end-session/> tag enclosed in an
<rpc-reply> tag element and a closing
The client application waits to receive this reply before
emitting its closing
The client application can then close the SSH, SSL, or other connection to the Junos XML protocol server device.
Similarly, client applications written in Perl can end the Junos XML protocol session and close the connection by using the Junos XML protocol Perl module and methods described in Closing the Connection to the Junos XML Protocol Server in Perl Client Applications. Client applications that do not use the Junos XML protocol Perl module use the routine provided for closing a connection in the standard library for their programming language.