Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cache the value of last unfinished job in the PropagateDerectory scheduleNextJob #5274

Merged
merged 1 commit into from
Oct 31, 2016

Conversation

mrow4a
Copy link
Contributor

@mrow4a mrow4a commented Oct 25, 2016

This PR solves the problem discussed in this PR #5269, implementing the solution of @ckamm which appears to work :

I did not run in any race condition and manualy tested most of the cases. Hope this will work out

@guruz @ogoffart

@mention-bot
Copy link

@mrow4a, thanks for your PR! By analyzing the history of the files in this pull request, we identified @ogoffart, @ckamm and @dragotin to be potential reviewers.

Copy link
Contributor

@ckamm ckamm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, but it doesn't hurt to also leave this for review by @ogoffart when he's back next week.

@mrow4a mrow4a force-pushed the reduce_loops_dirjob branch from f9bc21e to a2d2690 Compare October 25, 2016 13:52
@guruz guruz added this to the 2.3.0 milestone Oct 26, 2016
@dragotin
Copy link
Contributor

On a more general note: We're using int type as index here. If we have a really huge directory, couldn't we have more entries than MAX(int)? Not sure tough if QVector would survive that, or everything....

@@ -194,11 +194,12 @@ class OWNCLOUDSYNC_EXPORT PropagateDirectory : public PropagatorJob {

int _jobsFinished; // number of jobs that have completed
int _runningNow; // number of subJobs running right now
SyncFileItem::Status _hasError; // NoStatus, or NormalError / SoftError if there was an error
SyncFileItem::Status _hasError; // NoStatus, or NormalError / SoftError if there was an errorv
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo (errorv)

@ogoffart
Copy link
Contributor

Looks good (appart from the typo in the comment)

@mrow4a mrow4a force-pushed the reduce_loops_dirjob branch from a2d2690 to 34c59ba Compare October 31, 2016 18:45
@mrow4a
Copy link
Contributor Author

mrow4a commented Oct 31, 2016

Ok, done. Ready to merge if checks will pass.

@mrow4a mrow4a merged commit a2287c9 into master Oct 31, 2016
@mrow4a mrow4a deleted the reduce_loops_dirjob branch October 31, 2016 21:07
@mrow4a mrow4a mentioned this pull request Nov 16, 2016
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants