Batching settings is ignored
See original GitHub issueHi,
I am running a nodejs-pubsub client on Windows and Linux and finding this bug on both Platform.
The batching
parameter of topic.publisher()
is ignored when message are published, despite being visibile and correctly set-up when I read from publisher.settings.batching
.
I tried to set the maxMessages
parameter to 1 but my messages are still published in batches.
I tried to set BatchSettings(max_messages=1)
with Python (with the same subscribers) and it worked.
Environment details
- OS: Ubuntu 17.10 , 64 bits
- Node.js version: 6.11.4
- npm version: 3.5.2
- google-cloud/pubsub version: 0.16.4
Steps to reproduce
const PubSub = require('@google-cloud/pubsub');
const pubsub = new PubSub({});
const topic = pubsub.topic('mytopic');
const publisher = topic.publisher({
batching: {
maxMessages: 1
}
})
const callback = function (err, messageId) {
if (err) {
console.log(err)
}
};
for (var i = 1; i <= 3; i++) {
publisher.publish(Buffer.from('This is a message'), { myattribute: 'attributeValue'}, callback);
} // These messages will be sent in a batch rather than as 3 independant messages
Thanks for your help!
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
2 in batch file is ignored on execution in command prompt
I have a test.bat file that renames images. It looks like this: Timeout 3 Copy "C:\first%20second.png" "C:\sub\first% ...
Read more >Keras seem to ignore my batch_size and tries to fit all data in ...
No, keras is not ignoring your batch size. You're trying to create numpy arrays with too large dimensions. 'inputsB': np.array(n_input2) ...
Read more >Processing Options and Settings (Analysis Services)
Some processing settings are primarily used for batch processing jobs. ... Other settings are Ignore error and Report and stop.
Read more >Update set batching - Product Documentation | ServiceNow
Punctuation and capital letters are ignored. Special characters like underscores (_) are removed. Known synonyms are applied.
Read more >Batch Processing with Seldon Core
If data type is specified as raw then each row in the input file will be sent to model as it is. In...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ok thanks! I have reported the issue on the github of the python library. FYI : https://github.com/GoogleCloudPlatform/google-cloud-python/issues/4912
@Etendard7 I’m going to close this issue. Moving forward Node is going to adopt Python’s strategy for flow control. Thanks again for bringing this to our attention!