http

package
v0.0.8 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2023 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	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

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

func Count

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

func Create

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

func Delete

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

func Distinct

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

func DoRequestFile

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

func DoRequestRedis

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

func Find

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

func FindOne

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

func GetCommonHttpClient

func GetCommonHttpClient() *http.Client

func GetFaaSInfraPathFile

func GetFaaSInfraPathFile() string

func GetFaaSInfraPathMongodb

func GetFaaSInfraPathMongodb() string

func GetFaaSInfraPathRedis

func GetFaaSInfraPathRedis() string

func Update

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

Types

This section is empty.

Jump to

Keyboard shortcuts

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