Monday, October 9, 2017

Flex5: A New Scalable Backend

Reposting this from our main company blog at:

Hello, everyone! This is Roger Diller, Technical Lead here at Flex. Let’s discuss Flex5 and its new scalable backend. This aspect is perhaps more important than the new UI as it lays down the foundation for Flex5.

We have been methodically crafting the Flex5 strategy for over a year now. It all began with the knowledge that Flash was on its way out and we needed to rewrite the UI in order to stay relevant. After quite a bit of discussion, we ended up on a “mobile first” strategy for two main reasons.

Adopting the mobile first strategy

First, we didn’t have a large mobile presence outside of our warehouse iOS app so gaining a stronger presence for mobile is important to us. Second, we knew that if we started with a less complex mobile UI, we could more easily focus on our design there, and then scale up to desktop vs the other way around. We decided to start with a tablet UI first and later move on to phone and desktop UI’s. It took a lot of work to come up with a UI design for tablet that would transition well to phone. By late spring of 2016, we had completed the brunt of the mobile design strategy. We began experimental coding of a tablet app and started a new REST API inside the existing Flex4 backend.

After our tablet UI design and app proof-of-concept success, we still had concern for the Flex4 backend. Could it stand up as a backend for the long-term? We weren’t sure. We thought we could possibly refactor our way to a faster and more scalable Flex4 backend. In the fall of 2016, we made substantial improvements to Flex4 performance, but we could see we weren’t going to be able to  reach the necessary level of performance to support future growth.

Rewriting the Flex backend architecture

It took some time to figure out a solid approach for rewriting the backend. How could we accomplish that without a risky all-or-nothing rewrite? In late 2016, we came up with a proof of concept Flex5 backend that would coexist with the Flex4 backend.

Let me take a moment and explain the key difference between the Flex4 & Flex5 backend. Flex4 was designed to run as one process per customer. This means we don’t have any way to run a second process for a customer to provide service redundancy in case one process goes down.

The Flex5 backend, on the other hand, is a cluster of at least two Flex5 processes that work together via a load balancer to provide the Flex service. This means one process can fail and the other process  will still be there to provide the service without the user knowing anything happened.

Improved reliability and performance

With this new architecture, we will be able to horizontally scale the Flex5 service. If demand goes up, we can add new application servers to the cluster to handle the load. This is huge and will allow us to support the high demand that Flex5 is going to bring. 

By early 2017, we gained confidence that the new backend was the way forward. We began to incrementally build new API’s in the Flex5 backend and simultaneously call “hard to rebuild” API’s in Flex4 (such as search and availability) until our schedule allows us to build them in the new backend.

We didn’t know it at the time, but later realized we were following the “strangler” rewrite pattern. It sounds kind of strange, but basically it means the new application grows beside or around an existing one and over time it takes over more and more of the work until eventually the old system is not used at all. This dramatically reduces risk and allows access to the new system much sooner and throughout the migration process. An important point I want to emphasize is that you will be able to use Flex4 & Flex5 side by side until the feature migration is complete. This means both systems point to the same database, so changes in one system are visible in the other.

This approach was working well but we were still missing one piece. We needed a way to coordinate events between Flex4 and Flex5. For example, if Flex5 saved a new inventory model, Flex4 was completely unaware that it was inserted into the database so its caches and search index were stale. In the Spring of 2017, we found an inter-process communication tool to solve this problem. The tool keeps each system aware of events happening in the other system and enables each system to respond to remote events.

The road ahead for Flex

In summary, all of the key pieces for shipping the tablet version of Flex5 are in place. We are still rounding out some less critical pieces, but we are getting closer and closer. We expect Flex5 to continue to gain momentum the rest of this year with 2018 being a year of heavy code lifting. It’s very exciting!

Saturday, August 19, 2017

Adobe Flash Withers as Flex 5 Comes to Life

Reposting this from our main company blog at:
Hello, everyone! This is Roger Diller, Technical Lead here at Flex. The purpose of this blog post is to briefly address the recent announcement from Adobe on ending updates for Adobe Flash at the end of 2020.
Some of you have likely already seen the Adobe announcement a couple of weeks ago that they are going to end Flash updates at the end of 2020; this is the official end of life date for Flash in terms of updates and support from Adobe. For us at Flex, this wasn’t a big surprise. We’ve known for years now that Flash’s days were numbered. Now, we have an exact date which is more than 3 years out, giving us a nice window to build out the Flex5 platform.
As you all know, we use Flash technology for our Flex4 frontend, so you will naturally have questions about our HTML5-based Flex5 timeline in light of the Adobe news. In short, we are already on the right path. The news from Adobe just validates the path that we have been hard at work on for the last year or so. Our development team is focused on completing the Flex5 tablet MVP (minimum viable product). We plan to begin incrementally rolling out Flex5 Tablet around the end of the year. From there, in 2018, we will have incremental updates going out for Flex5, some for tablet and phone but we plan to have some core desktop UI’s coming out sometime in 2018. The bulk of the UI transition will be completed in the next couple years well ahead of the end of 2020 Flash end of life date.
Not only are we reinventing the frontend and getting off the Flash platform, but we are also reinventing the backend as well. I plan to write about the Flex5 backend re-architecture soon in a separate blog post in the next couple weeks. In short, we have created an all new Flex5 multi-tenant backend that will run alongside the Flex4 backend for the next couple years. Eventually, all functionality will be migrated over, and the Flex4 backend will be decommissioned entirely. The new backend is designed to be faster, more scalable, and more reliable from the ground up and will serve as the foundation of the Flex platform for many years to come.
In summary, we are on a path to fundamentally transform the Flex product. From transitioning to HTML5-based UI’s for phone, tablet, and desktop to a new backend that will be able to handle the additional load that Flex5 will bring. We believe we will be entirely off the Flash platform well before the end of 2020.

Tuesday, March 7, 2017

Choosing a HTML5 Web Toolkit for Flex 5

We just posted "Choosing a HTML5 Web Toolkit for Flex 5" blog post on our main corporate site. In this blog, I talk about how & why we choose the HTML5 toolkit that we did and our "mobile first" approach to Flex 5.

The link is below. Enjoy!

Choosing a HTML5 Web Toolkit for Flex 5

Flex 5: Everything you’ve been wanting to know

We posted our first Flex 5 blog post on our main corporate website the other month. I'm re-posting the blog link here so that folks following this blog will be aware of it.

We plan to post all the Flex 5 blog series on the main corporate blog, and repost the links here. We will still post engineering blogs here, but since Flex 5 is an important topic to our customers, we wanted to post the Flex 5 blog series on our main website.

Without any further ado, here is first Flex 5 blog post:

Flex 5: Everything you’ve been wanting to know

Friday, January 20, 2017

We are hiring Full Stack Engineers!

We are hiring full stack engineers to help us build out the new Flex 5 platform! The job description is posted below. While the job description states we are seeking candidates that are close enough to Carlisle, PA to commute to the office once a week, we will consider candidates from anywhere in the United States if you have industry experience (e.g. you have used Flex software, worked in the AV industry, etc).

If you are interested or know somebody that is, please go to our job post at Indeed and apply asap!

Regarding Flex 5 development, we are planning to start a blogging series soon to flush out all the exciting things we have been doing with Flex 5 over the last while! Stay tuned!


Job Description

We are looking for developers to join our growing engineering team.
We are looking for developers to help build out our exciting next generation SaaS platform. Our engineering office is located in Carlisle, PA. We are looking for local or semi remote candidates with the ability to commute to Carlisle once a week.

Our developers work up and down the stack. We have developers that prefer backend or frontend development. We think it’s awesome to have a forte, however, all of our developers are expected to be able to work anywhere in the stack to get things done.

We integrate our code regularly and ship often. We believe in short incremental development cycles so we expect our developers to be committing code at least daily. Our next generation platform is being driven by automated tests and a continuous deployment philosophy. We expect developers to work autonomously, and want candidates with an ability to identify, communicate, and solve problems.

Skills & Requirements

You are fluent with the JVM ecosystem. You will write code in Groovy, Java, JavaScript, & SQL but you are open minded about other languages & ecosystems. You know something about ORM’s such as Hibernate and the tricky tradeoffs that come along with them. It is normal for you to not use the ORM for everything and write pure SQL for complex queries. You know something about Spring Boot and have coded on Spring applications before.

You are an avid unit tester. You already practice test driven development, primarily with unit tests. It is normal for you to commit code with accompanying unit tests. You are able to articulate principles of unit testing to other team members.

You view yourself as a software craftsman. You are constantly improving your craft and know how to stay relevant in the changing technology landscape. You embrace failure as a learning opportunity. You love collaboration and transparency. You look for simple solutions to complex problems.

You are self motivated. At Flex, we won’t tell you when to work. We just expect that you’ll love coding and will naturally have a bias towards getting things done.

You value agile & lean development. At Flex, we don’t subscribe to dogmatic views on agile processes. We happen to use some elements of Scrum but really we just value fast feedback, collaboration, quick iterations, test driven development, continuous integration & deployment.

About Flex Rental Solutions

Our team of dedicated engineers develops rental and event management software for over 600 business customers from all over the world. Our customers are primarily within the Professional Audio Visual, Concert Touring, Live Event, Staging, and Production market segments. Flex offers a flexible and dynamic work environment, opportunity to work on interesting projects and technical challenges, paid company holidays, paid vacation, and health, dental, and vision insurance, along with other benefits.