MCPcopy Create free account
hub / github.com/GoEdgeLab/EdgeNode / ExecContext

Method ExecContext

internal/utils/dbs/stmt.go:31–46  ·  view source on GitHub ↗
(ctx context.Context, args ...any)

Source from the content-addressed store, hash-verified

29}
30
31func (this *Stmt) ExecContext(ctx context.Context, args ...any) (result sql.Result, err error) {
32 // check database status
33 if this.db.BeginUpdating() {
34 defer this.db.EndUpdating()
35 } else {
36 return nil, errDBIsClosed
37 }
38
39 if this.enableStat {
40 defer SharedQueryStatManager.AddQuery(this.query).End()
41 }
42 fsutils.WriterLimiter.Ack()
43 result, err = this.rawStmt.ExecContext(ctx, args...)
44 fsutils.WriterLimiter.Release()
45 return
46}
47
48func (this *Stmt) Exec(args ...any) (result sql.Result, err error) {
49 // check database status

Callers

nothing calls this directly

Calls 6

BeginUpdatingMethod · 0.80
EndUpdatingMethod · 0.80
AddQueryMethod · 0.80
EndMethod · 0.45
AckMethod · 0.45
ReleaseMethod · 0.45

Tested by

no test coverage detected