When api work on less data $http.post() gets response but when working with large data the api takes time (like 2-3 min) but on front-end angularjs do not get any response. I check on the backend(nodejs) the code is working and also returns data which does not get response on angular side while the api takes time to return else when working on less data it works fine.
$http.post('/campaign/addInventorytocampaign', params).then(function (addInventorydata) {
console.log("addInventorydata = ",addInventorydata.data);});
The error i get in console is
angular.min.js:11756 POST http://localhost:3000/campaign/addInventorytocampaign net::ERR_EMPTY_RESPONSE
While the backend is still in process
is there any way/correct way to do it