backend

package
v1.3.22 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 25, 2024 License: MIT Imports: 20 Imported by: 0

Documentation

Overview

Package backend contains implementation of various backend providers.

  • Copyright (c) 2018-2024, NVIDIA CORPORATION. All rights reserved.

Package backend contains implementation of various backend providers.

  • Copyright (c) 2018-2024, NVIDIA CORPORATION. All rights reserved.

Package backend contains implementation of various backend providers.

  • Copyright (c) 2018-2024, NVIDIA CORPORATION. All rights reserved.

Package backend contains implementation of various backend providers.

  • Copyright (c) 2018-2024, NVIDIA CORPORATION. All rights reserved.

Package backend contains implementation of various backend providers.

  • Copyright (c) 2018-2022, NVIDIA CORPORATION. All rights reserved.

Package backend contains implementation of various backend providers.

  • Copyright (c) 2018-2022, NVIDIA CORPORATION. All rights reserved.

Package backend contains implementation of various backend providers.

  • Copyright (c) 2018-2022, NVIDIA CORPORATION. All rights reserved.

Package backend contains implementation of various backend providers.

  • Copyright (c) 2021-2022, NVIDIA CORPORATION. All rights reserved.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AbortMpt added in v1.3.22

func AbortMpt(*core.LOM, string) (int, error)

func CompleteMpt added in v1.3.22

func CompleteMpt(*core.LOM, string, *s3types.CompleteMptUpload) (string, int, error)

func NewAWS

func NewAzure

func NewAzure(_ core.TargetPut) (core.BackendProvider, error)

func NewDummyBackend

func NewDummyBackend(t core.TargetPut) (core.BackendProvider, error)

func NewGCP

func NewHDFS

func NewHDFS(_ core.TargetPut) (core.BackendProvider, error)

func NewHTTP

func NewHTTP(t core.TargetPut, config *cmn.Config) core.BackendProvider

func PutMptPart added in v1.3.22

func PutMptPart(*core.LOM, *os.File, string, int32, int64) (string, int, error)

func StartMpt added in v1.3.22

func StartMpt(*core.LOM) (string, int, error)

Types

type AISBackendProvider

type AISBackendProvider struct {
	// contains filtered or unexported fields
}

func NewAIS

func (*AISBackendProvider) Apply

func (m *AISBackendProvider) Apply(v any, action string, cfg *cmn.ClusterConfig) (err error)

apply new or updated (attach, detach) cmn.BackendConfAIS configuration

func (*AISBackendProvider) CreateBucket

func (*AISBackendProvider) CreateBucket(_ *meta.Bck) (errCode int, err error)

func (*AISBackendProvider) DeleteObj

func (m *AISBackendProvider) DeleteObj(lom *core.LOM) (errCode int, err error)

func (*AISBackendProvider) GetInfo

func (m *AISBackendProvider) GetInfo(clusterConf cmn.BackendConfAIS) (res meta.RemAisVec)

At the same time a cluster may have registered both types of remote AIS clusters(HTTP and HTTPS). So, the method must use both kinds of clients and select the correct one at the moment it sends a request. See also: GetInfoInternal() TODO: ditto

func (*AISBackendProvider) GetInfoInternal

func (m *AISBackendProvider) GetInfoInternal() (res meta.RemAisVec)

return (m.remote + m.alias) in-memory info wo/ connecting to remote cluster(s) (compare with GetInfo() below) TODO: caller to pass its cached version to optimize-out allocations

func (*AISBackendProvider) GetObj

func (m *AISBackendProvider) GetObj(_ ctx, lom *core.LOM, owt cmn.OWT) (errCode int, err error)

func (*AISBackendProvider) GetObjReader

func (m *AISBackendProvider) GetObjReader(_ ctx, lom *core.LOM, offset, length int64) (res core.GetReaderResult)

func (*AISBackendProvider) HeadBucket

func (m *AISBackendProvider) HeadBucket(_ ctx, remoteBck *meta.Bck) (bckProps cos.StrKVs, errCode int, err error)

TODO: remote AIS clusters provide native frontend API with additional capabilities that, in particular, include `dontAddRemote` = (true | false). Here we have to hardcode the value to keep HeadBucket() consistent across all backends. For similar limitations, see also ListBuckets() below.

func (*AISBackendProvider) HeadObj

func (m *AISBackendProvider) HeadObj(_ ctx, lom *core.LOM) (oa *cmn.ObjAttrs, errCode int, err error)

TODO: remote AIS clusters provide native frontend API with additional capabilities in part including apc.Flt* location specifier. Here, and elsewhere down below, we hardcode (the default) `apc.FltPresent` to, eesentially, keep HeadObj() consistent across backends.

func (*AISBackendProvider) ListBuckets

func (m *AISBackendProvider) ListBuckets(qbck cmn.QueryBcks) (bcks cmn.Bcks, errCode int, err error)

func (*AISBackendProvider) ListObjects

func (m *AISBackendProvider) ListObjects(remoteBck *meta.Bck, msg *apc.LsoMsg, lst *cmn.LsoResult) (errCode int, err error)

func (*AISBackendProvider) Provider

func (*AISBackendProvider) Provider() string

func (*AISBackendProvider) PutObj

func (m *AISBackendProvider) PutObj(r io.ReadCloser, lom *core.LOM, _ *core.ExtraArgsPut) (errCode int, err error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL