How to handle the request that need a long period of time.

huojia
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 28, 2024

I read from this topic that the time allowed to process jira app event is no more than 25 seconds.  

  • When using Forge Tunnel, we may encounter the following error if a timeout occurs: ERROR 407 - PROXY_UNAUTHORIZED 
  • When using deployed forge app and the program exceeds 25 seconds, it will be automatically terminated.

And the only suggestion is to split the work into small pieces, the serve will auto process these works parallelly. 

But What if a single request already exceeds 25 seconds, what should i do? (Because during event processing, i need to make requests to external servers to fetch certain data and using the response to do something.)

Here are the possible approaches I think can be implemented:

  1. Register an Endpoint in the Jira app: register an endpoint in my Jira app. When making requests to the external server, include the relevant endpoint information in the payload. After the server processes the request, it can send a request to the endpoint, and the endpoint can handle the logic for responding.

  2. Submit the Tasks to Atlassian Servers: Submit the tasks that require longer execution time to the Atlassian servers for processing. This allows the tasks to be executed on the server side, bypassing the 25-second timeout limitation.

0 answers

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
TAGS
AUG Leaders

Atlassian Community Events