Documentation ¶
Index ¶
- type Scanner
- func (s *Scanner) AddNodeToDB(ctx context.Context, detectInfo *inspec.OSInfo, job *types.InspecBaseJob, ...) (string, error)
- func (s *Scanner) CheckForHungJobs(ctx context.Context) ([]string, error)
- func (s *Scanner) CreateChildJob(job *jobs.Job) (*jobs.Job, error)
- func (s *Scanner) GetDueJobs(nowTime time.Time) []*jobs.Job
- func (s *Scanner) GetNodeUUID(ctx context.Context, sourceID string, region string, acctID string) (string, error)
- func (s *Scanner) IsJobDeleted(jobID string) (bool, error)
- func (s *Scanner) UpdateJobNodeCount(jobID string, nodeCount int)
- func (s *Scanner) UpdateJobStatus(job_id string, newStatus string, startTime *time.Time, endTime *time.Time)
- func (s *Scanner) UpdateNode(ctx context.Context, job *types.InspecJob, detectInfo *inspec.OSInfo)
- func (s *Scanner) UpdateParentJobSchedule(jobId string, jobCount int32, recurrence string, ...)
- func (s *Scanner) UpdateResult(ctx context.Context, job *types.InspecJob, output []byte, ...)
- type SourceInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Scanner ¶
func New ¶
func New(managerClient manager.NodeManagerServiceClient, nodesClient nodes.NodesServiceClient, db *pgdb.DB) *Scanner
func (*Scanner) AddNodeToDB ¶
func (*Scanner) CheckForHungJobs ¶
func (*Scanner) GetNodeUUID ¶
func (*Scanner) UpdateJobNodeCount ¶
func (*Scanner) UpdateJobStatus ¶
func (*Scanner) UpdateNode ¶
func (*Scanner) UpdateParentJobSchedule ¶
func (s *Scanner) UpdateParentJobSchedule(jobId string, jobCount int32, recurrence string, lastScheduledTime *timestamp.Timestamp)
UpdateParentJobSchedule updates recurrent(parent) jobs fields: status: "new" -> "scheduled" -> "completed" if no more runs are required based on the recurrent fields and job count job_count: how many child jobs have been created for this recurrent job scheduled_time: when is the next run due
type SourceInfo ¶
Click to show internal directories.
Click to hide internal directories.