Documentation
¶
Index ¶
- Constants
- Variables
- type Config
- type DebugChunkInfo
- type DebugImage
- type DebugReq
- type DebugResp
- type DebugSizeStats
- type DebugSlabInfo
- type GcReq
- type GcResp
- type InitReq
- type MaterializeReq
- type MountReq
- type PrefetchReq
- type RepairReq
- type Server
- func (s *Server) AllocateBatch(ctx context.Context, blocks []uint16, digests []cdig.CDig) ([]erofs.SlabLoc, error)
- func (s *Server) SlabInfo(slabId uint16) (tag string, totalBlocks uint32)
- func (s *Server) Start() error
- func (s *Server) Stop(closeDevnode bool)
- func (s *Server) VerifyParams(blockShift shift.Shift) error
- type Sph
- type SphPrefix
- type Stats
- type Status
- type TarballReq
- type TarballResp
- type UmountReq
- type VaporizeReq
Constants ¶
View Source
const ( // only public so they can be referenced by tests InitOpSize = 8 MaxOpSize = 128 // must be ≤ manifester.ChunkDiffMaxDigests MaxOpBytes = 12 << 20 // must be ≤ manifester.ChunkDiffMaxBytes MaxDiffOps = 8 MaxSources = 3 // start doubling on any file RRs, but require two extra image RRs ImageRROffset = 2 )
View Source
const ( /* * Fscache ensures that the maximum length of cookie key is 255. The volume key * is controlled by netfs, and generally no bigger than 255. */ CACHEFILES_MSG_MAX_SIZE = 1024 CACHEFILES_OP_OPEN = 0 CACHEFILES_OP_CLOSE = 1 CACHEFILES_OP_READ = 2 CACHEFILES_IOC_READ_COMPLETE = _IOC_WRITE<<_IOC_DIRSHIFT | 0x98<<_IOC_TYPESHIFT | 1<<_IOC_NRSHIFT | 4<<_IOC_SIZESHIFT )
Variables ¶
View Source
var ( // protocol is json over http over unix socket // socket is path.Join(CachePath, Socket) // accessible to root only! Socket = "styx.sock" InitPath = "/init" MountPath = "/mount" UmountPath = "/umount" MaterializePath = "/materialize" VaporizePath = "/vaporize" PrefetchPath = "/prefetch" TarballPath = "/tarball" GcPath = "/gc" DebugPath = "/debug" RepairPath = "/repair" )
Functions ¶
This section is empty.
Types ¶
type DebugChunkInfo ¶
type DebugImage ¶
type DebugReq ¶
type DebugReq struct {
IncludeAllImages bool `json:",omitempty"`
IncludeImages []string `json:",omitempty"` // list of base32 sph
IncludeManifests bool `json:",omitempty"`
IncludeSlabs bool `json:",omitempty"`
IncludeAllChunks bool `json:",omitempty"`
IncludeChunks []string `json:",omitempty"` // list of base64 digests
IncludeChunkSharing bool `json:",omitempty"`
}
type DebugResp ¶
type DebugResp struct {
Params *pb.DbParams
OnDemand bool
Stats Stats
DbStats bbolt.Stats
Images map[string]DebugImage `json:",omitempty"`
Slabs []*DebugSlabInfo `json:",omitempty"`
Chunks map[string]*DebugChunkInfo `json:",omitempty"`
ChunkSharingDist map[int]int `json:",omitempty"`
}
type DebugSizeStats ¶
type DebugSlabInfo ¶
type DebugSlabInfo struct {
Index uint16
Stats DebugSizeStats
ChunkSizeDist map[uint32]int
}
type GcResp ¶
type GcResp struct {
// always filled in
DeleteImagesByState map[pb.MountState]int
RemainImagesByState map[pb.MountState]int
DeleteImages int
RemainImages int
DeleteManifests int // should match DeleteImages
DeleteChunks int
RemainRefChunks int
RemainHaveChunks int // should match RemainRefChunks
RewriteChunks int
// only filled in on dry-run-slow or real run
PunchLocs int
PunchBytes int64
}
type InitReq ¶
type InitReq struct {
PubKeys []string
Params pb.DaemonParams
}
type MaterializeReq ¶
type PrefetchReq ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func (*Server) AllocateBatch ¶
type Stats ¶
type Stats struct {
ManifestCacheReqs int64 // total manifest cache requests
ManifestCacheHits int64 // requests that got a hit
ManifestReqs int64 // requests for new manifest
ManifestErrs int64 // requests for new manifest that got an error
SlabReads int64 // read requests to slab
SlabReadErrs int64 // failed read requests to slab
SingleReqs int64 // chunk request count
SingleBytes int64 // chunk bytes received (uncompressed)
SingleErrs int64 // chunk request error count
BatchReqs int64 // no-base diff request count
BatchBytes int64 // no-base diff bytes received (compressed)
BatchErrs int64 // no-base diff request error count
DiffReqs int64 // with-base diff request count
DiffBytes int64 // with-base diff bytes received (compressed)
DiffErrs int64 // with-base diff request error count
RecompressReqs int64 // reqs with recompression
ExtraReqs int64 // extra read-ahead reqs (beyond 1 per read)
}
type TarballReq ¶
type TarballResp ¶
type VaporizeReq ¶
Click to show internal directories.
Click to hide internal directories.