mongodb

package
v0.0.0-...-592b0ac Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMongo

func NewMongo(mongoUrl string, database string, ctx context.Context) (*mongo.Database, error)

func NewMongoZero

func NewMongoZero()

func Test_Mongo

func Test_Mongo()

Types

type ConnectData

type ConnectData struct {
	Latency  float64  `json:"latency"`
	RespCode int      `json:"respCode"`
	Url      string   `json:"url"`
	Detail   CurlInfo `json:"details"`
}

type CurlInfo

type CurlInfo struct {
	DNS float64 `json:"NAMELOOKUP_TIME"` //NAMELOOKUP_TIME
	TCP float64 `json:"CONNECT_TIME"`    //CONNECT_TIME - DNS
	SSL float64 `json:"APPCONNECT_TIME"` //APPCONNECT_TIME - CONNECT_TIME
}

type Sensor

type Sensor struct {
	ISP       string
	Clientutc int64
	DataByAPP map[string]ConnectData
}

Jump to

Keyboard shortcuts

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