I have a simple function
const y = await goToFirestore;
const x =await axios.post('third-party',{}). // this could take 10-20 seconds
const v = const x =await axios.post('third-party/another',{}). // this could take another 10-20 seconds. but this has to wait to the previous one
return x;
my question is . in this situation i have only 5 instance up and running (max)
means i can handle only 5 multiple requests what will happen if i will have 20 multiple requests . this means they will wait ??
firebase run instance per request ? there is no support of multiple request?
how can I change the logic
is it possible to return immidiate res.end() to the client (another http app) and give the code run in the background with pub/sub or smth ?
how it will affect in case of lot of requests ? the pub-sub will wait ?
is that means that firebase cloud functions does not fit my needed ?
is cqrs could be a good option for this ?