github.com/blend/go-sdk@v1.20220411.3/status/constants.go (about) 1 /* 2 3 Copyright (c) 2022 - Present. Blend Labs, Inc. All rights reserved 4 Use of this source code is governed by a MIT license that can be found in the LICENSE file. 5 6 */ 7 8 package status 9 10 import ( 11 "time" 12 13 "github.com/blend/go-sdk/ex" 14 ) 15 16 // Errors 17 const ( 18 ErrServiceCheckNotDefined ex.Class = "service check is not defined for service" 19 ) 20 21 const ( 22 // DefaultFreeformTimeout is a timeout. 23 DefaultFreeformTimeout = 10 * time.Second 24 // DefaultTrackedActionExpiration is the default tracker expiration. 25 DefaultTrackedActionExpiration = 5 * time.Minute 26 // DefaultYellowRequestCount is the default tracker yellow request count. 27 DefaultYellowRequestCount = 10 28 // DefaultYellowRequestPercentage is the default tracker yellow request percentage. 29 DefaultYellowRequestPercentage = 0.005 // 0.5% or 50 bps 30 // DefaultRedRequestCount is the default tracker red request count. 31 DefaultRedRequestCount = 50 32 // DefaultRedRequestPercentage is the default tracker yellow request percentage. 33 DefaultRedRequestPercentage = 0.05 // 5% or 500 bps 34 ) 35 36 // Signal is a status signal. 37 type Signal string 38 39 // Signal constants 40 const ( 41 SignalUnknown Signal = "" 42 SignalGreen Signal = "green" 43 SignalYellow Signal = "yellow" 44 SignalRed Signal = "red" 45 )