gc

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: May 22, 2020 License: Apache-2.0 Imports: 12 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Manager

type Manager struct {
	// contains filtered or unexported fields
}

Manager is an implementation of the interface of DfgetTaskMgr.

func NewManager

func NewManager(cfg *config.Config, taskMgr mgr.TaskMgr, peerMgr mgr.PeerMgr, dfgetTaskMgr mgr.DfgetTaskMgr,
	progressMgr mgr.ProgressMgr, cdnMgr mgr.CDNMgr, register prometheus.Registerer) (*Manager, error)

NewManager returns a new Manager.

func (*Manager) GCPeer

func (gcm *Manager) GCPeer(ctx context.Context, peerID string)

GCPeer is used to do the gc job when a peer offline.

func (*Manager) GCTask

func (gcm *Manager) GCTask(ctx context.Context, taskID string, full bool)

GCTask is used to do the gc job with specified taskID.

func (*Manager) StartGC

func (gcm *Manager) StartGC(ctx context.Context)

StartGC starts to do the gc jobs.

Jump to

Keyboard shortcuts

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