cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1219
Views
0
Helpful
2
Replies

Cisco XML? Why?

RON ROYSTON
Level 1
Level 1

Cisco XML API Overview

This Cisco IOS XR XML API Guide explains how to use the Cisco XML API to configure routers or request information about configuration, management, or operation of the routers.

Why continue down the XML road?  As JSON.org indicates:

Unfortunately, XML is not well suited to data-interchange, much as a wrench is not well-suited to driving nails. It carries a lot of baggage, and it doesn't match the data model of most programming languages.

The fight has been fought and the clear winner is JSON/JavaScript (ECMA Script 5/6).  XML lost.  If you've ever tried to implement an XSLT transform you know how difficult it is.  If you ever read JSON, you know how easy it is.

While I'm at it - enough with SNMP.  Replace it all with node.js running on the networking device and using HTTPS as the transport and JSON as the message format.

XML is document-oriented. JSON is data-oriented. JSON can be mapped more easily to object-oriented systems.

2 Replies 2

leesa
Level 1
Level 1

While I'm at it - enough with SNMP.  Replace it all with node.js running on the networking device and using HTTPS as the transport and JSON as the message format.

I'm not sure how I feel about that. While returned json data is easier to handle, SNMP is generally considered as for management purposes and is permitted through our firewalls on that basis. HTTP/S is largely denied across the network so that users are pushed through a proxy. I'm sure there are a lot of other companies with a similar setup.

How would you differentiate user-requested HTTP/S data from API-requested HTTPS? Not without complicating things further than they need to be complicated.

As well as that.. what would be your solution to device-generated traps that are automatically sent without someone/something having requested that data?

SNMP is old and occasionally troublesome but it seems to work for the purpose it serves.

(Sorry if I'm not supposed to be replying to other peoples' topics, I'm new here. Am I supposed to not reply to other peoples' topics??)

Syslog.  I guess I'm just venting but SNMP and those crazy OID's seem down right silly.  XML is difficult - over-engineered.

The main motivation for HTTPS is authentication of the visited website and protection of the privacy and integrity of the exchanged data.

https://en.wikipedia.org/wiki/HTTPS