--- a/server/checkintegrity.py Fri Mar 05 17:22:41 2010 +0100
+++ b/server/checkintegrity.py Fri Mar 05 17:24:01 2010 +0100
@@ -68,7 +68,6 @@
"""reindex all entities in the repository"""
# deactivate modification_date hook since we don't want them
# to be updated due to the reindexation
- from cubicweb.server.repository import FTIndexEntityOp
repo = session.repo
cursor = session.pool['system']
if not repo.system_source.indexer.has_fti_table(cursor):
@@ -104,9 +103,11 @@
pb.update()
# reindex entities by generating rql queries which set all indexable
# attribute to their current value
+ source = repo.system_source
for eschema in etypes:
for entity in session.execute('Any X WHERE X is %s' % eschema).entities():
- FTIndexEntityOp(session, entity=entity)
+ source.fti_unindex_entity(session, entity.eid)
+ source.fti_index_entity(session, entity)
if withpb:
pb.update()
# restore Entity.check