project_report

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2024 License: Apache-2.0 Imports: 40 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IterationInfo

type IterationInfo struct {
	Iteration  *iterationdb.Iteration
	OrgDto     *orgpb.Org
	ProjectDto *model.Project
	Labels     []string

	IterationMetricFields *IterationMetricFields
}

type IterationLabelsFunc

type IterationLabelsFunc func(info *IterationInfo) map[string]string

type IterationMetricFields

type IterationMetricFields struct {
	IterationID  uint64
	CalculatedAt time.Time
	UUID         string

	// task-related metrics
	TaskTotal                          uint64
	TaskTotalIDs                       []uint64
	TaskEstimatedMinute                uint64
	TaskElapsedMinute                  uint64
	TaskDoneTotal                      uint64
	TaskDoneTotalIDs                   []uint64
	TaskCompleteSchedule               float64
	TaskBeInclusionRequirementTotal    uint64
	TaskBeInclusionRequirementTotalIDs []uint64
	TaskUnAssociatedTotal              uint64
	TaskUnAssociatedTotalIDs           []uint64
	TaskAssociatedPercent              float64
	TaskWorkingTotal                   uint64
	TaskWorkingTotalIDs                []uint64
	TaskEstimatedDayGtOneTotal         uint64
	TaskEstimatedDayGtTwoTotal         uint64
	TaskEstimatedDayGtThreeTotal       uint64

	// requirement-related metrics
	RequirementTotal                  uint64
	RequirementTotalIDs               []uint64
	RequirementDoneTotal              uint64
	RequirementDoneTotalIDs           []uint64
	RequirementCompleteSchedule       float64
	RequirementAssociatedTaskTotal    uint64
	RequirementAssociatedTaskTotalIDs []uint64
	RequirementAssociatedPercent      float64

	// bug-related metrics
	BugTotal                uint64
	BugTotalIDs             []uint64
	SeriousBugTotal         uint64
	SeriousBugTotalIDs      []uint64
	SeriousBugPercent       float64
	DemandDesignBugTotal    uint64
	DemandDesignBugTotalIDs []uint64
	DemandDesignBugPercent  float64
	ReopenBugTotal          uint64
	ReopenBugTotalIDs       []uint64
	ReopenBugPercent        float64
	BugDoneTotal            uint64
	BugDoneTotalIDs         []uint64
	BugUndoneTotal          uint64
	BugUndoneTotalIDs       []uint64
	BugCompleteSchedule     float64
	BugWontfixTotal         uint64
	BugWontfixTotalIDs      []uint64
	BugWithWonfixTotal      uint64
	BugWithWonfixTotalIDs   []uint64

	// iteration-related metrics
	IterationAssigneeNum       uint64
	IterationAssignees         []string
	IterationEstimatedDayTotal float64
	ProjectAssigneeNum         uint64
}

func (*IterationMetricFields) IsValid

func (i *IterationMetricFields) IsValid() bool

IsValid returns true if the IterationMetricFields is valid. we need to ensure that IterationMetricFields is the data of the day to avoid double calculation

type ProjectReportRow

type ProjectReportRow struct {
	RequirementTotal             float64   `json:"requirementTotal" ch:"requirementTotal"`
	BugTotal                     float64   `json:"bugTotal" ch:"bugTotal"`
	TaskTotal                    float64   `json:"taskTotal" ch:"taskTotal"`
	ResponsibleFuncPointsTotal   float64   `json:"responsibleFuncPointsTotal" ch:"responsibleFuncPointsTotal"`
	RequirementFuncPointsTotal   float64   `json:"requirementFuncPointsTotal" ch:"requirementFuncPointsTotal"`
	DevFuncPointsTotal           float64   `json:"devFuncPointsTotal" ch:"devFuncPointsTotal"`
	DemandFuncPointsTotal        float64   `json:"demandFuncPointsTotal" ch:"demandFuncPointsTotal"`
	TestFuncPointsTotal          float64   `json:"testFuncPointsTotal" ch:"testFuncPointsTotal"`
	BudgetMandayTotal            float64   `json:"budgetMandayTotal" ch:"budgetMandayTotal"`
	TaskEstimatedMinute          float64   `json:"taskEstimatedMinute" ch:"taskEstimatedMinute"`
	TaskEstimatedManday          float64   `json:"taskEstimatedManday" ch:"taskEstimatedManday"`
	ActualMandayTotal            float64   `json:"actualMandayTotal" ch:"actualMandayTotal"`
	RequirementDoneRate          float64   `json:"requirementDoneRate" ch:"requirementDoneRate"`
	TaskDoneTotal                float64   `json:"taskDoneTotal" ch:"taskDoneTotal"`
	TaskDoneRate                 float64   `json:"taskDoneRate" ch:"taskDoneRate"`
	TaskEstimatedDayGtOneTotal   float64   `json:"taskEstimatedDayGtOneTotal" ch:"taskEstimatedDayGtOneTotal"`
	TaskEstimatedDayGtTwoTotal   float64   `json:"taskEstimatedDayGtTwoTotal" ch:"taskEstimatedDayGtTwoTotal"`
	TaskEstimatedDayGtThreeTotal float64   `json:"taskEstimatedDayGtThreeTotal" ch:"taskEstimatedDayGtThreeTotal"`
	UnfinishedAssigneeTotal      float64   `json:"unfinishedAssigneeTotal" ch:"unfinishedAssigneeTotal"`
	RequirementDoneTotal         float64   `json:"requirementDoneTotal" ch:"requirementDoneTotal"`
	RequirementAssociatedTotal   float64   `json:"requirementAssociatedTotal" ch:"requirementAssociatedTotal"`
	RequirementAssociatedRate    float64   `json:"requirementAssociatedRate" ch:"requirementAssociatedRate"`
	RequirementUnassignedTotal   float64   `json:"requirementUnassignedTotal" ch:"requirementUnassignedTotal"`
	RequirementUnassignedRate    float64   `json:"requirementUnassignedRate" ch:"requirementUnassignedRate"`
	TaskUnassignedTotal          float64   `json:"taskUnassignedTotal" ch:"taskUnassignedTotal"`
	BugUndoneTotal               float64   `json:"bugUndoneTotal" ch:"bugUndoneTotal"`
	BugDoneRate                  float64   `json:"bugDoneRate" ch:"bugDoneRate"`
	BugSeriousTotal              float64   `json:"bugSeriousTotal" ch:"bugSeriousTotal"`
	BugSeriousRate               float64   `json:"bugSeriousRate" ch:"bugSeriousRate"`
	BugDemandDesignTotal         float64   `json:"bugDemandDesignTotal" ch:"bugDemandDesignTotal"`
	BugDemandDesignRate          float64   `json:"bugDemandDesignRate" ch:"bugDemandDesignRate"`
	BugOnlineTotal               float64   `json:"bugOnlineTotal" ch:"bugOnlineTotal"`
	BugOnlineRate                float64   `json:"bugOnlineRate" ch:"bugOnlineRate"`
	BugReopenTotal               float64   `json:"bugReopenTotal" ch:"bugReopenTotal"`
	BugReopenRate                float64   `json:"bugReopenRate" ch:"bugReopenRate"`
	TaskAssociatedTotal          float64   `json:"taskAssociatedTotal" ch:"taskAssociatedTotal"`
	TaskAssociatedRate           float64   `json:"taskAssociatedRate" ch:"taskAssociatedRate"`
	BugLowLevelTotal             float64   `json:"bugLowLevelTotal" ch:"bugLowLevelTotal"`
	BugLowLevelRate              float64   `json:"bugLowLevelRate" ch:"bugLowLevelRate"`
	IterationCompletedRate       float64   `json:"iterationCompletedRate" ch:"iterationCompletedRate"`
	TaskWorkingTotal             float64   `json:"taskWorkingTotal" ch:"taskWorkingTotal"`
	BugWontfixTotal              float64   `json:"bugWontfixTotal" ch:"bugWontfixTotal"`
	IterationAssigneeTotal       float64   `json:"iterationAssigneeTotal" ch:"iterationAssigneeTotal"`
	IterationEstimatedDayTotal   float64   `json:"iterationEstimatedDayTotal" ch:"iterationEstimatedDayTotal"`
	ProjectName                  string    `json:"projectName" ch:"projectName"`
	ProjectDisplayName           string    `json:"projectDisplayName" ch:"projectDisplayName"`
	ProjectID                    string    `json:"projectID" ch:"projectID"`
	Timestamp                    time.Time `json:"timestamp" ch:"timestamp"`
	EmpProjectCode               string    `json:"empProjectCode" ch:"empProjectCode"`
	BeginDate                    string    `json:"beginDate" ch:"beginDate"`
	EndDate                      string    `json:"endDate" ch:"endDate"`
	ActualEndDate                string    `json:"actualEndDate" ch:"actualEndDate"`
	ProjectAssignees             []string  `json:"projectAssignees" ch:"projectAssignees"`
}

type PrometheusCollector

type PrometheusCollector struct {
	// contains filtered or unexported fields
}

func (*PrometheusCollector) Collect

func (c *PrometheusCollector) Collect(ch chan<- prometheus.Metric)

func (*PrometheusCollector) Describe

func (c *PrometheusCollector) Describe(ch chan<- *prometheus.Desc)

Jump to

Keyboard shortcuts

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