Le jeudi 4 juin 2020 21:12:06 UTC+2, Brian Brazil a écrit : > > >> - our software must support RedHat 7 because some of our client >> servers are running on this distribution; the existing client does not >> compile on this distribution because it uses atomic doubles for thread >> safety, that is only supported from gcc 4.8 (and RHEL 7 has gcc 4.7). >> >> That's a fun one, is there a way to fallback to something else based on > macros or similar? I've had similar issues over in Java. >
AFAICT there is no way of bypassing this limitation. And I really don't think hiding locks behind atomic macros would be a good idea, even if it was possible haha. The only way is to install a more recent version of gcc as suggested by Christian. And I know nothing about Java, so I can't help sorry ;-). > >> - the existing client has a dependency on microhttpd library, and >> would have been a new dependency itself for us. We usually tend to avoid >> having too much external dependencies for our programs. On the other >> hand, >> we already have a HTTP library embeeded in our lib-common, so we >> preferred >> reusing it. >> - thanks to all the tools we have in our library (classes, string >> manipulation, memory allocators, ...), we thought we could develop the >> prometheus client in a more simple way than from scratch, and end up with >> a >> library more simple to use >> >> > I'd hope that the instrumentation bits of a client library would be > independant of the rest and the exposition be replaceable, which does seem > to be the case for the one that's currently listed. > Both parts are separated indeed, but we did not even have the idea to try that (regarding the other aspects). Asking users to pull in a whole library suite plus its dependencies may be > a bit much. > Indeed, if you already have a project and want to add prometheus metrics in it afterwards, the lib-common is not adapted (and it could be *really* complicated to use anyway, we have to work on that). But in the case *"I want to start a new C project for Linux from scratch and I would need to expose prometheus metrics in it"*, it is interresting I guess. > >> - (I think it really is). >> >> Yeah from the code examples the usage looks good, particularly given the > constraints of C. > Glad to hear that! > Brian > > Romain. -- You received this message because you are subscribed to the Google Groups "Prometheus Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-developers/11759738-5bef-4ff2-8f3b-0589f48ae1d4o%40googlegroups.com.

