---
title: "Architecture"
description: "834 posts about Architecture, summarised, each linking to the original."
---

# Architecture
> 834 posts about Architecture, summarised, each linking to the original.

## Articles

### [The Data and Science Behind GrabShare Part I: Verifying Potential and Developing the Algorithm](https://yomu.fyi/post/the-data-and-science-behind-grabshare-part-i-verifying-potential-and-d.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Tang Muchen
- Published: Oct 20, 2017
- Type: Problem & solution

Expanding from point-to-point dispatch services to dynamic carpooling requires matching independent passenger requests traveling in similar directions without causing unacceptable delays. Grab evaluated the feasibility of its GrabShare service by analyzing historical trip data with DBSCAN clustering on coordinates projected into a Universal Transverse Mercator system. This analysis demonstrated that 35% to 46% of rides across typical daytime windows fell into tight geographic clusters with near-identical pickup and drop-off coordinates. The resulting matching framework adapts the baseline dispatch flow by searching for in-transit drivers and enforcing real-time seat reservation constraints. Route assignment decisions subsequently evaluate detour times, trip angles, and expected arrival times to ensure driver utilization improves while total driving distance decreases.


### [Evolution of the Heroku CLI: 2008-2017](https://yomu.fyi/post/evolution-of-the-heroku-cli-2008-2017.md)
- Company: [Heroku](https://yomu.fyi/company/heroku.md)
- Author: Jeff Dickey
- Published: Aug 15, 2017
- Type: Explainer

Between 2008 and 2017, Heroku's CLI evolved from Ruby (v1–v3) through Go/Node versions v4 and v5 to a pure Node v6 implementation. The rewrite addressed slower Windows performance, separation of the CLI's runtime from users' Ruby environments, migration to API v3, and limitations in Ruby-based plugin dependencies. V4 kept existing command syntax and output while adding features such as non-TTY color suppression and --json output; its Go core used Node for plugins, and the CLI became a collection of core plugins that could also be developed and installed independently. The team migrated commands incrementally, then added Flow, Babel, and improved tests, including Jest tests that run the flag parser. The resulting foundation supports modular, tested feature development, with cli-engine and more interactive interfaces planned.


### [Grab's Front End Study Guide](https://yomu.fyi/post/grab-s-front-end-study-guide.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Yangshun Tay
- Published: Jun 3, 2017
- Type: Explainer

Rapid hiring and engineering expansion created a steep learning curve for newcomers and backend engineers unfamiliar with modern web architecture. Grab created an opinionated front-end study guide to help engineers navigate JavaScript tooling, state management, and modern application practices. The guide frames client-side single-page applications as a scalable alternative to traditional server-side rendering, enabling clear client-server separation for multiple client apps hitting the same backend API. It establishes core competencies in ECMAScript 2015 via Babel and explains how component-driven interfaces in React improve maintainability and performance through virtual DOM reconciliation. Ultimately, the resource aims to ramp up developer onboarding and accelerate shipping speeds across web platforms.


### [Driving Southeast Asia Forward with AWS](https://yomu.fyi/post/driving-southeast-asia-forward-with-aws.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Arul Kumaravel
- Published: May 21, 2017
- Type: Explainer

Grab transitioned its transportation platform from a single Ruby on Rails monolith on Amazon EC2 and Amazon RDS MySQL to a microservices architecture hosted on Amazon Web Services. The platform processes multi-petabyte real-time data flows and hundreds of millions of GPS data points to match drivers with passengers and push proactive demand heat maps. Operational efficiency is sustained with fewer than ten full-time infrastructure engineers, supported by AWS managed services. The analytics backend also transitioned from MySQL to Amazon Redshift, eventually moving to an Amazon S3 data lake using Amazon EMR and Presto. These data-driven matching systems improved driver-passenger allocation rates by up to 30%.


### [How to Go from a Quick Idea to an Essential Feature in Four Steps](https://yomu.fyi/post/how-to-go-from-a-quick-idea-to-an-essential-feature-in-four-steps.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Da Huang
- Published: May 16, 2017
- Type: Problem & solution

Grab engineered an in-app messaging platform, GrabChat, to help drivers and passengers coordinate pickups across Southeast Asian markets characterized by weak 2G connectivity and high packet loss. The team developed an in-house TCP messaging architecture consisting of a TCP gateway named Gundam and a message dispatcher named Hermes connected to internal backend services over HTTPS. To protect backend server resources from resend loops during poor connection states, the communication protocol adopts a "server only push once" model that delegates retry handling to the client. Data science evaluations using a pre-trained cancellation prediction model confirmed that GrabChat adoption correlated with reduced booking cancellations. Following early usage feedback, the team further iterated on the feature by introducing pre-written message templates to reduce driver distraction on the road.


### [Scaling Like a Boss with Presto](https://yomu.fyi/post/scaling-like-a-boss-with-presto.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Aneesh Chandra
- Published: May 1, 2017
- Type: Problem & solution

Grab experienced severe performance degradation, long queue times, and connection timeouts on its Amazon Redshift analytics cluster as user concurrency and reporting workloads expanded. Although an initial Amazon S3 data lake decoupled storage from compute, business users required standard SQL interfaces rather than Spark data pipelines. The team deployed Presto clusters on AWS EMR, switching their storage format from AVRO to Parquet to support ANSI SQL querying directly against S3. Utilizing a shared Hive metastore on Amazon RDS allowed Grab to adopt a shared-data multi-cluster architecture that isolated distinct workloads across dedicated compute clusters. This setup enabled rapid cluster scaling, streamlined failover, and matched Redshift performance on partitioned time-range queries.


### [Why you should co-locate your Xcode tests](https://yomu.fyi/post/why-you-should-co-locate-your-xcode-tests.md)
- Company: [Kickstarter](https://yomu.fyi/company/kickstarter.md)
- Author: Brandon Williams
- Published: Mar 23, 2017
- Type: Problem & solution

Xcode projects with unit tests commonly separate implementation and test files into two directories, often mirroring the source structure in the tests directory. The post argues that this arrangement creates maintenance overhead, slows navigation, obscures how well-tested a codebase is when browsed or reviewed, and can leave tests with lower coding standards. It proposes co-locating each unit-test file beside its implementation file while retaining the test target association, accepting more files per directory in exchange for clearer relationships and easier movement between code and tests. The same SwiftLint configuration is used for implementation and test code, treating tests as first-class code. Tests without a single-file correspondence, including integration or UI tests, should remain in separate directories and may warrant separate targets; the authors say their codebase has adopted the style.


### [Grab Vietnam Careers Week](https://yomu.fyi/post/grab-vietnam-careers-week.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Grab Engineering
- Published: Oct 14, 2016
- Type: Announcement

Grab announced its first Grab Vietnam Careers Week, held in Ho Chi Minh City from 22 to 26 October 2016, aimed at hiring engineers to improve regional transportation and reduce congestion. At the time, Grab operated on 23 million mobile devices supported by 460,000 drivers across Southeast Asia. The announcement features an interview with Singapore-based iOS engineer Hai Pham and Android engineer Son Nguyen discussing team culture, regular hackathons termed "Grabathons", and relocation to Singapore. Technical candidates undergo a Codility test and are evaluated on clean mobile architecture, testing, and performance maintenance. The engineers also offer advice on apartment hunting through online community forums and adapting to life in Singapore.


### [Round-robin in Distributed Systems](https://yomu.fyi/post/round-robin-in-distributed-systems.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Gao Chao
- Published: Sep 27, 2016
- Type: Explainer

Building client-side load balancing for Grab's Common Data Service prompted a move from AWS Elastic Load Balancers to DNS discovery due to persistent connection issues and unpredictable scaling events. After patching an open-source library that failed to rotate IP sequences properly, the author evaluated different Go patterns for round-robin routing. A mutex-protected array counter provides the simplest model for basic retrieval, though adding mutations requires careful lock coordination. Alternatively, a dedicated balancer goroutine receiving requests over nested channels enables explicit operation timeouts and centralized event handling at the cost of higher code complexity and channel creation overhead. The author recommends the mutex approach for resource fetching and the goroutine-based design for workload balancing.


### [Programmers Beware - UX is Not Just for Designers](https://yomu.fyi/post/programmers-beware-ux-is-not-just-for-designers.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Corey Scott
- Published: Jul 5, 2016
- Type: Explainer

Software engineers frequently overlook user experience when designing APIs, SDKs, and code-level functions. Usability issues arise across various technical interfaces, from mobile apps forced to coordinate multiple round-trip network calls to ambiguous function signatures that obscure boolean arguments. To counter this, engineers can apply a five-question discovery framework to identify user identity, core objectives, user capabilities, ways to reduce user burden, and familiar paradigms. Practical remedies include sacrificing strict RESTful separation to merge mobile endpoints, placing validation logic inside internal RPC servers, and replacing boolean arguments with explicitly named helper functions. Ultimately, treating calling systems, end users, and fellow programmers as users shifts implementation complexity from consumers to servers.


### [Grab You Some Post-Mortem Reports](https://yomu.fyi/post/grab-you-some-post-mortem-reports.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Lian Yuanlin
- Published: Feb 4, 2016
- Type: Problem & solution

Grab describes how its service-oriented architecture makes cross-team production debugging difficult because engineers may lack familiarity with other teams’ code and architecture. Post-mortem reports are presented as the glue for shared understanding, but a sample incident entry lacks service context, bug detail, impact, chronology, and investigation steps. The proposed standard has four requirements—Chronology, Context, Empowerment, and Solutions—covering timelines, service internals, blameless educational diagnosis, and remedies across People, Product, and Process. A template includes initial symptoms, a timestamped timeline, log-based investigation with code evidence, temporary and permanent fixes, and improvement actions, while peer review by another team is required before finalization.


### [Introducing Heroku’s React Refetch Operations Console](https://yomu.fyi/post/introducing-heroku-s-react-refetch-operations-console.md)
- Company: [Heroku](https://yomu.fyi/company/heroku.md)
- Author: Ryan Brainard
- Published: Dec 16, 2015
- Type: Announcement

Heroku built an operations console for Private Spaces to provide a bird’s-eye view of the platform and detailed investigation of individual spaces. It is a single-page React application backed by a reverse proxy, but its constituent applications originally used jQuery state, mixins, or classic Flux. The team considered Redux, then rejected a global store for server-rendered data because application state was already represented in the URL. React Refetch instead maps component props to remote requests, injects immutable PromiseState props, and recalculates requests when URL parameters change. Its declarative model removes stores, callbacks, actions, reducers, and switch statements while supporting composed and chained requests, periodic refresh, custom headers and methods, lazy loading, and server writes; the team presents it as a simpler alternative when client-side state need not persist.


### [Heroku Proxying becomes Free Software](https://yomu.fyi/post/heroku-proxying-becomes-free-software.md)
- Company: [Heroku](https://yomu.fyi/company/heroku.md)
- Author: Fred Hebert
- Published: Oct 21, 2015
- Type: Announcement

Heroku’s HTTP routing stack has three layers: state synchronization, request routing, and HTTP proxying. The platform team open-sourced the proxying layer as Vegur, an Erlang library that validates, normalizes, and forwards requests between clients and dynos. Unlike a conventional nginx reverse proxy, Vegur’s hosts and configuration are fully programmable, allowing state from hardcoded values, files, databases, or direct updates, while routing algorithms and debugging headers can also remain dynamic. Its delegated capabilities include domain lookup, backend selection, interface choice, resource checkout and checkin, customizable failure pages, per-application or per-backend controls for tunneling 100-continue requests, and upstream or downstream header insertion. Vegur had run in production on Heroku for over a year and powered the Heroku Private Spaces router.


### [Django and Node together on Heroku](https://yomu.fyi/post/django-and-node-together-on-heroku.md)
- Company: [Heroku](https://yomu.fyi/company/heroku.md)
- Author: David Gouldin
- Published: Oct 29, 2014
- Type: Problem & solution

Django-based Heroku Connect needed realtime dashboard support through socket.io and Node.js, but Heroku apps could route traffic through only one dyno type. The team chose to run both stacks in one dyno using a runit buildpack and its sub-Procfile format: Node binds to PORT, while node-http-proxy forwards normal web requests to Gunicorn-hosted Django on 127.0.0.1:$DJANGO\_PORT. This arrangement increases contention because processes share memory, CPU, and a filesystem, and it makes dyno logs less directly attributable; the team also flattened Procfiles into Procfile.local for Foreman-based local development. After running the architecture in production for a few months without issue, the team reported minimal proxy overhead and retained single-git-push deployment while establishing a path for websocket communication.


[Newer posts](https://yomu.fyi/topic/architecture/page/41.md)
