1
0
mirror of https://github.com/ManyakRus/starter.git synced 2025-11-25 23:02:22 +02:00

сделал delete gitlab.aescorp.ru

This commit is contained in:
Nikitin Aleksandr
2025-11-17 13:49:18 +03:00
parent 7f3b520455
commit b4d312d4fa
208 changed files with 7600 additions and 20410 deletions

View File

@@ -292,8 +292,9 @@ func (c *Conn) clearOuts() {
c.outs = outputs{}
}
func (c *Conn) simpleProcessResp(ctx context.Context) error {
func (c *Conn) simpleProcessResp(ctx context.Context, isRollback bool) error {
reader := startReading(c.sess, ctx, c.outs)
reader.noAttn = isRollback
c.clearOuts()
var resultError error
@@ -311,7 +312,7 @@ func (c *Conn) Commit() error {
if err := c.sendCommitRequest(); err != nil {
return c.checkBadConn(c.transactionCtx, err, true)
}
return c.simpleProcessResp(c.transactionCtx)
return c.simpleProcessResp(c.transactionCtx, false)
}
func (c *Conn) sendCommitRequest() error {
@@ -336,7 +337,7 @@ func (c *Conn) Rollback() error {
if err := c.sendRollbackRequest(); err != nil {
return c.checkBadConn(c.transactionCtx, err, true)
}
return c.simpleProcessResp(c.transactionCtx)
return c.simpleProcessResp(c.transactionCtx, true)
}
func (c *Conn) sendRollbackRequest() error {
@@ -390,7 +391,7 @@ func (c *Conn) sendBeginRequest(ctx context.Context, tdsIsolation isoLevel) erro
}
func (c *Conn) processBeginResponse(ctx context.Context) (driver.Tx, error) {
if err := c.simpleProcessResp(ctx); err != nil {
if err := c.simpleProcessResp(ctx, false); err != nil {
return nil, err
}
// successful BEGINXACT request will return sess.tranid