From: Igor D.C Date: Mon, 31 Aug 2020 23:00:46 +0000 (+0000) Subject: Let instructions exist under /subresource level X-Git-Tag: 0.7.0~29^2 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=76cf5a8195d7d7c042eda9cefde2fdf77875fd0a;p=multicloud%2Fk8s.git Let instructions exist under /subresource level Instructions (order/dependency) can now belong to an app, a resource or a subresource. Issue-ID: MULTICLOUD-1143 Signed-off-by: Igor D.C Change-Id: Iee55c2bbb569de242e66f5a5456ac52025a00f0e --- diff --git a/src/orchestrator/pkg/appcontext/appcontext.go b/src/orchestrator/pkg/appcontext/appcontext.go index 5d757940..d77672db 100644 --- a/src/orchestrator/pkg/appcontext/appcontext.go +++ b/src/orchestrator/pkg/appcontext/appcontext.go @@ -419,7 +419,7 @@ func (ac *AppContext) AddInstruction(handle interface{}, level string, insttype if !(insttype == "order" || insttype == "dependency") { return nil, pkgerrors.Errorf("Not a valid app context instruction type") } - if !(level == "app" || level == "resource") { + if !(level == "app" || level == "resource" || level == "subresource") { return nil, pkgerrors.Errorf("Not a valid app context instruction level") } h, err := ac.rtc.RtcAddInstruction(handle, level, insttype, value)