Github user tillrohrmann commented on a diff in the pull request:

    https://github.com/apache/flink/pull/1030#discussion_r37564115
  
    --- Diff: 
flink-staging/flink-streaming/flink-streaming-core/src/test/java/org/apache/flink/streaming/api/functions/sink/SocketClientSinkTest.java
 ---
    @@ -125,4 +121,102 @@ public void testSocketSink() throws Exception{
                assertEquals("Connected", this.access);
                assertEquals("testSocketSinkInvoke", value);
        }
    +
    +   public Thread t;
    +
    +   @Test
    +   public void testSocketSinkNoRetry() throws Exception{
    +           ServerSocket server = new ServerSocket(0);
    +           port = server.getLocalPort();
    +
    +           new Thread(new Runnable() {
    +
    +                   @Override
    +                   public void run() {
    +                           t = Thread.currentThread();
    +                           SerializationSchema<String, byte[]> 
simpleSchema = new SerializationSchema<String, byte[]>() {
    +                                   @Override
    +                                   public byte[] serialize(String element) 
{
    +                                           return element.getBytes();
    +                                   }
    +                           };
    +
    +                           try {
    +                                   SocketClientSink<String> simpleSink = 
new SocketClientSink<String>(host, port, simpleSchema, 0);
    +                                   simpleSink.open(new Configuration());
    +                                   Thread.sleep(10000);
    --- End diff --
    
    Why do we have to sleep here?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to