Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( CommonsRepoAdded = "" RepoName = "" )
View Source
var ( BasicUser = "" BasicPass = "" )
View Source
var ( ServerRestURL = "" ServerGrpcURL = "" FilePath = filepath.Join(api.RitchieHomeDir(), "metrics") )
Functions ¶
This section is empty.
Types ¶
type CheckManager ¶
type CheckManager struct {
// contains filtered or unexported fields
}
func NewChecker ¶
func NewChecker(file stream.FileReadExister) CheckManager
func (CheckManager) Check ¶
func (c CheckManager) Check() bool
type Data ¶
type Data struct { CommandError string `json:"commandError,omitempty"` CommonsRepoAdded string `json:"commonsRepoAdded,omitempty"` CommandExecutionTime float64 `json:"commandExecutionTime"` MetricsAcceptance string `json:"metricsAcceptance,omitempty"` FormulaRepo formula.Repo `json:"repo,omitempty"` Flags []string `json:"flags,omitempty"` }
type DataCollectorManager ¶
type DataCollectorManager struct {
// contains filtered or unexported fields
}
func NewDataCollector ¶
func NewDataCollector( userId UserIdGenerator, ritchieHomeDir string, file stream.FileReader, ) DataCollectorManager
type SendManagerHttp ¶
type SendManagerHttp struct { URL string // contains filtered or unexported fields }
func NewHttpSender ¶
func NewHttpSender(url string, client *http.Client) SendManagerHttp
func (SendManagerHttp) Send ¶
func (sm SendManagerHttp) Send(APIData APIData)
type SendManagerRpc ¶
type SendManagerRpc struct {
// contains filtered or unexported fields
}
func NewRpcSender ¶
func NewRpcSender(processClient pb.ProcessorClient) SendManagerRpc
Example of how to create a grpc client and processor client: ctx, cancel := context.WithTimeout(context.Background(), time.Second) defer cancel() conn, _ := grpc.DialContext(ctx, "localhost:50080", grpc.WithInsecure(), grpc.WithBlock()) if conn != nil { defer conn.Close() } processorClient := pb.NewProcessorClient(conn)
func (SendManagerRpc) Send ¶
func (sm SendManagerRpc) Send(apiData APIData)
type UserIdGenerator ¶
type UserIdManager ¶
type UserIdManager struct {
// contains filtered or unexported fields
}
func NewUserIdGenerator ¶
func NewUserIdGenerator() UserIdManager
func (UserIdManager) Generate ¶
func (us UserIdManager) Generate() (UserId, error)
Click to show internal directories.
Click to hide internal directories.