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
AccountState: Avoid ConnectionCheck if ETag job was just done. #3964
Conversation
This patch lets a successful etag job check mark a timestamp. If next time a connection check is requested, it is checked if the last ETag happened within the last 30 seconds and if so the connection check can be checked. This way we avoid half of the PROPFINDs if all goes well.
(haven't tested this theory) With multiple sync folders/accounts the ETag checks will be done sequentially (at least that's how it was before multi-account) Having a check with <= 30 sec will therefore mostly be false since those checks were sequential and could be longer than 30 sec ago |
Please mention the related issue ID in the commit message |
Ah, and the 30 sec should be instead related to remotePollInterval ? (Plus the comment above I mentioned with regards to multiple accounts/folders) |
@guruz yes, exactly my thought, it should be the same as remotePollInterval. Will follow up. |
I think the right fix is not to do the connection check chen the account is online. The etag check will make the connection drop. |
* this account. | ||
* The checkConnectivity() method uses the timestamp to save a call to | ||
* the server to validate the connection if the last successful etag job | ||
* is not so lang away. |
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.
"was not too far in the past." ?
btw, we also must not break
|
@dragotin You had asked me for an explanation on #3964 (comment) What I meant is that I'll have a look at this and possibly fix this here. |
Cherry picked into 2.1 |
Avoids requests on startup. For #3964
This patch lets a successful etag job check mark a timestamp.
If next time a connection check is requested, it is checked if
the last ETag happened within the last 30 seconds and if so the
connection check can be checked.
This way we avoid half of the PROPFINDs if all goes well.
@ckamm @ogoffart @guruz please check.