Dear Vignesh,

> The attached v1-0002 patch contains a TAP test that reproduces the
> issue on HEAD. I'm attaching it in case anyone wants to reproduce the
> problem locally, although I don't think this test needs to be
> committed.

Thanks for posting a patch. I confirmed that "out of shared memory" error
could happen on the HEAD, and after the patch it won't happen anymore.

One minor comment:
```
+               /*
+                * Lock the sequence so its identity (namespace and name) 
cannot change
+                * under us via a concurrent DROP, RENAME or SET SCHEMA. 
Release it
+                * right away rather than at transaction end, to avoid 
accumulating a
+                * lock per sequence.
+                */
+               sequence_rel = try_table_open(subrel->srrelid, AccessShareLock);
```

I think this comment is not enough. We can describe why the releasing the lock
immediately is OK. IIUC, it's because the name and the namespace would be 
checked
again in copy_sequences(), right?

Best regards,
Hayato Kuroda
FUJITSU LIMITED

Reply via email to