-
Notifications
You must be signed in to change notification settings - Fork 284
Remove resource size from task header #3917
Conversation
12a1911
to
817eeba
Compare
1d5032c
to
1a83c28
Compare
1a83c28
to
64d4d2a
Compare
0f1de69
to
1fe89b7
Compare
if task_header: | ||
options.set(size=task_header.resource_size) | ||
if size and options: | ||
options.set(size=size) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@badb there seems to be something not quite right here... unless I'm misreading...
what I mean is that previously, the size here had always been set to the resource size specified in the task header...
right now, the only call to this method that specifies the size
, uses the ReportComputedTask.size
which is not the resource size but rather the result size ... is that indeed what we need here? am I wrong?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Size option can be also already specified in options (that should be the case for TaskToCompute (check line 233 in taskkeeper).
This option is used to estimate how long may it take to download resources. With ReportComputedTask we want to dowload results so their size should be used. I guess that usage of resource_size in this place was just a heuristic (we assumed that results size won't be significantly different that size of resources, which of course doesn't have to be true).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Codecov Report
@@ Coverage Diff @@
## develop #3917 +/- ##
==========================================
+ Coverage 87.66% 87.8% +0.13%
==========================================
Files 216 216
Lines 18968 18977 +9
==========================================
+ Hits 16629 16662 +33
+ Misses 2339 2315 -24 |
If we want to make possible to add different resources for different subtasks we cannot send just one size in the TaskHeader. This PR:
Golem-messages PR: golemfactory/golem-messages#319