digest

package
v1.4.3 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2020 License: MIT Imports: 17 Imported by: 15

Documentation

Index

Constants

View Source
const (
	EmptySha256 = "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
	EmptyHash   = ""
)

Variables

This section is empty.

Functions

func Compute

func Compute(in io.Reader) (*repb.Digest, error)

func ComputeForMessage

func ComputeForMessage(in proto.Message) (*repb.Digest, error)

func DownloadResourceName

func DownloadResourceName(d *repb.Digest, instanceName string) string

func ExtractDigestFromDownloadResourceName

func ExtractDigestFromDownloadResourceName(resourceName string) (string, *repb.Digest, error)

func ExtractDigestFromUploadResourceName

func ExtractDigestFromUploadResourceName(resourceName string) (string, *repb.Digest, error)

func GetInvocationIDFromMD

func GetInvocationIDFromMD(ctx context.Context) string

func GetRequestMetadata

func GetRequestMetadata(ctx context.Context) *repb.RequestMetadata

This is probably the wrong place for this, but works for now.

func IsCacheDebuggingEnabled

func IsCacheDebuggingEnabled(ctx context.Context) bool

func MissingDigestError

func MissingDigestError(d *repb.Digest) error

func UploadResourceName

func UploadResourceName(d *repb.Digest, instanceName string) (string, error)

func Validate

func Validate(d *repb.Digest) (string, error)

Types

type InstanceNameDigest

type InstanceNameDigest struct {
	*repb.Digest
	// contains filtered or unexported fields
}

func NewInstanceNameDigest

func NewInstanceNameDigest(d *repb.Digest, instanceName string) *InstanceNameDigest

func (*InstanceNameDigest) GetInstanceName

func (i *InstanceNameDigest) GetInstanceName() string

Jump to

Keyboard shortcuts

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