Versions in this module Expand all Collapse all v1 v1.0.15 Aug 17, 2023 v1.0.14 Aug 17, 2023 v1.0.13 Aug 17, 2023 v1.0.12 Aug 17, 2023 v1.0.11 Aug 17, 2023 v1.0.10 Aug 17, 2023 v1.0.9 Aug 14, 2023 v1.0.8 Aug 14, 2023 v1.0.7 Aug 14, 2023 v1.0.6 Aug 14, 2023 v1.0.5 Aug 1, 2023 v1.0.4 Aug 1, 2023 v1.0.3 Aug 1, 2023 v1.0.2 Aug 1, 2023 Changes in this version + const AdvanceLocalTaskStoreStrategy + const AttributeGetPieceCount + const AttributeGetPieceLimit + const AttributeGetPieceRetry + const AttributeGetPieceStartNum + const AttributeMainPeer + const AttributePeerHost + const AttributePeerID + const AttributePeerPacketCode + const AttributePeerTaskCode + const AttributePeerTaskCost + const AttributePeerTaskMessage + const AttributePeerTaskSize + const AttributePeerTaskSizeScope + const AttributePeerTaskSuccess + const AttributePiece + const AttributePieceSize + const AttributePieceSuccess + const AttributePieceWorker + const AttributeReusePeerID + const AttributeReuseRange + const AttributeSeedTaskSuccess + const AttributeTargetPeerAddr + const AttributeTargetPeerID + const AttributeTaskContentLength + const AttributeTaskID + const AttributeWritePieceSuccess + const BackSourceReasonDownloadError + const BackSourceReasonHostSysError + const BackSourceReasonInitError + const BackSourceReasonMd5NotMatch + const BackSourceReasonNoSpace + const BackSourceReasonNodeEmpty + const BackSourceReasonNone + const BackSourceReasonRegisterFail + const BackSourceReasonSourceError + const BackSourceReasonUserSpecified + const BackSourceReasonWriteError + const CmdDelete + const CmdExport + const CmdImport + const CmdStat + const DefaultDaemonAliveTime + const DefaultDownloadTimeout + const DefaultEndPort + const DefaultGCInterval + const DefaultHealthyStartPort + const DefaultMinRate + const DefaultObjectMaxReplicas + const DefaultObjectStorageStartPort + const DefaultPeerStartPort + const DefaultPerPeerDownloadLimit + const DefaultPieceChanSize + const DefaultPieceDispatcherRandomRatio + const DefaultPieceQueueExponent + const DefaultProbeInterval + const DefaultScheduleTimeout + const DefaultSchedulerIP + const DefaultSchedulerPort + const DefaultSchedulerSchema + const DefaultTaskExpireTime + const DefaultTimestampFormat + const DefaultTotalDownloadLimit + const DefaultUploadLimit + const DefaultUploadStartPort + const ForceNotBackSourceAddition + const HeaderDragonflyApplication + const HeaderDragonflyFilter + const HeaderDragonflyObjectMetaDigest + const HeaderDragonflyObjectMetaLastModifiedTime + const HeaderDragonflyObjectMetaStorageClass + const HeaderDragonflyObjectOperation + const HeaderDragonflyPeer + const HeaderDragonflyPriority + const HeaderDragonflyRange + const HeaderDragonflyRegistry + const HeaderDragonflyTag + const HeaderDragonflyTask + const LocalSourceType + const ManagerSourceType + const SchemaHTTP + const SimpleLocalTaskStoreStrategy + const SpanBackSource + const SpanDownload + const SpanDownloadPiece + const SpanFileTask + const SpanFirstSchedule + const SpanGetPieceTasks + const SpanPeerGC + const SpanPeerTask + const SpanProxy + const SpanRecursiveDownload + const SpanRegisterTask + const SpanReportPeerResult + const SpanReportPieceResult + const SpanReusePeerTask + const SpanSeedTask + const SpanStreamTask + const SpanSyncPieceTasks + const SpanTransport + const SpanWaitPieceLimit + const SpanWriteBackPiece + const SpanWritePiece + var DefaultAnnouncerSchedulerInterval = 30 * time.Second + var DefaultCertDNSNames = []string + var DefaultCertIPAddresses = []net.IP + var DefaultCertValidityPeriod = 180 * 24 * time.Hour + var DefaultSupernodesValue = &SupernodesValue + var ErrUnimplemented = errors.New("operation is not implemented") + func ConvertCacheDelete(cfg *CacheOption, args []string) error + func ConvertCacheExport(cfg *CacheOption, args []string) error + func ConvertCacheStat(cfg *CacheOption, args []string) error + func GetCertificate(certifyClient *certify.Certify) func(hello *tls.ClientHelloInfo) (*tls.Certificate, error) + func MkdirAll(dir string, perm os.FileMode, uid, gid int) error + func ValidateCacheDelete(cfg *CacheOption) error + func ValidateCacheExport(cfg *CacheOption) error + type AnnouncerOption struct + SchedulerInterval time.Duration + type BasicAuth struct + Password string + Username string + type CacheOption struct + Cid string + LocalOnly bool + LogDir string + Output string + Path string + RateLimit rate.Limit + Tag string + Timeout time.Duration + WorkHome string + func NewDfcacheConfig() *CacheOption + func (cfg *CacheOption) Convert(cmd string, args []string) error + func (cfg *CacheOption) String() string + func (cfg *CacheOption) Validate(cmd string) error + type CertPool struct + Files []string + func (cp *CertPool) MarshalJSON() ([]byte, error) + func (cp *CertPool) MarshalYAML() (any, error) + func (cp *CertPool) UnmarshalJSON(b []byte) error + func (cp *CertPool) UnmarshalYAML(unmarshal func(any) error) error + type CertSpec struct + DNSNames []string + IPAddresses []net.IP + ValidityPeriod time.Duration + type ClientOption struct + Application string + BenchmarkRate unit.Bytes + Cacerts []string + DaemonSock string + Digest string + DigestMethod string + DigestValue string + DisableBackSource bool + Filter string + Header []string + Insecure bool + KeepOriginalOffset bool + LogDir string + Md5 string + MoreDaemonOptions string + Output string + Priority int32 + Range string + RateLimit util.RateLimit + Recursive bool + RecursiveAcceptRegex string + RecursiveLevel uint + RecursiveList bool + RecursiveRejectRegex string + ShowProgress bool + Tag string + Timeout time.Duration + URL string + WorkHome string + func NewDfgetConfig() *ClientOption + func (cfg *ClientOption) Convert(args []string) error + func (cfg *ClientOption) String() string + func (cfg *ClientOption) Validate() error + type ConcurrentOption struct + GoroutineCount int + InitBackoff float64 + MaxAttempts int + MaxBackoff float64 + ThresholdSize util.Size + ThresholdSpeed unit.Bytes + type DaemonConfig = DaemonOption + type DaemonOption struct + AliveTime util.Duration + Announcer AnnouncerOption + CacheDir string + CacheDirMode uint32 + DataDir string + DataDirMode uint32 + Download DownloadOption + GCInterval util.Duration + Health *HealthOption + Host HostOption + KeepStorage bool + LogDir string + Metrics string + Network *NetworkOption + NetworkTopology NetworkTopologyOption + ObjectStorage ObjectStorageOption + PluginDir string + Proxy *ProxyOption + Reload ReloadOption + Scheduler SchedulerOption + Security GlobalSecurityOption + Storage StorageOption + Upload UploadOption + WorkHome string + WorkHomeMode uint32 + func NewDaemonConfig() *DaemonOption + func (p *DaemonOption) Convert() error + func (p *DaemonOption) Load(path string) error + func (p *DaemonOption) Validate() error + type DfcacheConfig = CacheOption + type DfgetConfig = ClientOption + type DfstoreConfig struct + Endpoint string + Filter string + MaxReplicas int + Mode int + func NewDfstore() *DfstoreConfig + func (cfg *DfstoreConfig) Validate() error + type DownloadOption struct + CacheRecursiveMetadata time.Duration + CalculateDigest bool + Concurrent *ConcurrentOption + DownloadGRPC ListenOption + GRPCDialTimeout time.Duration + GetPiecesMaxRetry int + PeerGRPC ListenOption + PerPeerRateLimit util.RateLimit + PieceDownloadTimeout time.Duration + Prefetch bool + RecursiveConcurrent RecursiveConcurrent + ResourceClients ResourceClientsOption + SplitRunningTasks bool + SyncPieceViaHTTPS bool + TotalRateLimit util.RateLimit + TrafficShaperType string + Transport *TransportOption + WatchdogTimeout time.Duration + type DurationValue time.Duration + func NewDurationValue(p *time.Duration) *DurationValue + func (d *DurationValue) Set(s string) error + func (d *DurationValue) String() string + func (d *DurationValue) Type() string + type Dynconfig interface + Deregister func(Observer) + Get func() (*DynconfigData, error) + GetObjectStorage func() (*managerv1.ObjectStorage, error) + GetResolveSchedulerAddrs func() ([]resolver.Address, error) + GetSchedulers func() ([]*managerv1.Scheduler, error) + Notify func() error + OnNotify func(*DaemonOption) + Refresh func() error + Register func(Observer) + Serve func() error + Stop func() error + func NewDynconfig(sourceType SourceType, cfg *DaemonOption, options ...DynconfigOption) (Dynconfig, error) + type DynconfigData struct + ObjectStorage *managerv1.ObjectStorage + Schedulers []*managerv1.Scheduler + type DynconfigOption func(d *dynconfig) error + func WithCacheDir(dir string) DynconfigOption + func WithManagerClient(c managerclient.V1) DynconfigOption + func WithTransportCredentials(creds credentials.TransportCredentials) DynconfigOption + type GlobalSecurityOption struct + AutoIssueCert bool + CACert types.PEMContent + CertSpec *CertSpec + TLSPolicy string + TLSVerify bool + type HealthOption struct + Path string + type HijackConfig struct + Cert string + Hosts []*HijackHost + Key string + SNI []*TCPListenOption + type HijackHost struct + Certs *CertPool + Insecure bool + Regx *Regexp + type HostOption struct + AdvertiseIP net.IP + Hostname string + IDC string + Location string + type KeepAliveOption struct + Interval time.Duration + type ListenOption struct + Security SecurityOption + TCPListen *TCPListenOption + UnixListen *UnixListenOption + type ManagerOption struct + Enable bool + NetAddrs []dfnet.NetAddr + RefreshInterval time.Duration + SeedPeer SeedPeerOption + type NetAddrsValue struct + func NewNetAddrsValue(n *[]dfnet.NetAddr) *NetAddrsValue + func (nv *NetAddrsValue) Set(value string) error + func (nv *NetAddrsValue) String() string + func (nv *NetAddrsValue) Type() string + type NetworkOption struct + EnableIPv6 bool + type NetworkTopologyOption struct + Enable bool + Probe ProbeOption + type ObjectStorageOption struct + Enable bool + Filter string + MaxReplicas int + type Observer interface + OnNotify func(*DynconfigData) + type ProbeOption struct + Interval time.Duration + type ProxyOption struct + BasicAuth *BasicAuth + DefaultApplication string + DefaultFilter string + DefaultPriority commonv1.Priority + DefaultTag string + DumpHTTPContent bool + ExtraRegistryMirrors []*RegistryMirror + HijackHTTPS *HijackConfig + MaxConcurrency int64 + ProxyRules []*ProxyRule + RegistryMirror *RegistryMirror + WhiteList []*WhiteList + func (p *ProxyOption) UnmarshalJSON(b []byte) error + func (p *ProxyOption) UnmarshalYAML(node *yaml.Node) error + type ProxyRule struct + Direct bool + Redirect string + Regx *Regexp + UseHTTPS bool + func NewProxyRule(regx string, useHTTPS bool, direct bool, redirect string) (*ProxyRule, error) + func (r *ProxyRule) Match(url string) bool + type RateLimitValue struct + func NewLimitRateValue(rate *util.RateLimit) *RateLimitValue + func (r *RateLimitValue) Set(s string) error + func (r *RateLimitValue) String() string + func (r *RateLimitValue) Type() string + type RecursiveConcurrent struct + GoroutineCount int + type Regexp struct + func NewRegexp(exp string) (*Regexp, error) + func (r *Regexp) MarshalJSON() ([]byte, error) + func (r *Regexp) MarshalYAML() (any, error) + func (r *Regexp) UnmarshalJSON(b []byte) error + func (r *Regexp) UnmarshalYAML(unmarshal func(any) error) error + type RegistryMirror struct + Certs *CertPool + Direct bool + DynamicRemote bool + Insecure bool + Remote *URL + UseProxies bool + func (r *RegistryMirror) TLSConfig() *tls.Config + type ReloadOption struct + Interval util.Duration + type ResourceClientsOption map[string]interface + type SchedulerOption struct + DisableAutoBackSource bool + Manager ManagerOption + NetAddrs []dfnet.NetAddr + ScheduleTimeout util.Duration + type SecurityOption struct + CACert types.PEMContent + Cert types.PEMContent + Insecure bool + Key types.PEMContent + TLSConfig *tls.Config + TLSVerify bool + type SeedPeerOption struct + ClusterID uint + Enable bool + KeepAlive KeepAliveOption + Type string + type SourceType string + type StorageOption struct + DataPath string + DiskGCThreshold unit.Bytes + DiskGCThresholdPercent float64 + Multiplex bool + StoreStrategy StoreStrategy + TaskExpireTime util.Duration + type StoreStrategy string + type SupernodesValue struct + Nodes []string + func (sv *SupernodesValue) Set(value string) error + func (sv *SupernodesValue) String() string + func (sv *SupernodesValue) Type() string + type TCPListenOption struct + Listen string + Namespace string + PortRange TCPListenPortRange + type TCPListenPortRange struct + End int + Start int + func (t *TCPListenPortRange) UnmarshalJSON(b []byte) error + func (t *TCPListenPortRange) UnmarshalYAML(node *yaml.Node) error + type TLSConfig struct + func (t *TLSConfig) UnmarshalJSON(b []byte) error + func (t *TLSConfig) UnmarshalYAML(node *yaml.Node) error + type TelemetryOption struct + Jaeger string + type TransportOption struct + DialTimeout time.Duration + ExpectContinueTimeout time.Duration + IdleConnTimeout time.Duration + KeepAlive time.Duration + MaxIdleConns int + ResponseHeaderTimeout time.Duration + TLSHandshakeTimeout time.Duration + type URL struct + func (u *URL) MarshalJSON() ([]byte, error) + func (u *URL) MarshalYAML() (any, error) + func (u *URL) UnmarshalJSON(b []byte) error + func (u *URL) UnmarshalYAML(unmarshal func(any) error) error + type UnixListenOption struct + Socket string + type UploadOption struct + RateLimit util.RateLimit + type WhiteList struct + Host string + Ports []string + Regx *Regexp