helpers

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2023 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckTagExists

func CheckTagExists(tags []models.ExperimentTag, key, value string) bool

CheckTagExists makes check that Tag exists in provided Tag list.

func GetDatabaseUri

func GetDatabaseUri() string

func GetInputDatabaseUri added in v0.3.0

func GetInputDatabaseUri() string

func GetOutputDatabaseUri added in v0.3.0

func GetOutputDatabaseUri() string

func GetS3EndpointUri added in v0.3.0

func GetS3EndpointUri() string

func GetServiceUri

func GetServiceUri() string

func NewS3Client added in v0.3.0

func NewS3Client(endpoint string) (*s3.Client, error)

NewS3Client creates new instance of S3 client.

func StrReplace

func StrReplace(str string, original []string, replacement []interface{}) string

StrReplace makes replacing of multiple placeholders by theirs values in a string.

func TransformRunsToActivityMap added in v0.3.0

func TransformRunsToActivityMap(runs []*models.Run) map[string]int

TransformRunsToActivityMap transform a slice of runs into a map of experiments activity to match the GetExperimentsActivity endpoint response.

Types

type HttpClient

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

HttpClient represents HTTP client.

func NewAimApiClient

func NewAimApiClient(baseURL string) *HttpClient

NewAimApiClient creates new HTTP client for the aim api

func NewMlflowApiClient

func NewMlflowApiClient(baseURL string) *HttpClient

NewMlflowApiClient creates new HTTP client for the mlflow api

func (HttpClient) DoDeleteRequest

func (c HttpClient) DoDeleteRequest(uri string, response interface{}) error

DoDeleteRequest do DELETE request.

func (HttpClient) DoGetRequest

func (c HttpClient) DoGetRequest(uri string, response interface{}) error

DoGetRequest do GET request.

func (HttpClient) DoPostRequest

func (c HttpClient) DoPostRequest(uri string, request interface{}, response interface{}) error

DoPostRequest do POST request.

func (HttpClient) DoPutRequest added in v0.3.0

func (c HttpClient) DoPutRequest(uri string, request interface{}, response interface{}) error

DoPutRequest do PUT request.

func (HttpClient) DoStreamRequest

func (c HttpClient) DoStreamRequest(method, uri string, request interface{}) ([]byte, error)

DoStreamRequest do stream request.

Jump to

Keyboard shortcuts

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