@alicloud/mns
Advanced tools
Comparing version 1.0.0-beta2 to 1.0.0-beta3
@@ -124,4 +124,4 @@ 'use strict'; | ||
const contentType = 'text/xml'; | ||
const degist = kitx.md5(body, 'hex'); | ||
const md5 = Buffer.from(degist, 'utf8').toString('base64'); | ||
const digest = kitx.md5(body, 'hex'); | ||
const md5 = Buffer.from(digest, 'utf8').toString('base64'); | ||
@@ -204,3 +204,15 @@ const headers = Object.assign({ | ||
batchReceiveMessage() {} | ||
async batchReceiveMessage(queueName, numOfMessages, waitSeconds) { | ||
var url = `/queues/${queueName}/messages?numOfMessages=${numOfMessages}`; | ||
if (waitSeconds) { | ||
url += `&waitseconds=${waitSeconds}`; | ||
} | ||
const subType = 'Message'; | ||
// 31000 31s +1s max waitSeconds is 30s | ||
var response = await this.get(url, 'Messages', {timeout: 31000}); | ||
response.body = response.body[subType]; | ||
return response; | ||
} | ||
peekMessage() {} | ||
@@ -207,0 +219,0 @@ batchPeekMessage() {} |
{ | ||
"name": "@alicloud/mns", | ||
"version": "1.0.0-beta2", | ||
"version": "1.0.0-beta3", | ||
"description": "> 该 SDK 并未完全实现所有文档所提及的功能,如果您想使用的功能并未实现,请提[issue](https://github.com/aliyun/aliyun-mns-nodejs-sdk/issues/new)以增加优先级。", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
15245
317