THRIFT-3397 Implement TProcessorFactory in C# to enable per-client processors
Client: C#
Patch: Jonathan Heard
This closes #663
diff --git a/lib/csharp/test/ThriftTest/TestClient.cs b/lib/csharp/test/ThriftTest/TestClient.cs
index f0297d0..4c42ef7 100644
--- a/lib/csharp/test/ThriftTest/TestClient.cs
+++ b/lib/csharp/test/ThriftTest/TestClient.cs
@@ -43,6 +43,8 @@
public bool framed;
public string protocol;
public bool encrypted = false;
+ protected bool _isFirstTransport = true;
+
public TTransport CreateTransport()
{
@@ -72,9 +74,13 @@
if (framed)
trans = new TFramedTransport(trans);
- //ensure proper open/close of transport
- trans.Open();
- trans.Close();
+ if (_isFirstTransport)
+ {
+ //ensure proper open/close of transport
+ trans.Open();
+ trans.Close();
+ _isFirstTransport = false;
+ }
return trans;
}
else