-
Bug
-
Resolution: Fixed
-
Highest
-
None
-
90
-
Severity 2 - Major
-
66
-
Summary
Running a search calling the REST API endpoint rest/api/2/search (methods GET and POST) returns "Internal Server Error" (error 500) when expanding the changelog.
Steps to Reproduce
- Run a search using the REST API and expand the changelog. For example:
curl -D- -u EMAIL:PASSWORD -H "Accept: application/json" -H "Content-Type: application/json" -X POST -d '{"jql":"key=ISSUE-KEY", "expand": ["changelog"] }' https://INSTANCE/rest/api/2/search
Expected Results
The issue having "key=ISSUE-KEY" is returned.
Actual Results
"HTTP/1.1 500 Internal Server Error" is returned and the below exception is logged by JIRA:
com.atlassian.jira.rest.exception.ExceptionInterceptor Returning internal server error in response java.lang.reflect.InvocationTargetException at sun.reflect.GeneratedMethodAccessor1407.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.atlassian.plugins.rest.common.interceptor.impl.DispatchProviderHelper$TypeOutInvoker$1.invoke(DispatchProviderHelper.java:222) at com.atlassian.plugins.rest.common.interceptor.impl.DispatchProviderHelper$1.intercept(DispatchProviderHelper.java:96) at com.atlassian.plugins.rest.common.interceptor.impl.DefaultMethodInvocation.invoke(DefaultMethodInvocation.java:53) [....] Caused by: java.lang.IllegalArgumentException: Too many entities. Was: 1050, limit: 1000 at com.atlassian.jira.entity.property.JsonEntityPropertyManagerImpl.getPropertiesInternal(JsonEntityPropertyManagerImpl.java:207) at com.atlassian.jira.entity.property.JsonEntityPropertyManagerImpl.get(JsonEntityPropertyManagerImpl.java:201) at com.atlassian.jira.entity.property.BaseEntityPropertyService.getPropertiesWithoutPermissionCheck(BaseEntityPropertyService.java:166) at com.atlassian.jira.issue.changehistory.metadata.DefaultHistoryMetadataManager.getHistoryMetadata(DefaultHistoryMetadataManager.java:67) a...
Notes
Expanding any other property works fine:
curl -D- -u EMAIL:PASSWORD -H "Accept: application/json" -H "Content-Type: application/json" -X POST -d '{"jql":"key=ISSUE-KEY", "expand": ["operations", "renderedFields", "versionedRepresentations", "editmeta"] }' https://INSTANCE/rest/api/2/search ..... HTTP/1.1 200 OK ...... {"expand":"names,schema","startAt":0,"maxResults":50,"total":1,"issues":[{"expand":"operations,versionedRepresentations,editmeta,changelog,renderedFields","id":"22519","self":.... ...
Workaround
We have recently added a new API endpoint to retrieve all the changelog entries for an issue:
Please see the JIRA Cloud REST API Reference for details.
- has a regression in
-
JRACLOUD-76012 Search endpoint returns error 500 when expanding the changelog
- Closed
- is duplicated by
-
JRACLOUD-67490 Search rest requests return http status code 500
- Closed
- is related to
-
JRACLOUD-59998 Limit changelog to 100 entries, and add /changelog endpoint for full history
- Closed
- relates to
-
JRACLOUD-59998 Limit changelog to 100 entries, and add /changelog endpoint for full history
- Closed
-
ACJIRA-940 Loading...
-
ACJIRA-1200 Loading...
-
JCE-1046 Loading...
-
JCE-1409 Loading...
-
JEX-31142 Loading...
-
JEX-31143 Loading...
- has action
-
FD-1180 Loading...
- is caused by
-
JCE-1416 Loading...