Only keep aggregated data when the records is older than a specific period of time

Is there any configuration we can set to only keep some granularity aggregated data when the data is older than a specific time period.
Say for example, we have 100 records in druid now and we want to only keep the data aggregated in 10 minutes when the records is 30 minutes old from now. Is it possible? Thanks!