News:

SQL Table To C# Entity Model ConverterEntity Model (Class Properties) to SQL Table ConverterIf you encounter any trouble visiting our site, please contact us.

Advertisement

Looking for job. Try JobLoader- First ever job search engine in Bangladesh. All open bd jobs now a single mouse click away.

;
[ServiceContract]
public interface IDataService
{
[OperationContract]
string GetData();
}

Existing clients are making blocking calls to GetData. Calls to GetData take five seconds to complete. You need to allow new clients to issue non-blocking calls to get the data, without breaking any existing clients. What should you do?

  1. Replace the service interface with the following interface and implement the new methods

    [ServiceContract]
    public intetface IDoSomething
    {
    [OperationContract]
    string DoLongOperation();
    [OperationContract(AsyncPattern= true)]
    IAsyncResult BeginDoLongOperation();
    [OperationContract(AsyncPattern = true)]
    string EndDoLongOperation(lAsyncResult result);
    }
  2. Replace the service interface with the following interface and implement the new methods.

    [ServiceContract]
    public interface IDoSomething
    {
    [OperationContract(AsyncPattern=true)]
    IAsyncResult BeginDoLongOperation();
    [OperationContract(AsyncPattern=true)]
    string EndDoLongOperation(IAsyncResult result);
    }
  3. Generate a proxy class with asynchronous methods and use it for the new clients.

  4. Add a new endpoint to the service that uses a full-duplex binding and use it for the new clients.

Answer: Answer is c
comments powered by Disqus
Advertisement

BCS Preparation now even more easy. ReadBD is the place where you can find all kind of resources to be successful in BCS,Bank,Islami Bank exam and interview.

Looking for job. Try JobLoader- First ever job search engine in Bangladesh. All open bd jobs now a single mouse click away.

;