Professional.Open.Source.dot.NET.Development.Programming.with.NAnt.NUnit.NDoc [Electronic resources] نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

Professional.Open.Source.dot.NET.Development.Programming.with.NAnt.NUnit.NDoc [Electronic resources] - نسخه متنی

John Wait

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
لیست موضوعات
توضیحات
افزودن یادداشت جدید







Cross Platform ASP.NET and Web Services


Before diving into developing Web applications and services, it is necessary to choose a Web server. Serving up data and Web page applications is just as important as having a database in which to store the information. As you may have already guessed, there are a number of Open Source Web servers already available. Of course ASP.NET also runs within Microsoft's Internet Information Server (IIS), but IIS is not really free since it is bundled with a Windows Server and therefore incurs Windows Server Licensing pricing.

Cassini


Cassini (http://www.asp.net/Projects/Cassini/Download/Default.aspx?tabindex=0&tabid=1) is a Microsoft Shared Source Personal Web Server written entirely in C#. Figure 11-1 shows Cassini's startup page.

Figure 11-1. Microsoft's Cassini Web Server.

[View full size image]

This managed Web server shows how easy it is to use the BCL of .NET to create a Web server. While this is a useful Web server example, carefully read the Microsoft Shared Source License to ensure it meets the needs of your project, especially considering scalability and performance.

XSP


If you prefer Open Source to Shared Source, then Mono's XSP (http://www.go-mono.com/asp-netl) is for you. XSP is also completely managed and written in C# and is under a license that allows for proprietary use or Open Source use. In addition, XSP also runs on all the operating systems that Mono supports!

Apache


Apache is the most popular Web server in the world, according to Netcraft (http://www.netcraft.com) surveys. Apache (http://httpd.apache.org/) itself is also an Open Source project, which necessitated the Apache Open Source License. Mono also provides an Apache Module (mod_mono) available from http://www.go-mono.com/asp-netl. Mod_mono works with both 1.3 and 2.0 versions of Apache. This mod_mono Apache module is an extension to support ASP.NET. This requires both the Apache Web server and the Mono runtime. This broadens the operation system support for ASP.NET greatly.

Which Web Server to Use?


Well, as with many development questions, there is no one right answer. With the Web servers written in C#, there is the obvious advantage of managed environments. Many of the security problems with Web servers spring from memory buffer problems, which are not nearly as prevalent in managed code. Also XSP and Cassini could be run under most operating systems supported by a CLI implementation. XSP is certainly used on multiple platforms, and I have heard of people running Cassini on Mac using the SSCLI.

On the other hand, Apache has much more runtime and is proven to be both stable and scalable, especially the 1.3 version of Apache. Apache and its modules are mostly written in C, which is open to the "security of managed code versus the performance of unmanaged code" debate. But this debate is somewhat old and is becoming more of a moot point as hardware improves.

Chapter 10 and ASP.NET all running on Mandrake 9 Linux using Mono 0.28.


Web Services Not Just for the Web?


"Web service" is turning out to be a great misnomer. Currently, Web services are used to call methods over the Web in the most general of definitions. This was in use even before standards like SOAP came on the scene. But .NET Web services promised an easy and standardized way of creating and consuming Web services. For the most part, they have succeeded. But many developers like the more structured separation of the Formatters and Channels in .NET remoting. Microsoft quickly realized that Web services should also be channel-independent (not tied to HTTP) and released the Web Service Enhancements (WSE) that allowed Web services over TCP and a host of new APIs for WS-* specifications. Going forward, Indigo (Microsoft's New Messaging System on the next version of Windows) really eliminates the Remoting vs. Web services debate. Both sides are agreeing that Indigo is the way to go! It has been encouraging to see that several Open Source developers and CLI implementers have taken interest in Indigo. Hopefully, Microsoft will continue the current approach of open standardization for Indigo.


/ 275