metrics

package
v0.46.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 17, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Metrics

type Metrics struct {
	Rancher      ReleaseMetrics   `json:"rancher"`
	RancherPrime ReleaseMetrics   `json:"rancher_prime"`
	Workflows    WorkflowsMetrics `json:"actions"`
}

func ExtractMetrics

func ExtractMetrics(rancherReleases []github.RepositoryRelease, primeReleases []github.RepositoryRelease, workflows []github.WorkflowRun) (Metrics, error)

type ReleaseMetrics

type ReleaseMetrics struct {
	// Number of GA releases per year and month
	// Value: Number of releases per month (Jan: 0, Feb: 1, ..., Dec: 11)
	GAReleasesPerMonth yearMonthMap `json:"ga_releases_per_month"`
	// Number of Pre-releases per year and month (any release with a suffix that starts with a dash '-*')
	// Value: Number of releases per month (Jan: 0, Feb: 1, ..., Dec: 11)
	PreReleasesPerMonth yearMonthMap `json:"pre_releases_per_month"`
	// Number of GA releases per year
	// Value: Number of releases per year
	GAReleasesPerYear yearMap `json:"ga_releases_per_year"`
	// Number of Pre-releases per year
	// Value: Number of releases per year
	PreReleasesPerYear yearMap `json:"pre_releases_per_year"`
}

type WorkflowsMetrics

type WorkflowsMetrics struct {
	// Number of successful actions per year and month
	// Key: Year
	// Value: Number of successful actions per month (Jan: 0, Feb: 1, ..., Dec: 11)
	SuccessfulWorkflowsPerMonth yearMonthMap `json:"successful_actions_per_month"`
	// Number of failed actions per year and month
	// Key: Year
	// Value: Number of failed actions per month (Jan: 0, Feb: 1, ..., Dec: 11)
	FailedWorkflowsPerMonth yearMonthMap `json:"failed_actions_per_month"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL