Update README.md
This commit is contained in:
Родитель
b0becf70fd
Коммит
28162b8ebd
|
@ -101,7 +101,7 @@ const { EventHubClient, EventPosition } = require('azure-event-hubs');
|
|||
const client = EventHubClient.createFromConnectionString(process.env["EVENTHUB_CONNECTION_STRING"], process.env["EVENTHUB_NAME"]);
|
||||
|
||||
async function main() {
|
||||
const datas = await receiver.receiveBatch("1", 100 /*number of events*/, 20 /*amount of time in seconds the receiver should run. Default 60 seconds.*/, { eventPosition: EventPosition.fromEnqueuedTime(Date.now()) });
|
||||
const datas = await client.receiveBatch("1", 100 /*number of events*/, 20 /*amount of time in seconds the receiver should run. Default 60 seconds.*/, { eventPosition: EventPosition.fromEnqueuedTime(Date.now()) });
|
||||
console.log("Array of EventData objects", datas);
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче