futurewei-cloud / alcor

Alcor: Cloud native SDN platform powered by Kubernetes and Istio
MIT License
32 stars 33 forks source link

Fix race condition in subnet deletion API #663

Open xieus opened 3 years ago

xieus commented 3 years ago

This PR proposes two issue fix

lgtm-com[bot] commented 3 years ago

This pull request introduces 1 alert and fixes 1 when merging 4831ad652004d1ae6777dd03003afabb76867ab4 into 7a85c18f26cf95ef0dfa155b9e2c04364b6e7fb2 - view on LGTM.com

new alerts:

fixed alerts:

xieus commented 3 years ago

@kevin-zhonghao Could you also review this PR? This PR is to address a concurrency issue #662. Basically when we try to access db multiple times or multiple tables, we will need to ensure the set of operations are in a transaction, otherwise we will hit race condition like this one when the level of concurrency increases.

lgtm-com[bot] commented 3 years ago

This pull request fixes 1 alert when merging 4cb934ebb8f1cb5c7d7e3bb0ebf760212f2b5c80 into 559f2bd90ec4273dfef10024e657739bd4fb6c15 - view on LGTM.com

fixed alerts:

lgtm-com[bot] commented 3 years ago

This pull request fixes 1 alert when merging f756eef3c53afbf27ba2d5703a48d59a877ddf92 into 559f2bd90ec4273dfef10024e657739bd4fb6c15 - view on LGTM.com

fixed alerts:

kevin-zhonghao commented 3 years ago

@kevin-zhonghao Could you also review this PR? This PR is to address a concurrency issue #662. Basically when we try to access db multiple times or multiple tables, we will need to ensure the set of operations are in a transaction, otherwise we will hit race condition like this one when the level of concurrency increases.

Sure, working on it.

lgtm-com[bot] commented 3 years ago

This pull request fixes 1 alert when merging 8160d4a3ac12351990ab3db392faf8c52c239723 into 559f2bd90ec4273dfef10024e657739bd4fb6c15 - view on LGTM.com

fixed alerts:

lgtm-com[bot] commented 3 years ago

This pull request fixes 1 alert when merging 639a0cd1c5dc32a943ad99c7b1c488615769b092 into 559f2bd90ec4273dfef10024e657739bd4fb6c15 - view on LGTM.com

fixed alerts:

lgtm-com[bot] commented 3 years ago

This pull request fixes 1 alert when merging 85de8fbade8b33a4d70c5992431184b4f9bb84a8 into 559f2bd90ec4273dfef10024e657739bd4fb6c15 - view on LGTM.com

fixed alerts:

lgtm-com[bot] commented 3 years ago

This pull request fixes 1 alert when merging d6ed075881657ed5b4987e7a3bcaf4ebbfa4bab5 into 559f2bd90ec4273dfef10024e657739bd4fb6c15 - view on LGTM.com

fixed alerts:

lgtm-com[bot] commented 3 years ago

This pull request fixes 1 alert when merging 016aaf5d9de7b0115c79718e238a1ca4ce0cedf3 into faed9db9fce64476a1d940f4db650bcc35897394 - view on LGTM.com

fixed alerts:

lgtm-com[bot] commented 3 years ago

This pull request fixes 1 alert when merging 2ae9045ff9b50bf99d2310c00f1ea04582cb7486 into 9887247005daf2e9e99db8917c131201c7926f29 - view on LGTM.com

fixed alerts: