diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-05-20 17:34:42 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-05-20 17:34:42 +0300 |
commit | 9f46488805e86b1bc341ea1620b866016c2ce5ed (patch) | |
tree | f9748c7e287041e37d6da49e0a29c9511dc34768 /doc/development/namespaces_storage_statistics.md | |
parent | dfc92d081ea0332d69c8aca2f0e745cb48ae5e6d (diff) |
Add latest changes from gitlab-org/gitlab@13-0-stable-ee
Diffstat (limited to 'doc/development/namespaces_storage_statistics.md')
-rw-r--r-- | doc/development/namespaces_storage_statistics.md | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/doc/development/namespaces_storage_statistics.md b/doc/development/namespaces_storage_statistics.md index f175739e55e..3065d4f84a2 100644 --- a/doc/development/namespaces_storage_statistics.md +++ b/doc/development/namespaces_storage_statistics.md @@ -38,7 +38,7 @@ alternative method. ### Attempt A: PostgreSQL materialized view -Model can be updated through a refresh strategy based on a project routes SQL and a [materialized view](https://www.postgresql.org/docs/9.6/rules-materializedviews.html): +Model can be updated through a refresh strategy based on a project routes SQL and a [materialized view](https://www.postgresql.org/docs/11/rules-materializedviews.html): ```sql SELECT split_part("rs".path, '/', 1) as root_path, @@ -111,11 +111,11 @@ Directly relate the root namespace to its child namespaces, so whenever a namespace is created without a parent, this one is tagged with the root namespace ID: -| id | root_id | parent_id -|:---|:--------|:---------- -| 1 | 1 | NULL -| 2 | 1 | 1 -| 3 | 1 | 2 +| ID | root ID | parent ID | +|:---|:--------|:----------| +| 1 | 1 | NULL | +| 2 | 1 | 1 | +| 3 | 1 | 2 | To aggregate the statistics inside a namespace we'd execute something like: |