Share via


Checklist: Web Services Performance

 

Retired Content

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

patterns & practices Developer Center

Improving .NET Application Performance and Scalability

J.D. Meier, Srinath Vasireddy, Ashish Babbar, and Alex Mackman
Microsoft Corporation

May 2004

Related Links

Home Page for Improving .NET Application Performance and Scalability

Send feedback to Scale@microsoft.com

patterns & practices Library

How to Use This Checklist

This checklist is a companion to Chapter 10, "Improving Web Services Performance"

Design Considerations

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Design chunky interfaces to reduce round trips.
Ff647682.checkbox(en-us,PandP.10).gif Prefer message-based programming over remote procedure call (RPC) style.
Ff647682.checkbox(en-us,PandP.10).gif Use literal message encoding for parameter formatting.
Ff647682.checkbox(en-us,PandP.10).gif Prefer primitive types for Web service parameters.
Ff647682.checkbox(en-us,PandP.10).gif Avoid maintaining server state between calls.
Ff647682.checkbox(en-us,PandP.10).gif Consider input validation for costly Web methods.
Ff647682.checkbox(en-us,PandP.10).gif Consider your approach to caching.
Ff647682.checkbox(en-us,PandP.10).gif Consider approaches for bulk data transfer and attachments.
Ff647682.checkbox(en-us,PandP.10).gif Avoid calling local Web Services.

Connections

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Configure the maxconnection attribute.
Ff647682.checkbox(en-us,PandP.10).gif Prioritize and allocate connections across discrete Web services.
Ff647682.checkbox(en-us,PandP.10).gif Use a single identity for outbound calls.
Ff647682.checkbox(en-us,PandP.10).gif Consider UnsafeAuthenticatedConnectionSharing with Windows Integrated Authentication.
Ff647682.checkbox(en-us,PandP.10).gif Use PreAuthenticate with Basic authentication.

Threading

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Tune the thread pool using the formula for reducing contention.
Ff647682.checkbox(en-us,PandP.10).gif Consider minIoThreads and minWorkerThreads for intermittent burst load.

One Way (Fire and Forget) Communication

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Consider using the OneWay attribute if you do not require a response.

Asynchronous Web Methods

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Use asynchronous Web methods for I/O operations.
Ff647682.checkbox(en-us,PandP.10).gif Do not use asynchronous Web methods when you depend on worker threads.

Asynchronous Invocation

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Consider calling Web services asynchronously when you have additional parallel work.
Ff647682.checkbox(en-us,PandP.10).gif Use asynchronous invocation to call multiple unrelated Web services.
Ff647682.checkbox(en-us,PandP.10).gif Call Web services asynchronously for UI responsiveness.

Timeouts

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Set your proxy timeout appropriately.
Ff647682.checkbox(en-us,PandP.10).gif Set your ASP.NET timeout greater than your Web service timeout.
Ff647682.checkbox(en-us,PandP.10).gif Abort connections for ASP.NET pages that timeout before a Web services call completes.
Ff647682.checkbox(en-us,PandP.10).gif Consider the responseDeadlockInterval attribute.

WebMethods

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Prefer primitive parameter types.
Ff647682.checkbox(en-us,PandP.10).gif Consider buffering.
Ff647682.checkbox(en-us,PandP.10).gif Consider caching responses.
Ff647682.checkbox(en-us,PandP.10).gif Enable session state only for Web methods that need it.

Serialization

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Reduce serialization with XmlIgnore.
Ff647682.checkbox(en-us,PandP.10).gif Reduce round trips.
Ff647682.checkbox(en-us,PandP.10).gif Consider XML compression.

Caching

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Consider output caching for less volatile data.
Ff647682.checkbox(en-us,PandP.10).gif Consider providing cache-related information to clients.
Ff647682.checkbox(en-us,PandP.10).gif Consider perimeter caching.

State Management

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Use session state only where it is needed.
Ff647682.checkbox(en-us,PandP.10).gif Avoid server affinity.

Attachments

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Prefer Base64 encoding. Direct Internet Message Encapsulation (DIME) is a supported part of Web Services Enhancements (WSE), but Microsoft® is not investing in this approach long-term. DIME is limited because the attachments are outside the SOAP envelope.

COM Interop

Check Description
Ff647682.checkbox(en-us,PandP.10).gif Avoid single-threaded apartment (STA) COM objects.

patterns & practices Developer Center

Retired Content

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

© Microsoft Corporation. All rights reserved.