Add merge blocks command to parquet-tools
- Dominant language
- Java
- Stars
- 3.1k
- Forks
- 1.6k
- Avg merge
- 3d 12h
- Merged PRs (30d)
- 33
Description
Current implementation of merge command in parquet-tools doesn't merge row groups, just places one after the other. Add API and command option to be able to merge small blocks into larger ones up to specified size limit.
###### Implementation details:
Blocks are not reordered not to break possible initial predicate pushdown optimizations.
Blocks are not divided to fit upper bound perfectly.
This is an intentional performance optimization.
This gives an opportunity to form new blocks by coping full content of smaller blocks by column, not by row.
###### Examples:
1. Input files with blocks sizes:
```java
[128 | 35], [128 | 40], [120]
```
Expected output file blocks sizes:
`merge `
```java
[128 | 35 | 128 | 40 | 120]
```
`merge -b`
```java
[128 | 35 | 128 | 40 | 120]
```
`merge -b -l 256 `
```java
[163 | 168 | 120]
```
1. Input files with blocks sizes:
```java
[128 | 35], [40], [120], [6]
```
Expected output file blocks sizes:
`merge`
```java
[128 | 35 | 40 | 120 | 6]
```
`merge -b`
```java
[128 | 75 | 126]
```
`merge -b -l 256`
```java
[203 | 126]
```
**Reporter**: [Ekaterina Galieva](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=Katya) / @kgalieva
**Assignee**: [Ekaterina Galieva](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=Katya) / @kgalieva
#### PRs and other links:
- [GitHub Pull Request #512](https://github.com/apache/parquet-mr/pull/512)
- [GitHub Pull Request #621](https://github.com/apache/parquet-mr/pull/621)
- [GitHub Pull Request #775](https://github.com/apache/parquet-mr/pull/775)
- [GitHub Pull Request #512](https://github.com/apache/parquet-mr/pull/512)
**Note**: *This issue was originally created as [PARQUET-1381](https://issues.apache.org/jira/browse/PARQUET-1381). Please see the [migration documentation](https://issues.apache.org/jira/browse/PARQUET-2502) for further details.*
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.