是的,有几个类似的线程存在,但我们现在是在2011年,有很大的变化.

Grails1.3.6与v1相比有了巨大的改进.3.当我最初try 学习框架时(并放弃了缓慢的编译时间和其他引发呻吟的事件).

花了几个月的时间研究最新版本,我印象深刻,输入一个应用程序绝对是轻而易举的事(GORM很棒!).在开发模式下,不再需要重新启动,除非对域类进行更改.棒极了.lang非常棒(简单地说,这与我在PHP中的日常工作相比).

现在,另一方面是Ruby/Rails,除了阅读Ruby文档和探索活动记录(与GORM相比),我对它几乎没有什么经验.groovy语法来自PHP/Jquery,是蛋糕,ruby不是那么多,尽管可以访问.

Ruby/Rails风靡一时,而Groovy/Grails似乎正凭借自身优势加速发展.

我想听听这两个阵营都说了些什么(火焰引发的语言战争欢迎)re:2011年两种语言/框架的优缺点.在 Select 一个框架时,了解你要进入的领域是很重要的,因此,了解它,新手将受益,专家可以发泄;--)

推荐答案

轨道和圣杯在当前版本中都是优秀的框架.这两样你都不会错的.不过,以下是一些我觉得有趣的事情:

轨道

  • 轨道 (Ruby) does not scale as well as 圣杯 (Groovy). You will need more horsepower to run your application. This isn't a big deal at all with PaaS options like EngineYard (and hopefully a AWS BeanStalk 轨道 option in the future), but it might just cost a little more to run a 轨道 app vs a 圣杯 app (obviously JRuby is also an option to though).
  • 轨道 is slightly better with NoSQL alternatives currently, but 圣杯 is catching up quickly
  • 轨道 has many more plugins, but this can lead to trouble if you use some that aren't maintained (a lot of them don't currently work with 轨道 3 yet either).
  • 轨道 is more mature and has more features at this point in time because it's been around longer
  • 轨道 REST support is amazing
  • There are many more "big" 轨道 websites than 圣杯
  • Ruby比Groovy-TIOBE更受欢迎
  • No dependence on Oracle, ha! (圣杯 obviously needs the JVM)

圣杯

  • 圣杯 integrates with the JVM better than JRuby
  • 圣杯 GORM is better than ActiveRecord (IMHO), although 轨道 3 opened the door a little bit for other persistence options, but all the books, tutorials, etc all use ActiveRecord
  • 圣杯 View taglibs are better than <=%...%> in view
  • 圣杯 plugins are well documented and clearly state whether they are supported by SpringSource or not
  • SpringSource is investing heavily in 圣杯
  • There will be many more corporate jobs for 圣杯 than 轨道 in the future, but more startups use 轨道 (where do you want to work?)

我的观点

  • I used 轨道 a couple years ago, I'm working on a 圣杯 project now
  • 与Django(Python)或Zend Framework(PHP)相比,我更喜欢它们
  • 我计划下一步学习升降机(Scala)

我的推荐

  • If you have never done Java development and are working on a side project for a small to medium website, go with 轨道
  • If you are working at a big company that uses Java, try pitching 圣杯 to your management as the "next Java framework" they should invest in
  • 如果你正在开发"下一个twitter或foursquare",那么你就足够聪明,可以自己回答这个问题了!:)

Ruby-on-rails相关问答推荐

用至少一个缺省值初始化Ruby数组的最简洁方法是什么?

在控制器操作中适当使用ActiveModel Dirty

为什么没有生成命名空间路由?

Rails ActiveRecord::LogSubscriber 不输出详细查询日志(log)

Trailblazor 操作 -> 集合 :attribute(has_many 通过关联) 与填充器 -> 如何填充 Reform::Form 形式的 slugs 数组?

Ruby on Rails form_with 不显示错误,卡在服务器端

Rspec期望()与期望{}

正确更新其他列的更新列

如何使用默认的 Rails 记录器记录 Ruby 异常的整个回溯?

Rails:包含多态关联

jbuilder vs rails-api/active_model_serializers 用于 Rails 4 中的 JSON 处理

Rails:设计:按角色登录后重定向

如何按值按降序对哈希进行排序并在 ruby​​ 中输出哈希?

Rails,获取模型中的资源路径

.increment vs += 1

关于在不适合任何地方的 Rails 应用程序中放置类的指南

非持久 ActiveRecord 模型属性

从 Rails 中的 ActiveRecord::RecordNotFound 救援

ActiveRecord 何时会保存关联?

在 Ruby on Rails 中设置日志(log)记录级别