Blackfire.io: What’s next? Continuous Integration for all!

By Christophe Dujarric, on Oct 06, 2015

If you follow this blog on a regular basis, you’ve probably read a few weeks ago that we were proud to release the v1.0 of Blackfire, and the assertions feature.
Now it’s time to unveil what’s coming in the next few months.

Performance impacts user experience… and engagement

3 seconds is the time it takes for a user to get frustrated by a page load. After that, most users go away. Forever. If your apps are not fast enough, you will lose both customers and revenue. That’s why performance optimization is key to success.

Application performance management until today

Nowadays, development teams try to give more focus to quality during the development cycle. They setup unit tests, continuous integration environnements,… But performance testing is still overlooked because nobody has time to spend on it, not even QA teams. Actually, they don’t have the right tools.

Application Performance Monitoring tools have done a great job since a few years, enabling production teams to be warned when something is going wrong, so that they can react fast and correct issues. By monitoring all requests, they were able to draw out stats and alerts. But deep code performance analysis cannot be done for each and every request without an overhead which isn’t acceptable on production websites. And therefore, APMs can’t tell you why something is going wrong and how to fix it.

That’s what profilers are here for. They enable to drill down to the function level and understand where resources are spent in terms of time, memory, SQL… Blackfire.io of course has roots in tools such as xhprof and XDebug.

But we also made it better by offering a cleaner visualisation, easier installation, lower overhead making it possible to profile single requests on production websites, and collaboration features to make it Enterprise-ready.

Now on top of this, add a comprehensive integration into the developer workflow, and you have the Blackfire’s vision.

Blackfire.io helps you continuously improve your app’s performance

Throughout the development lifecycle, Blackfire will automatically check your app’s performance based on your technical and business requirements, alert you when something isn’t in line, and give you all of the details to help you correct it even before you release to production.

Assertions

Assertions are a way for you to set your very own expectations on performance for your app and to check code behavior at runtime. Defining assertions for your code is as simple as adding a simple .blackfire.yml file to your repository.

An assertion is an acceptance criteria based on profile data. It can use main costs such as the wall time or the CPU time, or a metric cost like the number of SQL statements executed (list available here). And it goes even further as you can also define custom metrics, based on your code and your business context.

Assertions can also set the maximum deviation allowed when comparing two profiles; so you can check on your app’s performance evolution!

Performance Tests

Based on metrics and assertions, the next version of our PHP SDK will also let you write Performance Unit Tests with PHPUnit or any other testing libraries.

Integration Tests

The next step is to extend the use of the .blackfire.yml file to let you easily write test scenarios. A test scenario is a typical user session you want to run assertions on. Those scenarios will be automatically triggered, for instance whenever you will deploy to production, or push some new code as a pull request on Github. Finally, Blackfire will notify you if a scenario fails via email, Slack and more.

We’re already alpha testing those features, so stay tuned for more information in the coming weeks!

Happy profiling!

Christophe Dujarric

Christophe is the Chief Product Officer at Blackfire. He's an engineer, but probably one of the least "tech" people in the company. He's wearing many hats, from product management to marketing and sales. He loves the beauty of simple solutions that solve actual problems.