Next Gen Service Virtualization for Continuous Delivery and DevOps
Next Gen Service Virtualization for Continuous Delivery and DevOps
See how service virtualization and API mocking fit into DevOps and how they're becoming essential infrastructure for software teams.
Join the DZone community and get the full member experience.Join For Free
Do you need to strengthen the security of the mobile apps you build? Discover more than 50 secure mobile development coding practices to make your apps more secure.
On the 13th of September, 2017, more than 40 software development and testing enthusiasts interested in service virtualization, API mocking, and system simulation met at the Next Gen Service Virtualization Forum organized by WireMock and Red Hat Open Innovation Labs. There were also representatives from tool vendors including Curiosity Software Ireland, Hoverfly, MockLab, and Traffic Parrot, who contributed to the discussion on a panel. In this report, we will explore the highlights of the event. A full recording of the event is available online.
API Mocking Is Becoming a Critical Piece of Infrastructure for Software Teams
“I hate the term service virtualization. I spent years thinking it meant copying your services into a VMWare image.” -Tom Akehurst, WireMock
As part of the introduction, Tom Akehurst described service virtualization as “simulating the interfaces that your application depends on during testing, so that you can test more quickly and more effectively.”
Tom defined the practice by stating, “I use the term service virtualization and API mocking interchangeably, because I think conceptually I think they are the same thing. The terminology you use depends on whether you come from a big banking environment or the agile community.” He has also said that “Service virtualization or API mocking can be transformative to the performance of a software team. I think it’s an underused technique. Although there are old-world big expensive vendor tools that have been in the service virtualization space for best part of the decade and the ideas have not trickled down to people in other sectors. There is an emerging set of tools, some open source and some commercial, that are more modern in nature and tend to better fit with agile practices and play more nicely with other tools and not try to lock you in into a particular ecosystem. Getting more people doing [API mocking] would be a net positive for teams delivering software”.
How Do Service Virtualization and API Mocking Fit Into DevOps?
Hue Price shared a story about a successful project at a bank, where he used virtual MQ messages to reduce reputational damage. “If you look at most legacy systems, there are mainframes and there are MQ messaging systems. They [software teams at large enterprises] have no idea what’s in them. For example, for one bank client, we created pivot tables and showed them what they had [in the MQ messages]. They had masses of data but very little spread of the actual differences of the data. So, if you can actually fill in all the gaps and create those as virtual MQ messages, that means we would stop all of the bugs that result in reputational damage.”
Hue did raise a few issues with the current state of service virtualization. He noticed that the tools still need improvement: “How good is the [API mocking] tech? Pretty average. There is still a lot of hacking and editing. The tech is pretty clunky.” He also expressed a concern with how the tools are used: “A lot of the SI’s [Software Implementation outsourcing companies] like more inefficient products because they can make money out of them. They can add bodies to them and create a service. I’ve heard $200k to virtualize one service.”
Hue noticed that “DevOps is about keeping requirements, code, and tests as close as possible together. Service virtualization is part of the tests.”
Tools for Continuous Delivery Are Evolving
Wojciech Bulaty shared a story about his experience at a large bank and the lack of tools supporting messaging protocols that would not get in the way of Continuous Delivery practices. He described a time when there were open source tools that supported HTTP(S), but none that managed messaging, such as JMS or MQ. He said that led him to developing a new tool called Traffic Parrot that supports both HTTP(S) and messaging. It is designed for both test and development teams following the Continuous Delivery and DevOps practices.
Problems Today and the Future of Service Virtualization and API Mocking
The panel session discussions highlighted several key issues with service virtualization and API mocking today and generated a few ideas about where the industry might be heading and what the community should focus on.
Masking and Anonymization Is Still Hard
Hue Price and Dave Syer agreed that masking and anonymization of test data is hard. There are practices to approach the problem but the tools could help with it as well. They are also agreed that failure testing is becoming more and more important, especially in the world of microservices where there are more APIs that can fail.
Understanding Failure Scenarios Takes Time
Benji Hooper from Hoverfly noticed that “The hard part about virtualizing APIs is really trying to understand what part of the interaction with the dependency or a service are you actually testing. The happy case is always the easiest to work out, but trying to work out how many bad cases are there and what are they like is difficult”. He also remarked that he had a problem virtualizing a messaging service due to a lack of technology, but he is happy that tools like Traffic Parrot that support messaging virtualization are now available.
Tools Are Not Intuitive Enough
Dave suggested that “The tools aren’t actually that good. There is a lot of technology out there, but learning how to use it effectively is quite a challenge. Getting everybody up to speed with the practices is quite time-consuming,” to which Wojciech Bulaty from Traffic Parrot added that it's an especially important issue in large organizations where you have many developers and testers of various experience levels.
Record and playback has its place, but has to be used with caution. Hue and Wojciech agreed that record and playback of traffic has its applications, but has to be used with great care. Hue suggested that a better approach might be “Record and Analyze.” Tom added that record and playback is “one of those things that can gain you productivity in short term at the expense costing you a lot in the long term.”
Adoption Is Below Expectation
The panel agreed that the adoption of the practice is below its capability.
Benji shared a story that “The name [service virtualization] does not help. Most people I talk to have no clue, but after 2 minutes they get it. They are probably doing it already with some servlet. The name is too enterprise-like.” Wojciech added that “There are too many people that do not know that they do not know about service virtualization. We here as a community could take it to the next level and make them realize that they don’t know [about service virtualization] by having a 2-minute conversation with them.”
Changes in Delivering Software
Changes in software delivery and architecture are creating the pull for new tools. If you want to be able to develop at speed, you need tools to support it to stay competitive.
Service virtualization and API mocking are becoming more and more relevant in today's world of microservices and highly distributed systems. The move towards more Agile delivery models, moving away from mainframe and monolith development to more distributed microservice based systems requires new tooling. The next generation of service virtualization and API mocking tools, including Hoverfly, MockLab, Traffic Parrot and WireMock are making it easier and more affordable to create an effective software delivery process.
Opinions expressed by DZone contributors are their own.