Showcasing

Noodles.dev

A community curated database of technologies and learning resources that help developers to learn software development.

Featured

Support all screen sizes

Although our target users mostly use big screen devices (at least 12 inches) we don't want to lose any user. Considering the cost/benefit we choose to support all screen sizes and implement a fluid design, real-time adaptive to viewport size changes.

Blazing fast loading and processing times (less than 1 second)

Frontend

We could have gone for Bootstrap but because we want the CSS bundle size to be as small as possible, we opt for creating a CSS file specifically for noodles.dev. Minimized Bootstrap file is 19kB while our custom .css file is almost half the size.

For interactivity on frontend we opted to use ReactJS mini-apps. This allowed to load the main ReactJS bundle only once while the individual mini-apps each have less than 30kB.

All static resources are served through a CDN service (Cloudflare) thus the initial resources loading times is considerably fast.

Backend

Whenever possible we are using Django inbuilt caching with Redis backend for serving content as fast as possible.

Processing full-text and aggregation queries would be very slow on SQL Databases, especially when searching through large amounts of data. PostgreSQL supports trigram indexing and is quite fast but is still not as powerful as Elasticsearch which is built specifically for fastest full text search. More on implementing Elasticsearch with PostgreSQL on the full text search section.

Speed Measurements:

  • Fulltext search in up to 0.5 million records in under 0.5s
  • 0.7s load time for homepage
  • 0.7s load time for searchpage
  • 99/100 score on Google PageSpeed

Bundle Sizes

  • 1 .css file of 10.8 kB in the top 10% of css bundle sizes < 14 kB
  • 3 .js files totaling 72.1 kB in the top 10% js bundle sizes < 108 kB)
Full text search through all content types

Processing full-text and aggregation queries would be very slow on SQL Databases, especially when searching through large amounts of data. PostgreSQL supports trigram indexing and is quite fast but is still not as powerful as Elasticsearch which is built specifically for fastest full text search.

Elasticsearch is a NoSQL database so data persistence is not as good as on using an SQL database. Noodles.dev uses a PostgreSQL instance for persisting all data but we want the searchable data to be passed on to the Elasticsearch instance running on AWS.

PostgreSQL and Elasticsearch synchronization

Through the clever usage of hooks to the django data models each time a resource is created,updated or deleted a background task is queued to synchronizes it to the Elasticsearch index. For queue management system we use the lightweight Huey python library.

Users can authenticate with facebook or google social accounts

Allowing users to easily authenticate makes for a pleasant user experience, especially when they can do so with just 1 click. Using an authentication library using OAuth2 specifications is both secure and easy to implement.

Using allauth django package

Noodles.dev uses allauth library for django. It supports a wide range of OAuth providers such as Facebook, Google, Github, Stackoverflow etc.

Collaborative editing of resources

Because the main selling point of Noodles.dev is the "community curated list of learning resources" we needed a way for the registered users to edit any resource type. For this purpose a modular django package was created. It can easily make any django data model to be transformed into a community editable resource.

Same mechanism as Wikipedia or StackOverflow

Any registered user can create an edit suggestion for a resource. After the edit suggestion is created, it can be voted by the other registered users. The edit can be published or rejected if a condition is met. In our project's case the condition is that the user should be either the resource owner, an user with a high positive score or a staff member.

If the edit is published, the edit owner receives a positive reward. More on that in the next section.

Reward system for contributing users

You can't have community creating or editing content without rewarding such behaviours somehow. Noodles.dev has a points/rewards system where each user has a positive and a negative score reflecting their actions.

Different type of actions give different rewards:

  • Creating a resource is the most rewarding
  • Getting an edit suggestion published
  • Owned resource gets voted up or reviewed
  • Review gets voted up

Proofing the rewards system

  • Voting on a resource, review or an edit suggestion can only be done once per user
  • An user can only review a learning resource once
Minimum running costs

We don't like waste resources but also hope that Noodles.dev will get millions of users. Until we become the next social network of developers unicorn app, we want to pay as little as possible while delivering the best experience.

Current capabilities for 16 USD/month:

  • Up to 25 000 users/day
  • Search through up to 1.2 milion records in under 0.5s
  • 0.7s load time for homepage
  • 0.7s load time for searchpage
  • 99/100 score on Google PageSpeed
Easily scaling up if neccessary

While i'm sure that the current capabilities are enough for a long time from now, when we'll be approaching the limits of the current set up the first steps towards scaling up will be:

  • Move to a server with more Cores/RAM
  • Move PostgreSQL to a separate server
  • Analyze the load on each subsystem and scale accordingly using a load balancer
  • Containerize each subsystem (main app, queuing management) and use a container orchestration like Docker-Swarm or Kubernetes to dynamically manage the traffic requirements

What’s your Project About?

We would love to know about your line of business and how we can help you grow!
Tell Us About Your Project