How Cajoo Migrated From Shopify in 4 weeks with Hasura Cloud
Cajoo is a French direct-to-customer delivery app that delivers fresh groceries in 15 minutes (from when the order is placed to the customer's doorstep). It's one of the fastest-growing startups in Europe, gaining over 100,000 users in less than nine months and recently raising $40 million in funding.
95% monthly cost savings
Four weeks from concept to production with three engineers
Excellent performance that automatically scales to meet client demand
Cajoo needed more flexibility and performance
Cajoo's development team needed to move fast as an early-stage startup.
Their initial technical architecture included a React Native mobile app connected to Shopify as their ecommerce backend (their order management system), a third-party warehouse management system, a third-party courier delivery application, and a Nest JS API hosted in Heroku to connect all these systems and handle user authentication.
As their customer base grew, they started to observe performance and flexibility bottlenecks affecting user experience and decided to redesign their tech stack to cater to their custom scenarios and meet business demands. The challenges Cajoo faced with the initial tech stack included:
Slow data fetching
Cajoo needed to manage different stock quantities per warehouse, which Shopify struggled with. To work around it, they included the warehouse stock information in the product meta field and left the client to handle the filtering. But as the number of warehouses and products increased, fetching product data became cumbersome and slow, leading to slower app response time and a poor user experience.
Small development team
Cajoo's team needed to stay lean and iterate quickly on new features. The engineers needed to be flexible enough to work on and understand all layers of their system — database, backend, integrations, and the frontend web UI.
Limited architecture flexibility
The Cajoo team needed features which the Shopify API did not natively offer. In addition, they wanted to avoid the rate-limiting on Shopify APIs, which caused their application to struggle, especially during peak periods.
The Cajoo team wanted to move away from overreliance on third-party proprietary software. Building in-house order management and warehouse inventory software meant they had complete control of the technology supply chain.
As a team of full-stack developers, we realized that we only had to focus on the frontend because Hasura took care of most of our backend work.
Co-founder and CTO, Cajoo
Hasura Cloud provides more control and flexibility
As Cajoo started investigating solutions to the challenges above, they discovered Hasura while browsing Hacker News and decided to try it out. They migrated their entire ecommerce backend from Shopify to their proprietary in-house software in four weeks with just three engineers.
The Cajoo team settled on Hasura because it provided features such as instant GraphQL APIs on their databases, subscriptions, aggregates, and event triggers that aligned with the direction of their future tech stack.
Cajoo’s new tech architecture
Ease of use
Hasura's intuitive user interface and documentation made it easy to set up and connect their Postgres database, making their data instantly accessible over GraphQL APIs. Hasura also took care of their API data layer, allowing them to focus on architecture and custom business logic while saving them development and maintenance time.
Hasura offered the flexibility and control Cajoo was seeking, as it is open-source and can be run locally or in the cloud. It can also connect to a private database instance so Cajoo can essentially control its data and avoid third-party vendor lock-ins.
Security and authorization
Hasura provided built-in security and authorization capabilities, which allowed for a role and user-based authorization down to the individual column and row level. Having this feature out-of-the-box saved Cajoo development time and ensured security was baked right into every application's data layer.
Subscription and aggregates
Hasura provided out-of-the-box support for subscriptions and aggregates. Cajoo could implement real-time delivery tracking with subscriptions, so the client's screen gets updated anytime there's a change to the order status. Having aggregates automatically generated with the GraphQL API meant the backend could easily carry out queries such as order counting and filtering with a single line of text.
Cajoo's infrastructure relied heavily on events such as notifying the client via email when an order was placed and notifying warehouses via Slack to let them know the new order was to be fulfilled. Hasura offered a reliable and easy way to create event triggers on specified tables and invoke webhooks (like listening to Stripes API for payment success) to carry out business logic.
Cajoo also utilized Hasura Event Triggers and webhooks to provide real-time integrations to the multiple AWS Lambda functions they're using.
“Hasura reduced our client data fetching time from 10 seconds to less than 1 second, which greatly improved the user experience.”
Co-founder and CTO, Cajoo
“Hasura saved us so much time when building our backend”
Co-founder and CTO, Cajoo
Cajoo cut infrastructure costs by 95% and improved product load time
Utilizing Hasura for their ecommerce backend worked so well they then replaced other pieces of their stack using the same architecture: their warehouse management system and the courier delivery application.
Some of the other benefits they attributed to using Hasura include:
Improved application performance
Cajoo saw improved performance on their client's applications after implementing Hasura. The client's data fetching time improved from 10 seconds to load all products in a category to less than 1 second, which greatly improved customer experience and kept customers from bouncing off a page that took too long to load.
Faster development time
Hasura's simplified GraphQL data fetching architecture made it easy to add new features in less time. Cajoo was able to migrate their ecommerce backend from Shopify in less than four weeks and roll out their custom delivery tracking application in less than a month because of the speed at which Hasura helped them operate.
Cajoo experienced significant cost savings with Hasura. Monthly infrastructure costs went from over $2,000 to just $100 with Hasura (about a 95% reduction in cost).
Hasura enabled Cajoo to move to a cleaner and more reliable application architecture. They could migrate to a serverless architecture using AWS Lambda with a one-on-one relationship to Hasura event triggers, helping them encapsulate their business logic and keep it separate from the delivery mechanism. Moving to Hasura gave Cajoo more flexibility with its technical architecture, allowing them to quickly adapt to changing technology and interfaces.
Less reliance on third-party proprietary software
Hasura enabled Cajoo to quickly replace their third-party warehousing and Courier delivery software with in-house custom software, which gave them more control of their tech stack.
What’s Next for Cajoo
Cajoo has experienced tremendous growth in both users and employees in the past year and still has ongoing expansion plans. The development team started with just three developers and has grown to 15-20 developers.
The Cajoo team continues to work closely with Hasura to improve developer tooling and boost developer productivity even as they continue to innovate and improve their product offerings.
Visit Cajoo website