jaysonsantos opened a new issue, #429: URL: https://github.com/apache/pulsar-client-node/issues/429
Not sure what would be better here, that either the exception should be catchable or it should be idempotent. ```javascript const Pulsar = require("pulsar-client"); const STAGING = { serviceUrl: "pulsar+ssl://any-server:6651", }; async function main() { const client = new Pulsar.Client({ ...STAGING, logLevel: Pulsar.LogLevel.ERROR, log: (level, file, line, message) => { console.log(`[${level}] ${file}:${line}: ${message}`); }, }); try { await client.close(); await client.close(); } catch (error) { console.error("omg closing client:", error); } } main(); ``` ```json { "dependencies": { "pulsar-client": "^1.14.0" } } ``` Will throw ``` node error-report.js node:internal/process/promises:391 triggerUncaughtException(err, true /* fromPromise */); ^ [Error: Failed to close client: AlreadyClosed] Node.js v20.18.1 ``` Even though I catched it -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@pulsar.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org