You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "Étienne Lafarge (Jira)" <ji...@apache.org> on 2020/12/09 19:22:00 UTC
[jira] [Commented] (AVRO-2927) Error fetching next object from
block
[ https://issues.apache.org/jira/browse/AVRO-2927?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17246759#comment-17246759 ]
Étienne Lafarge commented on AVRO-2927:
---------------------------------------
I confirm I can reproduce this issue with fields containing more than 256 bytes of data. Typically: long blobs of text :/
> Error fetching next object from block
> -------------------------------------
>
> Key: AVRO-2927
> URL: https://issues.apache.org/jira/browse/AVRO-2927
> Project: Apache Avro
> Issue Type: Bug
> Components: csharp
> Affects Versions: 1.10.0
> Environment: .net core 3.1
>
> Windows 10
> Reporter: Anita
> Priority: Major
>
> Below Error we are getting at last line
> var dataFileReader = Avro.File.DataFileReader<avroclass>.OpenReader(stream);
> while (dataFileReader.HasNext())
> {
> var genRec = dataFileReader.Next();
> }
>
> Avro.AvroRuntimeException
> HResult=0x80131500
> Message=Error fetching next object from block: Avro.AvroException: Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index') in field DESC_LONG
> ---> System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')
> at System.Collections.Generic.List`1.get_Item(Int32 index)
> at Avro.UnionSchema.get_Item(Int32 index)
> at Avro.Generic.DefaultReader.ReadUnion(Object reuse, UnionSchema writerSchema, Schema readerSchema, Decoder d)
> at Avro.Generic.DefaultReader.Read(Object reuse, Schema writerSchema, Schema readerSchema, Decoder d)
> at Avro.Generic.DefaultReader.ReadRecord(Object reuse, RecordSchema writerSchema, Schema readerSchema, Decoder dec)
> --- End of inner exception stack trace ---
> at Avro.Generic.DefaultReader.ReadRecord(Object reuse, RecordSchema writerSchema, Schema readerSchema, Decoder dec)
> at Avro.Generic.DefaultReader.Read(Object reuse, Schema writerSchema, Schema readerSchema, Decoder d)
> at Avro.Generic.DefaultReader.Read[T](T reuse, Decoder decoder)
> at Avro.Generic.GenericReader`1.Read(T reuse, Decoder d)
> at Avro.File.DataFileReader`1.Next(T reuse)
> Source=Avro
> StackTrace:
> at Avro.File.DataFileReader`1.Next(T reuse)
> at Avro.File.DataFileReader`1.Next()
> at CCC.CAS.ReferenceMessages.AvroBuilder.ReadAvro(Dictionary`2 avroDict, Stream stream, iAvroFileMaper mapper) in C:\dev\CAS-Common-Reliance\src\CCC.CAS.ReferenceMessages\AvroCodeLookupRepository.cs:line 186
> at CCC.CAS.ReferenceMessages.AvroBuilder.BuildAvroLookUpDictionary(String baseUri, String[] pathStrings) in C:\dev\CAS-Common-Reliance\src\CCC.CAS.ReferenceMessages\AvroCodeLookupRepository.cs:line 239
> at CCC.CAS.ReferenceMessages.AvroBuilder..ctor(String baseUri, String[] pathStrings) in C:\dev\CAS-Common-Reliance\src\CCC.CAS.ReferenceMessages\AvroCodeLookupRepository.cs:line 141
> at CCC.CAS.ReferenceMessages.AvroCodeLookupRepository..ctor(String baseUri, String[] pathStrings) in C:\dev\CAS-Common-Reliance\src\CCC.CAS.ReferenceMessages\AvroCodeLookupRepository.cs:line 30
> at ReferenceRepoTest.Program.Main(String[] args) in C:\dev\CAS-Common-Reliance\src\ReferenceRepoTest\Program.cs:line 11
--
This message was sent by Atlassian Jira
(v8.3.4#803005)