nodejs / node

Node.js JavaScript runtime βœ¨πŸ’πŸš€βœ¨
https://nodejs.org
Other
107.72k stars 29.66k forks source link

Performance issue with Node js version 20 and version 22 #55443

Closed richakhosla closed 3 weeks ago

richakhosla commented 3 weeks ago

we are facing issue with respect to Node js application deployed on BTP Cloud foundry Canada region. Please find more details below :

This application internally calls https REST endpoint in Convergent mediation system(On premise) we are on Node js version 20 and using sap-cf-axios latest to send request to convergent mediation system(On premise ) via cloud connector .The connectivity is made using Destination which is maintained in BTP subaccount.

Issue : The performance is bad when we use Node js version 20/22with stated axios Library. However, if we switch to Node js version 18 and same current library performance is way better.

For comparison, please find stats below πŸ‘

Node js 20 with sap-cf-axios image

Node js 18 with sap-cf-axios image

Sample code below

let SapCfAxios = require('sap-cf-axios').default;

let callSoapApi = async (data, req, res) => { try { let axios = SapCfAxios("Destination_name"); let dataResp = await axios({ method: "POST", url: req.url, data: data, headers: { SOAPAction: "SOAP ACTION NAME", // Replace with your SOAP action } }); res.status(200).send(dataResp.data); } catch (error) { generateErrorMessage(req,res,error); //Separate function for error handling } }

RedYetiDev commented 3 weeks ago

The library in question is not maintained by Node.js.