Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitc51d6bf

Browse files
authored
"When it's a time to re-learn?" section added (thanks tohttps://www.reddit.com/user/mage2k)
1 parentb3954c7 commitc51d6bf

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

‎README.md‎

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ ZSON is a PostgreSQL extension for transparent JSONB compression. Compression is
66

77
ZSON was originally created in 2016 by[Postgres Professional](https://postgrespro.ru/) team: researched and coded by[Aleksander Alekseev](http://eax.me/); ideas, code review, testing, etc by[Alexander Korotkov](http://akorotkov.github.io/) and[Teodor Sigaev](http://www.sigaev.ru/).
88

9+
See also[discussion on Reddit](https://www.reddit.com/r/PostgreSQL/comments/55mr4r/zson_postgresql_extension_for_transparent_jsonb/).
10+
911
##Install
1012

1113
Build and install ZSON:
@@ -121,6 +123,20 @@ delete from zson_dict where dict_id = 0;
121123

122124
In general it's safer to keep old dictionaries just in case. A few KB of disk space don't worth the risk of losing data.
123125

126+
##When it's a time to re-learn?
127+
128+
Unfortunately, it's hard to recommend a general approach.
129+
130+
A good heuristic could be:
131+
132+
```
133+
select pg_table_size('tt') / (select count(*) from tt)
134+
```
135+
136+
... i.e. average document size. When it suddenly starts to grow it's time to re-learn.
137+
138+
However, developers usually know when they change a schema significantly. It's also easy to re-check whether current schema differs a lot from the original using zson_dict table.
139+
124140
##Benchmark
125141

126142
**Disclaimer**: Synthetic benchmarks could not be trusted. Re-check everything on specific hardware, configuration, data and workload!

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp