bootUtils

package
v0.1.28 Latest Latest
Warning

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

Go to latest
Published: May 16, 2023 License: Apache-2.0 Imports: 10 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BufferGrpcServerStream

func BufferGrpcServerStream(acceptableMimeTypes []string, maxFileSize int, readBytes func() ([]byte, error)) (bytes.Buffer, string, error)

Output: Returns byte buffer of stream and mime-type of the stream. Input: acceptableMimeTypes, fileSizeLimit and a stream readByte function. To accept any kind of stream pass "application/octet-stream" in acceptableStreams.

func GetEnv

func GetEnv(key, fallback string) string

func GetFileExtension added in v0.1.25

func GetFileExtension(mimeType string) string

func StreamContextError added in v0.1.25

func StreamContextError(ctx context.Context) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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