OPENTELEMETRY_BEGIN_NAMESPACE namespace sdk
{ namespace common
{ // Wraps a thread_local random number generator, but adds a fork handler so that // the generator will be correctly seeded after forking. // // See https://stackoverflow.com/q/51882689/4447365 and // https://github.com/opentracing-contrib/nginx-opentracing/issues/52 namespace
{ class TlsRandomNumberGenerator
{ public:
TlsRandomNumberGenerator() noexcept
{
Seed(); if (!flag.test_and_set())
{
platform::AtFork(nullptr, nullptr, OnFork);
}
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.