70-513 無料問題集「Microsoft TS: Windows Communication Foundation velopment with Microsoft .NET Framework 4」

A Windows Communication Foundation (WCF) service implements a contract with one-way and requestreply operations.
The service is exposed over a TCP transport.
Clients use a router to communicate with the service. The router is implemented as follows. (Line numbers are included for reference only.)
01 ServiceHost host = new ServiceHost(typeof(RoutingService));
02 host AddServiceEndpoint(
03 typeof(lSimplexDatagramRouter),
04 new NetTcpBinding0, "net.tcp:/flocalhostlRouter"
05);
06 List <ServiceEndpoints lep new List <ServiceEndpoint>0;t
07 lep.Add(
08 new ServiceEndpoint(
09 ContractDescription.GetContract(
10 typeof(lSimplexDatagramRouter)
11),
12 new NetTcpBinding0,
13 new EndpointAddress|'nettcp://localhost: 8080/Logger")
14)
15);
16 RoutingConfiguration rc new RoutingConfigurationO;
17 FilterTable.Add(new MatchAilMessageFilterO, lep);
18 host. Description. Behaviors. Add(new RoutingBehavior(rc));
Request-reply operations are failing.
You need to ensure that the router can handle one-way and request-reply operations.
What should you do?

You are developing a client application that uses the following code to consume a Windows Communication Foundation (WCF) service. (Line numbers are included for reference only.)
01 BasicHttpBinding myBinding = new BasicHttpBinding(); 02 EndpointAddress myEndpointAddress = new EndpointAddress( "http://contoso.com/TaxService.svc");
04 ITaxService client = channelFactory.CreateChannel();
05 string data = client.GetData(1);
You need to consume the service.
Which code segment should you insert at line 03?

A Windows Communication Foundation (WCF) solution uses two services to manage a shopping cart. Service
A processes messages containing line items that total between $0 and $500. Service B processes messages containing line items that total more than $500.
All messages are of equal importance to the business logic.
You need to route incoming messages to the appropriate services by using WCF routing.
Which two message filters should you add to the router? (Each correct answer presents part of the solution. Choose two.)

正解:C、D 解答を投票する
You are developing a client that sends several types of SOAP messages to a Windows Communication Foundation (WCF) service method named PostData.
PostData is currently defined as follows.
[OperationContract]
void PostData(Order data);
You need to modify PostData so that it can receive any SOAP message.
Which code segment should you use?

You are developing a Windows Communication Foundation (WCF) service. You enable logging in the configuration file.
The opening tag is defined as follows.

You need to ensure that logging is implemented so that only messages with SOAP headers are logged.
What should you add to the filters element of the application configuration file?

You are developing an application to update a user s social status. You need to consume the service using Windows Communication Foundation (WCF).
The client configuration is as follows.
<system.serviceModel> <bindings> <webHttpBinding>
<binding name="SocialConfig">
<security mode="TransportCredentialOnly">
<transport clientCredentialType="Basic"
realm="Social API" />
</security>
</binding>
</webHttpBinding>
</bindings>
<client>
<endpoint address= " http:// contoso .com "
binding="webHttpBinding"
bindingConfiguration="SocialConfig"
contract="ISocialStatus"
name="SocialClient" />
</client>
</system.serviceModel>
The service contract is defined as follows.
<ServiceContract()>
Public Interface ISocialStatus
<OperationContract()>
<WebInvoke(UriTemplate:="/statuses/update.xmlstatus={text}")>
Sub UpdateStatus(ByVal text As String)
End Interface
Which code segment should you use to update the social status?

You are developing a Windows Communication Foundation (WCF) service. The service configuration file has a <System.Diagnostics> element defined.
You need to ensure that all security audit information, trace logging, and message logging failures are recorded.
Which configuration segment should you add to the <System.Diagnostics> element?

A Windows Communication Foundation (WCF) client configuration file contains the following XML segment in the system.serviceModel element.
<client>
<endpoint address=" net.tcp://server/ContosoService "
binding=" netTcpBinding "
contract=" Contoso. IContoso Service "
name=" netTcp " / >
<endpoint address=" net.pipe://localhost/ContosoService "
binding=" netNamedPipeBinding "
contract=" Contoso. IContoso Service "
name=" netPipe " />
</client>
You need to create a channel factory that can send messages to the endpoint listening at net.pipe://localhost/ContosoService.
Which code segment should you use

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.)

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?

You have a Windows Communication Foundation (WCF) service that uses a multicast protocol as a custom transport. The service implements the channel framework.
You need to choose a message exchange pattern for the transport.
What should you use?

You are developing a Windows Communication Foundation (WCF) service. You write a method named Submit that accepts messages of the type System.ServiceModel.Channels.Message.
You need to process the body of the incoming messages multiple times in the method.
Which two actions should you perform? (Each correct answer presents part of the solution. Choose two.)

正解:A、D 解答を投票する
A Windows Communication Foundation (WCF) service uses the following service contract.
[ServiceContract]
public interface IService
{
[OperationContract]
string Operation 1 (string s);
}
You need to ensure that the operation contract Operationi responds to HTTP POST requests.
Which code segment should you use?

You have a Windows Communication Foundation (WCF) service.
The service has issues with performance when it receives messages on a specific endpoint. The service must collect the minimum number of performance counters to diagnose the message issues.
You need to configure the service.
In the web.config file for the service, what should you do?

A Windows Communication Foundation (WCF) service handles online order processing for your company.
You discover that many requests are being made with invalid account numbers. You create a class named AccountNumberValidator that has a method named Validate.
Before the message is processed, you need to validate account numbers with AccountNumberValidator and reject messages with invalid account numbers.
You create a new class that implements the IParameterInspector interface. Which code segment should you use in this class?

Your company has an existing Windows Communication Foundation (WCF) service that allows business partners to place orders. The service uses netMsmqBinding.
You find that processing every order in its own transaction is causing a delay.
You need to ensure that the service is configured to process multiple orders in one transaction.
What should you do?

A Windows Communication Foundation (WCF) solution uses the following contracts. (Line numbers are included for reference only.)

When the client calls GetMessage on the service interface, the service calls GetName on the client callback.
In the client, the class NameService implements the callback contract.
The client channel is created as follows.

You need to ensure that the service callback is processed by the instance of NameService.
What are two possible ways to achieve this goal? (Each correct answer presents a complete solution. Choose two.)

正解:A、C 解答を投票する
A Windows Communication Foundation (WCF) application exposes a service as a SOAP endpoint for consumption by cross-platform clients. During integration testing, you find that one of the clients is not generating the correct messages to the WCF application.
In order to debug the issue and fix the communication, you need to configure the service to log messages received from the client.
What should you do?

You are maintaining a Windows Communication Foundation (WCF) service that uses a custom UserNamePassword class to authenticate clients. The service certificate is hosted in the deployment server store for trusted root certificate authorities and has a Subject value of TaxServiceKey. Other service certificates hosted on the server also use TaxServiceKey as a Subject value.
You need to ensure that the service identifies itself with a certificate whose subject name and distinguished names are TaxServiceKey.
Which code segment should you use?

You develop a Windows Communication Foundation (WCF) SOAP service that contains a class named Order. The Order class includes a field named secret that stores private data.
The Order class includes the following code:

The service has the following requirements:
- The secret field must be encrypted.
- All other fields in the Order class must serialize as plain text. You need to configure serialization for the Order class.
What should you do?

You are modifying a Windows Communication Foundation (WCF) service that allows customers to update financial data. The service currently requires a transaction from the client application and is working correctly. The service contract is defined as follows. (Line numbers are included for reference only.)

The service must be modified so that client applications do not need to initiate a transaction when calling the operation. The service must use the client application's transaction if one is available. Otherwise it must use its own transaction.
You need to ensure that the service operation is always executed within a transaction.
What should you do?

弊社を連絡する

我々は12時間以内ですべてのお問い合わせを答えます。

オンラインサポート時間:( UTC+9 ) 9:00-24:00
月曜日から土曜日まで

サポート:現在連絡