Programming using Enterprise Services

Services in unmanaged code are known as COM+ services. The COM+ services infrastructure can be accessed from managed and unmanaged code. In .NET, these services are referred to as Enterprise Services. Working with transactions in Enterprise Services using ADO.NET is straightforward.

StepsProgramming using Enterprise Services

  1. Derive the components from System.EntrepriseService.ServicedComponent.

  2. Specify the custom attributes (such as Transaction, AutoComplete, and others) to specify the requested services and their options. For a complete list of the attributes, refer to the Enterprise Services documentation.

    NoteThe Timeout Option in the .NET Transaction attribute has to be explicitly set to -1 or a very high number. .NET documentation states that the ADO.NET transaction timeout default is 0, which means it will never time out. However, this actually causes an immediate transaction timeout, which rolls back the entire transaction.

  3. Sign and build the assembly.

  4. Register the assembly.