Welcome!

@DevOpsSummit Authors: Yeshim Deniz, Zakia Bouachraoui, Pat Romanski, Liz McMillan, Elizabeth White

Related Topics: @DevOpsSummit, Linux Containers, Containers Expo Blog, FinTech Journal

@DevOpsSummit: Blog Feed Post

Application Modularization in Testing | @CloudExpo @BlueBox #DevOps

One of the most important best practices in application development is testing

Why Application Modularization Matters: Testing
By Ruben Orduz

Preface
A few weeks ago my colleague PJ Hagerty wrote about driving your existing monolithic application toward a more modular design. This time around I'll dive a little bit deeper into its importance and the benefits of application modularization.

The Case
One of the most important best practices in application development is testing, and more specifically automated and continuous testing. When your application is a monolith with multiple functionalities and responsibilities, automated testing becomes massively unwieldy. To illustrate this issue let's use the following illustration of conceptual (and, admittedly trivial) photo gallery web application:

conceptual photo gallery web application example

Say you want to test Login functionality. After writing some basic testing setup and "plumbing" code, etc., you can start writing tests against the Login functionality. What if you want to test Post Photo functionality? On top of all the testing code for Login functionality now you also need special testing code for Post Photo functionality. How about testing Get Photo functionality? You need all of the above code plus the code to test Get Photo. At this point as you start getting testing failures, you'll be heading down-head first-into the proverbial rabbit hole. You won't know for sure where things are going awry: is the Login functionality failing or the Post Photo functionality or Get Photo functionality? And this is as trivial and straightforward as it gets. Now imagine a real application with more complex and intertwined functionality: a nightmare to maintain, test and develop.

Now, let's imagine the same application with a more modular approach:

conceptual photo gallery web application example with modular approach example

It's worth noting that in this example for the sake of simplicity, the Login module is also the front end your users interact with your application.

In the illustration above, we modularized the application in their own logical models and functionality driving toward what is known in the world of software development as single-responsibility principle. So, let's circle back to testing. Let's say you want to test Get Photo functionality. Now it's substantially easier: you can write tests against the Photo module and mock or stub out all other functionality (namely the Login module), same with Album module and any other modularized components. So now you can not only add automated testing more easily, but it becomes significantly simpler to figure out and fix when things fail-you have complete control over the context, so you'll know if it's a real failure or a false-positive and where those failures come from.

Closing thoughts
Testing is a critical part of your application. It's as critical as having a snazzy UI layer, super fast performance or some insanely clever functionality. Without proper testing you're, figuratively speaking, going off the deep end of technical debt and sooner or later you will have to pay. With a monolith, your testing will be limited, at best and nonexistent at worst. If you want your application to be easily maintainable, simple to work on and add or modify existing functionality with ease, you must drive toward modularization and thus testing.

Read the original blog entry...

More Stories By Blue Box Blog

Founded in 2003 by Jesse Proudman, Blue Box offers Blue Box Cloud—a managed Private Cloud as a Service (PCaaS) product available in both hosted and on-prem versions, powered by OpenStack.

Blue Box employees bring a wealth of diverse, in-depth operational experience to each customer installation of our unique hosted private cloud offering. Think of Blue Box team as your application’s lifeline.

@DevOpsSummit Stories
Dion Hinchcliffe is an internationally recognized digital expert, bestselling book author, frequent keynote speaker, analyst, futurist, and transformation expert based in Washington, DC. He is currently Chief Strategy Officer at the industry-leading digital strategy and online community solutions firm, 7Summits.
Addteq is a leader in providing business solutions to Enterprise clients. Addteq has been in the business for more than 10 years. Through the use of DevOps automation, Addteq strives on creating innovative solutions to solve business processes. Clients depend on Addteq to modernize the software delivery process by providing Atlassian solutions, create custom add-ons, conduct training, offer hosting, perform DevOps services, and provide overall support services.
Contino is a global technical consultancy that helps highly-regulated enterprises transform faster, modernizing their way of working through DevOps and cloud computing. They focus on building capability and assisting our clients to in-source strategic technology capability so they get to market quickly and build their own innovation engine.
The standardization of container runtimes and images has sparked the creation of an almost overwhelming number of new open source projects that build on and otherwise work with these specifications. Of course, there's Kubernetes, which orchestrates and manages collections of containers. It was one of the first and best-known examples of projects that make containers truly useful for production use. However, more recently, the container ecosystem has truly exploded. A service mesh like Istio addresses many of the challenges faced by developers and operators as monolithic applications transition towards a distributed microservice architecture. A tracing tool like Jaeger analyzes what's happening as a transaction moves through a distributed system. Monitoring software like Prometheus captures time-series events for real-time alerting and other uses. Grafeas and Kritis provide security polic...
DevOpsSUMMIT at CloudEXPO will expand the DevOps community, enable a wide sharing of knowledge, and educate delegates and technology providers alike. Recent research has shown that DevOps dramatically reduces development time, the amount of enterprise IT professionals put out fires, and support time generally. Time spent on infrastructure development is significantly increased, and DevOps practitioners report more software releases and higher quality. Sponsors of DevOpsSUMMIT at CloudEXPO will benefit from unmatched branding, profile building and lead generation opportunities.