Documentation ¶
Index ¶
- func Creat(path string, perm uint32) (int, error)
- func FileMode(m uint32) uint32
- type Content
- type DeltaBundle
- type File
- type FileChunk
- type Image
- type ImageLayer
- type ReferencedFile
- func (r *ReferencedFile) AppendChild(children fs.ReceivedFile)
- func (r *ReferencedFile) GetAttr(out *fuse.Attr) syscall.Errno
- func (r *ReferencedFile) GetBaseDir() string
- func (r *ReferencedFile) GetChildren() []fs.ReceivedFile
- func (r *ReferencedFile) GetLinkName() string
- func (r *ReferencedFile) GetName() string
- func (r *ReferencedFile) GetRealPath() string
- func (r *ReferencedFile) GetStableAttr() *fuseFs.StableAttr
- func (r *ReferencedFile) GetXAttrs() map[string][]byte
- func (r *ReferencedFile) InPayload() bool
- func (r *ReferencedFile) InitFuseStableAttr()
- func (r *ReferencedFile) IsReady() bool
- func (r *ReferencedFile) IsReferencingLocalFilesystem() (serial int64, yes bool)
- func (r *ReferencedFile) IsReferencingRequestedImage() (stack int64, yes bool)
- func (r *ReferencedFile) SetBlockSize(out *fuse.Attr)
- func (r *ReferencedFile) WaitForReady()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Content ¶
type Content struct { Signal chan interface{} `json:"-"` // ------------------------------------------ // stack identify which layer should this content be placed, all the files will be referencing the content Stack int64 `json:"t"` // offset is non-zero if the file is in the delta bundle body Offset int64 `json:"o,omitempty"` // size is the size of the compressed content Size int64 `json:"s"` Chunks []*FileChunk `json:"c"` Digest string `json:"d"` }
func (*Content) GetBaseDir ¶
type DeltaBundle ¶
type DeltaBundle struct { Source *Image `json:"s"` Destination *Image `json:"d"` // contents and BodyLength are computed by Builder.computeDelta() Contents []*Content `json:"c"` BodyLength int64 `json:"bl"` // RequestedFiles are all the files in the requested images // Use this to reconstruct the file system RequestedFiles []*ReferencedFile `json:"rf"` }
type Image ¶
type Image struct { Serial int64 `json:"s"` Layers []*ImageLayer `json:"l"` }
type ImageLayer ¶
type ImageLayer struct { Size int64 `json:"s"` Serial int64 `json:"f"` // Hash is the digest of the compressed layer Hash string `json:"h"` // path to the local storage Local string }
func (ImageLayer) String ¶
func (il ImageLayer) String() string
type ReferencedFile ¶
type ReferencedFile struct { File // Stack in the existing image from bottom to top, 0-indexed Stack int64 `json:"S"` // if the file is available on the client then ReferenceFsId is non-zero, // expecting the file is available on the client and can be accessed using the File.Digest . // (This is the Serial index in the database `filesystem.id`) ReferenceFsId int64 `json:"R,omitempty"` // if the file is not available on the client but on other layers in the requested image, // then ReferenceFsId is zero and ReferenceStack is non-zero, // expecting the file content in the delta bundle body // (This is Stack not Serial, 0-indexed) ReferenceStack int64 `json:"T,omitempty"` // PayloadOrder is set if the file is not available on the client, then PayloadOrder is non-zero. // It indicates the order of the file in the delta bundle body (payload) PayloadOrder int `json:"O,omitempty"` // if Ready is nil or closed, means the file is ready Ready *chan interface{} `json:"-"` // contains filtered or unexported fields }
func (*ReferencedFile) AppendChild ¶
func (r *ReferencedFile) AppendChild(children fs.ReceivedFile)
func (*ReferencedFile) GetBaseDir ¶
func (r *ReferencedFile) GetBaseDir() string
func (*ReferencedFile) GetChildren ¶
func (r *ReferencedFile) GetChildren() []fs.ReceivedFile
func (*ReferencedFile) GetLinkName ¶
func (r *ReferencedFile) GetLinkName() string
func (*ReferencedFile) GetName ¶
func (r *ReferencedFile) GetName() string
func (*ReferencedFile) GetRealPath ¶
func (r *ReferencedFile) GetRealPath() string
func (*ReferencedFile) GetStableAttr ¶
func (r *ReferencedFile) GetStableAttr() *fuseFs.StableAttr
func (*ReferencedFile) GetXAttrs ¶
func (r *ReferencedFile) GetXAttrs() map[string][]byte
func (*ReferencedFile) InPayload ¶
func (r *ReferencedFile) InPayload() bool
InPayload returns true if the content of the file is in the delta bundle (payload)
func (*ReferencedFile) InitFuseStableAttr ¶
func (r *ReferencedFile) InitFuseStableAttr()
func (*ReferencedFile) IsReady ¶
func (r *ReferencedFile) IsReady() bool
func (*ReferencedFile) IsReferencingLocalFilesystem ¶ added in v0.2.1
func (r *ReferencedFile) IsReferencingLocalFilesystem() (serial int64, yes bool)
func (*ReferencedFile) IsReferencingRequestedImage ¶ added in v0.2.1
func (r *ReferencedFile) IsReferencingRequestedImage() (stack int64, yes bool)
func (*ReferencedFile) SetBlockSize ¶
func (r *ReferencedFile) SetBlockSize(out *fuse.Attr)
func (*ReferencedFile) WaitForReady ¶
func (r *ReferencedFile) WaitForReady()
Click to show internal directories.
Click to hide internal directories.