|
3 | 3 | // Licensed under the MIT License (MIT). See License.txt in the repo root for license information.
|
4 | 4 | // ------------------------------------------------------------
|
5 | 5 |
|
| 6 | +using System; |
| 7 | +using System.Collections.Generic; |
| 8 | +using Microsoft.ServiceFabric.Actors.Client; |
| 9 | +using Microsoft.ServiceFabric.Actors.Remoting.V2.Wcf.Client; |
| 10 | +using Microsoft.ServiceFabric.Actors.Runtime; |
| 11 | +using Microsoft.ServiceFabric.Services.Communication.Wcf; |
| 12 | +using Microsoft.ServiceFabric.Services.Remoting.Runtime; |
| 13 | +using Microsoft.ServiceFabric.Services.Remoting.V2.Client; |
| 14 | + |
6 | 15 | namespace Microsoft.ServiceFabric.Actors.Remoting.Wcf
|
7 | 16 | {
|
8 |
| - using System; |
9 |
| - using System.Collections.Generic; |
10 |
| - using Microsoft.ServiceFabric.Actors.Client; |
11 |
| - using Microsoft.ServiceFabric.Actors.Remoting.V1.Wcf.Client; |
12 |
| - using Microsoft.ServiceFabric.Actors.Runtime; |
13 |
| - using Microsoft.ServiceFabric.Services.Communication.Wcf; |
14 |
| - using Microsoft.ServiceFabric.Services.Remoting.Runtime; |
15 |
| - using Microsoft.ServiceFabric.Services.Remoting.V2.Client; |
16 |
| - |
17 | 17 | /// <summary>
|
18 | 18 | /// Sets WCF as the default remoting provider for actors.
|
19 | 19 | /// </summary>
|
@@ -71,30 +71,6 @@ public long CloseTimeoutInMilliSeconds
|
71 | 71 | set;
|
72 | 72 | }
|
73 | 73 |
|
74 |
| - /// <summary> |
75 |
| - /// Creates a service remoting client factory to connect to the remoted actor interfaces. |
76 |
| - /// </summary> |
77 |
| - /// <param name="callbackClient"> |
78 |
| - /// Client implementation where the callbacks should be dispatched. |
79 |
| - /// </param> |
80 |
| - /// <returns> |
81 |
| - /// A <see cref="Microsoft.ServiceFabric.Actors.Remoting.V1.Wcf.Client.WcfActorRemotingClientFactory"/> |
82 |
| - /// as <see cref="Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClientFactory"/> |
83 |
| - /// that can be used with <see cref="ActorProxyFactory"/> to |
84 |
| - /// generate actor proxy to talk to the actor over remoted actor interface. |
85 |
| - /// </returns> |
86 |
| - [Obsolete(Services.Remoting.DeprecationMessage.RemotingV1)] |
87 |
| - public override Microsoft.ServiceFabric.Services.Remoting.V1.Client.IServiceRemotingClientFactory CreateServiceRemotingClientFactory( |
88 |
| - Microsoft.ServiceFabric.Services.Remoting.V1.IServiceRemotingCallbackClient callbackClient) |
89 |
| - { |
90 |
| - return new Microsoft.ServiceFabric.Actors.Remoting.V1.Wcf.Client.WcfActorRemotingClientFactory( |
91 |
| - WcfUtility.CreateTcpClientBinding( |
92 |
| - maxMessageSize: this.GetMaxMessageSize(), |
93 |
| - openTimeout: this.GetOpenTimeout(), |
94 |
| - closeTimeout: this.GetCloseTimeout()), |
95 |
| - callbackClient); |
96 |
| - } |
97 |
| - |
98 | 74 | /// <summary>
|
99 | 75 | /// Creates a V2 service remoting listener for remoting the actor interfaces.
|
100 | 76 | /// </summary>
|
@@ -126,44 +102,21 @@ public override Dictionary<string, Func<ActorService, IServiceRemotingListener>>
|
126 | 102 | /// </param>
|
127 | 103 | /// <returns>
|
128 | 104 | /// A <see cref="WcfActorRemotingClientFactory"/>
|
129 |
| - /// as <see cref="Microsoft.ServiceFabric.Services.Remoting.V2.Client.IServiceRemotingClientFactory"/> |
| 105 | + /// as <see cref="IServiceRemotingClientFactory"/> |
130 | 106 | /// that can be used with <see cref="ActorProxyFactory"/> to
|
131 | 107 | /// generate actor proxy to talk to the actor over remoted actor interface.
|
132 | 108 | /// </returns>
|
133 | 109 | public override IServiceRemotingClientFactory CreateServiceRemotingClientFactory(
|
134 | 110 | IServiceRemotingCallbackMessageHandler callbackMessageHandler)
|
135 | 111 | {
|
136 |
| - return new Microsoft.ServiceFabric.Actors.Remoting.V2.Wcf.Client.WcfActorRemotingClientFactory( |
| 112 | + return new WcfActorRemotingClientFactory( |
137 | 113 | WcfUtility.CreateTcpClientBinding(
|
138 | 114 | maxMessageSize: this.GetMaxMessageSize(),
|
139 | 115 | openTimeout: this.GetOpenTimeout(),
|
140 | 116 | closeTimeout: this.GetCloseTimeout()),
|
141 | 117 | callbackMessageHandler);
|
142 | 118 | }
|
143 | 119 |
|
144 |
| - /// <summary> |
145 |
| - /// Creates a service remoting listener for remoting the actor interfaces. |
146 |
| - /// </summary> |
147 |
| - /// <param name="actorService"> |
148 |
| - /// The implementation of the actor service that hosts the actors whose interfaces |
149 |
| - /// needs to be remoted. |
150 |
| - /// </param> |
151 |
| - /// <returns> |
152 |
| - /// An <see cref="IServiceRemotingListener"/> |
153 |
| - /// for the specified actor service. |
154 |
| - /// </returns> |
155 |
| - [Obsolete(Services.Remoting.DeprecationMessage.RemotingV1)] |
156 |
| - public override IServiceRemotingListener CreateServiceRemotingListener( |
157 |
| - ActorService actorService) |
158 |
| - { |
159 |
| - return new Actors.Remoting.V1.Wcf.Runtime.WcfActorServiceRemotingListener( |
160 |
| - actorService, |
161 |
| - WcfUtility.CreateTcpListenerBinding( |
162 |
| - maxMessageSize: this.GetMaxMessageSize(), |
163 |
| - openTimeout: this.GetOpenTimeout(), |
164 |
| - closeTimeout: this.GetCloseTimeout())); |
165 |
| - } |
166 |
| - |
167 | 120 | private long GetMaxMessageSize()
|
168 | 121 | {
|
169 | 122 | return (this.MaxMessageSize > 0) ? this.MaxMessageSize : DefaultMaxMessageSize;
|
|
0 commit comments