LinkedIn is making a pretty important tool available for the masses — or more accurately, for the developer community. The company is open sourcing Flashback, a tool for mocking Internet traffic for developer tests, under a BSD two-clause license. The company developed the said tool in its pre-Microsoft days for testing purposes.
So here is the thing: LinekdIn creates a lot of new features and updates pre-existing ones. In such situation, the company uses the Flashback tool to test things like reliability, scalability and so on, before it rolls the feature out before the general public.
The Flashback tool was based upon Betamax, which helps in the creation of tools that can create situations that would be encountered in a regular day with the Internet. However, Flashback is an improvement over Betamax. While the latter mocks the actions of web services and REST APIs in developer tests by “intercepting HTTP connections initiated by a web application, and then later replaying them”, Flashback can work in isolated environments as well.
So basically, the system does not require Internet connectivity and can be used for testing purposes even in isolated environments.
Flashback is designed to mock HTTP and HTTPS resources, like web services and REST APIs, for testing purposes. It records HTTP/HTTPS requests and plays back a previously recorded HTTP transaction—which we call a ‘scene’—so that no external connection to the internet is required in order to complete testing.
This is absolutely vital when you need to perform tests when Intener connectivity is not allowed. Take LinkedIn for instance, the company can not conduct tests while being connected to the Internet every time.
Why? Because of the fact that LinkedIn’s test environment does not have Internet access for security reason. This is where Flashback comes in and now, LinkedIn has open sourced the tool with the intent of allowing other developers access to the same facilities.
We’d like to see if we can support non-HTTP protocols, such as FTP or JDBC, in the future, and maybe even give users the flexibility to inject their own customized protocol using the MITM proxy framework. We will continue improving the Flashback setup API to make it easier to support non-Java languages.