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

Dian Fu edited comment on FLINK-9992 at 7/31/20, 4:55 AM:
----------------------------------------------------------

It seems that 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, the 
failed test case generates the hostname randomly and it may happen that it 
generates a character which is not supported. 

So there are the following ways for this problem:
- Exclude all the invalid characters when generating the hostname (This means 
that we need to figure out all the characters which are not supported)
- Add some retries when generating the path util when we got a valid path
- Use a fixed hostname when generating the path

Personally I lean to 2), what do you think?


was (Author: dian.fu):
It seems that 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, the 
failed test case generates the hostname randomly and it may happen that it 
generates a character which is not supported. 

So there are two ways for this problem:
- Exclude all the invalid characters when generating the hostname (This means 
that we need to figure out all the characters which are not supported)
- Use a fixed hostname

Personally I lean to 2). 

What do you think?

> FsStorageLocationReferenceTest#testEncodeAndDecode failed in CI
> ---------------------------------------------------------------
>
>                 Key: FLINK-9992
>                 URL: https://issues.apache.org/jira/browse/FLINK-9992
>             Project: Flink
>          Issue Type: Bug
>          Components: FileSystems, Tests
>    Affects Versions: 1.11.0, 1.12.0
>            Reporter: vinoyang
>            Priority: Critical
>              Labels: test-stability
>             Fix For: 1.12.0
>
>
> {code:java}
> testEncodeAndDecode(org.apache.flink.runtime.state.filesystem.FsStorageLocationReferenceTest)
>   Time elapsed: 0.027 sec  <<< ERROR!
> java.lang.IllegalArgumentException: java.net.URISyntaxException: Illegal 
> character in hostname at index 5: 
> gl://碪⯶㪴]ឪ嵿⎐䪀筪ᆶ歑ᆂ玚୓䇷ノⳡ೯43575/䡷ᦼ☶⨩䚩筶ࢊණ⣁᳊尯/彡䫼畒伈森削㔞/缳漸⩧勎㓘癐⍖ᾐ䘽㼺䨶/粉掩㤡⪌⎏㆐罠Ꮨㆆ䤱ൎ堉儾
>       at java.net.URI$Parser.fail(URI.java:2848)
>       at java.net.URI$Parser.parseHostname(URI.java:3387)
>       at java.net.URI$Parser.parseServer(URI.java:3236)
>       at java.net.URI$Parser.parseAuthority(URI.java:3155)
>       at java.net.URI$Parser.parseHierarchical(URI.java:3097)
>       at java.net.URI$Parser.parse(URI.java:3053)
>       at java.net.URI.<init>(URI.java:746)
>       at org.apache.flink.core.fs.Path.initialize(Path.java:247)
>       at org.apache.flink.core.fs.Path.<init>(Path.java:217)
>       at 
> org.apache.flink.runtime.state.filesystem.FsStorageLocationReferenceTest.randomPath(FsStorageLocationReferenceTest.java:88)
>       at 
> org.apache.flink.runtime.state.filesystem.FsStorageLocationReferenceTest.testEncodeAndDecode(FsStorageLocationReferenceTest.java:41)
> {code}
> log is here : https://travis-ci.org/apache/flink/jobs/409430886
>  



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

Reply via email to