public class GenericRecordFullPayloadSizeEstimator extends Object implements Serializable
GenericRecord.
A full record is defined as "Every field of a generic record created contains 1 random value"| Constructor and Description |
|---|
GenericRecordFullPayloadSizeEstimator(org.apache.avro.Schema schema) |
| Modifier and Type | Method and Description |
|---|---|
protected int |
estimate(org.apache.avro.Schema schema)
This method estimates the size of the payload if all entries of this payload were populated with one value.
|
protected org.apache.avro.Schema |
getNonNull(org.apache.avro.Schema schema)
Get the nonNull Schema of a given UNION Schema.
|
protected boolean |
isOption(org.apache.avro.Schema schema) |
org.apache.hudi.common.util.collection.Pair<Integer,Integer> |
typeEstimateAndNumComplexFields() |
public GenericRecordFullPayloadSizeEstimator(org.apache.avro.Schema schema)
public org.apache.hudi.common.util.collection.Pair<Integer,Integer> typeEstimateAndNumComplexFields()
protected int estimate(org.apache.avro.Schema schema)
UUID so the length if 36 bytes
whereas a complex data type such as an Array of type Int, will be populated with exactly 1 Integer value.protected boolean isOption(org.apache.avro.Schema schema)
protected org.apache.avro.Schema getNonNull(org.apache.avro.Schema schema)
schema - Copyright © 2023 The Apache Software Foundation. All rights reserved.