final URI baseUri = UriBuilder.fromUri(serverUri).path("/rest/api/latest").build();
final HttpClient httpClient =
new AsynchronousHttpClientFactory().createClient(serverUri, new BasicHttpAuthenticationHandler(username,
password));
jiraRestClient = new AsynchronousJiraRestClientFactory().create(serverUri, httpClient);
userRestClient = new OesbAsynchronousUserRestClient(baseUri, httpClient);
}