Commit 615431ec authored by Jean-Paul Smets's avatar Jean-Paul Smets

cosmetic changes (comment) + use of m.method_id instead of method_id


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@894 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 17162c1f
...@@ -65,12 +65,12 @@ class RAMQueue(Queue): ...@@ -65,12 +65,12 @@ class RAMQueue(Queue):
for m in self.getQueue(activity_tool): for m in self.getQueue(activity_tool):
if not m.validate(self, activity_tool): if not m.validate(self, activity_tool):
self.deleteMessage(activity_tool, m) # Trash messages which are not validated (no error handling) self.deleteMessage(activity_tool, m) # Trash messages which are not validated (no error handling)
get_transaction().commit() get_transaction().commit() # Start a new transaction
return 0 # Keep on ticking return 0 # Keep on ticking
activity_tool.invoke(m) activity_tool.invoke(m)
if m.is_executed: if m.is_executed:
self.deleteMessage(activity_tool, m) # Trash messages which are not validated (no error handling) self.deleteMessage(activity_tool, m) # Trash messages which are not validated (no error handling)
get_transaction().commit() get_transaction().commit() # Start a new transaction
return 0 # Keep on ticking return 0 # Keep on ticking
else: else:
# Start a new transaction and keep on to next message # Start a new transaction and keep on to next message
......
...@@ -210,7 +210,7 @@ class SQLDict(RAMDict): ...@@ -210,7 +210,7 @@ class SQLDict(RAMDict):
if not m.is_executed: # Make sure message could be invoked if not m.is_executed: # Make sure message could be invoked
# The message no longer exists # The message no longer exists
raise ActivityFlushError, ( raise ActivityFlushError, (
'Could not evaluate %s on %s' % (method_id , path)) 'Could not evaluate %s on %s' % (m.method_id , path))
else: else:
# The message no longer exists # The message no longer exists
raise ActivityFlushError, ( raise ActivityFlushError, (
...@@ -232,7 +232,7 @@ class SQLDict(RAMDict): ...@@ -232,7 +232,7 @@ class SQLDict(RAMDict):
if not m.is_executed: # Make sure message could be invoked if not m.is_executed: # Make sure message could be invoked
# The message no longer exists # The message no longer exists
raise ActivityFlushError, ( raise ActivityFlushError, (
'Could not evaluate %s on %s' % (method_id , path)) 'Could not evaluate %s on %s' % (m.method_id , path))
else: else:
# The message no longer exists # The message no longer exists
raise ActivityFlushError, ( raise ActivityFlushError, (
......
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