Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(84)

Unified Diff: common/gcloud/pubsub/quota.go

Issue 1838303002: Use native Pub/Sub library primitives. (Closed) Base URL: https://github.com/luci/luci-go@logdog-go1.6
Patch Set: Use "Topic" instead of "NewTopic" ... don't want to create :) Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « common/gcloud/pubsub/pubsub.go ('k') | common/gcloud/pubsub/retry.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: common/gcloud/pubsub/quota.go
diff --git a/common/gcloud/pubsub/quota.go b/common/gcloud/pubsub/quota.go
index a52e1bc814564f3f2b1284fb6329ed5b78f7488f..116a27b5f9de78b9a49da178d54361a97ff63e19 100644
--- a/common/gcloud/pubsub/quota.go
+++ b/common/gcloud/pubsub/quota.go
@@ -5,7 +5,7 @@
package pubsub
import (
- "time"
+ "google.golang.org/cloud/pubsub"
)
// Cloud PubSub quota is documented here:
@@ -18,7 +18,7 @@ const (
MaxPublishSize = 10 * 1024 * 1024
// MaxPublishBatchSize is the maximum PubSub batch size.
- MaxPublishBatchSize = 1000
+ MaxPublishBatchSize = pubsub.MaxPublishBatchSize
// MaxProjectMessagesPerSecond is the maximum number of requests per second,
// across the entire project.
@@ -26,14 +26,5 @@ const (
// MaxSubscriptionPullSize is the maximum number of subscription records that
// can be pulled at a time.
- MaxSubscriptionPullSize = 100
-
- // MaxMessageAckPerRequest is the maximum number of messages one can
- // acknowledge in a single "acknowledge" call.
- //
- // NOTE: This is not verified, and is inspired by "MaxSubscriptionPullSize".
- MaxMessageAckPerRequest = 100
-
- // DefaultMaxAckDelay is the default maximum ACK delay.
- DefaultMaxAckDelay = (60 * time.Second)
+ MaxSubscriptionPullSize = pubsub.DefaultMaxPrefetch
)
« no previous file with comments | « common/gcloud/pubsub/pubsub.go ('k') | common/gcloud/pubsub/retry.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698