Joosep Simm created KNOX-760:
--------------------------------

             Summary: Knox breaks filename's special characters
                 Key: KNOX-760
                 URL: https://issues.apache.org/jira/browse/KNOX-760
             Project: Apache Knox
          Issue Type: Bug
          Components: Server
    Affects Versions: 0.6.0
         Environment: CentOS, in HortonWorks Hadoop package
            Reporter: Joosep Simm


When listing files with through Knox and WebHDFS, then Knox breaks special 
characters (unicode characters) in the file listing. Doing the same request 
directly to WebHDFS lists the unicode characters nicely.

See the "fooä.txt" file name.

Knox request: curl -k -u test:test -i -X GET 
https://sandbox.hortonworks.com:8443/gateway/default/webhdfs/v1/test?op=LISTSTATUS
{"FileStatuses":{"FileStatus":[{"accessTime":1476784247695,"blockSize":134217728,"childrenNum":0,"fileId":149034,"group":"hdfs","length":14,"modificationTime":1476784248002,"owner":"hdfs","pathSuffix":"fooä.txt","permission":"644","replication":3,"storagePolicy":0,"type":"FILE"},{"accessTime":1476788434925,"blockSize":134217728,"childrenNum":0,"fileId":149035,"group":"hdfs","length":14,"modificationTime":1476788435493,"owner":"hdfs","pathSuffix":"test.txt","permission":"644","replication":3,"storagePolicy":0,"type":"FILE"}]}}

WebHDFS request: curl -i -X GET 
http://localhost:50070/webhdfs/v1/test?op=LISTSTATUS
{"FileStatuses":{"FileStatus":[
{"accessTime":1476784247695,"blockSize":134217728,"childrenNum":0,"fileId":149034,"group":"hdfs","length":14,"modificationTime":1476784248002,"owner":"hdfs","pathSuffix":"fooä.txt","permission":"644","replication":3,"storagePolicy":0,"type":"FILE"},
{"accessTime":1476788434925,"blockSize":134217728,"childrenNum":0,"fileId":149035,"group":"hdfs","length":14,"modificationTime":1476788435493,"owner":"hdfs","pathSuffix":"test.txt","permission":"644","replication":3,"storagePolicy":0,"type":"FILE"}
]}}

The Knox exact version is: 
[root@sandbox ~]# /usr/hdp/current/knox-server/bin/knoxcli.sh version
Apache Knox: 0.6.0.2.4.0.0-169 (d6098dd63118515bf7f6d870cad068609a2fd5d5)

It is installed with the Ambari server.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to