Commit 51aaed94 authored by Vincent Pelletier's avatar Vincent Pelletier

erp5_full_text_mroonga_catalog: Use finer-grained serialization_tag.

The reason why root document is being used as serialization_tag is to cover
document which get recursively reindexed: such indexation activity would
not be able to be validated against all the the serializatio_tag of
documents it will process. But here, fulltext indexations are all spawned
per-document anyway, so we can use such per-document values.
parent 52ec5b9f
...@@ -14,7 +14,7 @@ except KeyError: ...@@ -14,7 +14,7 @@ except KeyError:
# including activities spawned by others into its activity group. # including activities spawned by others into its activity group.
# But prevent the group from going below 10 activities, for better throughput. # But prevent the group from going below 10 activities, for better throughput.
group_method_cost = min(.1, 1. / len(getPath)) group_method_cost = min(.1, 1. / len(getPath))
for document, root_document_path in zip(getPath, getRootDocumentPath): for document in getPath:
getattr( getattr(
activateObject( activateObject(
document, document,
...@@ -23,7 +23,7 @@ for document, root_document_path in zip(getPath, getRootDocumentPath): ...@@ -23,7 +23,7 @@ for document, root_document_path in zip(getPath, getRootDocumentPath):
node='same', node='same',
group_method_id=GROUP_METHOD_ID, group_method_id=GROUP_METHOD_ID,
group_method_cost=group_method_cost, group_method_cost=group_method_cost,
serialization_tag='full_text_' + root_document_path, serialization_tag='full_text_' + document,
), ),
METHOD_ID, METHOD_ID,
)() )()
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string>getPath, getRootDocumentPath</string> </value> <value> <string>getPath</string> </value>
</item> </item>
<item> <item>
<key> <string>description</string> </key> <key> <string>description</string> </key>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment