Systems | Development | Analytics | API | Testing

Rails

How to build your own user authentication system in Rails

When building an app, you'll probably need to handle user authentication in one form or another. In Rails applications, several pre-built libraries and gems make it a breeze to build user authentication including well-known libraries like Devise, Doorkeeper and OmniAuth. These libraries work well out of the box, but there's a caveat, as developers must follow certain configuration and design rules for each library.

Handle Incoming Webhooks with LiteJob for Ruby on Rails

In parts one and two of this series, we only dealt with the pure CRUD aspects of using SQLite as a production database. In this post, we will explore the world of queue mechanisms, using SQLite as the pub/sub adapter for ActiveJob. Let's make use of LiteJob to handle incoming webhooks in our Rails application.

How to organize your code using Rails Concern

There is a strong chance you’ve encountered Rails Concern if you’ve been using Rails for a while. It can be confusing to understand where it fits into your Rails application and how best to make use of it. This is what we’ll be covering in this tutorial: what Rails Concerns are, why they exist, and their use cases.

A Deep Dive Into LiteDB for Ruby on Rails

In the second post of our series covering LiteStack (an alternative way to build Rails applications entirely based on SQLite), we'll explore the database's concepts of flexible typing and type affinity. We'll not only discover how SQLite's data handling differs from other SQL databases, but also how we efficiently process and store binary data, like images, directly in a database column. Note: LiteDB is essentially SQLite, but fine-tuned for usage in Rails.

FactoryBot for Rails testing

In the Ruby community, there's near-unanimous agreement on the importance of testing. Tests act as a safeguard, ensuring that the digital experiences we craft remain consistent, reliable, and of high quality. Many in the Ruby community claim that no code change is complete without tests. They are an integral part of the development workflow. Regular testing ensures that new features, refactors, or bug fixes do not introduce unforeseen issues or regressions.

Using Action Policy for a Ruby on Rails App: The Basics

To keep your app secure, you need to control who and what can access it. Access control can be categorized into authentication — "who" to allow — and authorization — "what" they can access. Authentication is a subject for another day, but when it comes to user authorization, you generally have two ways to go about it: using a role-based or resource-based strategy. In this two-part series, we'll take a deep dive into using the Action Policy gem for a Ruby on Rails blog application.

An Introduction to LiteStack for Ruby on Rails

In this series of posts, we will look at LiteStack, a one-stop-shop solution that hosts and processes all your production data on a single machine. LiteStack (as the name suggests) makes use of SQLite to provide: In this first post, we'll introduce the basics of LiteStack and set up an example Rails application. Let's begin!

An Introduction to Sidekiq for Ruby on Rails

Sidekiq allows Ruby developers to maintain fast and responsive web applications by moving time-consuming tasks into the background. With multithreading at its core, Sidekiq can process many jobs at once. This makes Sidekiq an important part of Ruby or Rails applications that handle heavy loads or perform tasks like sending emails or processing files.