Reputation: 4182
Recently I've been playing a bit with Groovy and Grails and I have to say I'm nothing but impressed by the simplicity and productivity this framework could offer.
In the past I've also greeted the world via Ruby on Rails and what not, having that very same feeling so it's pretty much obvious that when it comes to web apps, DRY KISS is definitely the way to go.
The thing is, where I currently work people is quite Microsoft minded and I guess they would be kind of reticent to accept those jewels so I was wondering if there's any .NET project that implements the same principles than Grails and Rails?
Your comments will be much appreciated. Thanks a lot!
Upvotes: 10
Views: 7155
Reputation: 426
As old as this thread is I found that going through ASP.NET Core feels alot like Grails.
Environment Configuration https://docs.asp.net/en/latest/fundamentals/environments.html
Application Startup https://docs.asp.net/en/latest/fundamentals/startup.html
Dependency Injection https://docs.asp.net/en/latest/fundamentals/dependency-injection.html not as easy to get going as Grails as Grails is convention based while .NET there's still a bit of configuration to do.
Hope this helps.
Upvotes: 0
Reputation: 1032
If you want something that feels very much like Ruby on Rails in the .NET environment, you might try going with the following combination:
ASP.NET MVC - Implements the MVC pattern and, as other posters have mentioned, is strongly influenced by RoR, including some scaffolding capabilities via T4 templates.
Castle ActiveRecord - Implements the Active Record pattern that is at the core of Rails success. You see that ActiveRecord classes are very terse and DRY. Nothing more than mapping and validation attributes. Better yet, Castle ActiveRecord uses NHibernate under the hood so you can always step down to NHibernate and use tools like the NHibernate Profiler to understand and optimize Castle ActiveRecord's output.
There are several things that haven't really translated from the RoR / Grails world. Automated migrations a'la Capistrano and the immensely valuable plug-in libraries don't exist. I'd be interested to know if anyone has comments on like-minded alternatives in the .NET world.
Upvotes: 7
Reputation: 300
Sharp Architecture: http://code.google.com/p/sharp-architecture/
FUBU MVC http://www.fubumvc.com
ASP.NET MVC http://www.asp.net/mvc/
Dot Net Nuke http://www.dotnetnuke.com/
CSLA.Net http://www.lhotka.net/cslanet/
MonoRail http://www.castleproject.org/monorail/
Upvotes: 10
Reputation: 11
For .Net minded the best approach is using ASP.NET MVC and Castle ActiveRecord, but for real world applications you will need to include NHibernate Query Generator, part of Rhino Tools:, unless you have long experience with Nhibernate. You will also neet to activate the Second Level Cache as a first optimization, documentation available at ActiveRecord site.
I think both are necesary but are not included "out of the box".
Upvotes: 1
Reputation: 543
Anyone looking at this question today (in 2010) would do well to look at the Nimble plugin: http://www.grails.org/plugin/nimble
Upvotes: 0
None of those are even close to Grails in my opinion.
The answer is no. There isn't really anything in the .net world that provide what Grails does.
Grails isn't just a 'MVC' architecture, there is much more to it than that.
I would have hoped at this point in time that more work be done on creating such an environment, with IronRuby/IronPython.
The one part of Grails that shines is that it comes with everything you need - you don't have to follow 20 steps to get it installed.
Some examples of what it provides out of the box that asp.net mvc don't even touch: (1) built in support for Hibernate (2) built in support for dependency injection via. Spring (3) all the grails commands that make it so easy to work with it's conventions (4) built in testing support.
Upvotes: 7
Reputation: 3236
Another popular choice is SubSonic.
This program examines your database and builds a strongly-typed data access layer. It can also generate a CrUD (create-update-delete) website for you based on the DB. Can be integrated with Visual Studio.
The screencasts are a great way to learn the tool.
Can easily work with another framework, like ASP.NET MVC. I have used it very successfully for maintaining a MySql database from F#.
Highly recommended.
Upvotes: 3
Reputation: 3994
I agree that ASP.NET MVC is probably the closest. ASP.NET Dynamic Data also has similarities to Ruby on Rails. Although I have not tried this, I have heard that you can use both of them together.
Upvotes: 1
Reputation: 26096
Try ASP.NET MVC--it's very much influenced by Ruby on Rails, and they are both based on the MVC pattern.
Upvotes: 10