Language != Design
I came across an interesting interview with Mono’s Miguel de Icaza recently, in which he discusses .Net and J2EE integration, amongst other things, and the GrassHopper project to run ASP.Net on top of J2EE. The argument for doing so is that J2EE is unassailable inthe high-end market ($2million plus), but that development shops find it quicker to develop in ASP.Net than in J2EE technologies. Here’s the rationale for why:
Strikes me as a big risk. In addition to adding a language interpretation layer into the mix, you’re throwing away a lot of enterprise best practises. Sure, strict enforcement of tiers slows things down, and can be overkill for smaller projects, but J2EE doesn’t absolutely mandate it. If you want to talk straight to the database from your server pages, why not do so using straight JDBC inside JSP’s, rather than adding all the overhead of an ASP.Net to Java bytecode converter? If you think the customer will let you get away with it, of course…
I agree with your post about using good programming practices, still, lets keep in mind that most programmers are not good software developers.
I have seen and worked with many applications that have been written from start to finish in the same page without creating any kind of maintainable bussiness logic. To change any rule or procedure requires sorting through each class and page to look for code snippets that perform some function instead of navigating the namespaces. The programs look as if they have been hammered together instead of having been designed or engineered.
I know about these programmers because a couple of years ago I was one of them. And yes, I worked mainly with Visual Basic. Just don’t tell anyone, please ;-)
Nevertheless, I have always found the ASP.NET code behind model to be a promoter and facilitator of the Model View Controler methodology.
The aspx page is the view, the corresponding cs file is the controler, and the model is encapsulated in different classes in different namespaces according to its function.
What I have noticed about Java is its rigidity. It was rather difficult for me to start using the JSF model so I stuck with ASP.NET. Perhaps I took the wrong approach. To solve that problem I have used grasshopper with great success. I haven’t given up in learning Java for the web though.
Adolfo
Comment by Adolfo J. Peña — September 14, 2005 @ 10:16 pm
While you make some good points, you can’t argue with the way that a lot of people develop applications. MVC is great, but isn’t absolutely required for all situations.
And, I think you are mixing the rationale for two different things:
1) reason for using .NET
2) reason for using Grasshopper
I think that many folks would argue there are more reasons to use .NET than the one discussed by Miguel. And certainly the amount of .NET development goes along with that. Not all these apps ignore good design patterns.
On the second issue - of using Grasshopper - I see it having value for the simple reason that people DO use .NET and later have a need for different platforms. Sure, in some cases a rewrite can make sense, but that needs to be looked at for each situation. I haven’t seen any of the “overhead” you talk about being added by Mainsoft’s binary compiler - to the contrary, performance is quite good. And, why learn a new language and IDE if you don’t have too? Grasshopper seems to be able to port apps that are well designed, or not so well designed, it doesn’t matter.
So, to be fair, I think you need to not mix the two points together. But, I do get your basic point of you can throw out good development practices with J2EE just as easily as you can with .NET. :)
Comment by Cubesteak — July 25, 2006 @ 8:53 pm