Here you can find WCF Interview Questions and Answers.
In this WCF Interview Questions and Answers section you can learn and practice WCF Interview Questions and Answers to improve your skills in order to face technical inerview by IT companies. By Practicing these interview questions, you can easily crack any WCF interview.
AllIndiaExams provides you lots WCF Interview Questions and Answers with proper explanation. Fully solved examples with detailed answer description. All students, freshers can download WCF Interview Questions and Answers as PDF files and eBooks.
You no need to worry, we have given lots of WCF Interview Questions and Answers and also we have provided lots of FAQ's to quickly answer the questions in the WCF technical interview.
What is WCF?
Windows Communication Foundation (WCF) is an SDK for developing and deploying services on Windows. WCF provides a runtime environment for services, enabling you to expose CLR types as services, and to consume other services as CLR types. WCF is part of .NET 3.0 and requires .NET 2.0, so it can only run on systems that support it. WCF is Microsoftâ€™s unified programming model for building service-oriented applications with managed code. It extends the .NET Framework to enable developers to build secure and reliable transacted Web services that integrate across platforms and interoperate with existing investments. Windows Communication Foundation combines and extends the capabilities of existing Microsoft distributed systems technologies, including Enterprise Services, System.Messaging, Microsoft .NET Remoting, ASMX, and WSE to deliver a unified development experience across multiple axes, including distance (cross-process, cross- machine, cross-subnet, cross-intranet, cross-Internet), topologies (farms, fire-walled, content-routed, dynamic), hosts (ASP.NET, EXE, Windows Presentation Foundation, Windows Forms, NT Service, COM+), protocols (TCP, HTTP, cross-process, custom), and security models (SAML, Kerberos, X509, username/password, custom).
What is Windows card space?
Windows card space is a central part of Microsoft's effort to create an identify met system, or a unified, secure and interoperable identify layer for the internet.
What are the main components of WCF?
There are three main components of WCF: Service class Hosting environment End point
What are the advantages of hosting WCF Services in IIS as compared to self hosting?
There are two main advantages of using IIS over self hosting. Automatic activation Process recycling
What is .NET 3.0?
In one simple equation .NET 3.0 = .NET 2.0 + Windows Communication Foundation + Windows Presentation Foundation + Windows Workflow Foundation + Windows Card Space.
What is the difference between WCF and Web Services?
Web service make a use of http transport protocol with the SOAP message to tranfer the message . Where as with the WCF we can make a use of TCP, MSMQ , HTTP tranport with SOAP to tranfer the message. WCF is more flexible that webservice. In WCF we have the flexibility of versioning in which the client can access the new version of the service without disturbing the older version. where as in web service we donâ€™t have such flexibility.
What Message Exchange Patterns (MEPs) supported by WCF? Explain each of them briefly.
1. Request/Response 2. One Way 3. Duplex Request/Response Itâ€™s the default pattern. In this pattern, a response message will always be generated to consumer when the operation is called, even with the void return type. In this scenario, response will have empty SOAP body. One Way In some cases, we are interested to send a message to service in order to execute certain business functionality but not interested in receiving anything back. OneWay MEP will work in such scenarios. If we want queued message delivery, OneWay is the only available option. Duplex The Duplex MEP is basically a two-way message channel. In some cases, we want to send a message to service to initiate some longer-running processing and require a notification back from service in order to confirm that the requested process has been completed.
What is DataContractSerializer and How its different from XmlSerializer?
Serialization is the process of converting an object instance to a portable and transferable format. So, whenever we are talking about web services, serialization is very important. Windows Communication Foundation has DataContractSerializer that is new in .NET 3.0 and uses opt-in approach as compared to XmlSerializer that uses opt-out. Opt-in means specify whatever we want to serialize while Opt-out means you donâ€™t have to specify each and every property to serialize, specify only those you donâ€™t want to serialize. DataContractSerializer is about 10% faster than XmlSerializer but it has almost no control over how the object will be serialized. If we wanted to have more control over how object should be serialized that XmlSerializer is a better choice.
Explain briefly different Instance Modes in WCF?
WCF will bind an incoming message request to a particular service instance, so the available modes are: Per Call: instance created for each call, most efficient in term of memory but need to maintain session. Per Session: Instance created for a complete session of a user. Session is maintained. Single: Only one instance created for all clients/users and shared among all.Least efficient in terms of memory.
What are the different bindings supported by WCF?
basichttpbinding wsHttpBinding wsDualHttpBinding - for the duplex (callback) contracts netTCPBinding netMSMQBinding -- for message queuing netNamesPipedBinding netPeerTcpBinding msmqIntegrationBinding wsDualHttpBinding wsFederationBinding.