Documentation
¶
Index ¶
- type Client
- func (c *Client) AddACL(ctx context.Context, username, path string, readOnly bool, ...) error
- func (c *Client) CreateDir(ctx context.Context, username, path string) error
- func (c *Client) GetFileInfoByInode(ctx context.Context, username string, inode uint64) (*FileInfo, error)
- func (c *Client) GetFileInfoByPath(ctx context.Context, username, path string) (*FileInfo, error)
- func (c *Client) GetQuota(ctx context.Context, username, path string) (int, int, error)
- func (c *Client) List(ctx context.Context, username, path string) ([]*FileInfo, error)
- func (c *Client) ListDeletedEntries(ctx context.Context, username string) ([]*DeletedEntry, error)
- func (c *Client) ListVersions(ctx context.Context, username, p string) ([]*FileInfo, error)
- func (c *Client) PurgeDeletedEntries(ctx context.Context, username string) error
- func (c *Client) Read(ctx context.Context, username, path string) (io.ReadCloser, error)
- func (c *Client) ReadVersion(ctx context.Context, username, p, version string) (io.ReadCloser, error)
- func (c *Client) Remove(ctx context.Context, username, path string) error
- func (c *Client) RemoveACL(ctx context.Context, username, path string, recipient *api.ShareRecipient, ...) error
- func (c *Client) Rename(ctx context.Context, username, oldPath, newPath string) error
- func (c *Client) RestoreDeletedEntry(ctx context.Context, username, key string) error
- func (c *Client) RollbackToVersion(ctx context.Context, username, path, version string) error
- func (c *Client) UpdateACL(ctx context.Context, username, path string, readOnly bool, ...) error
- func (c *Client) Write(ctx context.Context, username, path string, stream io.ReadCloser) error
- type DeletedEntry
- type FileInfo
- type Options
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client performs actions against a EOS management node (MGM). It requires the eos-client and xrootd-client packages installed to work.
func (*Client) AddACL ¶
func (c *Client) AddACL(ctx context.Context, username, path string, readOnly bool, recipient *api.ShareRecipient, shareList []*api.FolderShare) error
func (*Client) GetFileInfoByInode ¶
func (c *Client) GetFileInfoByInode(ctx context.Context, username string, inode uint64) (*FileInfo, error)
GetFileInfoByInode returns the FileInfo by the given inode
func (*Client) GetFileInfoByPath ¶
GetFileInfoByPath returns the FilInfo at the given path
func (*Client) GetQuota ¶ added in v0.0.2
GetQuota gets the quota of a user on the quota node defined by path
func (*Client) ListDeletedEntries ¶
ListDeletedEntries returns a list of the deleted entries.
func (*Client) ListVersions ¶
ListVersions list all the versions for a given file.
func (*Client) PurgeDeletedEntries ¶
PurgeDeletedEntries purges all entries from the recycle bin.
func (*Client) ReadVersion ¶
func (c *Client) ReadVersion(ctx context.Context, username, p, version string) (io.ReadCloser, error)
ReadVersion reads the version for the given file.
func (*Client) RemoveACL ¶
func (c *Client) RemoveACL(ctx context.Context, username, path string, recipient *api.ShareRecipient, shareList []*api.FolderShare) error
func (*Client) RestoreDeletedEntry ¶
RestoreDeletedEntry restores a deleted entry.
func (*Client) RollbackToVersion ¶
RollbackToVersion rollbacks a file to a previous version.
type DeletedEntry ¶
type Options ¶
type Options struct {
// Location of the eos binary.
// Default is /usr/bin/eos.
EosBinary string
// Location of the xrdcopy binary.
// Default is /usr/bin/xrdcopy.
XrdcopyBinary string
// URL of the EOS MGM.
// Default is root://eos-test.org
URL string
// Location on the local fs where to store reads.
// Defaults to os.TempDir()
CacheDirectory string
// Enables logging of the commands executed
// Defaults to false
EnableLogging bool
// Logger to use
Logger *zap.Logger
}