Encoding issue using Confluence content search



This issue is the same as https://ecosystem.atlassian.net/browse/JSDECO-77.

We’re building an app for JSD Server that themes and organize the customer portal (RefinedTheme for JSD). In this app the user can setup a knowledge base with Confluence instances to search for Confluence content articles and questions.
We’re using the /rest/api/content/search. It looks like the returning response has weird encoding:
“title”:“Another article aboüt VPN (Велград) (СегоднÑ?шний)”
It should be:
“title”:“Another article aboüt VPN (Белград) (Сегодняшний)”
We’ve tried different setups and concluded that the problem seems to be related to the System encoding of the Jira server. When it is UTF-8 we get the correct response and when it is Cp1252 (Windows) we get the weird one.
We don’t have the issue with the /rest/questions/1.0/search API point.

Does anyone know what could be done about this?


Hi @julia,

Am I correct in the assumption that it’s the Confluence server API that’s causing this problem?
And not the JSD or Jira one?


Hi @pvandevoorde,

The issue seems to stem from the combination of the Confluence API and Jira server.


Hey @julia,

It’s clear now that it’s indeed a problem caused by Jira using the default encoding of the operating system it runs on. Which is ‘Cp1252’ for Windows. This encoding has problems with Non-ASCII characters.

A workaround can be found here: https://confluence.atlassian.com/jirakb/jira-application-internationalisation-and-encoding-troubleshooting-203394762.html

For Confluence this seems to have been solved already, see here: https://confluence.atlassian.com/conf510/configuring-url-encoding-on-tomcat-application-server-829078125.html


Thanks for your answer!