From 0557eafa8f6c0bb069a61a7f1ff5ee5399ed3a07 Mon Sep 17 00:00:00 2001 From: Ivan Kozlovic Date: Mon, 2 May 2022 11:14:31 -0600 Subject: [PATCH] Update locksordering.txt with some more ordering and jsa.usageMu Signed-off-by: Ivan Kozlovic --- locksordering.txt | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/locksordering.txt b/locksordering.txt index 1baf5203..88391838 100644 --- a/locksordering.txt +++ b/locksordering.txt @@ -2,6 +2,9 @@ Here is the list of some established lock ordering. In this list, A -> B means that you can have A.Lock() then B.Lock(), not the opposite. -jetStream -> jsAccount -> Server -> client-> Account +jetStream -> jsAccount -> Server -> client -> Account -stream -> consumer +jetStream -> jsAccount -> stream -> consumer + +A lock to protect jetstream account's usage has been introduced: jsAccount.usageMu. +This lock is independent and can be invoked under any other lock: jsAccount -> jsa.usageMu, stream -> jsa.usageMu, etc...