age icon indicating copy to clipboard operation
age copied to clipboard

Add advisory lock before creating label in create/merge operation

Open mdianjun opened this issue 9 months ago • 7 comments

When merging nodes or edges concurrently, there is label with the same name created by different session. However, checking whether the label exists cannot be guaranteed consistency. This commit add an advisory lock to ensure creating label is serial.

mdianjun avatar May 21 '25 09:05 mdianjun

@MuhammadTahaNaveed PTAL, thanks.

mdianjun avatar May 21 '25 09:05 mdianjun

@MuhammadTahaNaveed Can you check if this is a new CI issue?

jrgemignani avatar Jun 02 '25 03:06 jrgemignani

@mdianjun Can you rebase (against the master) and force push this PR? We had to fix the CI that was causing build issues.

jrgemignani avatar Jun 02 '25 19:06 jrgemignani

@mdianjun Can you rebase (against the master) and force push this PR? We had to fix the CI that was causing build issues.

Have rebased it.

mdianjun avatar Jun 03 '25 07:06 mdianjun

When merging nodes or edges concurrently, there is label with the same name created by different session. However, checking whether the label exists cannot be guaranteed consistency. This commit add an advisory lock to ensure creating label is serial.

@mdianjun As this fixes a purported issue, can you provide an example showing this issue? Additionally, can you provide regression tests for it?

edit: Why only merge and not create?

jrgemignani avatar Jun 03 '25 15:06 jrgemignani

@mdianjun As this fixes a purported issue, can you provide an example showing this issue? Additionally, can you provide regression tests for it?

edit: Why only merge and not create?

@jrgemignani Create operation should be fixed as well, I missed it. I add a python script in regress test.

mdianjun avatar Jun 04 '25 03:06 mdianjun

@MuhammadTahaNaveed Is this something we need to add/fix? Or,...

jrgemignani avatar Jun 10 '25 15:06 jrgemignani