Summary
LakebaseV1Connector.transaction() rotates credentials on 28P01, opens a retry client, and passes that retry client to the transaction callback. The retry path still executes BEGIN and COMMIT on the original client, which has already been released.
Impact
The callback work and transaction boundaries can run on different PostgreSQL clients. In practice the retry path may fail immediately because the original client was released, or it may leave the retry callback work outside the intended transaction.
Expected
After credential rotation, BEGIN, callback work, COMMIT, and rollback handling should all use the retry client.
Repro Pointer
See packages/appkit/src/connectors/lakebase-v1/client.ts in the auth retry branch of transaction().
Summary
LakebaseV1Connector.transaction()rotates credentials on28P01, opens a retry client, and passes that retry client to the transaction callback. The retry path still executesBEGINandCOMMITon the original client, which has already been released.Impact
The callback work and transaction boundaries can run on different PostgreSQL clients. In practice the retry path may fail immediately because the original client was released, or it may leave the retry callback work outside the intended transaction.
Expected
After credential rotation,
BEGIN, callback work,COMMIT, and rollback handling should all use the retry client.Repro Pointer
See
packages/appkit/src/connectors/lakebase-v1/client.tsin the auth retry branch oftransaction().