计算机科学与技术英文文献
Introduction to ASP.NET Development To overcome the perance and scalability problems that CGI brings, Microsoft developed a new way for developers to build scalable applications. This high perance alternative is called the Internet Server Application Programming Interface(ISAPI). Instead of housing functionality in cutable files, ISAPI uses DLLs. Using DLLs instead of cutable programs has some definite perance and scalability advantages The ISAPI extension could also be called with arguments that will allow a single ISAPI extension to per multiple tasks. Just as in the CGI example, the directory must have cute permissions enabled, or the DLL will be downloaded to the client rather than run on the server. ISAPI extensions are typically used to process client requests and output a response as HTML, which is very similar to the way CGI programs are used. ISAPI filters per a function that can’t be directly duplicated with CGI applications. ISAPI filters are never explicitly called; instead, they are called by IIS in response to certain events in the life of a request. The developer can request that an ISAPI filter be called whenever any of the following events occur: 1.When the server has preprocessed the client headers 2.When the server authenticates the client 3.When the server is mapping a logical URL to a physical URL 4.Before raw data is sent from the client to the server 5.After raw data is sent from the client to the server but before the server processes it 6.When the server logs ination 7.When the session is ending As with any filter, ISAPI filters should request only the notifications it requires and process them as quickly as possible. One of the more common uses of ISAPI filters is to provide custom authentication. Another use is to modify the HTML that will be sent to the client. For example, an ISAPI filter could be used to change the background color of each page. Because ISAPI filters aren’t nearly as common as ISAPI extensions, I won’t cover them any further in this book. If you want to learn more about ISAPI extensions, you can check out my book Inside Server-Based Applications (Microsoft Press, 1999).ISAPI specifies several entry-point functions that must be exported from the DLL. Using these entry points, IIS can load the DLL; call the functions that it implements, passing in parameters as required; and receive the data to write back to the browser. ISAPI requires only two entry-point functions to be implemented these entry points, IIS can load the DLL; call the functions that it implements, passing in parameters as required; and receive the data to write back to the browser. ISAPI requires only two entry-point functions to be implemented A Better Solution: Active Server Pages If you’re wondering why we’ve dwelt on the alternatives to ASP.NET in a book about programming ASP.NET, the answer lies in the details of the implementation of ASP.NET and its predecessor, Active Server Pages (AS