[OFFICIAL]Braindump2go 70-513 VCE Instant Download (301-310)
MICROSOFT NEWS: 70-513 Exam Questions has been Updated Today! Get Latest 70-513 VCE and 70-513 PDF Instantly! Welcome to Download the Newest Braindump2go 70-513 VCE&70-513 PDF Dumps: http://www.braindump2go.com/70-513.html (341 Q&As)
2015 Free Download of Latest Microsoft 70-513 Practce Exam Questions from Braindump2go will help you have a 100% success of 70-513 real exam! All questions are the latest checked and released! Answers are 100% correct guaranteed! In order to increase your confidence, 100% Full Money Back Guarantee is promised by Braindump2go! Instant Download Now!
Exam Code: 70-513
Exam Name: TS: Windows Communication Foundation Development with Microsoft .NET Framework 4
Certification Provider: Microsoft
Corresponding Certifications: MCPD, MCPD: Web Developer 4, MCPD: Windows Developer 4, MCTS, MCTS: Microsoft .NET Framework 4, Service Communication Applications
70-513 Dumps PDF,70-513 eBook,70-513 VCE,70-513 PDF,70-513 Latest Dumps,70-513 Certification,70-513 Training Kit PDF,70-513 Braindump,70-513 Exam Dumps,70-513 Exam Book,70-513 Exam PDF,70-513 Exam Book,70-513 Exam Preparation,70-513 Dumps VCE,70-513 Practice Test,70-513 Pracrice Exam,70-513 Preparation Book
QUESTION 301
A Windows Communication Foundation (WCF) solution uses the following contract.
<ServiceContract(SessionMode:=SessionMode Allowed)s
Public Interface lMyService <OperationContract(lsTerminating:sFalse)s
Sub Initialize ()
<OperationContract(lslnitiating:sFalse)>s
Sub DoSomething()
<OperationContract(lsterminating:=True)>
Sub Terminate ()
End Interface
You need to change this interface so that:
“Initialize is allowed to be called at any time before Terminate is called.
“DoSomething is allowed to be called only after Initialize is called, and not allowed to be called after Terminate is called. “Terminate will be allowed to be called only after Initialize is called
Which two actions should you perform? (Each correct answer presents part of the solution. Choose two.)
A. Change the ServiceContract attribute of the lMyService interface to the following.
ServiceContract(SessionMode:sSessionMode. Required)
B. Change the ServiceContract attribute of the lMyService interface to the following.
ServiceContract(SessionMode:sSessionModeAllowed)?
C. Change the OperationContract attribute of the Initialize operation to the following.
OperationContract(lslnitiating: `True, IsTerminating: `False)
D. Change the OperationContract attribute of the Terminate operation to the following.
OperationContract(Islnitiatings:False, lsTerminating: `True)
Answer: AD
QUESTION 302
A Windows Communication Foundation (WCF) solution uses the following contract.
[ServiceContract(SessionMode SessionModeAllowed)] public interface IMyService {
[OperaionContractQsTerminating false) void lnitialize0;
[OperaionContractQslnitiating false)] Void DoSomethingO;
[OperaionContractQsTerminating true)J void TerminateO;
}
You need to change this interface so that:
`Initialize is allowed to be called any time before Terminate is called
“DoSomething is allowed to be called only after Initialize is called, and n allowed to be called after Terminate is called “Terminate will be lowed to be called only after Initialize is called
Which two actions should you perform (Each correct answer presents part of the solution. Choose two)
A. Change the ServiceContract attribute of the IMyService interface to the following.
ServiceContract(SessionMode = SessionMode Required)
B. Change the ServiceContract attribute of the IMyService interface to the following.
ServiceContract(SessionMode SessionMode Allowed)
C. Change the OperationContract attribute of the Initialize operation to the following.
OperationContract(initiating = true, IsTerminating = false)
D. Change the OperationContract attribute of the Terminate operation to the following.
OperationContract(klnitiating = fase, IsTerminating = true)
Answer: AD
QUESTION 303
A Windows Communication Foundation (WCF) service implements a contract with one-way and request-reply 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(ISimplexDatagramRouter),
04 new NetTcpBinding(), “net.tcp://localhost/Router”
05 );
06 List<ServiceEndpoint> lep = new List<ServiceEndpoint>();
07 lep.Add(
08 new ServiceEndpoint(
09 ContractDescription.GetContract(
10 typeof(ISimplexDatagramRouter)
11 ),
12 new NetTcpBinding(),
13 new EndpointAddress(“net.tcp://localhost:8080/Logger”)
14 )
15 );
16 RoutingConfiguration rc = new RoutingConfiguration();
17 rc.FilterTable.Add(new MatchAllMessageFilter(), 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?
A. Change line 03 as follows:
typeof(IRequestReplyRouter),
B. Change line 03 as follows:
typeof(IDuplexSessionRouter),
C. Change line 10 as follows:
typeof(IRequestReplyRouter)
D. Change line 10 as follows:
typeof(IDuplexSessionRouter)
Answer: B
QUESTION 304
Windows Communication Foundation (WCF) service will be hosted in Microsoft Internet Information Services (IIS).
You create a new application in IIS to host this service and copy the service DLL to the bin directory of the application.
You need to complete the deployment of this service to IIS.
What should you do next?
A. Create an asmx file and add a @ServiceHost directive to this file.
Copy the file to the root of the application directory.
B. Create an .asmx file and add a @Register directive to this file.
Copy the file to the bin directoyy of the application.
C. Create a svc file and add a @ServiceHost directive to this file.
Copy the file to the root of the application directory.
D. Create a .svc file and add a @Register directive to this file.
Copy the file to the bin directory of the application.
Answer: C
QUESTION 305
A Windows Communication Foundation (WCF) service listens for messages at net.tcp://www.contoso.com/MyService.
It has a logical address at http://www.contoso.com/MyService.
The configuration for the WCF client is as follows:
<endpoint address=”http://www.contoso.com/MyService”
binding=”netTcpBinding”
bindingConfiguraton=”NetTcpBinding_IMyService”
contract=”ServiceReference1.IMyService”
name=”NetTcpBinding_IMyService”/>
The generated configuration does not provide enough information for the client to communicate with the server.
You need to update the client so that it can communicate with the server.
What should you do?
A. In the client configuration, change the value of the address attribute to
net.tcp://www.contoso.com/MyService
B. In the client configuration, change the value of the address attribute to
net.tcp://www.contoso.com/MyService listen=http://www.contoso.com/MyService.
C. After instantiating the client and before invoking any service operation, add this line of code.
EndpointBehaviors.Add(new EndpointDiscoveryBehavior()
{ Enabled = true });
D. After instantiating the client and before invoking any service operation, add this line of code.
client.Endpoint.Behaviors.Add(new ClientViaBehavior(
new Uri(“net.tcp://www.contoso.com/IMyService”)));
Answer: D
QUESTION 306
A Windows Communication Foundation (WCF) client communicates with a service.
You created the client proxy by using Add Service Reference in MS Visual Studio.
You need to ensure that the client accepts responses of up to 5 MB in size. What should you change in the configuration file’?
A. the value of the maxBufferPoolSize attribute to 5242880
B. the value of the maxReceivedMessageSize attribute to 5242880
C. the value of the maxBytesPerRead attribute to 5242880
D. the value of the maxBufferSize attribute to 5242880
Answer: B
QUESTION 307
You are building a client for a Windows Communication Foundation (WCF) service.
You need to create a proxy to consume this service.
Which class should you use?
A. ChannelFactory<TChannel>
B. ServiceHost
C. ClientRuntime
D. CommunicationObject
Answer: A
QUESTION 308
Windows Communication Foundation (WCF) application uses a data contract that has several data members.
You need the application to throw a Serialization Exception if any of the data members are not present when a serialized instance of the data contract is deserialized.
What should you do?
A. Add the Known Type attribute to the data contract.
Set a default value in each of the data member declarations.
B. Add the Known Type attribute to the data contract.
Set the Order property of each data member to unique integer value.
C. Set the Emit Default Value property of each data member to false.
D. Set the lsRequired property of each data member to true.
Answer: D
QUESTION 309
A Windows Communication Formation (WCF) client and service share the following service contract interface
<ServiceContractO>
Public Interface IContosoService <OperationContractO>
Sub SasePerson(BWal person As Person)
End Interface
They also use the following binding.
Dim binding As NetTcpBinding = New NetTcpBinding With {TransactionFlow = True) The client cals the service with the (following code using (mransactionScope ts = new TransactionScope(TransactionScopeOption
Required))
{
IContosoService client = factoryCreateChannelO;
client SavePerson(person);
Consde. WriteLine(
Transaction. CurreriTransactioninformation
DistnbutedldentifierX
ts CorrpleteO;
)
The service has the following impementation for SavePerson
Public Sub SavePerson(ByVal person As Perwn) — implements IContosoService SavePerson person Save()
ConsdeWriteLine(Transaction .Current Transactionlnformaiona
Distributedldentifier)
End Sit
The distributed identifiers do not match on the client and the server.
You need to ensure that the client and server enlist in the same distributed transaction
What should you do?
A. Add the following attributes to the SavePerson operation on IContosoService.
[OperationBehavior(TransactionScope.Required = true)]
[TransactionFlow(TransactionFlowOption.Mandatory)]
B. Add the following attributes to the SavePerson operation on lContosoService
[TransactionFlow(TransactionFlowOption.Mandatory)]
[OperationBehavior(TransactionScope.Required = true)]
C. Add the following attribute to the SavePerson operation on lContosoService
[OperationBehavior(TransactionScope.Required = true)]
Add the following attribute to the implementation of SavePerson.
[TransactionFlow(TransactionFlowOption.Allowed)]
D. Add the following attribute to the SavePerson operation on lContosoService
[TransactionFlow(TransactionFlowOption.Allowed)]
Add the following attribute to the implementation of SavePerson.
[OperationBehavior(TransactionScope.Required = true)]
Answer: D
QUESTION 310
A Windows Communication Foundation (WCF) solution uses the following contract to share a message across its clients (Line numbers are included for reference only)
01 <ServiceContract0>
02 PuElic Interface ITeamMessageService
04 <OperationContractO>
05 Function GetMessage() As String
07 <OperationContract0>
08 Sub PutMessage(Byval message As String)
O9 End Interface
The code for the serAce class is as follows.
10 Public Class TeamMessageService0
11 Implements lTearmt4essageService
13 Dim key As Guid = Guid.NewGuid()
14 Dim message As String = “Today’s Message’
16 PuUic Function GetMessage0As String –
17 lmpements lTearm*AessageServiceGetMessage
19 Retun String. Fommat(“Message:{0) Key:{ 1}”, message, key)
20 End Function
22 PubIic Sub PutMessage(ByV message As Stnng) –
23 lmpements lTearrlessageService PutMessage
25 Me message = message
26 End Sub
28 End Class
The service is self-hosted The hosting code rs as follows
29 Dim host As ServiceHost =
New ServiceHost(GetType(TearrwiessageSeMce))?
30 Dim binding As Basic HttpBindngt
New BasicHttpBindiig(BasicHttpSecurityMode. None) 31 host.AddServiceEndpoint(
“MyAppication lTearrtAessageService”, binding
Thttp /Ilac aihost. 1 2345)
32 host Open()
You need to ensure that all clients calling GetMessage will retrieve the same string, even if the message is upd(ed by clients calling PutMessage
what should you do?
A. Add the following attribute to the TeamMessageService class, before line 10.
<ServceBehavior(lnstanceContextMode lnstanceContextMode. Single)>
B. Add the following attribute to the TeamMessageService class, before line 10002E
<ServiceBehavior( lnstanceContextll ode. = InstanceContextMode.
PerSession)>
C. Pass a service instance to the instancing code in line 29, as follows.
Dim host As ServiceHost z New ServiceHost(New TeamMessageServiceO)
D. Redefine the message string in line 14, as follows.
Shared message As String “Today’s Message”
Then change the implementation of PutMessage in lines 22-26 to the following
Public Sub PutMessage(ByVal message As rng) – Implements ITean-
MessageService.PutMessage
TeamMessageSenAce.message = message End Sub
Answer: A
New Updated Braindump2go 70-489 Dumps Add Many New 70-489 Exam Questions,You can Download Free 70-489 PDF and 70-489 VCE from Braindump2go.
Use Braindump2go 70-489 Study Guide and 70-489 Braindump2go to 100% Get 70-489 Certification.
FREE DOWNLOAD: NEW UPDATED 70-513 PDF Dumps & 70-513 VCE Dumps from Braindump2go: http://www.braindump2go.com/70-513.html (341 Q&A)