0

I'm using Google Videointelligence API and according the documentation of the Quota & Limits, I can process ~3 videos parallel (and it works fine), but when I process more then 3 videos in parallel, exception was thrown.

The issue is that I can't catch this exception!

The exception: (node:31660) UnhandledPromiseRejectionWarning: Error: 8 RESOURCE_EXHAUSTED: Quota exceeded for quota metric 'Requests' and limit 'Requests per minute' of service 'videointelligence.googleapis.com' for consumer 'project_number:852521347926'.

I'm writing in node.js.

the code is just like the example:

const [operation] = await client.annotateVideo(request);
logger.debug('Waiting for enrichment operation to complete...');
try{
        const [operationResult] = await operation.promise(); //Exception was thrown on this line
}catch(err){
        console.log("exception was caught");//failed to catch the exception
}
  • That looks like an appropriate error for when you go over quota. What are you expecting to happen? – Brendan Apr 18 '20 at 21:02
  • I have the same issue. And like OP said, I can't catch that exception. I tried attaching an event listener on the `operation` object but it didn't work. – Duc Nguyen Mar 11 '21 at 07:14

0 Answers0