Skip to content

Runtime could provide a way to register with the current runtime #268

@cratelyn

Description

@cratelyn

this would be a small tweak for ease of use.

currently, one must explicitly provide a runtime handle, e.g.:

        let registry = registry.sub_registry_with_prefix("tokio_rt");
        let runtime = tokio::runtime::Handle::current();
        let metrics = kubert_prometheus_tokio::Runtime::register(registry, runtime);

it would be nice if there was a way to use the current runtime by default.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions