0008 dropped IF EXISTS dictionary_records_data_scope_check, но реальный
constraint в 0003 назывался dictionary_records_scope_check (без _data_).
Старый lowercase constraint остался жив — записи с UPPERCASE
data_scope не проходили. 0009 удаляет оба варианта имени и создаёт
UPPERCASE constraint.
JPA persists enum DataScope as @Enumerated(EnumType.STRING) by default,
which writes the enum name verbatim — UPPERCASE. The original CHECK
constraint allowed only lowercase ('public','internal','restricted'),
making every insert violate it.
Drop and recreate constraint with UPPERCASE values to match enum names.
Applies to dictionary_definitions.scope and dictionary_records.data_scope.
DictionaryDefinition and DictionaryRecord entities have @Version (BIGINT)
fields for optimistic locking, but the initial migrations did not create
the column. App fails with 'column dd1_0.version does not exist' on first
query.
Add 0007-add-version-columns.xml with idempotent addColumn changesets
(preConditions guard against re-add).
- 0001-extensions.xml: переставил <preConditions> перед <comment> (XSD требует
preConditions первым в changeSet)
- master.xml: include paths сделаны relative к самому master.xml (changes/...
вместо db/changelog/changes/...) — CWD inside Docker image это /liquibase,
Liquibase searchPath = /liquibase/changelog где master.xml лежит, includes
должны идти от него
CI: insecure-registry: registry.k8s.265.nstart.local (HTTP без auth для
internal cluster), REGISTRY_USER/PASSWORD optional (skip docker login если
не заданы)