Enterprise Services with the .NET Framework : Developing Distributed Business Solutions with .NET Enterprise Services
暫譯: 使用 .NET Framework 的企業服務:開發分散式商業解決方案與 .NET 企業服務

Christian Nagel

  • 出版商: Addison Wesley
  • 出版日期: 2005-06-01
  • 售價: $2,370
  • 貴賓價: 9.5$2,252
  • 語言: 英文
  • 頁數: 576
  • 裝訂: Paperback
  • ISBN: 032124673X
  • ISBN-13: 9780321246738
  • 相關分類: .NET
  • 海外代購書籍(需單獨結帳)

買這商品的人也買了...

相關主題

商品描述

Description:

"For anyone involved in the .NET community, it's hard to not have heard of Christian Nagel. Christian is a true heavyweight of .NET in general, and Enterprise Services in particular. By taking a relatively trivial application and architecting it in a way that would allow it to scale without any rework, users will find that using the techniques employed in this book will be of benefit to virtually any company that is running distributed or enterprise applications."

—William G. Ryan, Microsoft MVP, Senior Software Developer, TiBA Soutions, LLC

"Whether you are a seasoned architect or a new developer, distributed application development can be difficult, since it covers such a wide range of complex technologies. Until now there was precious little in the way of guidance—let alone a consolidated reference. Christian has provided that reference and more—going from the individual technologies to the big picture on how to architect and develop scalable distributed applications. Technical goodness through and through!"

—Clayton Burt, Managing Partner, Onzo, LLC

"Making the transition to distributed application architecture introduces many issues in security and deployment and requires a new way of thinking about events, transactions, and messaging. This book shows developers and architects alike how to use .NET Enterprise Services to create robust, secure, and maintainable applications in a distributed environment. This book is an excellent guide to the sometimes overwhelming field of .NET Enterprise Services."

—Brian Davis, Director of Software Development, InfoPro Group, Inc., Co-Creator, KnowDotNet.com

Enterprise Services with the .NET Framework is the only book that experienced .NET developers need to learn how to write distributed, service-oriented applications. Filled with clear examples in C# (with Visual Basic .NET examples available on the Web), this book will quickly get you up to speed on building distributed applications with serviced components. You'll also learn about Indigo, Microsoft's next-generation technology for building distributed applications, and how it compares to Enterprise Services.

Microsoft Regional Director, MVP, and veteran author Christian Nagel introduces and clearly explains the four major services included in Enterprise Services: Automatic Transactions, Queued Components, Loosely Coupled Events, and Role-Based Security. From his in-depth coverage, you'll learn

  • How to create a serviced component, how serviced objects are activated, and how to use the different kinds of object contexts

  • How to manage concurrency and synchronization for serviced components to achieve optimal performance and data integrity

  • How to integrate COM components with the .NET Framework

  • How to use serviced components over a network with DCOM, SOAP Services, and ASP.NET Web services

  • How to use .NET Enterprise Services transactions to achieve Atomicity, Consistency, Isolation, and Durability

  • How to build a compensating resource manager to allow your own resources to participate in Enterprise Services transactions

  • How to maintain application state in a client application, in a serviced component, in shared properties, or in a database

  • How to create and use Loosely Coupled Events using COM+

  • How to secure a distributed solution using authorization, authentication, impersonation, and confidentiality

  • How to deploy and configure Enterprise Services applications

 

Table of Contents:

About the Author

    Foreword

    Preface

    Acknowledgments

1. Introducing .NET Enterprise Services.

    Building Applications

      Application Layers

      Logical Tiers and Physical Systems

      Clustering Solutions

      Service-Oriented Architecture

      Smart Clients

    The History of Application Services

      COM and .NET

      Microsoft Transaction Server

      COM+ 1.0

    .NET Enterprise Services

      Applications and Components

      Declarative Programming

      Catalog

      Administration

    Application Services

      Automatic Transactions

      Queued Components

      Loosely Coupled Events

      Role-Based Security

      New Features with COM+ 1.5

    Summary

2. Object Activation and Contexts.

    Contexts

      .NET Remoting Contexts

      Contexts with Serviced Components

      Mixing .NET and COM+ Contexts

    Creating a Serviced Component

      Assembly Attributes

      Signing the Assembly

      Global Assembly Cache

      Using Interfaces

      ServicedComponent Class

      Component Registration

    Client Applications

    Debugging

      Library Applications

      Server Applications

    Object Activation

      Construction Strings

      Just-in-Time Activation (JITA)

      JITA and Object Disposing

      Object Pooling

      Private Components

    Application Activation

    Summary

3. Concurrency.

    Synchronization Overview

      Using Locks

      Interlocked Class

      More Synchronization Options

    Apartments

      Single-Threaded Apartments

      Multithreaded Apartments

      Thread-Neutral Apartments

    .NET Enterprise Services Synchronization

      Activity

      Configuring Synchronization

      Synchronization Example

      Reentrancy

      Selecting the Synchronization Option

    Services Without Components

      ServiceDomain Class

      ServiceConfig Class

      Activity Class

      Using a New Activity

      Starting a New Context

    Summary

4. COM Interop.

    .NET Clients Without COM Interop

      Side-by-Side Support

    COM Interoperability

      COM Callable Wrappers and Runtime Callable Wrappers

      Default COM Configuration

      Generated Type Library

    COM Interface Types

      Custom Interfaces

      Dispatch Interfaces

      Dual Interfaces

      ComVisible Attribute

    Versioning

      Applications

      Components

      Interfaces

      COMCompatibleVersion Attribute

    Finding Assemblies

      Private and Shared Assemblies

      COM Registry Entries

      COM and .NET Requirements

    Visual Basic 6 Clients

    C++ COM Clients

    Scripting Clients

    Calling a COM Object

      C++ Component

      Runtime Callable Wrapper

      .NET Component

      Registration

      Client Application

    Summary

5. Networking.

    DCOM

      DCOM Transport Protocols

      Application Proxies

      Creating an Application Proxy

      Installing the Application Proxy

      Creating a DCOM Client Application

    SOAP Services

      .NET Remoting Overview

      Creating a Serviced Component Using .NET Remoting

      Configuring the Server Application

      Creating a .NET Remoting Client

      Disadvantages of SOAP Services

    Web Services

      Overview

      Implementing a Web Service with ASP.NET

      Creating a Proxy

    Summary

6. Data Access.

    ADO.NET Overview

    Sample Database

    Entity Classes

    Database Access

      Database Query

      Insert

      Update

      Calling Stored Procedures

    Datasets

      Filling Datasets

      Updating Datasets

    Summary

7. Transaction Services.

    Transaction Overview

      ACID Properties

      Distributed Transactions

    Programmatic Transactions

    Automatic Transactions

      Transaction Attributes

      Transaction Streams

      Transaction Outcomes

      ContextUtil Methods

      Automatic Transaction Example

      Setting the Transactional Vote

      AutoComplete Attribute

      Distributed Transactions

    Transactions with Services Without Components

    Transactions Support with ASP.NET

    Transaction Isolation

      Potential Transaction Isolation Problems

      Transaction Isolation Levels

    Monitoring the DTC

    Transactions with .NET 2.0

    Summary

8. Compensating Resource Management.

    CRM Architecture

    CRM Application Classes

    CRM Application Example

      Application Configuration

      Helper Classes

      Worker Components

      Compensator Components

      Client Applications

    Monitoring

    Summary

9. State Management.

    State Characteristics

    Stateful or Stateless Components

    Databases and Files

      Isolated Storage

      Active Directory

    Shared Property Manager

      Shared Property Group Manager

      Shared Property Group

      Shared Property

      Client Application

      SPM State Characteristics

    ASP.NET State Management

      Session

      Cache

      Accessing ASP.NET State from Within Serviced Components

      ASP.NET State Characteristics

    Client State Management

      SOAP Headers

      .NET Remoting Call Contexts

    Summary

10. Queued Components.

    Overview

    Product Versions

      Message Queuing Server

      Message Queuing Client

    Message Queuing Features

      Message Queues

      Messages

      Administration Tools

    Creating a Queued Component

      Assembly Attributes

      Interface Definition

      The CourseControl Class

      Registration

    Client

    Error Handling

    Transactional Queues

    Returning Data

    Summary

11. Loosely Coupled Events.

    LCE Overview

      Event Class

      Publishers

      Subscribers

      Filters

    Programming LCEs

      Event Class

      Publisher

      Persistent Subscriber

      Transient Subscriber

    Filters

      Subscriber Filters

      Publisher Filters

    Using LCEs Across the Network

      LCE Routing

      Event Class Proxies

    LCE and Queued Components

      Event Classes as Queued Components

      Subscribers as Queued Components

    Summary

12. Security.

    Security Overview

      Windows Security

      SQL Server

      Internet Information Server

      ASP.NET Web Applications

      ASP.NET Web Services

      Enterprise Services

    Identity

    Authorization

      Enabling Access Checks

      Defining Roles

      Defining Role Access

      Checking Roles Within Methods

    Authentication Levels and Impersonation

      Authentication Levels

      Impersonation

      Reading the Identity of the Caller

    Enterprise Services and .NET Remoting

    Summary

13. Deployment and Configuration.

    Deployment

      Automatic Deployment

      Manual Deployment

      Creating a Custom Installer

      Creating an Installation Package

    Attributes

    Admin Components

      Configuring the Application as a Service

    Summary

14. The Future of Distributed Applications.

    Web Services Specifications

      Network Communication

      Reliable Messaging

      Transactions

      Security

    Indigo

      Hosting Environments

      System Services

      Connector

      Service Model

      Messaging Services

    Moving from Enterprise Services to Indigo

    Summary

15. Case Study.

    Use Case-Course Management

    Sample Projects

    CourseManagement.Entities-Entity Classes

    The CourseManagement Database

    CourseManagement.Data-Data Access

    CourseManagement.Control-Serviced Components

    CourseManager-Windows Forms Client

    CourseRegistrationService-Web Services

    CourseRegistrationWeb-Web Application

    CourseRegistration-Queued Component

    Summary

Final Thoughts.

Further Reading.

Index.

商品描述(中文翻譯)

描述:
「對於任何參與 .NET 社群的人來說,幾乎不可能沒聽過 Christian Nagel。Christian 是 .NET 領域的重量級人物,尤其是在企業服務方面。透過將一個相對簡單的應用程式架構設計成可以無需重工而擴展的方式,使用者會發現本書中所採用的技術對於幾乎任何運行分散式或企業應用程式的公司都有益處。」
—William G. Ryan,微軟 MVP,資深軟體開發人員,TiBA Solutions, LLC

「無論你是經驗豐富的架構師還是新手開發人員,分散式應用程式開發都可能很困難,因為它涵蓋了如此廣泛的複雜技術。直到現在,幾乎沒有任何指導可言,更不用說綜合參考資料了。Christian 提供了這樣的參考資料,並且不止於此——從個別技術到如何架構和開發可擴展的分散式應用程式的全貌。技術內容非常出色!」
—Clayton Burt,管理合夥人,Onzo, LLC

「轉向分散式應用程式架構會引入許多安全性和部署方面的問題,並需要對事件、交易和消息傳遞有新的思考方式。本書向開發人員和架構師展示了如何使用 .NET Enterprise Services 在分散式環境中創建穩健、安全且可維護的應用程式。本書是進入有時令人不知所措的 .NET Enterprise Services 領域的絕佳指南。」
—Brian Davis,軟體開發總監,InfoPro Group, Inc.,KnowDotNet.com 的共同創辦人

《使用 .NET Framework 的企業服務》是經驗豐富的 .NET 開發人員學習如何編寫分散式、面向服務的應用程式所需的唯一書籍。本書充滿了清晰的 C# 範例(並且在網路上提供 Visual Basic .NET 範例),將迅速幫助你掌握使用服務組件構建分散式應用程式的技巧。你還將了解 Indigo,微軟下一代的分散式應用程式構建技術,以及它與企業服務的比較。

微軟區域總監、MVP 和資深作者 Christian Nagel 介紹並清楚解釋了企業服務中包含的四大主要服務:自動交易、排隊組件、鬆耦合事件和基於角色的安全性。透過他的深入探討,你將學到:

- 如何創建服務組件,服務對象是如何被激活的,以及如何使用不同類型的對象上下文
- 如何管理服務組件的並發性和同步性,以實現最佳性能和數據完整性
- 如何將 COM 組件與 .NET Framework 整合
- 如何通過 DCOM、SOAP 服務和 ASP.NET Web 服務在網路上使用服務組件
- 如何使用 .NET Enterprise Services 交易來實現原子性、一致性、隔離性和持久性
- 如何構建補償資源管理器,以允許自己的資源參與企業服務交易
- 如何在客戶端應用程式、服務組件、共享屬性或數據庫中維護應用程式狀態
- 如何使用 COM+ 創建和使用鬆耦合事件
- 如何使用授權、身份驗證、模擬和保密來保護分散式解決方案
- 如何部署和配置企業服務應用程式

目錄:
關於作者
前言
序言
致謝
1. 介紹 .NET 企業服務
- 構建應用程式
- 應用程式層
- 邏輯層和物理系統
- 集群解決方案
- 面向服務的架構
- 智能客戶端
- 應用程式服務的歷史
- COM 和 .NET
- 微軟交易伺服器
- COM+ 1.0
- .NET 企業服務
- 應用程式和組件
- 聲明式編程
- 目錄
- 管理
- 應用程式服務
- 自動交易
- 排隊組件
- 鬆耦合事件
- 基於角色的安全性
- COM+ 1.5 的新特性
- 總結
2. 對象激活和上下文
- 上下文
- .NET 遠程上下文
- 與服務組件的上下文
- 混合 .NET 和 COM+ 上下文
- 創建服務組件
- 程式庫屬性
- 簽署程式庫
- 全域程式庫快取
- 使用介面
- ServicedComponent 類別
- 組件註冊
- 客戶端應用程式
- 除錯
- 程式庫應用程式
- 伺服器應用程式
- 對象激活
- 建構字串