Re: [HACKERS] CurTransactionContext freed before transaction COMMIT ???

2017-10-27 Thread Gaddam Sai Ram
Thanks for your responses Michael and Amit Kapila, Yes, we have included your suggestions in our code and started testing to reproduce the same issue. In case we encounter this issue again we will get back here. Regards G. Sai Ram

Re: [HACKERS] CurTransactionContext freed before transaction COMMIT ???

2017-10-25 Thread Gaddam Sai Ram
Thanks for the response, Can you check if CurTransactionContext is valid at that point? Any Postgres function to check if CurTransactionContext is valid or not? To see, if this problem is related to CurTransactionContext, can you try to populate the list in TopMemoryContext and see

Re: [HACKERS] CurTransactionContext freed before transaction COMMIT ???

2017-10-24 Thread Gaddam Sai Ram
This sounds broken on its face --- if you want stuff to survive to top-level commit, you need to keep it in TopTransactionContext. CurTransactionContext might be a subtransaction's context that will go away at subtransaction commit/abort.

[HACKERS] CurTransactionContext freed before transaction COMMIT ???

2017-10-24 Thread Gaddam Sai Ram
Hello people, We are implementing in-memory index. As a part of that, during index callbacks, under CurTransactionContext, we cache all the DMLs of a transaction in dlist(postgres's doubly linked list). We registered transaction callback, and in transaction

[HACKERS] Help needed regarding DSA based in-memory index!

2017-10-24 Thread Gaddam Sai Ram
Hi Munro, Thanks for cautioning us about possible memory leaks(during error cases) incase of long-lived DSA segements(have a look in below thread for more details). https://www.postgresql.org/message-id/CAEepm%3D3c4WAtSQG4tAF7Y_VCnO5cKh7KuFYZhpKbwGQOF%3DdZ4A%40mail.gmail.com

Re: [HACKERS] Error: dsa_area could not attach to a segment that has been freed

2017-10-05 Thread Gaddam Sai Ram
On Wed, 20 Sep 2017 14:25:43 +0530 Thomas Munro thomas.mu...@enterprisedb.com wrote On Wed, Sep 20, 2017 at 6:14 PM, Gaddam Sai Ram gaddamsaira...@zohocorp.com wrote: Thank you very much! That fixed my issue! :) I was in an assumption that pinning the area will increase its

Re: [HACKERS] Error: dsa_area could not attach to a segment that has been freed

2017-09-20 Thread Gaddam Sai Ram
...@enterprisedb.com wrote On Fri, Sep 15, 2017 at 7:51 PM, Gaddam Sai Ram gaddamsaira...@zohocorp.com wrote: As i'm pinning the dsa mapping after attach, it has to stay through out the backend session. But not sure why its freed/corrupted. Kindly help me in fixing this issue. Attached

[HACKERS] Re: Error: dsa_area could not attach to a segment that has been freed

2017-09-18 Thread Gaddam Sai Ram
Kindly help me with the above thread.. Thanks G. Sai Ram On Fri, 15 Sep 2017 13:21:33 +0530 Gaddam Sai Ram gaddamsaira...@zohocorp.com wrote Hello everyone, Based on the discussion in the below thread, I built a an extension using DSA(postgres-10 beta-3, linux machine