Skip to content

Commit

Permalink
tools/android/loading Reduce taskqueue access rate.
Browse files Browse the repository at this point in the history
This CL increases the number of URLs per ClovisTask, making them longer
to process, and thus reducing the rate at which workers pull tasks from
the queue.

Review-Url: https://codereview.chromium.org/2059683002
Cr-Commit-Position: refs/heads/master@{#399178}
  • Loading branch information
droger authored and Commit bot committed Jun 10, 2016
1 parent 4d8b60f commit de7d806
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tools/android/loading/cloud/frontend/clovis_frontend.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,9 @@ def SplitClovisTask(task):
task.ActionParams()['traces'] = traces

# Compute the split key.
split_params_for_action = {'trace': ('urls', 1), 'report': ('traces', 5)}
# Keep the tasks small, but large enough to avoid "rate exceeded" errors when
# pulling them from the TaskQueue.
split_params_for_action = {'trace': ('urls', 3), 'report': ('traces', 5)}
(split_key, slice_size) = split_params_for_action.get(task.Action(),
(None, 0))
if not split_key:
Expand Down

0 comments on commit de7d806

Please sign in to comment.