Skip to content

calling PropertiesV2 as library consumer #2370

@jkroepke

Description

@jkroepke

The windows_exporter embeds Microsoft's hcsshim library to fetch container metrics.

Currently, only the legacy v1 call can be used by other programs, as they do not have access to the internal package. For example, in hcsshim, the relevant function is defined internally and not exposed for external use.

hcsshim/container.go

Lines 169 to 170 in e5c83a1

// Statistics returns statistics for the container. This is a legacy v1 call
func (container *container) Statistics() (Statistics, error) {

However, there is no v2 function available that supports the new functionality.

The v1 legacy call has some limitations: If containerd is used, network statistics are no longer available, and Host/Job Containers are not exposed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions