How can I fix delays in Terra payloads?

BasicScorpion7 months ago

When I authenticate a user or make a HTTP request with to_webhook there is a significant delay, however if I make a HTTP request without to_webhook, the request takes less than 1 second. Wondering if anyone has experienced this issue?

terra

Matthewadmin7 months ago

Hey there

To diagnose this issue, please go onto the dashboard and use the debug tools by navigating to [Dashboard > Tools > Debug > Event Log] and identifying the payload that is affected. Then click the arrow on the right to pullup more details about the event and look at the response time. If you notice that the response time is very large (>2000ms), the issue is most likely caused by your server taking very long to respond to the post request we make to your webhook.


BasicScorpion7 months ago

Some events do report very large response times 5000-12000ms, what could be causing this and how can we fix this?


terra

Matthewadmin7 months ago

Slow server responses could caused by server-overload, if your server is unable to handle the number of requests Terra is sending, if your server is unable to handle multiple requests concurrently or does not have sufficient resources to manager large amounts of traffic, you should consider scaling your ingestion service (allocating more resources).

Or, there may be long synchronous queries being run on your webhook endpoint (to your database or other) that is stalling the response. Look through any queries you are making and optimise your queries or execute them asynchronously.


Cookie Preferences

Essential CookiesAlways On
Advertisement Cookies
Analytics Cookies

Crunch Time: Embrace the Cookie Monster Within!

We use cookies to enhance your browsing experience and analyse our traffic. By clicking “Accept All”, you consent to our use of cookies according to our Cookie Policy. You can change your mind any time by visiting out cookie policy.