{"id":3170,"date":"2020-11-17T07:13:24","date_gmt":"2020-11-16T23:13:24","guid":{"rendered":"https:\/\/tzlee.com\/blog\/?p=3170"},"modified":"2020-12-01T21:31:01","modified_gmt":"2020-12-01T13:31:01","slug":"the-end-of-an-era","status":"publish","type":"post","link":"https:\/\/tzlee.com\/blog\/2020\/11\/the-end-of-an-era\/","title":{"rendered":"The end of an era, start of a new"},"content":{"rendered":"\n<p><a rel=\"noreferrer noopener\" href=\"https:\/\/www.whymobile.com\/\" target=\"_blank\">WhyMobile<\/a> launched the 3rd major revision of its website earlier this morning. But instead of talking about the new site, this is a little journal to reminisce how far it has come.<\/p>\n\n\n\n<p>A <a href=\"https:\/\/web.archive.org\/web\/20040406231342\/http:\/\/whymobile.com\/\">proof-of-concept site<\/a> was first built in April 2004. It was nothing more than a static site with an order mailer form that sends an email. The <a rel=\"noreferrer noopener\" href=\"https:\/\/web.archive.org\/web\/20040614224533\/http:\/\/www.whymobile.com:80\/\" target=\"_blank\">first version<\/a> launched two months later in June 2004. It was written in PHP 4.<\/p>\n\n\n\n<p>WhyMobile, therefore, was formally incorporated, and a lot of crazy things happened in the years that followed &#8211; including operating an outdoor push-cart in front of Plaza Singapura, to an outlet next to the durian stores in Geylang with &#8220;interesting&#8221; customers.<\/p>\n\n\n\n<p>The second version (cover image above) was built circa June 2008. It was written in PHP 5 and deployed as a single CentOS 5 VM. It was nothing fancy &#8211; no frameworks, no 3-tier architecture, no design patterns, nothing. Just plain old Apache, PHP, and a local instance of MySQL.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"600\" height=\"580\" src=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/img_0111.jpg\" alt=\"\" class=\"wp-image-3172\" srcset=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/img_0111.jpg 600w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/img_0111-300x290.jpg 300w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><figcaption>WhyMobile ran on a Sun Fire X2100 server (2nd from top) as a single Virtual Machine.<br \/><em>Photo taken Apr 2008.<\/em><\/figcaption><\/figure><\/div>\n\n\n\n<p>The Sun Fire X2100 server where it ran as a VM also had other VMs. The WhyMobile VM was only allocated 512MB of RAM out of the 4GB total on the entire server.<\/p>\n\n\n\n<p><em>(Noteworthy mention: The server ran VMware Server 1.0 on CentOS 5 + Software RAID.<\/em><\/p>\n\n\n\n<p>The crummy old Sun server ran and ran and survived a disk failure\/upgrade or two, until a time when Cloud services became more efficient and cost-effective. It was eventually wheeled out of the datacenter in August 2014.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"700\" height=\"525\" src=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/IMG_9672-700x525.jpg\" alt=\"\" class=\"wp-image-3173\" srcset=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/IMG_9672-700x525.jpg 700w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/IMG_9672-300x225.jpg 300w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/IMG_9672-768x576.jpg 768w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/IMG_9672-600x450.jpg 600w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/IMG_9672.jpg 800w\" sizes=\"auto, (max-width: 700px) 100vw, 700px\" \/><figcaption>The old Sun server (middle) was still working when it was pulled out.<br \/><em>Photo taken August 2014.<\/em><\/figcaption><\/figure><\/div>\n\n\n\n<p>So sometime in June 2014, the website moved to DigitalOcean. It ran on a base Ubuntu 14 instance with 1GB of RAM and remained that way for the next 6 years. Minor tweaks and adjustments were made as the business demands changed but never was it upgraded to a newer version of Ubuntu or PHP.<\/p>\n\n\n\n<p>Sometime between 2010 and 2018, there were also two &#8220;mobile&#8221; versions. The first version was based on a very early version of <a rel=\"noreferrer noopener\" href=\"http:\/\/www.iui-js.org\/\" data-type=\"URL\" data-id=\"http:\/\/www.iui-js.org\/\" target=\"_blank\">iUI<\/a>, and the second version based also on a very early version of <a rel=\"noreferrer noopener\" href=\"https:\/\/jquerymobile.com\/\" target=\"_blank\">jQuery mobile<\/a>. The mobile version was meant to be a super lightweight product catalog since the predominant connectivity was only 3G back then.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"700\" height=\"838\" src=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.07.26-AM-700x838.png\" alt=\"\" class=\"wp-image-3221\" srcset=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.07.26-AM-700x838.png 700w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.07.26-AM-251x300.png 251w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.07.26-AM-600x718.png 600w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.07.26-AM.png 750w\" sizes=\"auto, (max-width: 700px) 100vw, 700px\" \/><figcaption>&#8220;Mobile&#8221; version, circa 2011-2016 based on jQuery Mobile.<\/figcaption><\/figure><\/div>\n\n\n\n<p>But it was all written in PHP 5, and people have given me weird looks.<\/p>\n\n\n\n<p>&#8220;Really? PHP 5? Isn&#8217;t PHP slow?&#8221;<\/p>\n\n\n\n<p>No, sir. At its peak, the website was serving around a million page views a month. Remember: it had only 512MB RAM and was sharing it with a MySQL server. It never flinched.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"700\" height=\"220\" src=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-17-at-6.57.10-AM-700x220.png\" alt=\"\" class=\"wp-image-3176\" srcset=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-17-at-6.57.10-AM-700x220.png 700w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-17-at-6.57.10-AM-300x94.png 300w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-17-at-6.57.10-AM-768x241.png 768w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-17-at-6.57.10-AM-600x188.png 600w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-17-at-6.57.10-AM-945x297.png 945w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-17-at-6.57.10-AM.png 965w\" sizes=\"auto, (max-width: 700px) 100vw, 700px\" \/><figcaption>CPU barely inched past 4% while serving on average of 400k pageviews\/mth.<br \/><em>CPU chart from DigitalOcean, 17th November 2020.<\/em><\/figcaption><\/figure><\/div>\n\n\n\n<p>Remember &#8211; no bloatware, no frameworks, no nothing. It is a good reference for KISS.<\/p>\n\n\n\n<p>Still, I am amused that it ran for 12 years (2008-2020). Time flies.<\/p>\n\n\n\n<p>But by around 2017 I knew the website wouldn&#8217;t last much longer. Not because it wouldn&#8217;t continue to run (there were fair concerns on security, the evolving PDPA laws, and all that) but because many competitors had &#8220;upgraded&#8221; their websites, albeit sloppily, and I have been receiving feedback that the site looks dated.<\/p>\n\n\n\n<p>I had embarked on several attempts to revamp the website between 2017-2019 but failed. I spent quite a fair bit of time evaluating various PHP frameworks (CI3, Laravel). I was mucking around and having a war with the ORM, and eventually arriving back at square one.<\/p>\n\n\n\n<p>Building the site has always been a one-man-show. A small business like WhyMobile will never be able to afford the skyrocketing salaries of Software Developers in Singapore. I was essentially paying myself over the years, and I &#8220;owe&#8221; the business an overdue revamp.<\/p>\n\n\n\n<p>With kids and a hectic work schedule, the revamp never happened&#8230; until 2020.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"700\" height=\"402\" src=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/960x0-700x402.jpg\" alt=\"\" class=\"wp-image-3211\" srcset=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/960x0-700x402.jpg 700w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/960x0-300x172.jpg 300w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/960x0-768x441.jpg 768w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/960x0-600x344.jpg 600w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/960x0-945x543.jpg 945w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/960x0.jpg 958w\" sizes=\"auto, (max-width: 700px) 100vw, 700px\" \/><\/figure><\/div>\n\n\n\n<p>2020 came. COVID-19 came. I would be kidding if I said the business wasn&#8217;t affected.<\/p>\n\n\n\n<p>During the Circuit Breaker, it wasn&#8217;t too bad. Then the trickle-down effect started to become apparent in Q3 2020.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"700\" height=\"509\" src=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/L1030109-700x509.jpg\" alt=\"\" class=\"wp-image-3214\" srcset=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/L1030109-700x509.jpg 700w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/L1030109-300x218.jpg 300w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/L1030109-768x559.jpg 768w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/L1030109-600x437.jpg 600w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/L1030109.jpg 800w\" sizes=\"auto, (max-width: 700px) 100vw, 700px\" \/><figcaption>Barely any foot traffic in Far East Plaza.<br \/><em>Photo taken 12th October 2020.<\/em><\/figcaption><\/figure><\/div>\n\n\n\n<p>I knew we had to do something to embrace the new work-from-home, shop-from-home, stay-at-home, die-at-home culture. I bit the bullet, picked a framework, committed to it, and then spent almost every single weekend of my spare time working on the code. Son&#8217;s at a  class? I&#8217;m coding. Son&#8217;s taking a nap? I&#8217;m coding. Son taking a poop? Coding.<\/p>\n\n\n\n<p>The launch of version 3 was intended to be past midnight on Monday 16th November 2020, but AWS was giving me grief about getting SES going in production mode.<\/p>\n\n\n\n<p>It was resolved the next day, and here we are, Tuesday 17th November 2020 at 01:00 hrs.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"700\" height=\"428\" src=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.26.09-AM-700x428.png\" alt=\"\" class=\"wp-image-3222\" srcset=\"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.26.09-AM-700x428.png 700w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.26.09-AM-300x184.png 300w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.26.09-AM-768x470.png 768w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.26.09-AM-1536x940.png 1536w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.26.09-AM-2048x1253.png 2048w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.26.09-AM-600x367.png 600w, https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-18-at-4.26.09-AM-945x578.png 945w\" sizes=\"auto, (max-width: 700px) 100vw, 700px\" \/><figcaption>Home page of WhyMobile 3.0, launched 17th November 2020.<\/figcaption><\/figure>\n\n\n\n<p>And for the record&#8230;<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code># cat \/etc\/issue.net \nUbuntu 14.04.5 LTS\n\n# php -v\nPHP 5.5.9-1ubuntu4.26 (cli) (built: Sep 17 2018 13:46:30) \nCopyright (c) 1997-2014 The PHP Group\nZend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies\n    with Zend OPcache v7.0.3, Copyright (c) 1999-2014, by Zend Technologies\n\n# mysql -V\nmysql  Ver 14.14 Distrib 5.5.62, for debian-linux-gnu (x86_64) using readline 6.3\n\n# uptime\n 07:09:19 up 973 days,  8:02,  1 user,  load average: 0.00, 0.01, 0.05\n\n# shutdown -h now<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>WhyMobile launched the 3rd major revision of its website earlier this morning. But instead of talking about the new site, this is a little journal to reminisce how far it has come. A proof-of-concept site was first built in April&#8230; <a class=\"more-link\" href=\"https:\/\/tzlee.com\/blog\/2020\/11\/the-end-of-an-era\/\">Continue Reading &rarr;<\/a><\/p>\n","protected":false},"author":2,"featured_media":3171,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[8],"tags":[407,158,480],"class_list":["post-3170","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tech","tag-business","tag-php","tag-whymobile"],"jetpack_featured_media_url":"https:\/\/tzlee.com\/blog\/wp-content\/uploads\/2020\/11\/Screenshot-2020-11-17-at-5.52.09-AM.png","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/posts\/3170","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/comments?post=3170"}],"version-history":[{"count":61,"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/posts\/3170\/revisions"}],"predecessor-version":[{"id":3244,"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/posts\/3170\/revisions\/3244"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/media\/3171"}],"wp:attachment":[{"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/media?parent=3170"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/categories?post=3170"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tzlee.com\/blog\/wp-json\/wp\/v2\/tags?post=3170"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}