On 08/05/2016 07:36 AM, Amit Kapila wrote:
> On Thu, Aug 4, 2016 at 8:02 PM, Mithun Cy <mithun.cy@enterprisedb.com> wrote:
>> I did some basic testing of same. In that I found one issue with cursor.
>>
>
> Thanks for the testing. The reason for failure was that the patch
> didn't take into account the fact that for scrolling cursors, scan can
> reacquire the lock and pin on bucket buffer multiple times. I have
> fixed it such that we release the pin on bucket buffers after we scan
> the last overflow page in bucket. Attached patch fixes the issue for
> me, let me know if you still see the issue.
>
Needs a rebase.
hashinsert.c
+ * reuse the space. There is no such apparent benefit from finsihing the
-> finishing
hashpage.c
+ * retrun the buffer, else return InvalidBuffer.
-> return
+ if (blkno == P_NEW)
+ elog(ERROR, "hash AM does not use P_NEW");
Left over ?
+ * for unlocking it.
-> for unlocking them.
hashsearch.c
+ * bucket, but not pin, then acuire the lock on new bucket and again
-> acquire
hashutil.c
+ * half. It is mainly required to finsh the incomplete splits where we are
-> finish
Ran some tests on a CHAR() based column which showed good results. Will
have to compare with a run with the WAL patch applied.
make check-world passes.
Best regards, Jesper