SYEDMDSAAD commented on PR #15752: URL: https://github.com/apache/lucene/pull/15752#issuecomment-3957732500
> @SYEDMDSAAD trying to understand the motivation behind this API in Lucene specifically? Why this cannot be added in your application side? @navneet1v Thanks for the question. The motivation is mainly consistency. Right now, Lucene exposes two different APIs for global min/max, and they behave differently when no data exists — one returns null, the other returns sentinel values. That forces callers to know internal details and handle edge cases themselves. While this can be implemented on the application side, the logic depends on Lucene-specific behavior (like skipper availability and sentinel semantics). Centralizing it in Lucene provides a single, consistent contract and avoids duplication and potential mistakes in user code. So the idea is to normalize existing Lucene behavior, not just add convenience. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
