I have a confession to make. I’m a product manager, not a software developer, but when I first decided to migrate my Windows eBook app to the cloud, I thought it would be easy to migrate all my source code. After all, I wrote my product using languages and frameworks that are wildly popular and supported by all the major cloud platforms. What I did not foresee was just how much work it takes to familiarize myself with cloud computing infrastructure, products, and development techniques. The good news is I hit a significant milestone this month.
Re-rethinking the architecture
As I already mentioned, I am less a developer and more of a product manager, but since this product is a labor of love, I write most of the code myself. It was interesting attending conferences from Amazon, Microsoft, and Google, to learn what other developers thought of my code and project.
Recently, at a cloud event here in San Francisco, I had three developers surrounding me. Each developer told me the ideal approach in which to convert my app. At some point, we started whiteboarding the approach. Fortunately, my original design was confirmed to be (generally) sound by all, but the specific implementation ideas were vastly different.
Side note: I’m not sure where this term monolithic came from, but I believe it stems from the AWS marketing machine as they push developers to move their code from one big (monolithic) app to smaller microservices (also termed serverless computing).
The worst thing you can do when programming is to do nothing, and I am not ashamed to admit that I spent too much time thinking and not enough time just doing. I forgot the reason I was able to release the original product was just to sit down, do some design, code, design again, code again, and just get through the iterations until things came together.
Easy looking stuff can be hard
My product produces eBooks for professional authors and publishers. Despite there being hundreds of writing tools on the market today, Microsoft Word is still the most popular, with estimates that 80 percent of all books start in Microsoft Word. That makes sense, because unlike Google Docs, Scrivener, Apple Pages, and other word processors, Microsoft Word comes from the print world and most authors like their books in print and eBook formats.
Naturally, the first step in the process is to get the book file(s) from a writer’s device and up onto the cloud for processing. To store a file in the cloud, you create a BLOB (binary large object) storage service. AWS calls their storage service S3 (simple storage service), and Microsoft calls their product Storage (or Azure Storage).
Looking at my API, you might think this is pretty straightforward as its job is simple: verify the user and shuttle files into BLOB storage all the while providing status back to the sender. Given the popularity of websites that allow you to upload pictures and documents, I thought this was going to be pretty easy. After all, there are thousands of examples scattered across blogs, YouTube videos, and Git repositories.
Getting there is half the battle
As it turns out, creating my API was not as easy as I thought. For example, before you even get started, you must set up your cloud environment to provide a secure login service. Of course, you can build your own security model, but I figure it is easier just to use what the cloud provider already offers. The next step is to set up the structure for how you will store the files and then you need to create the API (sort of a stub for where you will place your code).
Even though I used two very popular and proven technologies for my API and web page, those were not without some trial and error. For example, it turns out C# offers plenty of options to receive and manage files. After a lot of research, I am pretty sure my API uses best practices and is the most modern approach. Even though my initial API code taps in at around 100 lines of code, it uses a dozen different framework references.
As for the test website, it is just a basic wireframe at the moment but to make life easier I still had to use two different frameworks in jQuery and Bootstrap (to learn more about these two technologies, click here and here). The following image shows my still-very-early-stage website in action.
I am certainly a beginner at programming for the cloud, and my technical skills are building fast, but as you can see, planning out an app and delivering it can be quite an undertaking. My original estimation was three weeks just to get this far, and it took me two months (that’s less than part-time, mind you). If you are programming for the cloud or getting up to speed on the latest frameworks, do not underestimate the learning curve.
Catch up on Cloudifying my app
This article is part of a regular series where I share my experience migrating my Windows application to a cloud-based infrastructure. You can follow the series at this link.
Photo credit: Shutterstock