Project

General

Profile

Bug #2190

Unable to generate the 'Top Traffic' report from the GUI on production.

Added by Ayush Khandelwal over 2 years ago. Updated almost 2 years ago.

Status:
Closed
Priority:
High
Assignee:
Target version:
Start date:
03/16/2022
Due date:
10/14/2022
% Done:

100%

Estimated time:
3.00 h
Spent time:


Related issues

Related to Support #1622: Add 'Reports -> Top traffic'Closed09/09/2021Ram Kordale

Actions
#1

Updated by Venmuhilan B over 2 years ago

  • Status changed from New to In Progress
#2

Updated by Venmuhilan B over 2 years ago

The response for the request Url:

"files": [ {
"kind": "drive#file",
"id": "1Ub4roUaaO4W9R8Tba0zFE5AsSZ-wBzvq",
"name": "Prod",
"mimeType": "application/vnd.google-apps.folder"
}, {
"kind": "drive#file",
"id": "1wgGhfGFM8fDaXI62xpje8MoMhA6Wq_Ld",
"name": "prod",
"mimeType": "application/vnd.google-apps.folder"
}, {
"kind": "drive#file",
"id": "1SzmNJviLic3al-1dwmZbWJexvFfk4AcQ",
"name": "Prod",
"mimeType": "application/vnd.google-apps.folder"
}
]
}

There are three folders data present in the response. In the response, it is supposed to have only one folder.But here it had fetched 3 folders. So we are returning the first drive file object (i-e)in the response to ReportGenerationAPI, it is returning the object which is having "id": "1Ub4roUaaO4W9R8Tba0zFE5AsSZ-wBzvq","name": "Prod"

But there is no folder named "Prod" in this https://drive.google.com/drive/folders/1Zi7cD085GyhX6ZaW1h7tLl6pkeYfzh6F . It didn't have an outputs folder. So the drive file object becomes null and showed a null pointer exception.

The second drive file object("id": "1wgGhfGFM8fDaXI62xpje8MoMhA6Wq_Ld", "name": "prod") is the one which is present in the https://drive.google.com/drive/folders/1Zi7cD085GyhX6ZaW1h7tLl6pkeYfzh6F.

fix - Iterate over the files array until we found the drive object which has the outputs folder

#3

Updated by Venmuhilan B over 2 years ago

  • Status changed from In Progress to Resolved
#4

Updated by Venmuhilan B over 2 years ago

  • % Done changed from 0 to 100
#5

Updated by Ram Kordale over 2 years ago

  • Priority changed from Urgent to High
#6

Updated by Ayush Khandelwal about 2 years ago

  • Due date changed from 03/16/2022 to 10/14/2022
  • Status changed from Resolved to Reopened
  • % Done changed from 100 to 0
  • Estimated time changed from 2.00 h to 3.00 h
#7

Updated by Ayush Khandelwal about 2 years ago

  • Parent task deleted (#1622)
#8

Updated by Ayush Khandelwal about 2 years ago

#9

Updated by Venmuhilan B about 2 years ago

  • Status changed from Reopened to In Progress
#10

Updated by Venmuhilan B about 2 years ago

Issue:
java.lang.ArrayIndexOutOfBoundsException occured at processMessage() method in ReadJsonPayloadLogs class.

The error occurred at line 87 where we put a key( like url, userAgent, ..) and their value into the map. we are splitting the string by ":" (i-e "url:/learn/python3-docs"). I think the value part is not present for some key. It showed Array Index Out of Bounds Exception while accessing that index.

For the String accept-language: it only the have the key and don't have the value.
After the String is splitted, Array only have one element(pair0) and we are trying to access the value part(pair1) which is not present in the array.
This lead to java.lang.ArrayIndexOutOfBoundsException.

Fix:
we can add the condition to access the pair1 only if the array length is 2.

#11

Updated by Venmuhilan B about 2 years ago

  • Status changed from In Progress to Resolved
  • % Done changed from 0 to 100
#12

Updated by Venmuhilan B about 2 years ago

  • Status changed from Resolved to Feedback
  • Assignee changed from Venmuhilan B to Ayush Khandelwal
#13

Updated by Ayush Khandelwal about 2 years ago

  • Assignee changed from Ayush Khandelwal to Ram Kordale

Working as expected

#14

Updated by Ram Kordale almost 2 years ago

  • Status changed from Feedback to Closed

Also available in: Atom PDF