I want to create real time and historical charts (for example by chart.js library) from the elasticsearch documents.
each document has its own date field. So I want to have a linear chart (x axis : time field, y axis: another (value) filed) monthly, from example between (1-Jan-2020 to 1-Feb-2020).
If I want to query a list of (x,y) values between this time range, the problem is that the amount of data in this period is very large (2592000 records monthly).
Do I have to break down my chart into smaller periods (for example daily)?
what is the best way to do this scenario?