[Tarantool-patches] [PATCH v2 4/6] alter: parse data dictionary version

Vladislav Shpilevoy v.shpilevoy at tarantool.org
Fri Aug 6 01:17:30 MSK 2021


Thanks for the patch!

> diff --git a/src/box/schema.cc b/src/box/schema.cc
> index 963278b19..35026619a 100644
> --- a/src/box/schema.cc
> +++ b/src/box/schema.cc
> @@ -70,6 +71,9 @@ uint32_t schema_version = 0;
>   */
>  uint32_t space_cache_version = 0;
>  
> +/** Persistent version of the schema, stored in _schema["version"]. */
> +uint32_t dd_version_id = tarantool_version_id();

I propose to assign it to 0. Because at start there is no
schema at all until box.cfg{} is called first time. (Also then
version.h include could be dropped above.)

> +
>  struct rlist on_schema_init = RLIST_HEAD_INITIALIZER(on_schema_init);
>  struct rlist on_alter_space = RLIST_HEAD_INITIALIZER(on_alter_space);
>  struct rlist on_alter_sequence = RLIST_HEAD_INITIALIZER(on_alter_sequence);


More information about the Tarantool-patches mailing list