What started as a simple data structure native to the web programming language everyone wanted to slate to the history bins, has gone from relative obscurity to become the de facto data format used for quite literally everything in software development these days. To be fair, the rise of JSON came after developers collectively hit a wall with XML, which by the late 2000s had become the de facto standard used to develop the industry languages businesses use to communicate with each other. Even today, nearly all of these standards are still used and actively maintained despite the proliferation of JSON into the current year.
The seismic shift that started a needless debate
While JSON as a data interchange format is great, things get more complicated as developers and vendors alike continue their efforts to extend JSON past its intended scope. With the modernization of agile software development lifecycles, software vendors update and release new products at an increasing rate. These faster release cycles often come at a cost that typically manifests itself in obsolete documentation or, worse, breaking changes for all downstream customers and other dependent products. Unconstrained by any binding data contract, it’s has become like the Wild West for software vendors who increasingly play “fast and loose” with their data structures, often at the cost of the productivity of their downstream customers who have now have to interpret what changed and what they need to do to support the change. To manage this, developers and vendors alike channel their efforts into bastardizing JSON beyond the scope of its original intent with schemas, namespaces, and versioning, all of which are optional at best, arbitrary and unenforceable at worst.
XML and JSON can actually play nice together
The truth is, XML and JSON are two data formats that complement each other, and developers would benefit from treating them as such. There are good reasons for using either format. JSON excels at data interchange but not data modeling, while XML is built to define data while requiring more work on the front end for integration. As XML tools increasingly add JSON support, developers should consider employing both formats in their solutions, with XML for data definitions and JSON for data interchange.