Added comments for better readability and fixed probabistic patterns

This commit is contained in:
2024-12-04 17:26:34 -06:00
parent adba4e25dc
commit 5dad2d5275
5 changed files with 166 additions and 66 deletions

View File

@ -5,6 +5,8 @@ import (
"time"
)
// PerformanceMetrics represents a thread-safe container for tracking
// performance statistics during load testing
type PerformanceMetrics struct {
Mu sync.Mutex
TotalRequests int32
@ -15,12 +17,14 @@ type PerformanceMetrics struct {
ResponseCounters map[int]int32
}
// RequestError represents a detailed error that occurs during an HTTP request
type RequestError struct {
Verb string
URL string
Err error
}
// RequestPattern defines the characteristics of requests to be sent during load testing
type RequestPattern struct {
Verb string
Percentage float64