File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -4223,6 +4223,12 @@ func (r *rpcServer) FetchSupplyCommit(ctx context.Context,
42234223 req * unirpc.FetchSupplyCommitRequest ) (
42244224 * unirpc.FetchSupplyCommitResponse , error ) {
42254225
4226+ // Check the rate limiter to see if we need to wait at all. If not then
4227+ // this'll be a noop.
4228+ if err := r .proofQueryRateLimiter .Wait (ctx ); err != nil {
4229+ return nil , err
4230+ }
4231+
42264232 groupPubKey , err := unmarshalGroupKey (
42274233 req .GetGroupKeyBytes (), req .GetGroupKeyStr (),
42284234 )
@@ -4794,6 +4800,12 @@ func (r *rpcServer) InsertSupplyCommit(ctx context.Context,
47944800 req * unirpc.InsertSupplyCommitRequest ) (
47954801 * unirpc.InsertSupplyCommitResponse , error ) {
47964802
4803+ // Check the rate limiter to see if we need to wait at all. If not then
4804+ // this'll be a noop.
4805+ if err := r .proofQueryRateLimiter .Wait (ctx ); err != nil {
4806+ return nil , err
4807+ }
4808+
47974809 groupPubKey , err := unmarshalGroupKey (
47984810 req .GetGroupKeyBytes (), req .GetGroupKeyStr (),
47994811 )
You can’t perform that action at this time.
0 commit comments