Not Everything is Elegant, Get Over It

At some point, IBM released a thing called JSONx, which was a way to represent JSON in a XML schema. Partially because it is IBM, partially because it is more XML, and partially because the internet is a hive of scum and villainy, developers collectively shit their pants. Here is a sample:

It goes on from there.

Before I go any further, let me just get this out of the way - just because you don't like something doesn't make it a WTF moment. Not everything in programming can be cool, or innovative, or hip. Sometimes things are invented to solve a problem, and sometimes those solutions don't make sense outside of the scope of the original problem.

JSONx isn't going to affect most developers in any meaningful way, so stop acting like this is some new evil that must be slain.

But Why Would IBM Unleash This Evil?

Not everything in this world understands JSON. I know, it is crazy that in this day and age that a language, especially one that is potentially talking to other systems, does not understand JSON, but that happens all of the time. By converting the JSON into JSONx you can then use that with an XSLT to transform JSON into something else or work directly with the JSONx representation in your code that natively supports XML.

If we take a step back and look at what is going on, IBM is putting an appliance in front of legacy applications that do not understand JSON but do XML. The world of IBM is filled with applications that vendors have written that know and understand XML, and rewriting all of those to support JSON will be a major undertaking. I know that the vendors I have worked with on the IBM i platform could barely handle XML with a valid schema, let alone something as freeform as JSON. The DataPower appliance lets companies leverage their older XML-understanding code to use JSON.

As I said before, sometimes that answers to programming problems look ugly or stupid outside of the problem scope. In this case, the solution makes perfect sense - provide a way to turn something you can't understand into something you do.

This Doesn't Involve You

Unless you are a dev that has to work with a DataPower appliance, JSONx means nothing to you. It is not some sort of standard that IBM wants to make as a replacement for JSONx, and I'm sure that IBM isn't going to start requiring JSONx over straight JSON. Unless you work in an IBM shop and have to specifically deal with this problem, this will never come into your world.

If you work in a shop that does a lot of IBM mainframe work you are probably happy you can now provide JSON to all those external developers that are clamoring for it.

So Get Over It

People will always invent things to solve a problem, and those things will not always be elegant. That's the way things work in the programming world. It is your job to look at solutions and see if they solve your problem, and I doubt many people have this problem. I know for my old coworkers and people using IBM languages like RPG or COBOL JSONx will make their lives easier. For all my PHP and web developer friends JSONx is a non-issue.


Comments