mirror of
https://github.com/zulip/zulip.git
synced 2025-11-06 15:03:34 +00:00
transaction: Add durable=True to outermost transaction.atomic decorator.
This commit adds 'durable=True' to the outermost transactions of the following functions: * do_create_multiuse_invite_link * do_revoke_user_invite * do_revoke_multi_use_invite * sync_ldap_user_data * do_reactivate_remote_server * do_deactivate_remote_server * bulk_handle_digest_email * handle_customer_migration_from_server_to_realm * add_reaction * remove_reaction * deactivate_user_group It helps to avoid creating unintended savepoints in the future. This is as a part of our plan to explicitly mark all the transaction.atomic decorators with either 'savepoint=False' or 'durable=True' as required. * 'savepoint=True' is used in special cases.
This commit is contained in:
committed by
Tim Abbott
parent
9371bdb81d
commit
0fb5657131
@@ -19,7 +19,7 @@ log_to_file(logger, settings.LDAP_SYNC_LOG_PATH)
|
||||
|
||||
|
||||
# Run this on a cron job to pick up on name changes.
|
||||
@transaction.atomic
|
||||
@transaction.atomic(durable=True)
|
||||
def sync_ldap_user_data(
|
||||
user_profiles: QuerySet[UserProfile], deactivation_protection: bool = True
|
||||
) -> None:
|
||||
|
||||
Reference in New Issue
Block a user