O'Reilly logo

WCF 4.0 Multi-tier Services Development with LINQ to Entities by Mike Liu

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Summary

In this chapter, we have added the third layer—the data access layer—to RealNorthwindService. We have also added exception handling to the service. The key points covered in this chapter include:

  • Database connection strings should be stored in configuration files, not in C# code
  • The data access layer should contain the code to access the underlying databases, it should not contain business logic
  • If service contracts have been changed, the client has to update the reference to the service
  • You should throw fault contracts instead of exceptions to the client from WCF services
  • A handled fault exception won't make a communication channel invalid, but an exception will

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required