Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Log request that uses the REST api

Gordon Andersen September 10, 2019

Hi,

I trying to debug a performance problem in our Jira Server (v 7.11) installation.

We have a lot of users using BI to extract management reports. The reports use Jira REST to extract data. I have no exact numbers on how many extract data using BI. We maybe think the performance issues can relate to this massive data extraction.

Is there a log in Logging that I can enable/verbose to log request to JIRA based on REST calls?

 

2 answers

2 accepted

0 votes
Answer accepted
DPKJ
Community Champion
September 10, 2019

@Gordon Andersenyou can have access_log enabled for your Jira. There will file name access_log.xxx (where xxx date) in <JIRA_INSTALLATION>/logs/ directory.

Later you can you this tool ( https://confluence.atlassian.com/enterprise/jira-access-log-analyzer-687025035.html ) provided by Atlassian to analyze it.

This is best solution I know of so far.

0 votes
Answer accepted
Ravi Sagar _Sparxsys_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 10, 2019

Hi @Gordon Andersen 

You can use a log analyser to look into atlassian-jira-http-access.log (check if HTTP access log is enabled in System | Logging and profiling).

The request using REST api will have a specific pattern in the URL. Now Jira also uses internally REST api so it could be little tricky but internal requests have separate HTTP referrer and it would be your Jira base url.

Internal REST requests would be like this.

0:0:0:0:0:0:0:1 i937x6071x1 admin [14/Aug/2019:15:37:45 +0000] "GET https://JIRAURL/rest/api/1.0/menus/greenhopper_menu HTTP/1.1" - - - "https://JIRAURL/secure/Dashboard.jspa" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.80 Safari/537.36" "l6fov2"
0:0:0:0:0:0:0:1 o937x6071x1 admin [14/Aug/2019:15:37:45 +0000] "GET https://JIRAURL/rest/api/1.0/menus/greenhopper_menu HTTP/1.1" 200 672 0.0100 "https://JIRAURL/secure/Dashboard.jspa" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.80 Safari/537.36" "l6fov2"
0:0:0:0:0:0:0:1 i943x6228x1 admin [14/Aug/2019:15:43:37 +0000] "GET https://JIRAURL/rest/api/2/filter/favourite HTTP/1.1" - - - "https://JIRAURL/issues/?jql=" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.80 Safari/537.36" "l6fov2"
0:0:0:0:0:0:0:1 i949x6396x1 admin [14/Aug/2019:15:49:58 +0000] "GET https://JIRAURL/rest/api/2/issue/10812/subtask/move HTTP/1.1" - - - "https://JIRAURL/issues/?filter=10100" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.80 Safari/537.36" "l6fov2"
0:0:0:0:0:0:0:1 o949x6396x1 admin [14/Aug/2019:15:49:58 +0000] "GET https://JIRAURL/rest/api/2/issue/10812/subtask/move HTTP/1.1" 200 4 0.0030 "https://JIRAURL/issues/?filter=10100" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.80 Safari/537.36" "l6fov2"

External REST requests would be like this.

0:0:0:0:0:0:0:1 i937x6073x1 admin [14/Aug/2019:15:37:48 +0000] "GET https://JIRAURL/rest/api/latest/issue/SD-13 HTTP/1.1" - - - - "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.80 Safari/537.36" "l6fov2"
0:0:0:0:0:0:0:1 o937x6073x1 admin [14/Aug/2019:15:37:48 +0000] "GET https://JIRAURL/rest/api/latest/issue/SD-13 HTTP/1.1" 200 8078 0.0320 - "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.80 Safari/537.36" "l6fov2"
0:0:0:0:0:0:0:1 i947x6381x1 admin [14/Aug/2019:15:47:30 +0000] "GET https://JIRAURL/rest/api/latest/search/filter=10100 HTTP/1.1" - - - - "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.80 Safari/537.36" "l6fov2"

I hope it helps.

Ravi 

Gordon Andersen September 10, 2019

Hi @Ravi Sagar _Sparxsys_ 

Super, I will look into that. Any advice on a god log analyzer?

Suggest an answer

Log in or Sign up to answer