Senior Ruby on Rails Developer
Senior Ruby on Rails Developer Interview Questions and Answers

Asked in Comviva Technology

Q. How can an application running in the cloud with tightly coupled infrastructure be deployed to on-premise?
An application running in cloud with tightly coupled infrastructure can be deployed to on-premise by decoupling the components and using containerization.
Decouple the application components to make them more portable
Use containerization technologies like Docker to package the application and its dependencies
Deploy the containerized application to on-premise servers using tools like Kubernetes for orchestration

Asked in Comviva Technology

Q. How would you add a new column to a database table in production that already contains 100 million rows of data?
Use a tool like Rails migration to add a new column to the database table in production with 100 million data.
Create a new Rails migration file to add the new column to the database table.
Test the migration locally to ensure it works as expected.
Deploy the migration to the production environment during a maintenance window to avoid downtime.
Consider using tools like ActiveRecord's `change_column` method to efficiently add the new column to a large dataset.

Asked in Encora

Q. How do you compare STI with Polymorphic association?
STI is used for inheritance while polymorphic association is used for multiple associations
STI is used for modeling inheritance relationships where different classes share common attributes and behaviors
Polymorphic association is used when a model can belong to more than one other model on a single association
STI can lead to a large number of columns in a table, while polymorphic association requires an additional column to store the association type and ID
STI can be more eff...read more

Asked in Encora

Q. Importance of CSRF tokens and CSP headers
CSRF tokens and CSP headers are important security measures to protect against cross-site scripting attacks.
CSRF tokens are used to prevent cross-site request forgery attacks by generating a unique token for each user session.
CSP headers help prevent cross-site scripting attacks by specifying which resources can be loaded on a webpage.
Both CSRF tokens and CSP headers are essential in securing web applications against malicious attacks.

Asked in Encora

Q. Rails API best practices
Rails API best practices
Use versioning in API endpoints for future changes
Implement proper error handling and response codes
Follow RESTful principles for resource naming and routing
Use serializers to format JSON responses efficiently
Implement authentication and authorization for secure access

Asked in Finastra

Q. Design an API rate limiter.
Implementing an API rate limiter to control the number of requests a user can make within a certain time frame.
Use a token bucket algorithm to track and limit the number of requests per user.
Set a limit on the number of requests allowed per user within a specific time window.
Implement a sliding window approach to track request timestamps and enforce rate limits.
Consider using Redis or a similar caching mechanism to store and manage request data efficiently.
Senior Ruby on Rails Developer Jobs



Interview Questions of Similar Designations
Interview Experiences of Popular Companies




Calculate your in-hand salary
Confused about how your in-hand salary is calculated? Enter your annual salary (CTC) and get your in-hand salary


Reviews
Interviews
Salaries
Users

