The following is an example of a SOAP envelope.
You need to create a message contract that generates the SOAP envelope.
1 which code segment should you use?
A. [MessageContract(WrapperName="http:I/www. contoso. comn")] public class CheckStockRequest { [MessageHeader(Nanez"http:llwww.contoso.com")] public mnt Storeld{get; set.} [MessageBodyMember(Namee'intp://www..contoso.com")] public nit itemld{get set;) }You are developing a Windows Communication Foundation (WCF) service that allows customers to update financial data. The service contract is defined as follows. (Line numbers are included for reference only.)

You need to ensure that the service is invoked within a transaction. What should you do?
A. Replace line 01 with the following code.An ASP NET application hosts a RESTful Windows Communication Foundation (WCF) service at /ServiceslContoso.svc.
The service provides a JavaScript resource to clients. You have an explicit reference to the JavaScript in your page markup as follows.
You need to retrieve the debug version of the service JavaScript.
What should you do?
A. In the header for /ServiceslContoso.svc, set the Debug attribute to true.A Windows Communication Foundation (WCF) service is self-hosted in a console application. The service implements the IDataAccess contract, which is defined in the MyApplication namespace.
The service is implemented in a class named DataAccessService, which implements the IDataAccess interface and also is defined in the MyApplication namespace.
The hosting code is as follows. (Line numbers are included for reference only.)

You need to create a ServiceHost instance and assign it to the host variable. You also need to instantiate the service host. Which line of code should you insert at line 04?
A. host = New ServiceHost("MyApplication.DataAccessService")You are creating an ASP NET web application that hosts several Windows Communication Foundation (WCF) services the services have ASP.NET Compatibility Mode enabled. Users authenticate with the Web application by using a cookie-based ASR NET Forms Authentication model. You add a service tile named Authentication. svc that contains the following code segment
<%@ SenviceHost Servicee"System
Web Application Services Authentication Service"Factory="System.Web.ApplicationServices.AppicationServicesHostFactory' %>.
You need to ensure that users can access the WCF services without having to re- authenticate.
Which two configuration settings should you add? (Each is part of a complete solution. Choose two.)
A. In the system web.extensions/scripting/webServices/authenticationService element, set the enabled attribute to true.You are developing a Windows Communication Foundation (WCF) service. The following code defines and implements the service. (Line numbers are included for reference only.)

You need to ensure that two identical copies of the received message are created in the service.
Which code segment should you insert at line 12?
A. Message msgCopy = message. CreateBufferedCopy(8192) as Message; Message returnMsg = message. CreateBufferedCopy(8192) as Message;You are developing a client application that consumes a Windows Communication Foundation (WCF) service. The operation contract is as follows.
[OperationContract]
[FaultContract(typeof(SalesFault))]
string GetSales(string saleld);
The service configuration file contains the following line in the serviceBehaviors section.
A divide-by-zero exception is not being handled by the service. You need to ensure that the exception is caught in the client application.
Which type of exception should the client catch?
A. TimeoutExceptionYou are modifying a Windows Communication Foundation (WCF) service that provides access to report generation system. The following code segment is part of your service contract. (Line numbers are included for reference only.)

Client applications are blocked while the service processes reports.
You need to ensure that the service methods are asynchronous. What should you do?
A. Insert the following code at line 04. [OperationContract] Insert the following code at line 07. [OperationConcracc(AsyncPactern = true)]You develop a Windows Communication Foundation (WCF) service. Many client applications will consume the service.
You have the following requirements:
You must enable client sessions on the service.
The service must support multi-threaded operations. If a client application uses sessions, the lifetime of the service instance must be scoped to the lifetime of the session.
If a client application does not use sessions, the lifetime of the service must be scoped to the lifetime of a method cal
You need to configure the service.
What should you do? (Each correct answer presents part of the solution. Choose three.)
A. In the ServiceContract attribute, set the value of the InstanceContextMode property to InstanceContextMode.PerSession.A WCF service code is implemented as follows. (Line numbers are included for reference only)
01 [ServiceContract]
02 [ServiceBehavior(lnstanceContextMode =
03 lnstanceContextModeSingle)]
04 public class CalculatorService
05 {
06 [OperationContract]
07 public double Calculate(double op1, string op. double op2)
08 {
24 }
25 }
You need to increase the rate by which clients get the required response from the service.
What e two possible ways to achieve this goal? (Each correct answer presents a complete sokiion Choose two.)
A. Change the service behavior to the following. [ServiceBehavior( lnstanceContextMode = lnstanceContextModeSingle, ConcirrencyMode = ConcurrencyMode. Multide)]cNowadays, the certification exams become more and more important and required by more and more enterprises when applying for a job. But how to prepare for the exam effectively? How to prepare for the exam in a short time with less efforts? How to get a ideal result and how to find the most reliable resources? Here on Vcedump.com, you will find all the answers. Vcedump.com provide not only Microsoft exam questions, answers and explanations but also complete assistance on your exam preparation and certification application. If you are confused on your 70-513 exam preparations and Microsoft certification application, do not hesitate to visit our Vcedump.com to find your solutions here.