java jira rest client timeout issue

I get `` when searching in jira. How can I increase the timeout ?


JiraRestClientFactory restClientFactory = new AsynchronousJiraRestClientFactory();
SearchResult results = null;

try {
URI uri = new URI(jira_url);
restClient = restClientFactory.createWithBasicHttpAuthentication(uri, jira_username, jira_password);
final SearchRestClient searchClient = restClient.getSearchClient();
String jql = searchClient.getFilter(jira_filterid).get().getJql();
// setting max result to 1000 and start with 0
results = searchClient.searchJql(jql, 500, 0).claim();
System.out.println("Took: " + stopWatch.toString() + " to find " + results.getTotal() + " case in jira filter with id " + jira_filterid);
} catch (Exception e) {
return results;

The searching should not take so long, i think it is when doing claim().


at com.atlassian.httpclient.apache.httpcomponents.DefaultHttpClient$3.apply(
at com.atlassian.httpclient.apache.httpcomponents.DefaultHttpClient$3.apply(
at com.atlassian.util.concurrent.Promises$Of$2.apply(
at com.atlassian.util.concurrent.Promises$Of$2.apply(
at com.atlassian.util.concurrent.Promises$2.onFailure(
at com.atlassian.httpclient.apache.httpcomponents.SettableFuturePromiseHttpPromiseAsyncClient$1$
at com.atlassian.httpclient.apache.httpcomponents.SettableFuturePromiseHttpPromiseAsyncClient$ThreadLocalDelegateRunnable$
at com.atlassian.httpclient.apache.httpcomponents.SettableFuturePromiseHttpPromiseAsyncClient.runInContext(
at com.atlassian.httpclient.apache.httpcomponents.SettableFuturePromiseHttpPromiseAsyncClient$
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(
at java.util.concurrent.ThreadPoolExecutor$
Caused by:
at org.apache.http.nio.protocol.HttpAsyncRequestExecutor.timeout(
at org.apache.http.impl.nio.client.LoggingAsyncRequestExecutor.timeout(
at org.apache.http.impl.nio.DefaultHttpClientIODispatch.onTimeout(
at org.apache.http.impl.nio.DefaultHttpClientIODispatch.onTimeout(
at org.apache.http.impl.nio.reactor.AbstractIODispatch.timeout(
at org.apache.http.impl.nio.reactor.BaseIOReactor.sessionTimedOut(
at org.apache.http.impl.nio.reactor.AbstractIOReactor.timeoutCheck(
at org.apache.http.impl.nio.reactor.BaseIOReactor.validate(
at org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(
at org.apache.http.impl.nio.reactor.BaseIOReactor.execute(
at org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$
... 1 more

2 answers



Even i am getting same issue. Any solutions so far?

Thanks in advance.



Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

2,755 views 11 18
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot