[jira] [Commented] (CALCITE-2704) Multilingual decoded problem

2019-06-20 Thread Leo Tu (JIRA)


[ 
https://issues.apache.org/jira/browse/CALCITE-2704?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16868409#comment-16868409
 ] 

Leo Tu commented on CALCITE-2704:
-

I add test code at: [https://github.com/apache/calcite-avatica/pull/85]

> Multilingual decoded problem
> 
>
> Key: CALCITE-2704
> URL: https://issues.apache.org/jira/browse/CALCITE-2704
> Project: Calcite
>  Issue Type: Bug
>  Components: avatica
>Affects Versions: avatica-1.11.0, avatica-1.12.0, avatica-1.13.0
>Reporter: pufan
>Priority: Blocker
>  Labels: pull-request-available
> Fix For: avatica-1.16.0
>
>  Time Spent: 3h
>  Remaining Estimate: 0h
>
> When we execute SQL with Chinese characters, we find that the server parses 
> it in gibberish.
> After checking the code, we found that:
> org.apache.calcite.avatica.server.AvaticaJsonHandler.java line 109:
> {code:java}
> //The readFully method USES utf-8 encoding internally.
> rawRequest = AvaticaUtils.readFully(inputStream, buffer);
> {code}
> But in the org.apache.calcite.avatica.server.AvaticaJsonHandler.java line 116:
> {code:java}
> // Decoded using iso-8859-1 Cause Chinese garble.
> final String jsonRequest = new String(rawRequest.getBytes("ISO-8859-1"), 
> "UTF-8");
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CALCITE-2704) Multilingual decoded problem

2018-11-26 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/CALCITE-2704?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16698596#comment-16698596
 ] 

ASF GitHub Bot commented on CALCITE-2704:
-

Github user F21 commented on the issue:

https://github.com/apache/calcite-avatica/pull/76
  
@2k124 Thanks for opening the JIRA case. Can you also add a test for this?


> Multilingual decoded problem
> 
>
> Key: CALCITE-2704
> URL: https://issues.apache.org/jira/browse/CALCITE-2704
> Project: Calcite
>  Issue Type: Bug
>  Components: avatica
>Affects Versions: avatica-1.11.0, avatica-1.12.0
>Reporter: pufan
>Priority: Blocker
>
> When we execute SQL with Chinese characters, we find that the server parses 
> it in gibberish.
> After checking the code, we found that:
> org.apache.calcite.avatica.server.AvaticaJsonHandler.java line 109:
> {code:java}
> //The readFully method USES utf-8 encoding internally.
> rawRequest = AvaticaUtils.readFully(inputStream, buffer);
> {code}
> But in the org.apache.calcite.avatica.server.AvaticaJsonHandler.java line 116:
> {code:java}
> // Decoded using iso-8859-1 Cause Chinese garble.
> final String jsonRequest = new String(rawRequest.getBytes("ISO-8859-1"), 
> "UTF-8");
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (CALCITE-2704) Multilingual decoded problem

2018-11-25 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/CALCITE-2704?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16698511#comment-16698511
 ] 

ASF GitHub Bot commented on CALCITE-2704:
-

Github user 2k124 commented on the issue:

https://github.com/apache/calcite-avatica/pull/76
  
> Hey @2k124, thanks for opening this PR! Can you please open an issue on 
JIRA with a description of the issue and update the title of the PR to include 
the JIRA case number (ex. [CALCITE-]?

OK. done


> Multilingual decoded problem
> 
>
> Key: CALCITE-2704
> URL: https://issues.apache.org/jira/browse/CALCITE-2704
> Project: Calcite
>  Issue Type: Bug
>  Components: avatica
>Affects Versions: avatica-1.11.0, avatica-1.12.0
>Reporter: pufan
>Priority: Blocker
>
> When we execute SQL with Chinese characters, we find that the server parses 
> it in gibberish.
> After checking the code, we found that:
> org.apache.calcite.avatica.server.AvaticaJsonHandler.java line 109:
> {code:java}
> //The readFully method USES utf-8 encoding internally.
> rawRequest = AvaticaUtils.readFully(inputStream, buffer);
> {code}
> But in the org.apache.calcite.avatica.server.AvaticaJsonHandler.java line 116:
> {code:java}
> // Decoded using iso-8859-1 Cause Chinese garble.
> final String jsonRequest = new String(rawRequest.getBytes("ISO-8859-1"), 
> "UTF-8");
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)