Welcome to MSDN Blogs Sign in | Join | Help

Welcome to The Metaverse

Navigating the service-oriented, identity aware metaverse

News

  • Disclaimer:
    The content of this blog are my own personal opinions and do not necessarily represent Microsoft's position, commitments or strategy. In addition, my thoughts and opinions often change, and as a weblog is intended to provide a semi-permanent point in time snapshot you should not consider out of date posts to reflect my current thoughts and opinions.




    Add to Technorati Favorites
Two new whitepapers

I have just published two more whitepapers relating to building distributed systems on the Microsoft platform on MSDN:

  1. Performance of ASP.NET Web Services, Enterprise Services, and .NET Remoting
  2. System.Messaging Performance

These papers (written by Ingo and I), combined with our prescriptive guidance on building distributed services today,  aim to provide guidance to help you make the right decisions for your scenarios on where and when to most appropriately use Microsoft's currently shipping distributed systems technologies. I hope you find the content in these papers useful and look forward to your comments and thoughts.

Posted: Tuesday, August 16, 2005 9:18 AM by RichTurner666

Comments

Tom Fuller said:

After reading through the first whitepaper titled "Performance of ASP.NET Web Services, Enterprise Services, and .NET Remoting" I can't help but feel like there are a couple of additional tests that might make this much more meaningful to developers making decisions about distributed object technologies. I would also like to pose some questions about the potential impacts some other tests might have on these results. I understand the objectives of the test but I wonder if we aren't asking the wrong questions in some cases.

My first question is: What is the reason for distributing code in this manner if not for interoperability anyway? I guess there are some scenarios where multiple .Net clients need the same reusable component where this might come in handy but how often is deploying the code to multiple locations really that big of a problem? Is the belief that the application logic could in fact scale differently than the UI? Is there potentially different security requirements for the middle tier that would require physical separation?

We have looked at all the specific technologies used for distributing your code physically but there is no attention paid to the optimal case which is keeping your execution in the same process/app domain. There are some specific examples that show how the work at the server side is quite small and the transport/serialization time becomes a large part of the expense. My question would be: Why take that expense at all? The scenario you present is one where a simple read operation is performed, would that ever really make sense to distribute? I will again state that I realize that was not the purpose of the whitepaper but I can't help but want to know exactly what is the price I pay to use even the fastest of these distributed technologies. I guess I should stop being lazy and just extend the test you already started for me :)

My second question is related to how much impact load would have on these numbers. I know you state early in the whitepaper that this is not an exhaustive load test but I find myself extremely curious at what point ASMX begins to require multiple servers in a load balanced environment. I know this is not an exhaustive whitepaper on capacity planning but I'm hoping others with more experience in this field can help with some direction. In your opening you say that "multiple clients do not change significantly the absolute or relative performance of the technologies being tested". Can I take that to mean this is a straight forward mathematical algorithm that'll give me my service capacity under concurrent request load. So for example if you say ASMX can handle 63 cps and we have 500 clients simultaneously making those requests on the server is it 63 / 500 = .126 cps. It sure doesn't seem correct so I'm really curious how to move forward doing this analysis (which by the way I'm trying to do in my job today). I'm not asking you to change your test in any way, I would just like some good resources for how this is done in practice out in the real world. I'm sure you don't go far in this topic before IIS tuning becomes a portion of the discussion too.

Lastly I see no mention of using some of the Begin/End async functionality built into ASMX. It was my understanding that this would greatly increase the amount of incoming requests IIS could handle. Is that true or did I misinterpret those materials.

In summary I really found this whitepaper a great read but I would caution those that look at it and on the surface use it as a justification for the "web services everywhere" approach to designing an application. There are still other viable solutions that don't involve distributing your application logic at all. I found some of the results very intriguing too, how about that the remoting SOAP formatter takes longer than ASP.NET web services. I would have expected them to be much closer.

I'll end with this question, when do we get to see how WCF performs in a similar type of testing? I'd love to hear how well the new xml serializer handles text base communications over http and of course I would assume the .Net to .Net transports are smoking fast. Another interesting statistic will be how much faster or slower a service will run when it is hosted within and then outside of of IIS.

Thank you Rich and Ingo, this was a great read.
# August 17, 2005 10:41 PM

RichTurner666 said:

Thanks for your detailed comments Tom - I appreciate you taking the time to put forward your points, all of which I completely understand.

To your points:

1) When should I distribute my system:
Martin Fowler's first law of distributed systems essentially states that when building a distributed system, <b>don't</b>! Keep services that need to talk intensively with each another as close to one another as possible - on the same box if you can. With this I totally agree - it's a point I raised in an earlier whitepaper I published on ES/COM+ performance. However, there are many, many scenarios where distributing processing & logic around your environment is a very good idea. For example, hiding your databases behind a layer of business logic which can provider governance, logging, security, business-rule enforcement, etc., is often a good idea. You are unlikely to want to have to deploy all of this logic to every single machine that could ever want to act on your data, so you'd probably want to put this somewhere centrally in your datacenter and prevent direct access to the DB servers as much as possible. And let's not even begin to consider the organizational, legal, security and other type of reasons one might wish to distribute one's systems.

This becomes even more important if you have, for example, 60,000 desktops in 14 different time-zones in 10 different countries all needing to access several business apps (as several of our clients do). Putting the core business logic in a centrally accessable service and just deploying a lightweight client to the desktops often works really well if you design for this scenario.

This leads us on to your second point:

2) How do I handle Load in a distributed environment?
This depends on two things:

a) Have you designed your system to be sessionless?
b) Does your distributed systems technology support load-balancing?

If you can answer yes to both of the above, then you most likely have a great opportunity to use some form of network load balancing to seamlessly spread the workload across n machines.

If not, then you're into more complex scenarios where you might have to engineer some form of client-side load-balancing strategy, or you might simply not be able to do this.

Regarding our sample code: Yes, they were partially contrived. No, they're not a reference for how to build expertly designed distributed systems - that would have been well beyond the scope of the paper. Alas, however, the type of implementation you see here is extremely common in the many hundreds of distributed systems that Ingo and I (along with many of our colleagues) have seen for many years and continue to see today, so maybe they're not as contrived as you'd think! ;)

What we needed were some operations which performed some significant work (writing to a DB), moderate work (reading a catalog from the DB), minimal work (reading one record from the DB) and no work (empty method call).in order to illustrate the different performance characteristics of each type of interaction. Ignore the detail of the method implementations - they're not the important piece of the story.

The important piece is that we're not just testing transport times - we're testing scenarios much closer to the real-world experience.

Thanks again,

Rich.
# August 18, 2005 2:12 PM

David Ing said:

Hi Rich,

Good work - this is a nice set of papers.

A useful 'build' on this work would be to explore down the relative perf of the ASMX WS track, i.e. a set that compares the following would be interesting to me:

- Bare ASMX (baseline, as in the tests already)
- ASMX WSE 3.0 username/token Basic Sec Profile
- ASMX WSE 3.0 kerberos/intergrated
- ASMX WSE 3.0 x509 client cert
- Indigo set for comparison?

We've done our own relative tests and been surprised by the results. What do you think, any chance of a follow-on from these papers?

Thanks,
David
# August 22, 2005 3:31 PM

web designer said:

very nice work.
# August 27, 2005 9:24 AM

A Service Oriented Geek said:

I&#39;ve been having some great conversations with my SOA blog buddies and I wanted to share. 1. 10 Things

# June 27, 2007 11:37 PM
Anonymous comments are disabled
Page view tracker