Ruby technology for portals - ruby-on-rails

I just saw that whitehouse.gov is using drupal as a CMS and portal technology.
One of the advantages of drupal seems that it is easy to add plugins and that programming is minimum, i.e. that re-inventing the wheel is at minimum. That is actually exactly the DRY philosophy of Ruby-on-Rails. So:
What are the drawbacks of drupal?
What would Rails or other Ruby based technologies disqualify as portal technology for whitehouse.org (or other CMS portals) ?

What are the drawbacks of drupal?
This is really a quite subjective question in relation to Ruby and Rails. Drupal is a solid content management option and really shines for community-oriented sites. It is useful for general purpose content management for non-portal sites as well. The drawbacks would be that it is built on PHP, if you are a Rubyist then that is a significant drawback. Additionally it is a beast of a project if you are looking at just the core. The API is quite large which is fitting for a project like Drupal, but this can make getting substantial customization done into a lot of coding work. Also, because of the whole architecture of Drupal there is no clear separation of data types unless you write a custom module that makes a clear separation and while this is in keeping with the "Drupal way" it is a little odd to some to think of EVERYTHING as a node or within the structure of Drupal's Taxonomy system or the like.
The biggest drawback to Drupal really can be best summed up this way: in order to make effective use of Drupal you really need to know and understand Drupal in a way that you don't for a CMS system like Radiant; but Radiant is nowhere near as complex as Drupal.
What would Rails or other Ruby based technologies disqualify as portal technology for
whitehouse.org (or other CMS portals) ?
Rails is rather dissimilar from Drupal in that it is not really a content management system at all but a more general purpose application framework. You can use Drupal in ways similar to Rails, but Drupal is really much more than what Rails is. Better comparisons could be made between Drupal and say Radiant or BrowserCMS or some of the other Ruby/Rails CMS packages. There are Ruby/Rails portal systems out there but few match the bulk of Drupal and it's community. The most comparable options in the Ruby ecosystem only match bits and pieces of what Drupal can do, but that is because Drupal is that massive a project and a community. Drupal is a swiss army knife plus some for doing sites on the web. Ruby doesn't have a truly similar project out there because most Rubyists don't see any reason to duplicate Drupal's girth.
I would recommend the following projects as things to look at if you are considering use Ruby in place of Drupal (most of these Ruby projects will cover less than Drupal but fit closer with your site's actual needs):
Radiant
BrowserCMS
Lovd by Less
Community Engine

Quite subjectively, I find the Drupal administration interface a bit clunky. You can try it out for yourself without actually installing Drupal at opensourcecms.com. That being said, there seem to be a great momentum in Drupal community at the moment, and it's starting to become a really full-featured CMS.
Comparing Rails to Drupal is somewhat like comparing apples to oranges. Rails is an application framework and Drupal is a CMS (although with a kind of application framework included).

allesklar, what is wrong with the extension system within Radiant? There are plenty of Rails CMS out there already. I suspect contributing to an established system to improve it would be more productive for the community at large than creating yet another niche CMS.

I'm a Rails developer so I'm all for Rails solutions but presently there is no Rails CMS that comes any close to a CMS such as Drupal in terms of functionality and plugins.
I attribute this partly to the 'less is more' philosophy advocated by 37signals.
Wordpress, Drupal, and others go for 'as many features as possible' and doing such end up attracting masses of users who will find that these products do answer their needs.
I've been playing with the idea of, like many others, starting a Rails based CMS system with plenty of features and a good plugin architecture. No time to work on this yet though between client work and development of an hosted application I'm working on.

I just found this site:
drupal and rails

If you are looking for portal technology built in Ruby, a relatively new candidate to consider would be EngineY. EngineY was originally built as a social networking framework but also has features that make it a viable candidate as a traditional portal. EngineY's concept of a 'widget' is similar to a traditional portal's portlet. There is a Managed Content widget included with EngineY that lets you create a portal made up of managed content. Best of all is that EngineY is very actively maintained and is evolving and improving daily.

Related

Can Wordpress be replaced by a Framework like Django or Ruby on Rails?

I consider myself a well trained WordPress template developer, and i recently started to read books and documents about web app frameworks, particularly Django and Ruby on Rails. I didn't know any of the two languages, but i have no problems to learn another one or two. I really don't get the real benefits of using a framework, because i feel very confident about the power of WordPress. So, can anyone tell me the real benefits of using a framework? For example, Pinterest is made using Django, but i think that i can achieve the same results with a WordPress template using Javascript and CSS3. Can anyone tell me the differences/benefits of using a framework in that particular case?
You can achieve the same frontend with Wordpress, but what you will not be able to achieve is the speed and scale - and most importantly, maintainability - of an application based on a more application-oriented architecture.
Wordpress is highly flexible, but it's also slow, and needs an awful lot of TLC to be able to operate at any kind of significant scale. Its design allows for very flexible runtime modification of behavior, but this is also a bit of a Pandora's Box, since it means that code can end up running all over the place for any given page, which makes maintenance a nightmare.
Wordpress is extremely good at being a CMS, but once you start to push it outside of those bounds, you get into trouble, and find yourself having to write your own more abstract framework that runs inside of the context of Wordpress to be able to fulfill your application's needs.
That said, if you have an application that you can build in the context of Wordpress, I'd say go for it! Wordpress can be a wonderful tool for building a proof-of-concept or MVP. If it gets you up and running, then it may be the right choice over writing a full application. However, just be aware that you're going to hit some brick walls as your product design matures and your audience grows, unless your application fits within a rather narrow set of design requirements, so long-term, you may find yourself having to move to a custom application.
Credentials: I've spent the last couple of years maintaining a Wordpress install that served over 25 million monthly uniques, and we had to get very clever to keep it running. We've since replaced it with a Rails application that serves pages somewhere on the order of 10x-30x faster, and is significantly more extensible as an application, allowing us to start exploring application potential that we really couldn't get with Wordpress.
I once made the decision while working in some start-up to choose WordPress for an advanced e-commerce, community-driven marketplace.
It was an awful decision
This is how I was feeling:
At the beginning, it was looking good - you have an amazing community, plugins for everything etc. But sooner than later I hit the wall - at it's root - WordPress is a blogging platform!
Every piece of content technically is a post.
It's really hard to create advanced item relationships
Functionalities are not consistent. Some functions work one way, while others that seems to be very similar work in a different way. Sometimes you need some weird hacks to achieve task that seem to be simple. It makes you read the docs very often to see how a function that you're using for the 1000th time is working. (However, to be honest, I need to say that the WordPress documentation is great!)
The WordPress community is doing a great job, but compared to any regular Framework there is one main difference - Frameworks are just frameworks - they're a set of tools and those tools are there to help you do your project. WordPress already is trying to be something that you might then change.
I'll never again use WordPress for anything that needs some organised, custom functionality.
I'm actually quite impressed with what people has created with wordpress - so if you want to, it is possible and good luck!
It however often feels like buying a truck and rebuilding it to be a house. There are better ways to build a house.
I want to offer a dissenting opinion, even though I upvoted the top answer.
Is Rails really special?
Rails was created by David Hansson who extracted it from Basecamp, software that's replicated in a free Wordpress plugin, WP Project Manager. I think that's a pretty good indicator that Rails developers are underestimating PHP and Wordpress.
MVC and WP
True, it doesn't follow an MVC pattern. But if you use hooks, separate logic (in plugins) from views (in templates), then you'll have good code separation. (Also hint: custom post types are like models.)
Framework vs Application
As you can see, Wordpress can be treated like an application or a framework. It is an application, with all the components you'd expect to find in a framework. Right out of the box you have security, authentication, and extendibility. And it's meant to be extended.
Scaling
WP powers 18% of the internet's websites, including TechCrunch, Smashing Magazine, and (parts of) CNN. Seems there are ways to make WP scale. Disclaimer: I have no experience working on megasites like these, so I'm offering mere conjecture.
WP Future
The current abition of the WP community is to shift WP from a CMS to a framework. I think it's a natural progression considering that all the pieces are in place. And the Wordpress community is going strong.
Not really an answer, but a hint:
http://en.wikipedia.org/wiki/Comparison_of_web_application_frameworks
As if you can replace it completely... I think it is mostly a matter of logic flow. It depends how much imperative (Ruby on Rails) vs. descriptive (WordPress) programming you intend to do.
I don't think wordpress can replace rails, because wordpress have limited set of API and support as you compare it with RoR. Though wordpress is powerful tool for blogging application, but the same effect can be achieved with rails using gems like,
Radiant CMS,
Refinery CMS,
Locomotive.
Adding the power like ttd that can be done vary easily with rails is very difficult with wordpress.
Same with authentication and authorization mechanism like devise and cancan. There is no easy option to do the same with wordpress.
Rails make the programmer's life easier. For whole web app I will always prefer to go with the rails.
Wordpress cannot replace X framework, but the two can certainly complement each other.
For example a WP front end serving up CMS content with an attractive theme is pretty hard to beat; proxy to a back end server for custom content and voila, best of both worlds. Otherwise, WP will inevitably fall short of meeting every requirement and you'll find yourself going down the square-peg-round-hole rabbit hole, a painful place indeed; that's where X framework comes in, filling in the WP gaps.
The notion that WP does not scale may have some truth to it, but for the general case, the 95%, it will handle whatever you throw at it, particularly with WP Cache or other caching plugin thrown into the mix.
Some may say, well, you can build WP with Django or RoR! Heh, heh, you first ;-)
FWIW, I avoid dynamic language frameworks in favor of their statically/strongly typed counterparts. Use WP for the bling, and static X framework for the speed/scalability/safety. Of course, that's a matter of preference, clearly some prefer runtime flexibility over compile time safety. I'm fully in the latter camp these days...
In the simplest term,, I always want to put it like this...
You can use a framework to make WordPress it self and better
But you can't use WordPress to make a framework
Wordpress is a great CMS any way
Pros
1. We can easily set up a website using free themes and plugins
2. There are numerous number of plugins to extend our website functionality
3. Excellent Community support
4. The CMS uses PHP and MySQL, somewhat easy to lean
Cons
1. Updating plugins and themes regularly.
2. Slow
3. Malicious files can be easily injected.

Is Django inherently more difficult to host than RoR?

I know there are a lot of existing questions on Django hosting etc but my question is whether there is a technical reason why RoR hosts are easier to get by than Django hosts. Is there something in the technology itself or the architecture that makes it more of a hassle for providers to host and maintain?
It's both seemingly easier to find better free hosts for RoR than for Django (10mb from alwaysdata really doesn't allow for a lot and App Engine isn't a vanilla Django) and easier to find decent RoR hosts for 2$/month packed with features than for Django.
Is the reason technical or just because of market share/timing?
Thanks,
Xiao
Let's face it, free hosts are nowhere near good, and nor are very cheap ones.
If you want a decent host, you will have to pay a decent amount.
On the other hand, rails is nearly 1 year older than django, and started to popularize way earlier than django did. Also, php being older and popularized earlier, it seems a good reason for rails to be more popular with hosts than django.
Django it is not more difficult to host than RoR.
IMHO this offering delta is there mostly because of the market share the RoR has compared to Django.
If it is true that rails is older than Django, it's also true that Python is older (and used by more people) than Ruby.
Also a technology like WSGI that makes things easier for web applications was already there when something similar came out for Ruby (Rack).
I think it's less timing and more community push, myself. There is an extremely active and vocal community behind Rails. Just go down to your local bookstore and take a look at the books there. You'll probably find 5x the amount of Rails books that you will find over Django. As it is said, the squeeky wheel gets greased. There is a strong vocal minority of Rails users, and that means that people will cater to them on shared hosts, because otherwise they'll have to listen to a lot of requests that keep asking for it.
Not to say that time-in-market doesn't have something to do with it, I just find that the community behind any given technology has a lot to do with it's level of adoption in different business models.
Also, any host that hosts Ruby apps can host just about any of the major frameworks, as long as they are Rack compatible. So for having to deal with Rails, they usually get support for Sinatra, Ramaze, etc, for free. Instead of just supporting Django.

Uses of Ruby on Rails

I am a somewhat experienced rubyist, but I am now starting to do rails development. I know rails is used to make "web applications" but what exactly does that mean? Do you build entire sites with rails or do you build a feature for a website in rails, and integrate it in to an existing website? (I know this question is kind of vague, but any answers to how ROR is used in the creation of websites would be much appreciated).
Generally speaking, you will build a full site with Rails, though you can integrate it into an existing website, as well. It is designed to provide a top-to-bottom solution for entire websites.
For standalone features or small scripts you just want to expose to the web, you might look at something like Sinatra or Camping.
What is Ruby on Rails?
I'm also build some rails applications in that I had entirely use rails to develop my web application. It's quite easy rather than using two or three languages. But when I developed I had to use Javascripts, CSS and Ajax to create more attractively
For me it's a great framework to build website and minimal knowledge is required although experience and knowledge of ruby gives you an upper hand.
I also feel that rails is good not only to build websites but to manage it.
Also the support community of rails is awesome and is complemented by guys like Ryan bates with their screen casts.
Also when we build a website using ror, we have the flexibility to concentrate on different features at different times or by different person.
This gets a great modular structure.
So you can design the basic functionality today and tell your colleague to get the views attractive using JS and friends without affecting your functionality.
Also the external support for rails (like gems and plug ins) is awesome and makes life heaven!
I would suggest that it's a great framework and the best feature is that it is a very easy to begin and learn but it always surprises you with new things.
Thus it allows you to learn a lot!
Hope it helps.
The website/web application distinction is made because there are many Rails apps in existence with no front end or 'website' to speak of. Using Rails, one could serve JSON amongst a cluster of compute nodes for data aggregation, or text to unix sockets for display on terminals. The uses for Rails are only limited by ones imagination, and you could even use Rails for single host interprocess communication if you desired. This might prove effective for a highly skilled rails programmer rather than learn a new tool to achieve similar results.

Is the Rails ecosystem a suitable replacement for drupal

I want to make a community based site, which is Drupal's strength. However I also want to try other frameworks, especially Rails.
One of the best things about drupal is its huge modules library. If I were to switch to Rails, would I be able to find similar functionality freely available as plugins, or would I have to rebuild?
Does Rails have the equivalent of (as plugins or gems):
CCK/Fields?
Node Reference?
Views / Views Relationships?
PathAuto?
Threaded Commenting?
Multisite Functionality?
Apache Solr (or equivalent) Integration?
Thanks.
I'm afraid you'll probably hear this answer a lot, but it's not a suitable comparison.
Drupal is a ultimately a CMS, Rails is a framework. Apples to oranges, or perhaps even Apple Juice to oranges. Out of the box, you fire up Drupal and it does 'things': it has a database structure, the concept of nodes, interfaces blah, blah. If you fire up Rails you have an empty project.
As far as I know there isn't a "Drupal-on-Rails" project that would be a suitable equivalent. However, I can attest to the fact that there is an awful lot of Ruby/Rails community and O/S work out there and you might find something suitable. I'd also say that the level of modularity in Ruby and Rails tends to mean that the range of plugins/modules/gems one can use is much greater.
My personal $0.02. If Drupal does what you need, just use Drupal: it's mature and has a great community. It's never a good idea to try to port Project X over to a new language as a learning exercise because you'll inevitable fall into the "Well that's how it's done in language X!" trap and become disenchanted with the new system.
If you're wanting to learn Rails (which you should, it's awesome) I'd suggest you'd be best working on a small project and seeing what the ecosystem offers before deciding if it's suitable for the needs of your bigger projects.
I have to second what Govan said, but add to it.
With Drupal, unless you really want to get into building your own modules and extensions you are really interacting with an application. Even when you start using CCK, all you are really doing is flipping switches, filling in forms and defining new options for content on the site.
Ruby on Rails is two things, and neither of them bares much similarity to Drupal. You asked "How hard is it really?". To answer that you need to understand what both Ruby and Rails are. Ruby is a programming language designed to make the life of the object purist programmer simpler and more pleasant. So, the first part of how hard is it is simply to answer "how long do you feel it would take you to learn a completely new programming language, like PHP but different".
Rails is an 'opinionated' framework. It's opinionated in that it lays out how a Ruby web project should be structured, as well as providing multiple APIs for everything from database access to web presentation. To answer the "how hard is it" question for Rails then (assuming you know Ruby by this point), you have to answer how much do you need to learn about cacheing, database design, page design, RESTful programming etc etc.
It's not a short journey. you asked if there is an equivalent to CCK for Ruby and Rails which implies to me that at this point your knowledge of programming is somewhat limited. Ruby and Rails interact with the database. CCK lets you define things in a database. Thus, with Ruby and Rails you are effectively bypassing the wonderful dialogs and forms that CCK provides you with and doing the data definition bits yourself, by hand, in code.
From experience, when I've hired experts in another programming language and framework into my Rails teams, it has taken them between 1 and 3 months to get productive, and a further 3 to 6 months for their productivity to start to raise and approach that of the Rails experts on my team.
Thus, in your particular case, I would not recommend a switch away from Drupal to Ruby on Rails.
Drupal (core) on ohloh (130k lines of code) is estimated to be 34 years of work worth.
Drupal (contributions) on ohloh (modules for Drupal 4-6 (7M lines of code)) is estimated to be 2113 years of work.
That is the power of a community, and that is something that you can never replicate. I remeber there was a guy, who tried to port Drupal to python calling it drupy, but that project died before something useful ever came out of it. Even if you copy the code, you can never copy the community.
The thing you need to realize, is that each community is different. So even if you find a project that can solve your code needs in a RoR or a different language/framework, it will never be like Drupal and vice versa.
So don't try to find a replacement for Drupal, but go explore and try new things. You might end up learning new things, that you can use for your Drupal projects.
I've read this times and times again that people saying comparing drupal an ror is comparing apple to orange which is wrong.
I think the saying itself BS. Yes we want to compare apple to orange and find out which is better. We even want to compare apple to steak. Said that, they are different. Yes, we all know. I have limited experience with either. I first thought Drupal was great and can help me build the website I wanted overnight (or over a week or month) then it didn't happen (not blaming Drupal).
My impression is that, Drupal maybe still great but it has a learning curve and needs a lot of other knowledge or talents to use it well and tweak it. RoR on the other hand is a more general framework and needs programming (Drupal needs too actually).
If you are more of a web designer person with a little PHP maybe Drupal is better fit.
If you are more of a web developer type don't want to spend time looking for modules and make them work but rather do them yourself (not really from ground up) then maybe RoR is for you (with the same amount of learning). So yes they are both good for different purpose, background, etc.
For now I will go with RoR (or dJango and other ORANGEs). My 2 cents.
Rails, since version 3.0, has officially adopted the once-controversial engine way of incorporating third-party apps. this is roughly the equivalent of Drupal's modules/plug-ins, from a 10k foot perspective. To build a community-based site, you could make use of an engine called, appropriately enough, "Community Engine." http://communityengine.org/features.html"
The Rails ecosystem doesn't have anywhere near the same number of modules Drupalists have available to them, but there are enough good quality ones to cover the chief basics.
Drupal has so many strong areas, its hard for just one or two people to recreate it in a decent amount of time with any language. PHP, Ruby, Python, etc.
You have the core node system, taxonomy, aliasing, menus, users, permissions, and modules, the database api, and form api, among others.
You'd have to know how to assemble all these pieces independently and create the structure necessary for it to all work together.
It would take more than 'a few hours'. I would say, even if you are a ROR master, you're looking at a year to two years of solid consistent work to get the best parts of Drupal for a new system.

Ruby on Rails for web applications, Django for webpages?

Days ago I read something like "Ruby on Rails is for web applications, Django is for standard webpages". Is that true?
I have to decide in the next weeks if I go with Ruby on Rails or Django for an university project. It will be an email marketing software.
What do you advise me to use?
This is mainly because of their heritage - Rails was originally used for web applications like Basecamp, while Django was used to build newspaper/magazine sites.
I would say both have long since outgrown their original purposes however.
No that is not true, but however, Django has the built-in Admin back-end making it a great starting point for a CMS or something similar. Django is still very capable for creating complete web applications!
I presume this is:
Ruby on Rails (i.e. the Rails framework, using Ruby as the programming language)
vs
Django (i.e. the Django web framework, using Python as the programming language)
Both of these frameworks are Model View Controller (MVC) frameworks, so they are both capable of web applications and web pages.
Therefore, your decision is really "Python or Ruby".
Both Ruby and Python are object-oriented languages and are easy to get into... they both have quick-start guides here:
http://www.ruby-lang.org/en/documentation/quickstart/
http://wiki.python.org/moin/BeginnersGuide
I think Ruby has the edge in terms of simple documentation and ease of use - as long as you are happy to abide by the rules that the language enforces (which aren't necessarily a bad thing by the way).
Both frameworks are great for what you're trying to do and Ruby and Python are similar in a lot of ways. My suggestion would be to skim through the online documentation for each and go with what feels best for you.
First, you need to answer 2 questions:
Do you prefer Python or Ruby?
Do you need a minimalistic framework, or a more complete one?
As a minimalistic framework in Python, take a look at web.py.
Both are great frameworks.
The question is.. Do you prefer (or feel more comfortable, or know better) 'Python' or 'Ruby'?
Once you have the answer to this question you also have the answer to the original one.
You can use either framework to create almost any web application imaginable.
If you have no language preference, and you don't have a preference for their different design patterns (Django is nearly not as strict MVC as Rails), then think about the different Python and Ruby libraries/apis out there that could be useful for your project.
Go with whichever language supports those libraries/apis that help you the most.
In my experience, Rails developers are more likely to work in small, funded startups. Django seems to be the preferred environment for independent consultants building websites for small businesses. If you're picking a language to gain experience, you might keep this in mind.
You'll be spending most of your time configuring, learning the tools, frameworks, and environments. The language itself (Ruby or Python) will not be a big hurdle for you.
Also - Rails is really nice to develop with on a Mac. I don't know about Django tools.

Resources