 Documentation
      ¶
      Documentation
      ¶
    
    
  
    
  
    Index ¶
- Constants
- Variables
- func CheckState(rs ReplSetStatus, startupDelaySeconds int64, oplogSize int64) error
- func HealthCheckMongodLiveness(client *mgo.Client, startupDelaySeconds int64) (*mongo.MemberState, error)
- func HealthCheckMongosLiveness(client *mgo.Client) error
- func MongosReadinessCheck(client *mongo.Client) error
- type InitialSyncStatus
- type OplogRs
- type ReplSetStatus
- type ServerStatus
- type State
Constants ¶
      View Source
      
  
const (
	Version = "0.5.0"
)
    Variables ¶
      View Source
      
  
    var ErrNoReplsetConfigStr string = "(NotYetInitialized) no replset config has been received"
    
      View Source
      
  var OkMemberStates = []mongo.MemberState{ mongo.MemberStatePrimary, mongo.MemberStateSecondary, mongo.MemberStateRecovering, mongo.MemberStateArbiter, mongo.MemberStateStartup2, mongo.MemberStateRollback, }
OkMemberStates is a slice of acceptable replication member states
Functions ¶
func CheckState ¶ added in v1.10.0
func CheckState(rs ReplSetStatus, startupDelaySeconds int64, oplogSize int64) error
func MongosReadinessCheck ¶
Types ¶
type InitialSyncStatus ¶
type InitialSyncStatus interface{}
    type ReplSetStatus ¶
type ReplSetStatus struct {
	mongo.Status      `bson:",inline"`
	InitialSyncStatus InitialSyncStatus `bson:"initialSyncStatus" json:"initialSyncStatus"`
}
    type ServerStatus ¶
type State ¶
type State int
func HealthCheck ¶
func HealthCheck(client *mgo.Client, okMemberStates []mongo.MemberState) (State, *mongo.MemberState, error)
HealthCheck checks the replication member state of the local MongoDB member
func ReadinessCheck ¶
ReadinessCheck runs a ping on a pmgo.SessionManager to check server readiness
 Click to show internal directories. 
   Click to hide internal directories.