Commit 00393724 authored by Jérome Perrin's avatar Jérome Perrin

Lower severity of 'invoking a group method %s with %d objects' LOG

message


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@7284 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 49ec5164
...@@ -42,7 +42,7 @@ try: ...@@ -42,7 +42,7 @@ try:
except ImportError: except ImportError:
pass pass
from zLOG import LOG from zLOG import LOG, TRACE
MAX_PRIORITY = 5 MAX_PRIORITY = 5
MAX_GROUPED_OBJECTS = 500 MAX_GROUPED_OBJECTS = 500
...@@ -283,15 +283,16 @@ class SQLDict(RAMDict): ...@@ -283,15 +283,16 @@ class SQLDict(RAMDict):
if count >= MAX_GROUPED_OBJECTS: if count >= MAX_GROUPED_OBJECTS:
break break
get_transaction().commit() # Release locks before starting a potentially long calculation # Release locks before starting a potentially long calculation
get_transaction().commit()
# Try to invoke # Try to invoke
if group_method_id is not None: if group_method_id is not None:
LOG('SQLDict', 0, 'invoking a group method %s with %d objects (%d objects in expanded form)' % (group_method_id, len(message_list), count)) LOG('SQLDict', TRACE,
#for m in message_list: 'invoking a group method %s with %d objects '\
# LOG('SQLDict', 0, '%r has objects %r' % (m, m.getObjectList(activity_tool))) ' (%d objects in expanded form)' % (
group_method_id, len(message_list), count))
activity_tool.invokeGroup(group_method_id, message_list) activity_tool.invokeGroup(group_method_id, message_list)
else: else:
#LOG('SQLDict dequeueMessage', 0, 'invoke %s on %s' % (message_list[0].method_id, message_list[0].object_path))
activity_tool.invoke(message_list[0]) activity_tool.invoke(message_list[0])
# Check if messages are executed successfully. # Check if messages are executed successfully.
...@@ -303,7 +304,7 @@ class SQLDict(RAMDict): ...@@ -303,7 +304,7 @@ class SQLDict(RAMDict):
for m in message_list: for m in message_list:
if m.is_executed: if m.is_executed:
break break
else: else:
get_transaction().abort() get_transaction().abort()
for i in xrange(len(message_list)): for i in xrange(len(message_list)):
......
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