Skip to content

is flowControl.maxMessages option honored in 0.14.x to limit calls to handler #2638

@evilpacket

Description

@evilpacket

Environment details

  • OS: Linux (ubuntu)
  • Node.js version: 8.5.0
  • npm version: 5.3.0
  • google-cloud-node version: @google-cloud/pubsub 0.14.2

Steps to reproduce

Is it possible to get or limit the inflight messages using the new 0.14.x pubsub library?

I'm calling something like the following
this.subscription = this.topic.subscription(this.options.name, this.options.subscription);

Even if I get a topic.subscription with the following options it appears to call the my handler with as many messages in in the queue.

{
  flowControl: {
    maxMessages: 1
  }
}

Metadata

Metadata

Assignees

Labels

api: pubsubIssues related to the Pub/Sub API.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions