How Indexes on database works!

When it comes to performance of an application, databases are highly important and effective. And one of the key factor in database o...

Read More

All Stories

Rails 6.1 - adds defaults value to enum

How do we define enums? Pretty much like

In Rails, New addition, enum, Jul 04, 2020

Rails 6 - Managing API keys using 'credentials'

How do you manage application secret keys? We cannot commit them in Version Control System (like github), it is too dangerous.

In Rails, API keys, Secrets, Jul 04, 2020

Setting up Rails Performance dashboard with influxdb and grafana

When application gets stable at some point, we try to improve things we built for a while now. And improving performancetops the list for me. Application performance is a large concep...

In Rails, influxdb, grafana, APM, May 02, 2020

Reset primary key sequence

Resetting primary key sequence in Rails can be achieved by simply calling method reset_pk_sequence! on ActiveRecord with table_name.

In Rails, Postgres, Database, Apr 16, 2020

Error in logging! Rails log to STDOUT

Logs play important role in debugging application. Rails comes with six levels of logging :debug, :info, :warn, :error, :fatal, and :unknown. These logs are generally written to Rails...

In Rails, logs, Short Blog, Mar 27, 2020

Sending Email from Rails

Sending email is integral part of every web application nowadays. In this post we will cover how to send emailsfrom a rails application.

In Rails, Email, Mar 06, 2020

Ruby date formatting

Ruby provides two classes to format date string strftime and strptime.

In Rails, Ruby, Jan 01, 2020

json and jsonb - Postgresql

Postgresql provides a data-type jsonb to save data from JSON format. There are two ways for it - using jsonand jsonb. This article will clarify difference in short terms.

In Rails, Postgres, Database, Dec 10, 2019

Sidekiq By Example

What is the best way of handling background jobs in Rails, (maybe) using sidekiq.

In Rails, Sidekiq, Nov 28, 2019

Run seed data only on first Docker instance up

Q: Do we need to run rails db:seed, rails db:migrate every time the deployment happen? Ans - Absolutely no. rails db:seed should only run for the first time i.e. first deployment. But...

In Rails, Nov 22, 2019