Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,555,110
Community Members
 
Community Events
184
Community Groups

Calling Jira Edit Issue API from AWS Lambda Times out

Edited
ted_s
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!
Mar 24, 2023

Hi,

I am running into an issue where calling my lambda function locally through serverless offline runs smoothly and updates the Jira Issue successfully with the payload I passed in.

But when I deploy the Lambda to AWS and then trigger the function through Postman with the same payload, the connection to the Jira API times out.

Here is a snippet of my lambda service:

 

import { Version3Client } from "jira.js";
export const client = new Version3Client({

  host: process.env["JIRA_HOST"],

  authentication: {

    basic: {

      email: process.env["JIRA_USERNAME"],

      apiToken: process.env["JIRA_API_TOKEN"],

    },

  },

  newErrorHandling: true,

});
      client.issues.editIssue(

        {

          issueIdOrKey: issueKey,

          fields: {

            ...convertedPayload,

          },

        },

      );

 

As I stated above, when triggered locally through Postman and serverless offline, this code will update the ticket on my board on Jira within a second without any issues.

But when deploying to AWS Lambda and calling the API Gateway endpoint that triggers the lambda through Postman, the call to Jira will hang until it times out.

Does anyone know what may be happening? I figure that Jira is blocking the call.

Any help is appreciated. Cheers

1 answer

0 votes
ted_s
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!
Mar 29, 2023

I ended up solving the issue. It turned out to be an async issue where a call was never returned correctly, so the Lambda service calling the Jira API just timed out waiting for a response.

Suggest an answer

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

Atlassian Community Events