You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@devlake.apache.org by "eMurgaNd (via GitHub)" <gi...@apache.org> on 2023/04/11 22:32:24 UTC
[GitHub] [incubator-devlake] eMurgaNd opened a new issue, #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
eMurgaNd opened a new issue, #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903
### Search before asking
- [X] I had searched in the [issues](https://github.com/apache/incubator-devlake/issues?q=is%3Aissue) and found no similar issues.
### What happened
The Jira plugin is requesting the first 100 Jira issues but is not paginating to the rest, I have 17000+ Jira issues total.
I came across this issue because I was trying to find why no "Incident" Jira Issues were found by DevLake. I was creating the Jira integration for the first time so this pipeline should have fetched all of the Jira issues. While going through the debug logs I saw that lake does start one iteration of a fetch from Jira `maxResults:[100] startAt:[0]`, but it does not make any more requests after that.
The following is the relevant log. You can see that the collectIssues function runs the query once and then says that it has completed the collection without error. The same exists for the HTTP client log, only 1 HTTP request was made to Jira.
```
time="2023-04-11 13:51:26" level=info msg=" [pipeline service] [pipeline #2] [task #2] [collectIssues] finished records: 1"
time="2023-04-11 13:51:26" level=debug msg=" [pipeline service] [pipeline #2] [task #2] [collectIssues] fetchAsync >>> done for agile/1.0/board/1302/issue map[expand:[changelog] jql:[updated >= '2023/04/11 20:20' AND updated >= '2022/10/11 00:00' AND created is not null ORDER BY created ASC] maxResults:[100] startAt:[0]] <nil>"
time="2023-04-11 13:51:26" level=debug msg=" [pipeline service] [pipeline #2] [task #2] [api async client] schedulerJob <<< 4 ended"
time="2023-04-11 13:51:26" level=info msg=" [pipeline service] [pipeline #2] [task #2] [collectIssues] end api collection without error"
```
I should see the API request log 173 times total while it increased the `startAt:[0]` value each iteration.
I believe this issue would exist for daily pipelines along with this first run. If someone has over 100 updated issues in a day I think it would miss the newest tickets over 100.
### What do you expect to happen
I expect the Jira plugin to iterate through all 17000+ Jira Issues when I create the integration.
### How to reproduce
All you have to do is create and run a new Jira blueprint where the target board has over 100 Issues.
### Anything else
I'm running version 0.16.0-beta11
### Version
main
### Are you willing to submit PR?
- [X] Yes I am willing to submit a PR!
### Code of Conduct
- [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] eMurgaNd closed issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "eMurgaNd (via GitHub)" <gi...@apache.org>.
eMurgaNd closed issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
URL: https://github.com/apache/incubator-devlake/issues/4903
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] eMurgaNd commented on issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "eMurgaNd (via GitHub)" <gi...@apache.org>.
eMurgaNd commented on issue #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903#issuecomment-1504641739
@klesh i also realized I forgot to answer your question about the Jira version:
```
"version": "8.20.11",
"versionNumbers": [
8,
20,
11
],
"deploymentType": "Server",
"buildNumber": 820011,
```
I'm running devlake `0.16.0-beta11` but it was not an option in the version dropdown.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] klesh commented on issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "klesh (via GitHub)" <gi...@apache.org>.
klesh commented on issue #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903#issuecomment-1504421861
Hi, @eMurgaNd , Thanks for the quick response.
What is your jira version? is it cloud or server?
Can you try the following curl command and let me know the pagination information from the response?
Keep in mind to use the same account/password or token from the `config-ui` jira connection page.
Assuming you are using `BasicAuth`
```
curl -u <user>:<pass> 'https://jira.local/rest/agile/1.0/board/1302/issue?expand=changelog&jql=updated+%3E%3D+%272022%2F10%2F11+00%3A00%27+AND+created+is+not+null+ORDER+BY+created+ASC&maxResults=100&startAt=0'
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] klesh commented on issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "klesh (via GitHub)" <gi...@apache.org>.
klesh commented on issue #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903#issuecomment-1504386829
Hi, @eMurgaNd , Seems like the incremental sync was kicked in, judged by the time condition, I believe it is correct to fetch only one page.

--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] eMurgaNd commented on issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "eMurgaNd (via GitHub)" <gi...@apache.org>.
eMurgaNd commented on issue #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903#issuecomment-1504550676
@klesh here is the reply minus the jira issues:
```
{
"expand": "schema,names",
"startAt": 0,
"maxResults": 100,
"total": 17324,
"issues": [
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] klesh commented on issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "klesh (via GitHub)" <gi...@apache.org>.
klesh commented on issue #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903#issuecomment-1504697404
@mindlesscloud this one as well
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] klesh commented on issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "klesh (via GitHub)" <gi...@apache.org>.
klesh commented on issue #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903#issuecomment-1504582909
@eMurgaNd Thanks, what is your devlake version? I see you selected the `main`, did you build it yourself? Can I have the `commit_sha`?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] eMurgaNd commented on issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "eMurgaNd (via GitHub)" <gi...@apache.org>.
eMurgaNd commented on issue #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903#issuecomment-1522407992
It was definitely the silent permission issue on my side. It's all working now, thank you for your help/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] eMurgaNd closed issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "eMurgaNd (via GitHub)" <gi...@apache.org>.
eMurgaNd closed issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
URL: https://github.com/apache/incubator-devlake/issues/4903
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] eMurgaNd commented on issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "eMurgaNd (via GitHub)" <gi...@apache.org>.
eMurgaNd commented on issue #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903#issuecomment-1504398512
@klesh good catch it seems I uploaded the wrong log lines. The following are from the first execute that I mentioned:
```
time="2023-04-11 13:20:18" level=info msg=" [pipeline service] [pipeline #1] [task #1] finished step: 6 / 29"
time="2023-04-11 13:20:18" level=info msg=" [pipeline service] [pipeline #1] [task #1] executing subtask collectIssues"
time="2023-04-11 13:20:18" level=info msg=" [pipeline service] [pipeline #1] [task #1] [collectIssues] start api collection"
time="2023-04-11 13:20:18" level=debug msg=" [pipeline service] [pipeline #1] [task #1] [collectIssues] fetchAsync <<< enqueueing for agile/1.0/board/1302/issue map[expand:[changelog] jql:[updated >= '2022/10/11 00:00' AND created is not null ORDER BY created ASC] maxResults:[100] startAt:[0]]"
time="2023-04-11 13:20:18" level=debug msg=" [pipeline service] [pipeline #1] [task #1] [collectIssues] fetchAsync === enqueued for agile/1.0/board/1302/issue map[expand:[changelog] jql:[updated >= '2022/10/11 00:00' AND created is not null ORDER BY created ASC] maxResults:[100] startAt:[0]]"
time="2023-04-11 13:20:18" level=debug msg=" [pipeline service] [pipeline #1] [task #1] [collectIssues] wait for all async api to be finished"
time="2023-04-11 13:20:18" level=debug msg=" [pipeline service] [pipeline #1] [task #1] [api async client] schedulerJob >>> 4 started"
time="2023-04-11 13:20:18" level=debug msg=" [pipeline service] [pipeline #1] [task #1] [api async client] endpoint: agile/1.0/board/1302/issue method: GET header: map[] body: %!s(<nil>) query: map[expand:[changelog] jql:[updated >= '2022/10/11 00:00' AND created is not null ORDER BY created ASC] maxResults:[100] startAt:[0]]"
time="2023-04-11 13:20:18" level=debug msg=" [pipeline service] [pipeline #1] [task #1] [api-client] GET https://jira.local/rest/agile/1.0/board/1302/issue?expand=changelog&jql=updated+%3E%3D+%272022%2F10%2F11+00%3A00%27+AND+created+is+not+null+ORDER+BY+created+ASC&maxResults=100&startAt=0"
time="2023-04-11 13:20:18" level=info msg=" [pipeline service] [pipeline #1] [task #1] [collectIssues] finished records: 1"
time="2023-04-11 13:20:18" level=debug msg=" [pipeline service] [pipeline #1] [task #1] [collectIssues] fetchAsync >>> done for agile/1.0/board/1302/issue map[expand:[changelog] jql:[updated >= '2022/10/11 00:00' AND created is not null ORDER BY created ASC] maxResults:[100] startAt:[0]] <nil>"
time="2023-04-11 13:20:18" level=debug msg=" [pipeline service] [pipeline #1] [task #1] [api async client] schedulerJob <<< 4 ended"
time="2023-04-11 13:20:18" level=info msg=" [pipeline service] [pipeline #1] [task #1] [collectIssues] end api collection without error"
time="2023-04-11 13:20:18" level=info msg=" [pipeline service] [pipeline #1] [task #1] finished step: 7 / 29"
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] mindlesscloud commented on issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "mindlesscloud (via GitHub)" <gi...@apache.org>.
mindlesscloud commented on issue #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903#issuecomment-1508358299
@eMurgaNd Thank you for taking the time to report the issue. However, in order for us to effectively address the issue, we would require more information on how to reproduce the bug. Could you provide more specific details on the steps taken to encounter the bug?
Additionally, have you tried deploying the service with docker-compose? This information would be helpful for us to further investigate and resolve the issue.
Thank you for your assistance in this matter. We appreciate your efforts to help us improve the service.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-devlake] eMurgaNd commented on issue #4903: [Bug][Jira] Jira Plugin Fails to Paginate Through Issues
Posted by "eMurgaNd (via GitHub)" <gi...@apache.org>.
eMurgaNd commented on issue #4903:
URL: https://github.com/apache/incubator-devlake/issues/4903#issuecomment-1521182253
@mindlesscloud I did some more digging and it seems that my testing was flawed. The Jira service account I was using with DevLake did not have the same permissions as myself while viewing Jira. I got the permission issue resolved and now DevLake is seeing Jira Issues. I just need to run another onboarding test to see if DevLake processes the 17300 Jira Issues then I can close this GitHub Issue.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@devlake.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org