单项选择题
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)
01 [ServiceContract]
02 public interface IDataUpdate
03 {
04 [OperationContract]
05 [TransactionFlow(TransactionFlowOption.Mandatory)]
06 void Update(string accountNumber, double amount);
07 }
08
09 class UpdateService : IDataUpdate
10 {
11 [OperationBehavior(TransactionScopeRequired = true, TransactionAutoComplete = false)]
12 public void Update(string accountNumber, double amount)
13 {
14 ...
15 }
16 }
17
You need to ensure that the service is invoked within the transaction.
What should you do?()
A. Replace line 01 with the following code [ServiceContract(SessionMode = SessionMode.NotAllowed)]
B. Replace line 01 with the following code [ServiceContract(SessionMode = SessionMode.Required)]
C. Call the Invoke method of the form and supply a delegate.
D. Call the BeginInvoke method of the form and supply a delegate.
相关考题
-
单项选择题
You develop a Windows Communication Foundation (WCF) service. You enable all performance counters and run multiple calls to the service.The service must isolate session data to each user. You need to monitor the instancing behaviour used in the service. Which performance counter should you monitor?()
A. ServiceModeService 4.0.0.0\Calls
B. ServiceModeService 4.0.0.0\Instances
C. ASP.Net StateService \ Server Sessions Active
D. ASP.Net StateService \ Server Sessions Total -
单项选择题
You create a Windows Communication Foundation (WCF) service and deploy it with wsHttpBinding and message security enabled.You create an intermediate WCF service for logging messages sent to the primary service.The intermediate service is called via endpoint behaviour. The primary service is receiving malformed data from a client application.You need to enable inspection of the malformed data and prevent message tampering. What do you do?()
A. Specify a protection level of None in the contract for the intermediate service. Disable message and transport security from the client application configuration file.
B. Specify a protection level of Sign in the contract for the intermediate service. Disable transport security from the client application configuration file.
C. Modify the binding on the intermediate service to use netNamedPipeBinding.
D. Modify the binding on the intermediate service to use webHttpBinding. -
单项选择题
You are hosting a Windows Communication Foundation (WCF) service at http://www.contoso.com for a law enforcement agency.The agency adds operations to support sending biometric fingerprint data via non-buffered streaming.The service data is routed between intermediaries. The WCF binding you are using by default does not support encryption.You need to ensure that the fingerprint data is not disclosed when passed over the network. What should you do?()
A. Use basicHttpBinding with message security to https://www.contoso.com
B. Use basicHttpBinding with transport security to https://www.contoso.com
C. Use wsHttpBinding with message security to https://www.contoso.com
D. Use wsHttpBinding with transport security to http://www.contoso.com
