MongoDB and Low Friction Web Development – Part II

My first post in this series discussed how development teams and project managers can maximize project success by minimizing project friction. In Part II I will discuss how JavaScript and MongoDB are making web application development better, faster, and cheaper by helping to minimize friction in the Software Development Life Cycle.

Client-Side Integration Friction and JSON

Bus-Apps
Copyright: fgnopporn / 123RF Stock Photo

Extensible Markup Language (XML) is dead. Several years ago, I came to the realization that XML is dead when I started using JavaScript Object Notation (JSON) to describe and explain data moving through the software applications I was building. The simplicity and power of JSON became readily apparent to me as I built mobile applications that consumed web service APIs. Initial iterations of my mobile application and REST APIs utilized XML to markup the data flowing between the mobile device and web service. In the mobile space, especially in years past, being parsimonious with network communications was important in order to limit bandwidth usage and to keep application performance metrics within usable limits (anyone remember WBXML?).

However, simple load tests revealed that using JSON in our REST APIs, versus XML improved network response times considerably when using mobile http communications. But beyond mobile device consumption of REST APIs, JSON was already being widely used in web development project architectures. It now seems evident that JavaScript and JSON are simple and efficient technologies to use for front-end development. Largely because of the widespread use of JavaScript and JSON in client-side development, both have become more pervasive in the integration and back-end tiers of software systems, including the central application data store.

MongoDB Supports Client-Side JSON Storage

MongoDB is one document-oriented NoSQL data store that facilitates simple storage and retrieval of JSON Documents. Since many web applications already use JSON Documents extensively in the client-tier, it makes a great deal of sense to store these documents directly in the back-end data store, as-is, without much, if any, data transformation overhead that is traditionally associated with many JEE web applications. The mongo shell even allows JavaScript to be used natively to query and interact with the JSON documents stored in MongoDB, making front-end skills directly transferrable to working in the back-end. MongoDB does not complain if you need to refactor the front-end data elements and add new data elements to existing JSON documents in the data store. In essence, there is no need for updating or adding RDBMS tables when the data in the front-end changes. This allows for true developer agility when working with JSON Document stored in MongoDB, and thus, minimizing friction.

Simplify the Middle-Tiers

The integration layer between thin HTML/JavaScript/JSON clients and the MongoDB data store can be implemented in a number of ways. MongoDB provides a wide variety of drivers that support many languages such as Java, C++, C#, Perl, Ruby, etc (See the full list). You could even employ a full JavaScript technology stack by using node.js in the integration/middle tier, for example, leveraging a common skill set across all application tiers.

Conclusion

The ability to easily store and retrieve JSON documents using familiar JavaScript and JSON syntax are a few reasons that make MongoDB an intriguing data store to consider using in the never-ending quest to reduce friction in the Software Development Life Cycle.