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

Fix database locks #4819

Merged
merged 1 commit into from
Mar 25, 2021
Merged

Fix database locks #4819

merged 1 commit into from
Mar 25, 2021

Conversation

miaulalala
Copy link
Contributor

See #4812

Added the timestamp to the hasLocks method as to avoid only relying on tokens but not checking if they are still valid.

@GretaD
Copy link
Contributor

GretaD commented Mar 24, 2021

While testing i realized that things are a better but with the combined mailboxes(in my case 2) the problem still exist if the initial sync is in progress.

@ChristophWurst ChristophWurst changed the title Fix/database is locked Fix database locks Mar 24, 2021
Copy link
Member

@ChristophWurst ChristophWurst 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

@@ -119,7 +115,6 @@ public function findById(int $id): Mailbox {
*
* @return Mailbox
*
* @throws DoesNotExistException
Copy link
Member

Choose a reason for hiding this comment

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

please revert

@@ -93,7 +90,6 @@ public function find(Account $account, string $name): Mailbox {
*
* @return Mailbox
*
* @throws DoesNotExistException
Copy link
Member

Choose a reason for hiding this comment

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

revert

@@ -66,7 +64,6 @@ public function findAll(Account $account): array {
}

/**
* @throws DoesNotExistException
Copy link
Member

Choose a reason for hiding this comment

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

revert

@@ -31,13 +31,11 @@
use OCA\Mail\Account;
use OCA\Mail\Exception\MailboxLockedException;
use OCA\Mail\Exception\ServiceException;
use OCP\AppFramework\Db\DoesNotExistException;
Copy link
Member

Choose a reason for hiding this comment

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

revert

use OCP\AppFramework\Db\MultipleObjectsReturnedException;
use OCP\AppFramework\Db\QBMapper;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\DB\QueryBuilder\IQueryBuilder;
use OCP\IDBConnection;
use function array_map;
Copy link
Member

Choose a reason for hiding this comment

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

still used -> revert

@ChristophWurst
Copy link
Member

/backport to stable1.9

@ChristophWurst ChristophWurst merged commit 3575d85 into master Mar 25, 2021
@ChristophWurst ChristophWurst deleted the fix/database-is-locked branch March 25, 2021 09:06
@backportbot-nextcloud
Copy link

The backport to stable1.9 failed. Please do this backport manually.

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.

3 participants