MCPcopy
hub / github.com/fluid-cloudnative/fluid / BuildRuntimeInfo

Function BuildRuntimeInfo

pkg/ddc/base/runtime.go:186–202  ·  view source on GitHub ↗
(name string,
	namespace string,
	runtimeType string,
	opts ...RuntimeInfoOption)

Source from the content-addressed store, hash-verified

184}
185
186func BuildRuntimeInfo(name string,
187 namespace string,
188 runtimeType string,
189 opts ...RuntimeInfoOption) (runtime RuntimeInfoInterface, err error) {
190
191 runtime = &RuntimeInfo{
192 name: name,
193 namespace: namespace,
194 runtimeType: runtimeType,
195 }
196 for _, fn := range opts {
197 if err := fn(runtime.(*RuntimeInfo)); err != nil {
198 return nil, errors.Wrapf(err, "fail to build runtime info \"%s/%s\"", namespace, name)
199 }
200 }
201 return
202}
203
204type RuntimeInfoOption func(info *RuntimeInfo) error
205

Callers 15

TestCleanUpFuseFunction · 0.92
replicas_test.goFile · 0.92
TestSetupWorkersFunction · 0.92
TestBuildWorkersAffinityFunction · 0.92
TestCheckWorkerAffinityFunction · 0.92
node_test.goFile · 0.92
create_test.goFile · 0.92
delete_test.goFile · 0.92
deprecated_test.goFile · 0.92
TestGetLevelStorageMapFunction · 0.92
TestGetTieredLevelFunction · 0.92

Calls

no outgoing calls

Tested by 15

TestCleanUpFuseFunction · 0.74
TestSetupWorkersFunction · 0.74
TestBuildWorkersAffinityFunction · 0.74
TestCheckWorkerAffinityFunction · 0.74
TestGetLevelStorageMapFunction · 0.74
TestGetTieredLevelFunction · 0.74
TestCheckRuntimeHealthyFunction · 0.74
newJindoFSxEngineRTFunction · 0.74
getTestJindoFSxEngineFunction · 0.74
newTestJindoFSxEngineFunction · 0.74