apache / apache/parquet-java

ProtoReader does not iterate over the parquet file correctly.

Đang mở
#2,497 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
Component: Java Component: Parquet Priority: Major Type: bug
Ngôn ngữ chính
Java
Star
3.1k
Fork
1.6k
Merge trung bình
3 ngày 12 giờ
Pull request đã merge (30 ngày)
33

Mô tả

The `ProtoParquetReader` does not iterate over the parquet file correctly, but it gets stuck in the first element and keeps reading as many times as elements the file contained.

In my Scala example I am just reading from a local file that I know for sure it contains right data.

```

val hadoopCOnf = new Configuration()

val outfile: String = genTemporaryFile()

val r: ParquetReader[Event.Builder] = {
ProtoParquetReader.builder[Event.Builder](new Path(outfile)).withConf(hadoopCOnf).build()
}

```

Notice that the proto schema that I am using is generated from 

The generated proto implements com.google.protobuf.GeneratedMessageV3.

See an example on how the ProtoParquetReader is created line(65 and 69): 

and here how it is used (notice that is defined for only one record, the same one for multiple records would fail) 

 

**Reporter**: [Pau Alarcon ](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=paualarco)

**Note**: *This issue was originally created as [PARQUET-1871](https://issues.apache.org/jira/browse/PARQUET-1871). Please see the [migration documentation](https://issues.apache.org/jira/browse/PARQUET-2502) for further details.*

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Hướng nghiên cứu

Bắt đầu với ProtoParquetReader và so sánh cách khởi tạo nó trong ProtoParquetFixture.scala của monix-connect, khoảng các dòng 65-69, với cách sử dụng nó trong ProtoParquetSpec.scala, khoảng dòng 83. Tái hiện hành vi này với nhiều bản ghi và xác minh rằng việc lặp trả về các bản ghi tiếp theo thay vì lặp lại bản ghi đầu tiên.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
java, scala
Lĩnh vực
data-engineering
Loại issue
Lỗi
Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
35/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.