[ 
https://issues.apache.org/jira/browse/GEODE-8157?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17218029#comment-17218029
 ] 

ASF GitHub Bot commented on GEODE-8157:
---------------------------------------

mmartell commented on a change in pull request #674:
URL: https://github.com/apache/geode-native/pull/674#discussion_r508905378



##########
File path: clicache/acceptance-test/SNITests.cs
##########
@@ -127,5 +133,38 @@ public void ConnectionWithoutProxyFails()
 
             Assert.Throws<NotConnectedException>(() => region.Put("1", "one"));
         }
+

Review comment:
       I've updated the test to use timeouts instead of catching exceptions. If 
you stop the proxy, the socket is closed by the proxy and the client throws a 
"Not Connected exception with message "No locators available", which can be 
caught. However, this requires restarting the proxy on the same port, which I'm 
not sure how to do from C#. 
   
   It seems just as good of a test to merely **pause** the proxy, which 
suspends the process and stops all network traffic. Then the proxy can merely 
be **unpaused**, which allows it to resume network communications on the same 
port. The only caveat to this simpler approach is that since the proxy doesn't 
actually close the socket, the client continues to retry the operation and 
never throws an exception. We use a wait with timeout to show the operation 
doesn't succeed while the proxy is paused, and another wait with timeout to 
show the operation succeeds as soon as the proxy is unpaused.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Write "drop proxy test" for C# (clicache)
> -----------------------------------------
>
>                 Key: GEODE-8157
>                 URL: https://issues.apache.org/jira/browse/GEODE-8157
>             Project: Geode
>          Issue Type: New Feature
>          Components: native client
>            Reporter: Blake Bender
>            Priority: Major
>              Labels: pull-request-available
>




--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to