Documentation
¶
Index ¶
- func CalcMemCapacity(reqModelKey string, defaultSize int, multiplier float64, log logr.Logger) uint64
- func ClearDirectoryContents(dirPath string, condition func(entry os.DirEntry) bool) error
- func FileExists(path string) (bool, error)
- func GetModelType(req *mmesh.LoadModelRequest, log logr.Logger) string
- func GetSchemaPath(req *mmesh.LoadModelRequest) (string, error)
- func RemoveFileFromListOfFileInfo(filename string, files []os.DirEntry) (bool, []os.DirEntry)
- func ResolveLocalGrpcEndpoint(servingRuntimeEndpoint string) (string, error)
- func SecureJoin(elem ...string) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CalcMemCapacity ¶ added in v0.9.0
func ClearDirectoryContents ¶ added in v0.10.0
ClearDirectoryContents Clear contents of directory if it exists. If condition is specified then only delete dir entries to which it returns true
func GetModelType ¶ added in v0.8.0
func GetModelType(req *mmesh.LoadModelRequest, log logr.Logger) string
GetModelType first tries to read the type from the LoadModelRequest.ModelKey json If there is an error parsing LoadModelRequest.ModelKey or the type is not found there, this will return the LoadModelRequest.ModelType which could possibly be an empty string
func GetSchemaPath ¶ added in v0.8.0
func GetSchemaPath(req *mmesh.LoadModelRequest) (string, error)
GetSchemaPath extracts the schema path from the ModelKey field Will return an error if schema path exists but is in an invalid format
func RemoveFileFromListOfFileInfo ¶
RemoveFileFromListOfFileInfo The input `files` content is modified, the order of elements is changed
func ResolveLocalGrpcEndpoint ¶ added in v0.10.0
func SecureJoin ¶
Types ¶
This section is empty.