Skip to content

Commit 3a6e6af

Browse files
committed
trytond: Remove index dumping mechanism [CUSTOM]
1 parent 8307b51 commit 3a6e6af

File tree

2 files changed

+0
-20
lines changed

2 files changed

+0
-20
lines changed

trytond/trytond/model/modelsql.py

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -566,16 +566,6 @@ def no_subset(index):
566566
indexes = filter(no_subset, cls._history_sql_indexes)
567567
history_th.set_indexes(indexes, concurrently=concurrently)
568568

569-
@classmethod
570-
def _dump_sql_indexes(cls, file, concurrently):
571-
if not callable(cls.table_query):
572-
table_h = cls.__table_handler__()
573-
table_h.dump_indexes(cls._sql_indexes, file, concurrently)
574-
if cls._history:
575-
history_th = cls.__table_handler__(history=True)
576-
history_th.dump_indexes(
577-
cls._history_sql_indexes, file, concurrently)
578-
579569
@classmethod
580570
def _update_history_table(cls):
581571
if cls._history:

trytond/trytond/modules/__init__.py

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -295,16 +295,6 @@ def create_indexes(concurrently):
295295
if update:
296296
if indexes or indexes is None:
297297
create_indexes(concurrently=False)
298-
else:
299-
with tempfile.NamedTemporaryFile(
300-
suffix='.sql', delete=False) as tfd:
301-
for model_name in models_with_indexes:
302-
model = pool.get(model_name)
303-
if model._sql_indexes:
304-
model._dump_sql_indexes(tfd)
305-
logger.warning(
306-
'index:skipping indexes creation. SQL dumped on %s',
307-
tfd.name)
308298
for model_name in models_to_update_history:
309299
model = pool.get(model_name)
310300
if model._history:

0 commit comments

Comments
 (0)