Occasional ECONNRESET using API to enumerate Confluence contents

Some time ago we built an integration between our product and Confluence that allows our users to enumerate and inspect the content in a Confluence cloud instance.

In general the integration works fine, but occasionally we will get an ECONNRESET back that we can’t explain. e.g. When attempting to retrieve content by ID. In general if we keep trying to request will eventually succeed.

Looking at our logs, it seems like this was happening quite frequently in Oct and Nov 2022, but seems to have dropped off significantly towards the end of November. That’s a good sign in general but we’re not sure that the problem doesn’t still exist.

What would cause ECONNRESET on an API call like GET /wiki/rest/api/content/{id} ? Is there anything we can do on our end to avoid this?

And given that a) this was happening a lot in Oct and Nov, and b) there are no reported instances of it in Dec, is it possible that something was fixed on the Confluence side to make this better? We haven’t made any changes to this integration since August 2022.

FWIW we have similar integrations to other cloud services and Confluence is the only one of its kind that has this ECONNRESET issue.

We also see this once in a while with different Confluence instances. No idea about the cause.