Is there any way of setting a global parameter across indices in ES to the effect of defining the limit of size of each document and if the document size in any index exceeding this limit (either as result of indexing or as result of updates to the same document) updates a specific metric of ES ?
Context of usecase : I have a usecase where documents are either indexed immutably or same document updated at higher frequency exposed as a API on top of ES client API. As we know indexing large documents (~100 to ~120kb size per document) and in addition, updating the same is not a good practice. Hence, I wanted to find a way of defining a document-size threshold and track excess of the defined threshold.
Searched around for the configuration and metrics to above effect at ES level, but. could not find any direct way.
Please let me know if I am missing any existing metrics with above capability