Trace:
Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | |||
jvx:best_practice [2025/06/05 10:12] admin |
jvx:best_practice [2025/06/19 05:31] (current) admin |
||
---|---|---|---|
Line 11: | Line 11: | ||
* ZGC //(JVM >= 21, for very large memory configurations, needs more memory)// <code>-XX:+UseZGC -XX:+ZGenerational -XX:+UnlockExperimentalVMOptions -XX:+ExplicitGCInvokesConcurrent -XX:+ZProactive -XX:ZCollectionInterval=30</code> | * ZGC //(JVM >= 21, for very large memory configurations, needs more memory)// <code>-XX:+UseZGC -XX:+ZGenerational -XX:+UnlockExperimentalVMOptions -XX:+ExplicitGCInvokesConcurrent -XX:+ZProactive -XX:ZCollectionInterval=30</code> | ||
+ | ==== Postgres: set sequence to max ID ==== | ||
+ | Use following statement in your postgres database to get a list of **setval** statements which will set the sequences to the max value. | ||
+ | |||
+ | <code sql> | ||
+ | select t.table_name, | ||
+ | 'SELECT setval(''seq_'|| t.table_name || '_id'', max(id)::integer) FROM ' ||t.table_name | ||
+ | from information_schema.tables t | ||
+ | where table_schema = 'public' | ||
+ | and table_type = 'BASE TABLE'; | ||
+ | </code> |