Home > Mono > ASP.NET with Mono’s XSP and Apache ASP.NET with Mono’s XSP and Apache Submitted by Paul O Neil 2005-03-13 Mono 32 Comments The second article in a series of articles about Mono. This article explains how to host and serve ASP.NET Web Applications and Web Services on Linux using XSP and Apache with the help of Mono. About The Author Eugenia Loli Ex-programmer, ex-editor in chief at OSNews.com, now a visual artist/filmmaker. Follow me on Twitter @EugeniaLoli 32 Comments 2005-03-13 9:01 pm But in view of the fact that I’ve made a decision to move away from Windows I’ll be using PHP are a lot of the pretty extensive Java infrastructure out there. The question you have to ask yourself is what does ASP.Net on non-Windows platforms give you? The answer is, not a whole lot. 2005-03-13 9:04 pm no, the question is “what does ASP.net give you period” I think that it gives you nothing that can not be done on PHP or Java. really, with the amount of OSS and Java based solutions today, why would some one WANT (not need) to use ASP? 2005-03-13 9:30 pm I think that it gives you nothing that can not be done on PHP or Java. Well on non-Windows platforms, absolutely zilch. In fact, the performance of Mono for delivering web applications is a limiting factor as PHP and Java has been doing this for years. Mono is one of those technologies that looks as if it should be really, really special – and it just isn’t sadly. Using ASP.Net web applications with Mono and XSP whilst having to write them in Visual Studio.Net (there’s no other way, realistically) just totally wipes out any advantage you may get in moving your applications off Windows. I’ve done the hard work, now I might as well just deploy them on IIS. It just doesn’t make any sense. 2005-03-13 9:33 pm It gives existing (and future developed) ASP.NET applications somewhere else to run besides a windows server. It also gives existing .NET developers an alternative place to write applications besides windows. As a developer working in a .NET shop, mono gives me hope that I’ll have somewhere (in the future) to run code besides the Microsoft framework… this is an excellent choice as eventually, Microsoft will most likely dump the framework (like they do for almost all other development platforms they create) Alternatives are alternatives – there’s no reason that every developer has to use Java/PHP in order to build web applications. 2005-03-13 10:34 pm unlike other tech at .net plathform the windows.forms ado.net and asp.net is patented, why you would risk yourself dumping php/python/perl in favor of asp.net? I’m not trolling here but as web developers I can’t take it, because I use them for free, I don’t want a day microsoft come and do what SCO try to do with Linux, but once this point get clear I would use c# (when it needed) as web server side programming language. 2005-03-13 11:13 pm … and you’ll spend the rest of this thread proving absoluting nothing. Here’s a thought – how about spare us all the shit. If you think the only thing good about asp .net is windows than I think you’re better off using php. asp .net adds a hell of a lot of functionality in free/non free tools and resources. Yes, visual studio is pretty schwanky as far as tools go, but telling people that it’s the only way it’s possible [realistically] is yet more bullshit. 2005-03-13 11:36 pm It gives existing (and future developed) ASP.NET applications somewhere else to run besides a windows server. There aren’t very many ASP.Net applications now as it is, and there is no reason whatsoever to run them anywhere else exept Windows. Every Windows developer who’s looked at Mono seriously really knows that. As a developer working in a .NET shop, mono gives me hope that I’ll have somewhere (in the future) to run code besides the Microsoft framework… That’s all it can provide – hope. That’s a ringing endorsement, I have to say. 2005-03-13 11:41 pm Here’s a thought – how about spare us all the shit. Please do . If you think the only thing good about asp .net is windows than I think you’re better off using php. asp .net adds a hell of a lot of functionality in free/non free tools and resources. Does it? Mono and XSP barely runs now as it is, and it simply adds nothing extra over and above current open source web software. Java, PHP and others provide a vast array of functionality and they perform acceptably today. Yes, visual studio is pretty schwanky as far as tools go, but telling people that it’s the only way it’s possible [realistically] is yet more bullshit. Wow, really? OK. You tell me what IDE people are going to be using for Mono and ASP.Net running with XSP that is on a par with Visual Studio.Net. Make my day. The only option you have is to develop in VS.Net and port to Mono. It just isn’t feasible and is total lunacy in Windows developers eyes. We get comments like this every time because people know it’s true. 2005-03-13 11:42 pm While I do agree that you have to be wary of MS behaviour regarding Mono, don’t forget there are patents in Java (yeah, quite a few in fact). 2005-03-14 12:21 am The bigger issue is why is there only a *VERY* small number of companies going to be baseing their future products on .NET? Look at the number in the Java community and market place, and compare it to .NET – Had Microsoft made the WHOLE framework 100% BSD licensed and opensourced, then I might possibly take some interest in it – it would then have a definate competitive advantage over Java, but having had a look at the existing mine field of Patents that may dog Mono, and the crappiness of Rotor, you’re better of simply putting up with the limitations impose on the Java source that it is to go and try to use .NET 2005-03-14 12:23 am While I do agree that you have to be wary of MS behaviour regarding Mono, don’t forget there are patents in Java (yeah, quite a few in fact). So? Java is Java. If there will be a competing Java-like thing that is not Java, then the Java patents might perhaps be a problem to that other system. But clearly Sun has nothing against people running things based on Java as Java is their main product these days. On the other hand, in Mono/ASP:NET/ADO.NET case we have a competing product to Microsoft’s own patented technology and that could be interpreted to infringe MS patents too. The situation is very diferent from Java. My suggestion to Microsoft: Microsoft should make up their mind whether they want to keep ASP.NET and ADO.NET tied to Microsoft technologuies like Windows and IIS only, or not. If they embraced Mono/ASP.NET/ADO.NET openly and officially, they could win much more friends, even among open source people (and maybe even win more money in the end?). If, however, they keep potential Mono/ASP.NET/ADO.NET people afraid of their patents and just want people to use MS products only, many potential .NET users will look elsewhere. There’s always Java-based web offerings, PHP is already very good and is developing fast, as are new Python and Ruby based web technologies etc. Everything that can be done with ASP.NET can be done without it too, sometimes better too. I think that ASP.NET is not that big that it could overlook potential chances to grow, even if that would mean embracing related open source and non-MS .NET implementations. Sometimes success can be achieved by cooperating and not just by trying to kill every potential competitor out there. Many people (not wanting a pure MS/IIS/Windows environment) could be interested in Mono/ASP.NET/ADO.NET (maybe including me too). But they won’t touch ASP.NET and ADO.NET until the potential patent/IP issues of Mono/ASP.NET/ADO.NET are solved. And there probably won’t be good IDEs for Mono/ASP.NET-based web development before that either. 2005-03-14 12:39 am Seems nobody of you ever cared to read anything about ASP.NET. It really IS different from PHP/Java Servlets. When first programming in PHP I had a look at ASP, and I didn’t like what I saw… it was somehow like PHP, but lacked in every aspect, so I decided it wasn’t worth the effort. But ASP.NET is a completely different beast, don’t know if you ever noticed it ISN’T ASP. For example, in ASP.NET you can program web pages in a way more akin to RAD than that of “program, run thru firefox, run thru iexplore to correct any misbehaviour, go to next file” cycle you use in either ASP or PHP. The data models are different too, no more problem conecting to MySQL/Postgres/SQLite, you name it. So answering “what does ASP.net give you period”: for inexperienced people, is easier to program a web page using ASP.NET+SomeDB than using LAMP. I wouldn’t use it to program an enormous web site, or forum, or whatever, but others did with great result: http://www.codeproject.com for example. “OK”, you may say “but what does it give me that I cannot do using a OSS platform?”. Probably nothing. But remember: doing ASP.NET with Apache+Mono+XSP, is OSS. So, as a last note: please, before begining the OSS vs MS flame war, please, PLEASE RTFM. I use PHP for my projects, but at least I do understand the difference between ASP/ASP.NET/PHP. It’s my productivity that drives me, no my OSS zealotry. (FYI: Every other soft I use is open source. I only use Windows XP here, because I have no option) 2005-03-14 12:52 am For example, in ASP.NET you can program web pages in a way more akin to RAD Yep – when using MS Visual Studio.NET, MS Windows and MS IIS… VS.NET-style web RAD, not to mention VS.NET itself doesn’t work with Mono yet… 2005-03-14 12:54 am I would have thought thats OSS/Linux fan[atic]s would be happy about this. Does it not encourage Windows/.NET developers to think about looking at Linux/OSS as a viable platform for web applications? Does XSP add more power to Linux/OSS? Is MONO giving people choice over the arranged chaos that is LAMP and the inertia of the Java Politburo Community Process. 2005-03-14 1:14 am I would have thought thats OSS/Linux fan[atic]s would be happy about this. Not until the potential IP issues are solved. Period. Most ASP.NET on Linux users would be big companies and those kind of users are very sensitive and conservative about IP issues. MS should officially accept ASP.NET on Linux as an alternative legal ASP.NET technology. Until that day ASP.NET on Linux will remain a very small and tiny niche thing only, not only lacking VS.NET kind of IDEs but also all other enterprise level support necessary for it to have any real success. In Microsoft world ASP.NET may be a relatively succesfull thing, but really, very far from that in the Linux world. Even a relatively new (and very promising) technology like Ruby On Rails is much bigger than ASP.NET on Linux. Same with some Python things, not to mention PHP and Java. 2005-03-14 5:02 am Look at the number in the Java community and market place, and compare it to .NET – Had Microsoft made the WHOLE framework 100% BSD licensed and opensourced, then I might possibly take some interest in it – it would then have a definate competitive advantage over Java, but having had a look at the existing mine field of Patents that may dog Mono, and the crappiness of Rotor, you’re better of simply putting up with the limitations impose on the Java source that it is to go and try to use .NET OK. I am now confident most of you (a) don’t know remotely what you’re talking about and (b) you have never been close to C# or .NET. For the sake of yourself, read the articles below. http://techupdate.zdnet.com/techupdate/stories/main/0,14179,2879892… http://multiparadigm.com/Intro%20to%20CSharp%20and%… http://www.codeproject.com/dotnet/dotnet.asp “If Java was an open standard, technologies like [Microsoft’s] C# and the technologies it works with [like .Net] might not exist today.” “What are C# and the Common Language Runtime virtual machine (CLR)? They’re pretty much the same thing as Java. They’re a language and a virtual machine with a few other differences. Maybe if Java was an open standard, Microsoft would have supported it instead of coming out with .Net.” While Sun and other companies refer to Java as a standard, Java is no such thing. Sun will argue that the involvement of hundreds of vendors in the JCP means that Java’s fate is controlled by the same democratic process that controls standards coming out of the World Wide Web Consortium (W3C) or International Standards Organization (ISO). In my book, a technology that has not received the imprimatur of an independent standards setting consortia like the W3C or ISO–especially a technology that’s not royalty-free–is no more a standard than other technologies where prevalence gets confused with the term “standard” and royalties are charged for deployment (i.e.: Intel’s x86 instruction set or Microsoft’s Windows). ECMA and ISO standardization In December 2000, an ECMA committee was formed to produce a standard for C# and a subset of the .NET Framework (the Common Language Infrastructure — CLI). Two standards, one for the C# language and another for the runtime, were adopted in December, 2001 and are being submitted to ISO for further standardization. Members of the ECMA standards committee included Alcatel, Compaq, HP, IBM, Microsoft, Netscape, Sun, and other companies. The ECMA standards encompass the entire C# language and a subset of the .NET Framework called the Common Language Infrastructure (CLI). These standards are available for free download and are not copyright nor trade secret, and do not require licensing. Anyone may implement C# and the CLI on any hardware and operating system without entering into a license agreement. The C# standard is designated as ECMA-334 and the CLI standard as ECMA-335. Each is about 500 printed pages and is available for free download as a PDF. Both are very detailed and are intended to facilitate interoperable implementations among diverse platforms. Yes, Microsoft is the primary force driving changes into C# & .NET but that’s only because they want to kill Java so badly The deal is, that if tomorow, Microsoft stops further development of .NET, the ISO standard comitee (includes IBM and Sun btw) can/will drive it further without MS. If Sun would do the same… Then you are screwed. But nither will do that, because (a) Microsoft is betting everything they have on .NET (sumbitting it to the ECMA proves that) and they are losing developers over Java and (b) Java is basicly everything Sun’s got to survive. None of the technologies are going away anytime soon. In fact you might even see Sun sumbitting Java to ECMA for standardization, becasue that’s one of the (very big) advantages .NET has over Java. 2005-03-14 5:04 am Yes, it is true. But IMHO if the SUN out of business the java will also very risky, because the SUN-M$ agreement with java and M$ patents not refer for open source implementations. And if any SCO-like company buy the SUN, the java can be very problematic. PHP/Python, etc: IMHO this systems are also hurts at least one of 10 000 patents of M$. 2005-03-14 5:19 am IMHO at this moment the .NET on windows the safest solution. And if M$ will sue gcj+klasspath, PHP, python or any other system, it will sue this systems on every platform (not only on *nix, but also on windows) and in this case the users/developers of this technologies will be in a very big trouble). 2005-03-14 8:24 am I hear there’s only VS.NET to develop ASP.NET applications. What about the free Web Matrix? What about Visual Web Developer 2005 Express, which is still free (beta)? http://www.asp.net/webmatrix/default.aspx?tabIndex=4&tabId=46 http://lab.msdn.microsoft.com/express/vwd/default.aspx 2005-03-14 10:38 am I hear there’s only VS.NET to develop ASP.NET applications. What about the free Web Matrix? What about Visual Web Developer 2005 Express, which is still free (beta)? Well, they’re both Microsoft products, but to me that’s beside the point. Visual Studio .NET is good, despite what everyone who doesn’t use it says. If you write all your code in Emacs, then I guess there’s no point in trying to convert you, but Visual Studio .NET isn’t all that horrible. OK, it forces you to code in a certain way. OK, it hogs RAM and pages your machine hard. But for what it does, it’s good. Microsoft treats its developers better than it treats its users (OK, that’s a given, it’s impossible to treat anybody worse). And Java vs .NET arguments are pointless, because you code what you are told to code (or you find another job). If you’re an expensive Chief Technology Officer who pulls the strings, you can argue. But most people here aren’t. 2005-03-14 3:50 pm Wow, really? OK. You tell me what IDE people are going to be using for Mono and ASP.Net running with XSP that is on a par with Visual Studio.Net. Make my day. My day job is programming with the .NET Framework using VB.NET. I’ve actually used Mono and mod_mono with Apache to create some ASP.NET pages using C# on Linux. I will grant you that there are no drag and drop tools for building your ASP.NET Web interface on Linux. (As an aside, I think that if you cannot write your Web interface whether it be for PHP, JSP, ASP.NET, etc., then you have no business building Web-based applications.) However, you can use MonoDevelop to write your code behind pages. MonoDevelop gives many of the nice things available in VS.NET, such as adding references, code completion, and easy access to the Framework documentation. You can then write out your aspx pages using your favorite text editor. As a developer, this is acceptable. 2005-03-14 4:45 pm this “you can’t use ASP.NET due to patents” is a load of rubbish. patents could easily effect what you do with any language / framework. You think using PHP protects you from a patent on a method ASP.NET uses ? think again. even if there is prior art, unless you have deep pockets, you are screwed. 2005-03-14 6:31 pm Good reason to use .NET and mono to develop web apps its because you can choose your prefered programming language and take advantage of the framework. You’re not tied to inferior languages like php or java… You can choose anything you want: lisp, smalltalk, c#, delphi… 2005-03-14 8:35 pm serving ASP in Linux is all fine and dandy but VIEWING them under Linux is a PITA whats the story with that ? try here <a href=”http://donley.tk> I promise you, I have not altered the page so that it runs like treacle on Linux 2005-03-14 8:38 pm I forgot the ” in the link hehehe <a href=”http://donley.tk“> 2005-03-14 9:59 pm what exactly are we looking for?? (aside from the not-so-specatular design) 2005-03-14 10:28 pm PHP, J2EE, ASP.NET, Ruby on Rails, Plone, Flash etc. are all very different software projects from each other, with different backgrounds, histories, companies supporting them etc. What is rubbish is claiming that software patents could affect anything anyway, and that all software is as vulnerable to software patents. Just the fact that the whole US (software) patent system has become a huge mess doesn’t yet mean that all software and its usage is under similar patent threats. For example, HTML and Flash are two completely different beasts, aren’t they? Software technologies and their relation to each other and patents varies a lot, licenses and patents are different, companies and their official patent and other policies differ a lot too. ASP.NET on Linux is rather a straight copy of the patented, proprietary MS ASP.NET on Windows technology. You just cannot compare that situation to PHP, for example. 2005-03-15 5:59 am PHP, J2EE, ASP.NET, Ruby on Rails, Plone, Flash etc. are all very different software projects from each other, with different backgrounds, histories, companies supporting them etc. It doesn’t matter if you based your company to PHP and the M$ kill the PHP with their patetns. And it is also true to Ruby, Python, etc. The java at this moment safe, but if SUN is out of the business the M$-SUN agreement will no longer valid. Flash is very good thing, but only on client side (and IMHO the client-side .NET will kill it). 2005-03-15 2:12 pm It doesn’t matter if you based your company to PHP and the M$ kill the PHP with their patetns. How could they do that? What patents exactly would allow them to do that? I don’t think that they would even dare to try. PHP is a very independent project from Microsoft technology. PHP developers haven’t been copying MS technology. I think that developers and companies relying on PHP would easily win in court if MS tried to kill PHP with some odd patents because it just seems very clear that PHP is not violating any MS patents. In the case of ASP.NET on Linux, however, it is easy to point out, with patents or without them, that ASP.NET on Linux is practically just a straight copy of Microsoft’s patented proprietary ASP.NET on Linux technology. And hey (to some commentators) the article here is about ASP.NET on Linux not about ASP.NET on Windows (and about the related IDE and other tools, or how could ASP.NET on Windows may or may not be), nor is it about Mono and GTK#, for example, that may be relatively safe legally(?). The problematic .NET technologies from Mono’s point of view are especially ASP.NET, ADO.NET and Windows forms. 2005-03-15 2:17 pm Metic: …practically just a straight copy of Microsoft’s patented proprietary ASP.NET on Linux technology. Augh, a typo… Naturally I meant to say: …practically just a straight copy of Microsoft’s patented proprietary ASP.NET on Windows technology 2005-03-15 2:21 pm Metic: …, or how could ASP.NET on Windows may or may not be a typo #2…, meant to say: …, or how good ASP.NET on Windows may or may not be Yeah, sorry, maybe I ned a coffee break or something… =) 2005-03-15 3:23 pm How could they do that? What patents exactly would allow them to do that? I don’t know, I am not a lawyer and I don’t know the M$ patent portfolio. But if you have ~ 10 000 patents, probably you can find one or more suitable.