You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/07/31 05:16:58 UTC

[GitHub] [flink] dianfu opened a new pull request #13034: [FLINK-9992] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

dianfu opened a new pull request #13034:
URL: https://github.com/apache/flink/pull/13034


   
   ## What is the purpose of the change
   
   *Not all the characters could be used in the hostname: https://stackoverflow.com/questions/28568188/java-net-uri-get-host-with-underscores. For example, underscores could not be used in the hostname. Currently, FsStorageLocationReferenceTest#testEncodeAndDecode will generate the hostname randomly and it may happen that it generates a character which is not supported. This PR fixes this problem by adding retries to generate a valid path*
   
   ## Brief change log
   
     - *Add retries to generate a valid path in FsStorageLocationReferenceTest.randomPath*
   
   ## Verifying this change
   
   This change is a trivial rework without any test coverage.
   
   ## Does this pull request potentially affect one of the following parts:
   
     - Dependencies (does it add or upgrade a dependency): (no)
     - The public API, i.e., is any changed class annotated with `@Public(Evolving)`: (no)
     - The serializers: (no)
     - The runtime per-record code paths (performance sensitive): (no)
     - Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn/Mesos, ZooKeeper: (no)
     - The S3 file system connector: (no)
   
   ## Documentation
   
     - Does this pull request introduce a new feature? (no)
     - If yes, how is the feature documented? (not applicable)
   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-666932731


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5069",
       "triggerID" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * f9f773fd1a15b875596ab294ca90db912b2dd2c0 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5069) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] dianfu commented on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
dianfu commented on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-679978154


   @StephanEwen Thanks a lot for the review. I have updated the PR with the following changes:
   - Add the missing the ':' between host and port
   - Retry in a while loop until got a valid string. I prefer this option because I'm not confident that excluding "underscore, colon, whitespace" is enough. Considering that this is only used in test case and I think that retry should be enough.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] dianfu commented on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
dianfu commented on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-694157826


   @StephanEwen Thanks for the review. Merging...


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] dianfu closed pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
dianfu closed pull request #13034:
URL: https://github.com/apache/flink/pull/13034


   


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] flinkbot commented on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
flinkbot commented on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-666932731


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * f9f773fd1a15b875596ab294ca90db912b2dd2c0 UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] dianfu commented on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
dianfu commented on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-668951790


   cc @StephanEwen 


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] StephanEwen commented on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
StephanEwen commented on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-694149461


   +1 to merge this


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-666932731


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "status" : "DELETED",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5069",
       "triggerID" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "db2c909c2b516c253c5f4f2afc1a0d200df72d85",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5854",
       "triggerID" : "db2c909c2b516c253c5f4f2afc1a0d200df72d85",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * db2c909c2b516c253c5f4f2afc1a0d200df72d85 Azure: [SUCCESS](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5854) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] kezhuw commented on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
kezhuw commented on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-671069914


   @dianfu How about `StringUtils#generateRandomAlphanumericString` or its length-varying variant ? If the generated url is invalid, it would be better to generate a valid url. Retrying 5 times does not improve test stability that much.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] StephanEwen commented on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
StephanEwen commented on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-679901944


   Thanks for fixing this instability.
   
   Some comments from my side:
     - It would be nice to have non-alphanumeric characters.
     - The retries are okay, but we could also have a list of forbidden chars (like underscore, colon, whitespace) that we avoid in the random string generation.
     - If you want to stick with re-tries, I would suggest to make it a while loop until you have a valid string. The number 5 for retries seems very arbitrary.
   
   Other note: The test is missing the ':' between host and port, so it never has a port but counts the number into the hostname.
   Would be nice to fix that as well.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] dianfu commented on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
dianfu commented on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-679479779


   @kezhuw Thanks for your comments. 
   - Regarding to "retrying 5 times", I think that's enough considering the frequency of this issue(it occurs two times in the last two weeks). 
   - Regarding to use **generateRandomAlphanumericString** instead of **getRandomString**, I'm fine with this. However, it depends on the test purpose of this test case. For example, the generated string of **generateRandomAlphanumericString** only contains characters and digit, I'm not sure if this is what we want for this test case FsStorageLocationReferenceTest. What's your thought? @StephanEwen 


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] flinkbot commented on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
flinkbot commented on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-666928462


   Thanks a lot for your contribution to the Apache Flink project. I'm the @flinkbot. I help the community
   to review your pull request. We will use this comment to track the progress of the review.
   
   
   ## Automated Checks
   Last check on commit f9f773fd1a15b875596ab294ca90db912b2dd2c0 (Fri Jul 31 05:19:31 UTC 2020)
   
   **Warnings:**
    * No documentation files were touched! Remember to keep the Flink docs up to date!
    * **This pull request references an unassigned [Jira ticket](https://issues.apache.org/jira/browse/FLINK-9992).** According to the [code contribution guide](https://flink.apache.org/contributing/contribute-code.html), tickets need to be assigned before starting with the implementation work.
   
   
   <sub>Mention the bot in a comment to re-run the automated checks.</sub>
   ## Review Progress
   
   * ❓ 1. The [description] looks good.
   * ❓ 2. There is [consensus] that the contribution should go into to Flink.
   * ❓ 3. Needs [attention] from.
   * ❓ 4. The change fits into the overall [architecture].
   * ❓ 5. Overall code [quality] is good.
   
   Please see the [Pull Request Review Guide](https://flink.apache.org/contributing/reviewing-prs.html) for a full explanation of the review process.<details>
    The Bot is tracking the review progress through labels. Labels are applied according to the order of the review items. For consensus, approval by a Flink committer of PMC member is required <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot approve description` to approve one or more aspects (aspects: `description`, `consensus`, `architecture` and `quality`)
    - `@flinkbot approve all` to approve all aspects
    - `@flinkbot approve-until architecture` to approve everything until `architecture`
    - `@flinkbot attention @username1 [@username2 ..]` to require somebody's attention
    - `@flinkbot disapprove architecture` to remove an approval you gave earlier
   </details>


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-666932731


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5069",
       "triggerID" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * f9f773fd1a15b875596ab294ca90db912b2dd2c0 Azure: [SUCCESS](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5069) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] dianfu edited a comment on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
dianfu edited a comment on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-679978154


   @StephanEwen Thanks a lot for the review. I have updated the PR with the following changes:
   - Add the missing the ':' between host and port
   - Retry in a while loop until got a valid string. I prefer this option because I'm not confident that excluding "underscore, colon, whitespace" is enough. Considering that this is only used in test case, I think that retry should be enough.


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-666932731


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5069",
       "triggerID" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "db2c909c2b516c253c5f4f2afc1a0d200df72d85",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "db2c909c2b516c253c5f4f2afc1a0d200df72d85",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * f9f773fd1a15b875596ab294ca90db912b2dd2c0 Azure: [SUCCESS](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5069) 
   * db2c909c2b516c253c5f4f2afc1a0d200df72d85 UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
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:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #13034: [FLINK-9992][tests] Fix FsStorageLocationReferenceTest#testEncodeAndDecode by adding retries to generate a valid path

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #13034:
URL: https://github.com/apache/flink/pull/13034#issuecomment-666932731


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5069",
       "triggerID" : "f9f773fd1a15b875596ab294ca90db912b2dd2c0",
       "triggerType" : "PUSH"
     }, {
       "hash" : "db2c909c2b516c253c5f4f2afc1a0d200df72d85",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5854",
       "triggerID" : "db2c909c2b516c253c5f4f2afc1a0d200df72d85",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * f9f773fd1a15b875596ab294ca90db912b2dd2c0 Azure: [SUCCESS](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5069) 
   * db2c909c2b516c253c5f4f2afc1a0d200df72d85 Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=5854) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


----------------------------------------------------------------
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:
users@infra.apache.org