Does granularitySpec intervals have to be multiple of segmentGranularity ?

Becaues if the Intervals are not exact multiple of segmentGranularity, I get this problem :

In otherwords with segmentGranularity DAY the intervals must be at least one DAY long, correct ?

queryGranularity doesn’t make sense at ingestion time.

Are you trying to roll up all your data for all time?

I’m talking about lines :

“segmentGranularity” : “DAY”,
“intervals” : [ “2015-01-01T00Z/2015-01-01T05Z” ]

regardless of queryGranularity. That the intervals must be a multiple of segmentGranularity otherwise it throws an exception (in gist).

Btw, query granularity is specified here so I thought it had to be there…

In the ingestion spec you posted, you have queryGranularity “all”, that doesn’t make sense for ingesting data.

Hey Jakub,

The expected granularitySpec setup is:

  • “intervals” are aligned to “segmentGranularity” boundaries. If they don’t align, Druid will widen them out to be aligned.

  • “queryGranularity” is equal to or fits inside “segmentGranularity”, in particular queryGranularity “all” is not useful.

So what happened to you is that your “intervals” got widened out to the full day, but since you don’t have any data past hour 5, you got that file not found exception. You could avoid that by either,

  • using a shorter segment granularity (like HOUR)

  • or by creating empty directories for the hours you don’t have data for

  • or by using the “static” inputSpec to specify a specific list of directories to load rather than using the “granularity” inputSpec.

FYI, the FileNotFoundException was fixed in which should be in Druid 0.9.