Message-ID: From: "vlsi (@vlsi)" To: "pgjdbc/pgjdbc" Date: Fri, 13 Mar 2026 17:16:37 +0000 Subject: [pgjdbc/pgjdbc] PR #3960: fix: release COPY lock on IOException to prevent connection hang (#3957) List-Id: X-GitHub-Author-Id: 213894 X-GitHub-Author-Login: vlsi X-GitHub-Issue: 3960 X-GitHub-Labels: bug X-GitHub-Repo: pgjdbc/pgjdbc X-GitHub-State: merged X-GitHub-Type: pull_request X-GitHub-Url: https://github.com/pgjdbc/pgjdbc/pull/3960 Content-Type: text/plain; charset=utf-8 When an IOException occurs during COPY operations (endCopy, writeToCopy, flushCopy, readFromCopy), the COPY lock was not released, causing all subsequent operations on the connection (e.g. isValid, rollback) to hang indefinitely in waitOnLock(). This matches the existing pattern in cancelCopy() which already releases the lock in its finally block. Also adds closeAllClients() to StrangeProxyServer for triggering immediate IOExceptions in tests.