faasinfra

package
v0.0.13 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2023 License: MIT Imports: 28 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PathInvokeFunction            = "/cloudfunction/v1/namespaces/:namespace/function/invokeSync"
	PathInvokeFunctionAsync       = "/faasAsyncTask/v1/namespaces/:namespace/asyncTask/CreateAsyncTask"
	PathInvokeFunctionDistributed = "/distributedTask/v1/namespaces/:namespace/create"
	PathFaaSInfraPathMongodb      = "/resource/v3/namespaces/:namespace/db"
	PathFaaSInfraPathRedis        = "/resource/v2/namespaces/:namespace/cache"
	FaaSInfraPathFile             = "/resource/v2/namespaces/:namespace/file"
)

Variables

This section is empty.

Functions

func BatchCreate added in v0.0.10

func BatchCreate(ctx context.Context, param interface{}) ([]primitive.ObjectID, error)

func Count added in v0.0.10

func Count(ctx context.Context, param interface{}) (int64, error)

func Create added in v0.0.10

func Create(ctx context.Context, param interface{}) (*structs.RecordOnlyId, error)

func Delete added in v0.0.10

func Delete(ctx context.Context, param interface{}) error

func Distinct added in v0.0.10

func Distinct(ctx context.Context, param interface{}, results interface{}) error

func DoRequestFile added in v0.0.10

func DoRequestFile(ctx context.Context, contentType string, body *bytes.Buffer) ([]byte, error)

func DoRequestRedis added in v0.0.10

func DoRequestRedis(ctx context.Context, param interface{}) ([]byte, map[string]interface{}, error)

func Find added in v0.0.10

func Find(ctx context.Context, param, results interface{}) error

func FindOne added in v0.0.10

func FindOne(ctx context.Context, param, result interface{}) error

func GetFaaSInfraPathFile added in v0.0.10

func GetFaaSInfraPathFile() string

func GetFaaSInfraPathMongodb added in v0.0.10

func GetFaaSInfraPathMongodb() string

func GetFaaSInfraPathRedis added in v0.0.10

func GetFaaSInfraPathRedis() string

func GetInstance

func GetInstance() request.IRequestFaaSInfra

func GetPathInvokeFunction

func GetPathInvokeFunction(namespace string) string

func GetPathInvokeFunctionAsync

func GetPathInvokeFunctionAsync(namespace string) string

func GetPathInvokeFunctionDistributed

func GetPathInvokeFunctionDistributed(namespace string) string

func ReadFromURL added in v0.0.10

func ReadFromURL(ctx context.Context, targetURL string) ([]byte, error)

func Update added in v0.0.10

func Update(ctx context.Context, param interface{}) error

func UploadWithContent added in v0.0.10

func UploadWithContent(ctx context.Context, name string, content []byte, option *structs.Option) (*structs.UploadResult, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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