Skip to content
This repository has been archived by the owner on Apr 23, 2021. It is now read-only.

Polish instrument initialization and lookups #86

Closed
ktoso opened this issue Jul 22, 2020 · 3 comments
Closed

Polish instrument initialization and lookups #86

ktoso opened this issue Jul 22, 2020 · 3 comments

Comments

@ktoso
Copy link
Collaborator

ktoso commented Jul 22, 2020

related question is how the InstrumentationSystem should be configured,
for instance should there be only one instrument, one of a kind and so on:

    // FIXME: smarter impl
    public static var tracer: TracingInstrument {
        self.lock.withReaderLock {
            let tracer: TracingInstrument? = self._tracer
            let res: TracingInstrument = tracer ?? NoOpTracingInstrument()
            return res
        }
    }

BTW the code above will not find a tracer if its provided by official and public MultiplexInstrument

Originally posted by @pokryfka in #31 (comment)

@ktoso
Copy link
Collaborator Author

ktoso commented Jul 22, 2020

Yeah the initialization and obtaining of tracers is not polished yet, can we not conflate the topics though?
New ticket for the fixing of initialization and tracer lookup would be useful.

I agree that it's not clear how we should deal with multiples if there's a tracer and non tracers yet; though that should be solvable IMO.

@slashmo
Copy link
Owner

slashmo commented Aug 7, 2020

@ktoso Can this be closed now as we already merged #101?

@ktoso
Copy link
Collaborator Author

ktoso commented Aug 7, 2020

Good point, I think so 👍

@slashmo slashmo closed this as completed Aug 7, 2020
Development automation moved this from To do to Done Aug 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
Development
  
Done
Development

No branches or pull requests

2 participants