Skip to content

@odatano/nightgate 0.34.0

Choose a tag to compare

@maxalexweber1 maxalexweber1 released this 16 Oct 05:25
· 35 commits to main since this release
1459dd1

@odatano/nightgate 0.34.0

One throughput policy: rate classes, grant budgets per hour, one 429 answer. Schema delta: three nullable columns on AgentGrants. No circuit change.

  • Nine rate classes replace the per-action limiters (prove 60/h per session, deploy 5/h per session, sponsor 120/h, compute 120/h, read 60/min, wallet 10/min, signing 10/h, admin 10/h, public-verify 60/min per address); each count is NIGHTGATE_<CLASS>_RATE_LIMIT or rateLimits.<class> in NIGHTGATE_SPONSOR_POLICY_FILE, which applies without a restart. NIGHTGATE_GRANT_ADMIN_RATE_LIMIT is NIGHTGATE_ADMIN_RATE_LIMIT.
  • maxJobsPerHour on agent grants next to maxJobsPerDay; NIGHTGATE_GRANT_DEFAULT_JOBS_PER_HOUR and _PER_DAY fill a budget the creation leaves out.
  • Every 429 names its limit and carries Retry-After; answers under a limit carry RateLimit-Policy and RateLimit; getMetrics() counts rate_limited_total{limit}.
  • getGrantUsage returns limits (budgets with used and resetsAt, rate classes with remaining); a token may leave grantId empty.
  • @odatano/nightgate-tx 0.13.0: NightgateApiError.retryAfterSeconds.
  • Unbound sponsoring keeps a dust backing reserved until the sponsor wallet lists the spend (NIGHTGATE_NOTE_SPENT_WAIT_MS, default 30 s): no second spend of the same note under parallel load (1010/196, rebuild).
  • A submit that died on the client's closing socket is resent as a transport failure; a copy the node refuses is looked up on the indexer, never rebuilt. Resend, refusal and dust-race log lines carry the identifier.

Full Changelog: v0.33.3...v0.34.0