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

JQL Query in Confluence "Unable to generate JSON output" for more than one JIRA 5.0.6 Issue

jhgorse July 4, 2012

JIRA 5.0.6
Confluence 4.2.6
Host: ESXi 4.1
Guest OS: FreeBSD 9.0, openjdk6-b24, Apache 2.2 mod_proxy and name-based virtual host to wiki.domain.tld & jira.domain.tld

While following these documented processes for inserting the results of a JQL query

the Jira Issues Macro, such as project = DRA on the Confluence Page never gets past this error message once it attempts to render the page:

Unable to generate JSON output class java.io.IOException

The EDIT page properly shows the macro JIRA | project = DRA. The EDIT and Rendered Page show individual JIRA Issues perfectly, just not the list.

Anonymous access to JIRA Issues does not resolve the issue.

Below is a snippet of the logs/atlassian-confluence.log:

2012-07-05 11:46:00,949 WARN [http-8090-9] [confluence.extra.jira.JiraIssuesServlet] doGet An IO Exception has been encountered: Unable to generate JSON output
 -- url: /plugins/servlet/issue-retriever | userName: admin | referer: http://wiki.domain.tld/display/DRA/Dashboard
java.io.IOException: Unable to generate JSON output
	at com.atlassian.confluence.extra.jira.JsonFlexigridResponseGenerator.generate(JsonFlexigridResponseGenerator.java:324)
	at com.atlassian.confluence.extra.jira.JiraIssuesServlet.getResult(JiraIssuesServlet.java:210)
	at com.atlassian.confluence.extra.jira.JiraIssuesServlet.doGet(JiraIssuesServlet.java:120)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
... snip...
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)
	at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
	at java.lang.Thread.run(Thread.java:679)
Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -1
	at java.lang.String.substring(String.java:1949)
	at com.atlassian.confluence.extra.jira.JsonFlexigridResponseGenerator.getOutputAsString(JsonFlexigridResponseGenerator.java:269)
	at com.atlassian.confluence.extra.jira.JsonFlexigridResponseGenerator.generate(JsonFlexigridResponseGenerator.java:320)
	... 132 more

Request support for how to further troubleshoot and ultimately resolve the perceived lack of JQL functionality in Confluence.

Cheers,
Joe

P.S. Please use the same markup/down between Answers Atlassian and Confluence/JIRA from Support.

3 answers

2 votes
jhgorse July 5, 2012

Mr. Kazatchkov correctly identified this as a bug with the default language in JIRA being English (en) as opposed to either English UK (en-uk) or English US (en-us). Apparently, the lack of the "-" character causes this StringIndexOutOfBoundsException.

Change the default Language in JIRA from English (Default) to English US did the trick for me.

A big thanks to the Atlassian Support Team for identifying the fix! Great job.

0 votes
Mik_P February 6, 2013

I already have English UK/US but an issue appears with one particular jira-issue.

Any ideas what should I check in current jira-issue to avoid an error?

0 votes
Eric Wang December 9, 2012

How to fix, the default language is Chinese.

Eric Wang December 9, 2012

How to fix, the default language is Chinese.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events