when call adapter to adapter using AdaptersAPI in java , getting response as rabish if it contains Arabic letters. below snippet of my code
HttpEntity requestEntity = new StringEntity(new Gson().toJson(params),
ContentType.APPLICATION_JSON );
HttpPost httpPost = new HttpPost(url);
httpPost.setEntity(requestEntity);
HttpResponse httpResp = adaptersAPI.executeAdapterRequest(httpPost);
JSONObject response = adaptersAPI.getResponseAsJSON(httpResp);
the problem was found in parsing of json > adaptersAPI.getResponseAsJSON(httpResp);
my issue resolved by:
adding this property -Dfile.encoding=UTF-8
in "jvm.options" ,or change json parsing method