Pinot Version | 1.0.0 |
---|---|
Code | startreedata/pinot-recipes/geospatial-default |
jq
to structure the data in the key:payload
structure that Kafka expects:
point
has a data type of BYTES
. Geospatial columns must use the BYTES
type because Pinot will serialize the Geospatial objects into bytes for storage purposes.
We are also passing in a defaultNullValue
which must be a Hex encoded representation of a point. In this case the point is a location in the Arctic.
003fe5f4a42008f90c4054e004d205fbe4 |
---|
003fe5f4a42008f90c4054e004d205fbe4 |
BYTES
column we’ll need to create the schema and table separately, rather than using the AddTable
command. If we try to use the AddTable
command, we’ll end up with double decoding of the defaultNullValue
, resulting in Pinot trying to store an invalid value.
Instead, we’ll create the schema with the AddSchema
command:
distance | count(*) |
---|---|
0 | 3147529 |
250.4421880885498 | 1 |
250.35032602023736 | 1 |
250.3445873086931 | 1 |
250.32023987252305 | 1 |
250.28500644222484 | 1 |
250.26623501229875 | 1 |
250.26271972684384 | 1 |
250.25918510024783 | 1 |
250.2511511361528 | 1 |