Skip to content

Commit d5618c0

Browse files
committed
run normal vacuum
1 parent 43535fa commit d5618c0

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

mapswipe_workers/python_scripts/remove_duplicated_information_in_postgres.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ def run_vacuum_tasks_table():
8484
old_isolation_level = p_con._db_connection.isolation_level
8585
p_con._db_connection.set_isolation_level(0)
8686
query = """
87-
VACUUM FULL tasks
87+
VACUUM tasks
8888
"""
8989
p_con.query(query)
9090
# set isolation_level back to initial value
@@ -100,7 +100,7 @@ def run_vacuum_groups_table():
100100
old_isolation_level = p_con._db_connection.isolation_level
101101
p_con._db_connection.set_isolation_level(0)
102102
query = """
103-
VACUUM FULL groups
103+
VACUUM groups
104104
"""
105105
p_con.query(query)
106106
# set isolation_level back to initial value
@@ -113,7 +113,5 @@ def run_vacuum_groups_table():
113113
for i, project_id in enumerate(project_ids_list):
114114
update_tasks_table(project_id)
115115
update_groups_table(project_id)
116-
# vacuum every 50th project
117-
if i % 50 == 0 or i == len(project_ids_list) - 1:
118-
run_vacuum_tasks_table()
119-
run_vacuum_groups_table()
116+
run_vacuum_tasks_table()
117+
run_vacuum_groups_table()

0 commit comments

Comments
 (0)