Documentation ¶
Index ¶
- Constants
- func Access(ctx Context, ino Ino, mask int) (err syscall.Errno)
- func Compact(conf chunk.Config, store chunk.ChunkStore, slices []meta.Slice, chunkid uint64) error
- func CopyFileRange(ctx Context, nodeIn Ino, fhIn, offIn uint64, nodeOut Ino, ...) (copied uint64, err syscall.Errno)
- func Create(ctx Context, parent Ino, name string, mode uint16, cumask uint16, flags uint32) (entry *meta.Entry, fh uint64, err syscall.Errno)
- func Fallocate(ctx Context, ino Ino, mode uint8, off, length int64, fh uint64) (err syscall.Errno)
- func Flock(ctx Context, ino Ino, fh uint64, owner uint64, typ uint32, block bool) (err syscall.Errno)
- func Flush(ctx Context, ino Ino, fh uint64, lockOwner uint64) (err syscall.Errno)
- func Fsync(ctx Context, ino Ino, datasync int, fh uint64) (err syscall.Errno)
- func GetAttr(ctx Context, ino Ino, opened uint8) (entry *meta.Entry, err syscall.Errno)
- func GetInternalNodeByName(name string) (Ino, *Attr)
- func GetXattr(ctx Context, ino Ino, name string, size uint32) (value []byte, err syscall.Errno)
- func Getlk(ctx Context, ino Ino, fh uint64, owner uint64, start, len *uint64, typ *uint32, ...) (err syscall.Errno)
- func Init(conf *Config, m_ meta.Meta, store_ chunk.ChunkStore)
- func InitMetrics()
- func IsSpecialName(name string) bool
- func IsSpecialNode(ino Ino) bool
- func Link(ctx Context, ino Ino, newparent Ino, newname string) (entry *meta.Entry, err syscall.Errno)
- func ListXattr(ctx Context, ino Ino, size int) (data []byte, err syscall.Errno)
- func Lookup(ctx Context, parent Ino, name string) (entry *meta.Entry, err syscall.Errno)
- func Mkdir(ctx Context, parent Ino, name string, mode uint16, cumask uint16) (entry *meta.Entry, err syscall.Errno)
- func Mknod(ctx Context, parent Ino, name string, mode uint16, cumask uint16, rdev uint32) (entry *meta.Entry, err syscall.Errno)
- func Open(ctx Context, ino Ino, flags uint32) (entry *meta.Entry, fh uint64, err syscall.Errno)
- func Opendir(ctx Context, ino Ino) (fh uint64, err syscall.Errno)
- func Read(ctx Context, ino Ino, buf []byte, off uint64, fh uint64) (n int, err syscall.Errno)
- func Readdir(ctx Context, ino Ino, size uint32, off int, fh uint64, plus bool) (entries []*meta.Entry, err syscall.Errno)
- func Readlink(ctx Context, ino Ino) (path []byte, err syscall.Errno)
- func Release(ctx Context, ino Ino, fh uint64) (err syscall.Errno)
- func ReleaseHandler(ino Ino, fh uint64)
- func Releasedir(ctx Context, ino Ino, fh uint64) int
- func RemoveXattr(ctx Context, ino Ino, name string) (err syscall.Errno)
- func Rename(ctx Context, parent Ino, name string, newparent Ino, newname string) (err syscall.Errno)
- func Rmdir(ctx Context, parent Ino, name string) (err syscall.Errno)
- func SetAttr(ctx Context, ino Ino, set int, opened uint8, mode, uid, gid uint32, ...) (entry *meta.Entry, err syscall.Errno)
- func SetXattr(ctx Context, ino Ino, name string, value []byte, flags int) (err syscall.Errno)
- func Setlk(ctx Context, ino Ino, fh uint64, owner uint64, start, end uint64, typ uint32, ...) (err syscall.Errno)
- func Symlink(ctx Context, path string, parent Ino, name string) (entry *meta.Entry, err syscall.Errno)
- func Truncate(ctx Context, ino Ino, size int64, opened uint8, attr *Attr) (err syscall.Errno)
- func Unlink(ctx Context, parent Ino, name string) (err syscall.Errno)
- func UpdateLength(inode Ino, attr *meta.Attr)
- func Write(ctx Context, ino Ino, buf []byte, off, fh uint64) (err syscall.Errno)
- type Attr
- type Config
- type Context
- type DataReader
- type DataWriter
- type Entry
- type FileReader
- type FileWriter
- type Ino
- type LogContext
- type Statfs
Constants ¶
View Source
const ( NEW = iota BUSY REFRESH BREAK READY INVALID )
* state of sliceReader * * <-- REFRESH * | | * NEW -> BUSY -> READY * | | * BREAK ---> INVALID
View Source
const ( MODE_MASK_R = 4 MODE_MASK_W = 2 MODE_MASK_X = 1 )
View Source
const F_UNLCK = syscall.F_UNLCK
View Source
const O_ACCMODE = syscall.O_ACCMODE
Variables ¶
This section is empty.
Functions ¶
func CopyFileRange ¶ added in v0.11.0
func GetInternalNodeByName ¶
func InitMetrics ¶
func InitMetrics()
func IsSpecialName ¶
func IsSpecialNode ¶
func ReleaseHandler ¶ added in v0.9.0
func RemoveXattr ¶ added in v0.9.0
func UpdateLength ¶ added in v0.9.1
Types ¶
type Context ¶
type Context = LogContext
type DataReader ¶
type DataReader interface { Open(inode Ino, length uint64) FileReader Truncate(inode Ino, length uint64) Invalidate(inode Ino, off, length uint64) }
func NewDataReader ¶
func NewDataReader(conf *Config, m meta.Meta, store chunk.ChunkStore) DataReader
type DataWriter ¶
type DataWriter interface { Open(inode Ino, fleng uint64) FileWriter Flush(ctx meta.Context, inode Ino) syscall.Errno GetLength(inode Ino) uint64 Truncate(inode Ino, length uint64) }
func NewDataWriter ¶
func NewDataWriter(conf *Config, m meta.Meta, store chunk.ChunkStore) DataWriter
type Entry ¶
Entry is an alias of meta.Entry, which is used to generate the string representation lazily.
type FileReader ¶
type FileWriter ¶
type LogContext ¶
LogContext is an interface to add duration on meta.Context.
func NewLogContext ¶
func NewLogContext(ctx meta.Context) LogContext
NewLogContext creates an LogContext starting from now.
Click to show internal directories.
Click to hide internal directories.