Hello Fellows! I have problems creating a stream ...
# troubleshooting
d
Hello Fellows! I have problems creating a stream table. I'm executing
Copy code
docker run \
    --network=host \
    -v /Users/danieledu/PROJECTS/PERSONAL/pinot_poc/pinot/config:/config \
    --rm \
    apachepinot/pinot:latest AddTable \
    -schemaFile /config/lending-schema.json \
    -tableConfigFile /config/lending-realtime-table.json \
    -controllerHost localhost \
    -controllerPort 9000 \
    -exec
and I have the follow message
Copy code
2025/03/26 15:34:52.373 INFO [AddTableCommand] [main] {"code":400,"error":"Invalid TableConfigs: lending_realtime. Invalid granularity: null"}
this is my table config, Is based according the documentation getting starter
Copy code
{
  "tableName": "lending_realtime",
  "tableType": "REALTIME",
  "segmentsConfig": {
    "timeColumnName": "timestampInEpoch",
    "timeType": "MILLISECONDS",
    "schemaName": "lending_realtime",
    "replicasPerPartition": "1",
    "segmentGranularity": "hourly"
  },
  "tableIndexConfig": {
    "loadMode": "MMAP",
    "streamConfigs": {
      "streamType": "kafka",
      "stream.kafka.consumer.type": "lowlevel",
      "stream.kafka.topic.name": "data.test",
      "stream.kafka.decoder.class.name": "org.apache.pinot.plugin.stream.kafka.KafkaJSONMessageDecoder",
      "stream.kafka.consumer.factory.class.name": "org.apache.pinot.plugin.stream.kafka20.KafkaConsumerFactory",
      "stream.kafka.broker.list": "org.apache.kafka.common.security.plain.PlainLoginModule required username=\"\" password=\"\";",
      "realtime.segment.flush.threshold.rows": "0",
      "realtime.segment.flush.threshold.time": "24h",
      "realtime.segment.flush.threshold.segment.size": "50M",
      "stream.kafka.consumer.prop.auto.offset.reset": "smallest"
    }
  },
  "tenants": {},
  "metadata": {
    "customConfigs": {}
  }
}
k
this is a schema validation error thats checked when creating a new table you need to define "granularity" for "dateTimeFieldSpecs". example in https://docs.pinot.apache.org/basics/concepts/components/table/schema