You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-dev@hadoop.apache.org by "Doug Cutting (JIRA)" <ji...@apache.org> on 2007/10/01 19:12:50 UTC

[jira] Commented: (HADOOP-1969) org.apache.hadoop.io.Text uses static ChasetDecoders, but they aren't thread-safe

    [ https://issues.apache.org/jira/browse/HADOOP-1969?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12531570 ] 

Doug Cutting commented on HADOOP-1969:
--------------------------------------

Perhaps this should use a static ThreadLocal instead, so that encoders and decoders are reused per thread?

> org.apache.hadoop.io.Text uses static ChasetDecoders, but they aren't thread-safe
> ---------------------------------------------------------------------------------
>
>                 Key: HADOOP-1969
>                 URL: https://issues.apache.org/jira/browse/HADOOP-1969
>             Project: Hadoop
>          Issue Type: Bug
>          Components: io
>    Affects Versions: 0.14.0
>            Reporter: Colin Evans
>
> org.apache.hadoop.io.Text uses static instances Text.DECODER and Text.ENCODER for all encoding and decoding, but these classes are not thread-safe.  Multiple threads calling Text.toString() at the same time can cause the decoders to output jumbled and garbage data.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.