From 85f55315061f9b861e5a6411961445c0247d22dd Mon Sep 17 00:00:00 2001 From: Dan Rammer Date: Mon, 1 Nov 2021 13:48:50 -0500 Subject: [PATCH] Adding shard, project, and domain labels to crd (#357) * added shard, project, and domain labels to crd Signed-off-by: Daniel Rammer * fixed tests Signed-off-by: Daniel Rammer * removed test debugging log output Signed-off-by: Daniel Rammer * setting project / domain labels based on workflow identifer (in case of dynamic workflow) Signed-off-by: Daniel Rammer * fixed dynamic workflow test composedPBStore write size Signed-off-by: Daniel Rammer * fixing random pr comments Signed-off-by: Daniel Rammer * fixed dynamic workflow test composedPBStore write size ... again Signed-off-by: Daniel Rammer * moved ShardKeyspaceSize definition to v1alpha1 package Signed-off-by: Daniel Rammer --- .../apis/flyteworkflow/v1alpha1/workflow.go | 5 ++ .../app-workflows-work-one-python-task-w-f.pb | Bin 848 -> 992 bytes ...pp-workflows-work-one-python-task-w-f.yaml | 18 +++++++ .../5_myapp.workflows.cereal.mycereal_2.json | 3 ++ .../k8s/mycereal_condition_has_no_deps.json | 3 ++ .../test/testdata/branch/k8s/success_1.json | 3 ++ .../branch/k8s/success_10_simple.json | 3 ++ .../test/testdata/branch/k8s/success_2.json | 3 ++ .../test/testdata/branch/k8s/success_3.json | 3 ++ .../test/testdata/branch/k8s/success_4.json | 3 ++ .../test/testdata/branch/k8s/success_5.json | 3 ++ .../test/testdata/branch/k8s/success_6.json | 3 ++ .../testdata/branch/k8s/success_7_nested.json | 3 ++ .../testdata/branch/k8s/success_8_nested.json | 3 ++ .../testdata/branch/k8s/success_9_nested.json | 3 ++ .../pkg/compiler/transformers/k8s/workflow.go | 49 +++++++++++++----- .../transformers/k8s/workflow_test.go | 23 +++++--- .../nodes/dynamic/dynamic_workflow_test.go | 2 +- 18 files changed, 112 insertions(+), 21 deletions(-) diff --git a/flytepropeller/pkg/apis/flyteworkflow/v1alpha1/workflow.go b/flytepropeller/pkg/apis/flyteworkflow/v1alpha1/workflow.go index 0b4e6f3a31..e2207ac791 100644 --- a/flytepropeller/pkg/apis/flyteworkflow/v1alpha1/workflow.go +++ b/flytepropeller/pkg/apis/flyteworkflow/v1alpha1/workflow.go @@ -15,6 +15,11 @@ import ( metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) +// Defines a non-configurable keyspace size for shard keys. This needs to be a small value because we use label +// selectors to define shard key ranges which do not support range queries. It should only be modified increasingly +// to ensure backward compatibility. +const ShardKeyspaceSize = 32 + const StartNodeID = "start-node" const EndNodeID = "end-node" diff --git a/flytepropeller/pkg/compiler/test/testdata/app-workflows-work-one-python-task-w-f.pb b/flytepropeller/pkg/compiler/test/testdata/app-workflows-work-one-python-task-w-f.pb index 45947eb7def471aed817b4ee1d35dd95157b96f9..27701bb1753e2387593bf9fe3ed1193b4aedebda 100755 GIT binary patch delta 27 jcmcb>_JDoD7N%8f6MHl!-b-Lwz`EIiQGjW(0n-Ekno