You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Maxim Gekk (JIRA)" <ji...@apache.org> on 2019/04/06 08:54:00 UTC

[jira] [Created] (SPARK-27398) Get rid of sun.nio.cs.StreamDecoder in CreateJacksonParser

Maxim Gekk created SPARK-27398:
----------------------------------

             Summary: Get rid of sun.nio.cs.StreamDecoder in CreateJacksonParser
                 Key: SPARK-27398
                 URL: https://issues.apache.org/jira/browse/SPARK-27398
             Project: Spark
          Issue Type: Improvement
          Components: SQL
    Affects Versions: 2.4.0
            Reporter: Maxim Gekk


The CreateJacksonParser.getStreamDecoder method creates an instance of ReadableByteChannel and returns the result as of sun.nio.cs.StreamDecoder. This is unnecessary and overcomplicates the method. This code can be replaced by:
{code:scala}
val bais = new ByteArrayInputStream(in, 0, length)
new InputStreamReader(bais, enc)
{code}



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

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org