How to prevent GET requests logging only?
Author: eduardopezziCreated Feb 12, 2024Updated Feb 16, 2024
import hug
from threading import Thread
from src.libs.versionMiddleware import VersionMiddleware
api = hug.API(__name__)
api.http.add_middleware(
hug.middleware.CORSMiddleware(api, allow_origins=["*"])
)
api.http.add_middleware(
VersionMiddleware('prometheus-version')
)Implementing HUG API I am trying to prevent the GET requests output at the container logs/prompt
I tried to make a custom middleware without success... any suggestion?
Source: hugapi/hug