Hi -

> Could you also add a reference to the Prometheus Exposition format. I
> see it is already in a comment in the code. Best to also add it as See
> also in the docs.

OK.

> > +control.  The \fI/metrics\fP webapi endpoint is probably not
> > +appropriate for disclosure to the public.
> 
> So, should there be an option to turn it off?

IMHO not necessary.  The security section already advises against
exposing an unprotected debuginfod server to the public.  A front-end
reverse-proxy would easily filter requests to /metrics.


> > +#ifdef __linux__
> > +#define gettid() syscall(SYS_gettid)
> > +#else
> > +#define gettid() pthread_self()
> > +#endif
> 
> You might want to rename this since newer glibc might expose gettid().

OK.

> > +# Fetch some metrics, if curl program is installed
> > +if which curl 2>/dev/null; then
> > +    curl http://localhost:$PORT1/badapi
> > +    curl http://localhost:$PORT1/metrics
> >  ########################################################################
> 
> I think it is better to check with:
> if type curl >/dev/null 2>&1; then

OK.

- FChE

Reply via email to