/
githubmirror
/
ydb-kubernetes-operator
Обзор
Документация
Войти
/
githubmirror
/
ydb-kubernetes-operator
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
internal/annotations/annotations.go
26 строк
878 B
kobzonega
YDBOPS-9168 Storage finalizer waiting for existing Databases (#211)
04 июл 2024, 12:02
Не верифицирован
04 июл 2024, 12:02
3b62f2d
Код
Авторство
О чём код?
package annotations const ( PrimaryResourceStorageAnnotation = "ydb.tech/primary-resource-storage" PrimaryResourceDatabaseAnnotation = "ydb.tech/primary-resource-database" RemoteResourceVersionAnnotation = "ydb.tech/remote-resource-version" ConfigurationChecksum = "ydb.tech/configuration-checksum" StorageFinalizerKey = "ydb.tech/storage-finalizer" RemoteFinalizerKey = "ydb.tech/remote-finalizer" LastAppliedAnnotation = "ydb.tech/last-applied" ) func CompareLastAppliedAnnotation(map1, map2 map[string]string) bool { value1 := getLastAppliedAnnotation(map1) value2 := getLastAppliedAnnotation(map2) return value1 == value2 } func getLastAppliedAnnotation(annotations map[string]string) string { for key, value := range annotations { if key == LastAppliedAnnotation { return value } } return "" }