San Jose, USA

2066 N Capitol Ave #1117
San Jose, CA 95132

Pune, India

Office #803, 8th Floor, Tower 2
World Trade Center, Kharadi
Pune, Maharashtra 411014
India

hello@BigBinary.com
Ruby on Rails

#6 - Using services to manage code

Episode Notes

In all our applications we have a directory called app/services. In this directory we put all kinds of services. Now what’s a service.

A service is anything that a model should not be concerned about. Like How to send SMS, how to deliver email, making call to external service, parsing CSV file. It all depends on the application what should be in the model and what should be in the services.

The additional job of services is to keep model thin and manageable by extracting certain business rule into a service in itself.