Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
H
haf
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
hive
haf
Commits
59e75f7f
Commit
59e75f7f
authored
2 weeks ago
by
Marcin
Committed by
Marcin
2 weeks ago
Browse files
Options
Downloads
Patches
Plain Diff
update doc: vacuuming
parent
f94de4c2
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!629
update doc: managing indexes
Pipeline
#118027
passed
2 weeks ago
Stage: build_and_test_phase_1
Stage: build_and_test_phase_2
Stage: cleanup
Changes
1
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/hive_fork_manager/Readme.md
+26
-0
26 additions, 0 deletions
src/hive_fork_manager/Readme.md
with
26 additions
and
0 deletions
src/hive_fork_manager/Readme.md
+
26
−
0
View file @
59e75f7f
...
...
@@ -187,6 +187,32 @@ To optimize performance, applications should register their required indexes **b
initiating synchronization. This approach ensures that index creation is integrated into the
synchronization process, improving efficiency and reducing system load.
#### Managing Table Vacuuming
`hived`
is responsible for maintaining the integrity and performance of the database by executing
periodic vacuum operations at optimal moments. To enhance efficiency and prevent table bloat,
an API for managing table vacuuming has been introduced. This API allows applications to request
vacuuming for specific tables while ensuring that excessive vacuum operations do not negatively
impact system performance.
##### API Functions
##### Requesting Table Vacuuming
Applications can request vacuuming for a table using the function
**`hive.app_request_table_vacuum`**
.
This function:
-
Inserts a vacuum request for the specified table.
-
Optionally checks if the table has been vacuumed recently to avoid redundant operations.
-
Updates the request status to ensure that the vacuuming process is tracked properly.
###### Example Usage:
An application can request vacuuming of a specific table, ensuring that it has not been vacuumed
within a given interval. If the table was vacuumed recently, the request will be ignored.
```
sql
-- Request vacuuming for 'my_table' if it has not been vacuumed in the last hour
SELECT
hive
.
app_request_table_vacuum
(
'my_table'
,
INTERVAL
'1 hour'
);
```
#### Using HAF built-in roles
Based on extensive experience with a diverse range of applications, it is recommended to configure Postgres roles
in accordance with the guidelines depicted in the image below. This illustration provides a comprehensive overview
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment