Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6211781
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T06:23:53+00:00 2026-05-24T06:23:53+00:00

Can someone help me understand the differences between a Rails Engine and a Mountable

  • 0

Can someone help me understand the differences between a Rails Engine and a Mountable app? In Rails 3.1, you can create either one with the “rails new plugin ___” command.

rails plugin new forum --full        # Engine
rails plugin new forum --mountable   # Mountable App

When would you want to use one versus the other? I know you can package an Engine as a gem, for one. Is that not the case for Mountable Apps? What other differences are there?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T06:23:54+00:00Added an answer on May 24, 2026 at 6:23 am

    I have noticed the following:

    Full Engine

    With a full engine, the parent application inherits the routes from the engine. It is not necessary to specify anything in parent_app/config/routes.rb. Specifying the gem in Gemfile is enough for the parent app to inherit the models, routes etc. The engine routes are specified as:

    # my_engine/config/routes.rb 
    Rails.application.routes.draw do 
      # whatever 
    end 
    

    No namespacing of models, controllers, etc. These are immediately
    accessible to the parent application.

    Mountable Engine

    The engine’s namespace is isolated by default:

    # my_engine/lib/my_engine/engine.rb
    module MyEngine 
      class Engine < Rails::Engine 
        isolate_namespace MyEngine 
      end 
    end
    

    With a mountable engine, the routes are namespaced and the parent app can bundle this functionality under a single route:

    # my_engine/config/routes.rb 
    MyEngine::Engine.routes.draw do 
      #whatever 
    end 
    
    # parent_app/config/routes.rb 
    ParentApp::Application.routes.draw do 
        mount MyEngine::Engine => "/engine", :as => "namespaced" 
    end 
    

    Models, controllers, etc are isolated from the parent application – although helpers can be shared easily.

    These are the main differences I have spotted. Perhaps there are others? I have asked over here, but have yet to receive a response.

    My impression is that since a full engine does not isolate itself from the parent application, it is best used as a standalone application adjacent to the parent app. I believe name clashes could occur.

    A mountable engine could be used in situations where you want to avoid name conflicts and bundle the engine under one specific route in the parent application. For example, I am working on building my first engine designed for customer service. The parent application could bundle it’s functionality under a single route such as:

    mount Cornerstone::Engine => "/cornerstone", :as => "help" 
    

    If I’m way off in my assumptions, someone please let me know and I’ll fix this response. I have made a small article about the subject here.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Can someone help me create an index/count button for a UITableView, like this one?
Can someone help me understand this topshelf project...mainly the difference between ConfigureServiceinIsolation and ConfigureService.
Can someone help me understand this piece of code: char *line = new char[2048];
can someone help me understand this because it's working in as3 but not so
Can someone help me understand why this gives an output of 0? #include <iostream>
Can someone help me understand the WPF stretch alignment. I often run into issues
Can someone help me understand what's wrong with this query: DELETE FROM noteproject INNER
Can someone help me understand this commit What is \u00A0 ?
I know this regex divides a text into sentences. Can someone help me understand
Can someone help me understand how best to model a composition relationship? If for

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.