You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "Patrick Hunt (JIRA)" <ji...@apache.org> on 2009/04/10 22:15:15 UTC
[jira] Created: (AVRO-3) ValueReader does not detect EOF, infinite
loop results
ValueReader does not detect EOF, infinite loop results
------------------------------------------------------
Key: AVRO-3
URL: https://issues.apache.org/jira/browse/AVRO-3
Project: Avro
Issue Type: Bug
Components: java
Affects Versions: 1.0
Environment: Ubuntu 8.10, single core
Reporter: Patrick Hunt
Priority: Critical
readLong() will hang (100%cpu infinite loop) when the end of the stream is reached. in.read() returns -1 but that's not checked for. I suspect you want to throw EOFException similar to DataInput? Seems like all the read* methods in ValueReader have this issue.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (AVRO-3) ValueReader does not detect EOF, infinite
loop results
Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AVRO-3?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Patrick Hunt updated AVRO-3:
----------------------------
Attachment: AVRO-3.patch
This patch checks for EOF condition in the input stream.
> ValueReader does not detect EOF, infinite loop results
> ------------------------------------------------------
>
> Key: AVRO-3
> URL: https://issues.apache.org/jira/browse/AVRO-3
> Project: Avro
> Issue Type: Bug
> Components: java
> Affects Versions: 1.0
> Environment: Ubuntu 8.10, single core
> Reporter: Patrick Hunt
> Assignee: Doug Cutting
> Priority: Critical
> Attachments: AVRO-3.patch, AVRO-3.patch
>
>
> readLong() will hang (100%cpu infinite loop) when the end of the stream is reached. in.read() returns -1 but that's not checked for. I suspect you want to throw EOFException similar to DataInput? Seems like all the read* methods in ValueReader have this issue.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (AVRO-3) ValueReader does not detect EOF, infinite
loop results
Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AVRO-3?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Patrick Hunt updated AVRO-3:
----------------------------
Status: Patch Available (was: Open)
> ValueReader does not detect EOF, infinite loop results
> ------------------------------------------------------
>
> Key: AVRO-3
> URL: https://issues.apache.org/jira/browse/AVRO-3
> Project: Avro
> Issue Type: Bug
> Components: java
> Affects Versions: 1.0
> Environment: Ubuntu 8.10, single core
> Reporter: Patrick Hunt
> Assignee: Doug Cutting
> Priority: Critical
> Attachments: AVRO-3.patch, AVRO-3.patch, AVRO-3.patch
>
>
> readLong() will hang (100%cpu infinite loop) when the end of the stream is reached. in.read() returns -1 but that's not checked for. I suspect you want to throw EOFException similar to DataInput? Seems like all the read* methods in ValueReader have this issue.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (AVRO-3) ValueReader does not detect EOF, infinite
loop results
Posted by "Doug Cutting (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AVRO-3?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Doug Cutting updated AVRO-3:
----------------------------
Attachment: AVRO-3.patch
Here's a patch that fixes this by throwing EOFException. This has a performance impact, but hopefully not a significant one. It also fixes some other bugs in ByteBufferInputStream. Does this work for you?
> ValueReader does not detect EOF, infinite loop results
> ------------------------------------------------------
>
> Key: AVRO-3
> URL: https://issues.apache.org/jira/browse/AVRO-3
> Project: Avro
> Issue Type: Bug
> Components: java
> Affects Versions: 1.0
> Environment: Ubuntu 8.10, single core
> Reporter: Patrick Hunt
> Priority: Critical
> Attachments: AVRO-3.patch
>
>
> readLong() will hang (100%cpu infinite loop) when the end of the stream is reached. in.read() returns -1 but that's not checked for. I suspect you want to throw EOFException similar to DataInput? Seems like all the read* methods in ValueReader have this issue.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (AVRO-3) ValueReader does not detect EOF, infinite
loop results
Posted by "Doug Cutting (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AVRO-3?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Doug Cutting reassigned AVRO-3:
-------------------------------
Assignee: Doug Cutting
> ValueReader does not detect EOF, infinite loop results
> ------------------------------------------------------
>
> Key: AVRO-3
> URL: https://issues.apache.org/jira/browse/AVRO-3
> Project: Avro
> Issue Type: Bug
> Components: java
> Affects Versions: 1.0
> Environment: Ubuntu 8.10, single core
> Reporter: Patrick Hunt
> Assignee: Doug Cutting
> Priority: Critical
> Attachments: AVRO-3.patch
>
>
> readLong() will hang (100%cpu infinite loop) when the end of the stream is reached. in.read() returns -1 but that's not checked for. I suspect you want to throw EOFException similar to DataInput? Seems like all the read* methods in ValueReader have this issue.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (AVRO-3) ValueReader does not detect EOF, infinite
loop results
Posted by "Doug Cutting (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AVRO-3?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Doug Cutting updated AVRO-3:
----------------------------
Resolution: Fixed
Fix Version/s: 1.0
Status: Resolved (was: Patch Available)
I just committed this. Thanks, Pat!
> ValueReader does not detect EOF, infinite loop results
> ------------------------------------------------------
>
> Key: AVRO-3
> URL: https://issues.apache.org/jira/browse/AVRO-3
> Project: Avro
> Issue Type: Bug
> Components: java
> Affects Versions: 1.0
> Environment: Ubuntu 8.10, single core
> Reporter: Patrick Hunt
> Assignee: Doug Cutting
> Priority: Critical
> Fix For: 1.0
>
> Attachments: AVRO-3.patch, AVRO-3.patch, AVRO-3.patch
>
>
> readLong() will hang (100%cpu infinite loop) when the end of the stream is reached. in.read() returns -1 but that's not checked for. I suspect you want to throw EOFException similar to DataInput? Seems like all the read* methods in ValueReader have this issue.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (AVRO-3) ValueReader does not detect EOF, infinite
loop results
Posted by "Patrick Hunt (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AVRO-3?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Patrick Hunt updated AVRO-3:
----------------------------
Attachment: AVRO-3.patch
Latest patch merges in the individual patches from Doug and I into a single patch.
> ValueReader does not detect EOF, infinite loop results
> ------------------------------------------------------
>
> Key: AVRO-3
> URL: https://issues.apache.org/jira/browse/AVRO-3
> Project: Avro
> Issue Type: Bug
> Components: java
> Affects Versions: 1.0
> Environment: Ubuntu 8.10, single core
> Reporter: Patrick Hunt
> Assignee: Doug Cutting
> Priority: Critical
> Attachments: AVRO-3.patch, AVRO-3.patch, AVRO-3.patch
>
>
> readLong() will hang (100%cpu infinite loop) when the end of the stream is reached. in.read() returns -1 but that's not checked for. I suspect you want to throw EOFException similar to DataInput? Seems like all the read* methods in ValueReader have this issue.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.