Message-ID: From: "vlsi (@vlsi)" To: "pgjdbc/pgjdbc" Date: Tue, 07 Nov 2023 04:59:10 +0000 Subject: Re: [pgjdbc/pgjdbc] PR #2976: feat: fetch size for RefCursor In-Reply-To: References: List-Id: X-GitHub-Author-Login: vlsi X-GitHub-Comment-Id: 1384385335 X-GitHub-Comment-Type: review_comment X-GitHub-Commit: 2be046b8c76fcda813f53d5d9070e13feb009dd6 X-GitHub-Issue: 2976 X-GitHub-Path: pgjdbc/src/main/java/org/postgresql/jdbc/PgResultSet.java X-GitHub-Repo: pgjdbc/pgjdbc X-GitHub-Type: review_comment X-GitHub-Url: https://github.com/pgjdbc/pgjdbc/pull/2976#discussion_r1384385335 Content-Type: text/plain; charset=utf-8 (on pgjdbc/src/main/java/org/postgresql/jdbc/PgResultSet.java) It looks weird that `closeRefCursor` is called only when `fetchSize` exceeds 0. Why can't it close unconditionally? I might be missing something, but as I read the code, `close()` should probably free up the resources, and conditional release looks like a leak to me