Buy Questpond's video subscriptions on
huge discount
.
Online: 12428
Home
Articles
Interviews
Forums
For Beginners
Popular Questions
ITIL Career Advice
PMP Career Advice
Career Advices
Codes
Videos
ASP.NET
ASP.NET MVC
Android Intel XDK
Sql Server
AngularJS
Bootstrap
Backbone.JS
MongoDB
LESS (CSS)
jQuery
WPF
WWF
SSIS
LightSwitch
Tutorials
News
ASP.NET MVC
|
Be Interview Ready
|
Top Performers
|
DNF MVP
|
Top Posts
|
Winners
|
Subscribe
|
Catalogs
Welcome Guest !
Register
Login
Home
>
Interviews
> WCF
WCF Interview Questions and Answers (209) - Page 9
Latest and authentic Interview questions. You can also
post an interview question
and
win monthly prizes
as well as gain community
credit points
.
209 records found.
Post
|
Interview Experiences
|
Interview FAQs
|
Online Interviews
|
Exclusive Questions
Get 650+ Questpond's Interview videos on discount
Loading ...
Which two in-built binding elements are required to use while implementing custom binding in you wcf service ?
NOTE: This is objective type question, Please click question title for correct answer.
You have a class name OrderService that include two methods to reject and process order. you need to expose the orderservice class as a wcf service and ensure it support one or more inheritance. what must you do ?
NOTE: This is objective type question, Please click question title for correct answer.
What is Binding in WCF?
Binding describes how client will communicate with services. There are different protocols available to communicate to client. Binding has several characteristics :
Transport - Define base protocol to be used like HTTP, Named Pipes, TCP and MSMQ.
Encoding(Optional) - Three types of encoding available - Text, Binary or Message Transmission Optimization Mechanism(MTOM). MTOM is interoperable message format that allows the effective transmission of attachments or large message.
Protocol(Option) - Defines information to be used in Binding such as security transaction or reliable messaging capability.
What are types of Binding available in WCF?
BasicHttpBinding
– It uses SOAP over HTTP.
WsHttpBinding
– It uses SOAP over HTTP, it also supports reliable message transfer.
NetTcpbinding
– It uses SOAP over TCP, but server and client should be in .Net.
NetNamedPipesBinding
– It uses SOAP over Named Pipes.
Explain contract and all types of contract in WCF?
Contract is platform-neutral and standard way of describing what services does. In WCF, all services are exposed as contract. There are four types of contracts :
Service Contract
– It describes operation provided by service. A service should contain at least one service contract. Service Contract is defined by using [ServiceContract] attribute , it is similar to [WebMethod] of Web Services.
Data Contract
– It describes data exchange between service and client. Data Contract is defined using [DataContract] and [DataMember] attribute.
Message Contract
– It transfers information from service to client. WCF uses SOAP message format for communication.
Fault Contract
– It handles and convey error message to the client when service get error.
Difference between WCF and Web Service?
1) Web Services support hosting in IIS whereas WCF support hosting in IIS, WAS and Self-hosting.
2) Web Services can be invoked by Http whereas WCF service can be invoked by Http, Tcp, Named Pipes, MSMQ.
3) WCF Services are more reliable and secure as compare to Web Services.
4) WCF Services are more flexible as we make a new version of service we just have to expose a new endpoint.
5) In Web Service, [WebMethod] attribute specifies the method exposed to client. In WCF [OperationContract] attribute represents the method.
What is Service Host in WCF?
Service Host object is in process of hosting the WCF service and registering endpoints. It loads the service configuration endpoints, apply the settings. System.ServiceModel.ServiceHost namespace holds this object. This object is created while self hosting the WCF service.
There is scenerio, when one client has to access service SOAP using Http and other client have to access Binary using TCP, how can you acheive?
This can be acheived by adding extra endpoint in configuration file.
<endpoint address="http://locahost:8090/Service" contact="IMathService" binding="wsHttpBinding"/>
<endpoint address="net.tcp://locahost:8080/Service" contact="IMathService" binding="netTcpBinding"/>
What are advantages of WCF?
Advantages of WCF are :
WCF is interoperable with other services but .Net Remoting requires client and service in .Net.
WCF service provides better reliability and security as compare to Web Services.
In WCF, there is no need to make much change in code for implementing the security model and changing the binding. Small change in the configuration will make your requirement.
What is WCF?
WCF is a programming platform and runtime system for building, configuring and deploying network-distributed services. It is latest service oriented technology. Interoperability is fundamental characteristic of WCF. WCF is combined feature of Web Service, Remoting, MSMQ, and COM+. WCF provides a common platform for all .NET communication.
You are developing WCF service which read message from a system transactional dead-letter queue. which URI should you specify in the endpoint configuration settings of the service ?
NOTE: This is objective type question, Please click question title for correct answer.
In WCF, which binding is used for cross-machine communication or WCF-to-WCF communication?
NOTE: This is objective type question, Please click question title for correct answer.
What is the Extension of WCF service?
NOTE: This is objective type question, Please click question title for correct answer.
How many isolation levels are present and what are they?
1. READ UNCOMMITTED: - An uncommitted transaction can be read. This transaction can be rolled back later.
2. READ COMMITTED :- Will not read data of a transaction that has not been committed yet
3. REPEATABLE READ: - Locks placed on all data and another transaction cannot read.
4. SERIALIZABLE:- Does not allow other transactions to insert or update data until the transaction is complete.
How can we achieve overloading concept in WCF?
Yes, by using [OperationContract(Name="OverloadedName")] But, still outer world will get them with unique and different name. Overloading is a technique to write manageable/maintainable code. But in case of WCF service, uniqueness is required for generating WSDL, and that can be done either by using unique method name or unique OperationContract's name attribute value. Interfaces plays an important role and provides much flexibility for this. We can write many implementations of an interface, and it gives more flexibility plus concise. So why to think on overloading for WCF service methods?
In WCF, the type of contract used to define a class or an Interface is ?
NOTE: This is objective type question, Please click question title for correct answer.
In WCF, the type of contract used to define the method of a service is ?
NOTE: This is objective type question, Please click question title for correct answer.
In WCF, the type of contract used to define the data types passing on a service is ?
NOTE: This is objective type question, Please click question title for correct answer.
In WCF, the default type of binding is ?
NOTE: This is objective type question, Please click question title for correct answer.
In WCF, Binding of web services that supports duplex contract and transaction is ?
NOTE: This is objective type question, Please click question title for correct answer.
1
2
3
4
5
6
7
8
9
10
11
More WCF Exclusive Interview Questions & Answers here
Found this useful, bookmark this page to the blog or social networking websites.
Bookmark It
Interview Questions and Answers Categories
.NET Certifications
.NET Core
.NET Framework
ADO.NET
AI ML
Android
Angular
AngularJS 1x
Aptitute Test
ASP.NET
ASP.NET AJAX
ASP.NET Core
ASP.NET MVC
ASP.NET Web API
Aurelia
Azure
Best Practices
BizTalk Server
Bootstrap
C#
Cloud
CMS
CSS 3
Data Structures & Algorithms
Design Pattern & Practices
DotNetFunda.Com
Entity Framework
Error and Solution
F#
Function Points (FPA)
HR
HTML 5
IIS
Interview Questions
JavaScript
jQuery
Kinect
LightSwitch
LINQ
Management
Mobile Development
MSBI (SSIS, SSRS, SSAS)
Mule
Networking
News and Community
Node.js
NoSql
OOPS
Oracle
Others
PostgreSQL
PowerShell
Product Reviews
Project Management
Python
QA (Testing)
R Language
Regular Expressions
SEO
SharePoint
SignalR
Silverlight
Sql Server
TypeScript
UML
VB.NET
Visual Studio
WCF
Web Analytics
Web Services, Remoting
Windows 8
Windows Forms
Windows Metro
Windows Phone
WPF
WWF
XML