PrepAway - Latest Free Exam Questions & Answers

Category: 70-513

Exam 70-513: TS: Windows Communication Foundation Development with Microsoft .NET Framework 4

What should you do?

You are developing a Windows Communication Foundation (WCF) service that executes a long-running operation.
The service is accessed from your business applications in a server transaction in which the client does not participate.
You need to ensure that the transaction times out and aborts if the operation has not completed within 45 seconds.
What should you do?

What should you do?

A Windows Communication Foundation (WCF) service is deployed with netTcpBinding.
This service uses a duplex message exchange pattern.You are developing the next version of the WCF service.
You discover that your company’s hardware load balancer performs correctly only for WCF services that use HTTP.
You need to ensure that your service works with the load balancer. What should you do?

Which two actions should you perform?

You are developing a Windows Communication Foundation (WCF) service to provide shopping cart support.
ASP.NET compatibility mode is not enabled. The shopping cart information must be retained across user
visits to the store until the user explicitly empties the cart or submits the cart contents to order.
You need to implement the service as a DurableService.

Which two actions should you perform? (Each correct answer presents part of the solution. Choose two.)

Which code segment should you use to set the service behavior?

You are developing a Windows Communication Foundation (WCF) service.
One of the service operations contains the following code.

private static int counter = 0;
[OperationContract]
public void IncrementCount()
{
counter++;
}

You need to set a service behavior that prevents two or more threads from incrementing the counter variable at the same time.
Which code segment should you use to set the service behavior?

Which code segment should you add at line 04?

You are developing a Windows Communication Foundation (WCF) service.
You enable message logging, trace listeners, activity propagation, and tracing on the trace sources.
You have the following code segment in the client application. (Line numbers are included for reference only.)

01 Guid multiCallActivityId = Guid.NewGuid();
02 TraceSource ts = new TraceSource(“Multicall”);
03 Trace.CorrelationManager.ActivityId = multiCallActivityId;
04

You encounter errors when your client application consumes the service.
You need to ensure that your client application can correlate tracing information with the service.
Which code segment should you add at line 04?

Which ReliableSessionBindingElement property should you configure?

You are developing a Windows Communication Foundation (WCF) service. Client applications require reliable sessions to access the service.
Users report that they receive ServerTooBusyException errors when their client application tries to establish a session.
You need to ensure that the service can handle a minimum of 30 client connection requests.
Which ReliableSessionBindingElement property should you configure?

Which hosting environment should you choose?

You are developing an application that performs file backups in the background. The background application
will host a Windows Communication Foundation (WCF) service and must be active as soon as the machine is running.
The background application will not have a user interface. A front-end application will consume the WCF service and will provide the user interface.

You need to choose a host environment for the WCF service. Which hosting environment should you choose?

Which type of exception should the client catch?

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 saleId);

The service configuration file contains the following line in the serviceBehaviors section.

<behavior>
<serviceDebug includeExceptionDetailInFaults=”True”/>
</behavior>

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?

What should you do to ensure that the client sends a SOAP body that is accepted by the service?

You have a Windows Communication Foundation (WCF) service that accepts the following message contract.

[MessageContract(WrapperNamespace=”http://www.movies.com”, ProtectionLevel=ProtectionLevel.None)]
public class Ticket
{
[MessageBodyMember(Namespace=”http://www.movietheater.com”, Order=1)]
public DateTime ShowTime = DateTime.Now;

[MessageBodyMember(Namespace=”http://www.movietheater.com”)]
public string ReservationName = “Smith”;

[MessageBodyMember(Namespace=”http://www.movietheater.com”)]
public int NumberOfSeats = 0;
}

You need to ensure that the client sends a SOAP body that is accepted by the service.


Page 2 of 1512345...10...Last »