Sorry for the dup, but didn't get a response with the first one, so I cleaned it up a bit in hopes of getting a response.<br><span class="gmail_quote"><br></span><div>There
has been a couple of blogs (one posted at <a href="http://weblog.rubyonrails.com">weblog.rubyonrails.com</a>
"Things you shouldn't do in Rails") that are stating namespacing
controllers are bad and that you should avoid using them.<br>
<br>This idea does not sit well with me and am curious as to the Rails
roadmap. I've seen a couple things demonstrated in examples (Rails
Book, api) that later become deprecated. As others have suggested, a
resource for features/methodologies that are or will be deprecated
would be a very nice addition. <br><br>I use controller namespacing and am getting the uneasy feeling
that there is a growing anti-namespacing controller sentiment which
could lead to discontinued support. To me, this would be very bad as
my authorization code is built to take advantage of namespacing.<br><br>For
the following statement: "if your models aren't namespaced , why should
your controllers be?" (from: <a href="http://tinyurl.com/p9odk">http://tinyurl.com/p9odk</a> ) , well I
respond by saying models don't contain business logic, controllers do.
The duty of the model is to simply provide CRUD methods to your
database. Controllers utilize these models to provide functionality as
the business requires.
<br><br>I don't find myself violating the DRY principle by namespacing
controllers, I use partials and lib files to keep it that way. In
fact, putting some functionality into the lib directory has made it
easy for me to utilize the same code in multiple projects.
<br><br>I would like to see what my fellow railers think of
namespacing controllers and would also like to hear from some of the
rails developers. <br>
<br>
Is namespacing a real problem or just something some people think is bad design?<br><br>thanks,
<br>andy<br><br clear="all">p.s. I think I also something about has_and_belongs_to_many on the deprecation list in favor of has_many :though. Is this true?<br><br>-- <br></div><div><span class="sg">Andrew Stone
</span></div><br>