mirror of
https://github.com/openobserve/openobserve.git
synced 2026-11-05 08:09:22 +00:00
Currently we first parse the request body, and then check if the ingestion is allowed for given org (in case of cloud, for trial period) . However, if the ingestion is not allowed, we shouldn't even spend cpu and mem for parsing the request, and instead reject it with 429 right away. This will also clean up our logs a bit, as right now there are many req, which have invalid body, and log that error, however even if they had a valid body structure, they would be rejected because trial period expiry. With this PR, the logs would be reduced for such kind of requests. Signed-off-by: Yashodhan Joshi <yjdoc2@gmail.com> Co-authored-by: Yashodhan Joshi <yjdoc2@gmail.com>