Last active
December 25, 2021 10:36
-
-
Save samueleresca/840a180bc9ab4735dfb20fb274654b10 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// OptimizeType describes an optimization type | |
type OptimizeType string | |
const ( | |
Load OptimizeType = "Load" | |
Network OptimizeType = "Network" | |
Latency OptimizeType = "Latency" | |
) | |
// StrategyOptions describes the quorum system strategy options. | |
type StrategyOptions struct { | |
// Optimize defines the target optimization. | |
Optimize OptimizeType | |
// LoadLimit defines the limit on the load limit. | |
LoadLimit *float64 | |
// NetworkLimit defines the limit on the network limit. | |
NetworkLimit *float64 | |
// LatencyLimit defines the limit on the latency. | |
LatencyLimit *float64 | |
// ReadFraction defines the workflow distribution for the read operations. | |
ReadFraction Distribution | |
// WriteFraction defines the workflow distribution for the write operations. | |
WriteFraction Distribution | |
// F r ∈ R is F-resilient for some integer f if despite removing | |
// any f nodes from r, r is still a read quorum | |
F uint | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment