Click here to Skip to main content
15,892,746 members
Articles / All Topics

New Features in WCF 4.5 - Part 2

Rate me:
Please Sign up or sign in to vote.
0.00/5 (No votes)
8 Apr 2014CPOL2 min read 5.8K   5  
This WCF Tutorial is Part-2 in series of new features in Windows Communication Foundation v4.5.

This WCF Tutorial is Part-2 in series of new features in Windows Communication Foundation v4.5. In this part, we will further explore the following interesting features:

  • Single WSDL file
  • Tooltip and Intellisense Support
In the previous WCF Tutorial, we have already explored the following features:

  • Simplified Generated Configuration
  • Validating WCF Configuration

WCF - Single WSDL file

As we know that with previous versions of WCF, WSDL (Web Service Description Language) file does not contain Data Contracts of the service. XSD files contains the Data Contracts and WSDL has import directives for the those XSD files.

Due to this dependency on other files, processing of such WSDL file by some third-party was not possible. But now with Windows Communication Foundation v4.5, all WSDL information is returned in one single document including Data Contracts.

Now when we browse to WCF 4.5 service metadata URL, we have two options as follows:

  • http://localhost:xxxx/MyServiceProject/Service1/?wsdl
  • http://localhost:xxxx/MyServiceProject/Service1/?singleWsdl
Using the above second option, we can generate a single WSDL file containing Data Contracts instead of additional references for XSD files.

WCF - Tooltip and Intellisense Support

The most annoying thing about WCF was its complex and lengthy configurations. In WCF 4.5, Microsoft tried to make a developer's life easier by simplifying configuration.
In Part-1 of this WCF Tutorial series, we have already discussed about "Simplified Generated Configuration" and "Configuration Validation". Microsoft further provided Tooltip and Intellisense support in configuration file that will definitely improve WCF developer productivity because without Intellisense support, it was hard for developers to remember all configuration details.

Following in this WCF tutorial, I have provided few screenshots for Tooltip and Intellisense support and you can easily understand that how helpful all these enhancements are.

The below two screenshots are for tooltip support displays helping text for <behavior> and <serviceMetadata> elements in web.config of a WCF Application.

WCF 4.5 - Tooltip support

WCF 4.5 - Tooltip support

Intellisense support further improves developer performance as you can see that it's supported for service name, binding and contract. Now, you as a developer don't need to memorize it or copy/paste. Just choose your service, binding and contract easily.

WCF 4.5 - Intellisense Support for Service Name

WCF 4.5 - Intellisense Support for Binding

WCF 4.5 - Intellisense Support for Contract

I have given screenshots for only few things that are related to WCF but this intellisense support is for other configuration elements and inbuilt with Visual Studio.

Hopefully, these cool features will help you as a WCF developer to perform better. We will keep exploring the other new features in WCF 4.5 in this WCF 4.5 Tutorial Series.

Other Tutorials That Might Be of Interest

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer (Senior) Emaratech
United Arab Emirates United Arab Emirates
Imran Abdul Ghani has more than 10 years of experience in designing/developing enterprise level applications. He is Microsoft Certified Solution Developer for .NET(MCSD.NET) since 2005. You can reach his blogging at WCF Tutorials, Web Development, SharePoint for Dummies.

Comments and Discussions

 
-- There are no messages in this forum --