()
| 30 | } |
| 31 | |
| 32 | func (a *StatsAPI) now() time.Time { |
| 33 | if a.TimeNowFn != nil { |
| 34 | return a.TimeNowFn() |
| 35 | } |
| 36 | return dbtime.Now() |
| 37 | } |
| 38 | |
| 39 | func (a *StatsAPI) UpdateStats(ctx context.Context, req *agentproto.UpdateStatsRequest) (*agentproto.UpdateStatsResponse, error) { |
| 40 | res := &agentproto.UpdateStatsResponse{ |