Search functionality is not working after an upgrade of Bitbucket Data Center to 9.4 and later

Platform Notice: Data Center Only - This article only applies to Atlassian apps on the Data Center platform.

Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Summary

This article covers how to resolve search functionality not working after upgrading Bitbucket Data Center to 9.4 or later.

Diagnosis

Check application logs

Review the atlassian-bitbucket.log file and find that the search URL is pointing to localhost instead of the external host URL.

2025-07-09 05:31:54,193 DEBUG [Caesium-1-3] c.a.e.c.a.h.ApacheRequestExecutor Configure client to use server URL: 'http://localhost:7992/' 2025-07-09 05:31:54,194 DEBUG [Caesium-1-3] o.a.h.impl.nio.client.MainClientExec [exchange: 25] start execution 2025-07-09 05:31:54,194 DEBUG [Caesium-1-3] o.a.h.c.protocol.RequestAddCookies CookieSpec selected: default 2025-07-09 05:31:54,195 DEBUG [Caesium-1-3] o.a.h.c.protocol.RequestAuthCache Re-using cached 'basic' auth scheme for http://localhost:7992 2025-07-09 05:31:54,195 DEBUG [Caesium-1-3] o.a.h.c.protocol.RequestAuthCache No credentials for preemptive authentication 2025-07-09 05:31:54,195 DEBUG [Caesium-1-3] o.a.h.i.n.c.InternalHttpAsyncClient [exchange: 25] Request connection for {}->http://localhost:7992 2025-07-09 05:31:54,195 DEBUG [Caesium-1-3] o.a.h.i.n.c.PoolingNHttpClientConnectionManager Connection request: [route: {}->http://localhost:7992][total kept alive: 0; route allocated: 0 of 2; total allocated: 0 of 20] 2025-07-09 05:31:54,195 DEBUG [pool-60-thread-1] o.a.h.i.n.c.PoolingNHttpClientConnectionManager Connection request failed java.net.ConnectException: Connection refused at java.base/sun.nio.ch.Net.pollConnect(Native Method) at java.base/sun.nio.ch.Net.pollConnectNow(Net.java:672) at java.base/sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:946) at org.apache.http.impl.nio.reactor.DefaultConnectingIOReactor.processEvent(DefaultConnectingIOReactor.java:174) at org.apache.http.impl.nio.reactor.DefaultConnectingIOReactor.processEvents(DefaultConnectingIOReactor.java:148) at org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor.execute(AbstractMultiworkerIOReactor.java:351) at org.apache.http.impl.nio.conn.PoolingNHttpClientConnectionManager.execute(PoolingNHttpClientConnectionManager.java:221) at org.apache.http.impl.nio.client.CloseableHttpAsyncClientBase$1.run(CloseableHttpAsyncClientBase.java:64) at java.base/java.lang.Thread.run(Thread.java:842)

Check Bitbucket properties config

  • Navigate to <Bitbucket_Home>/shared/ directory and open bitbucket.properties.

  • Search for the following properties:

    plugin.search.elasticsearch.baseurl= plugin.search.elasticsearch.username= plugin.search.elasticsearch.password=
  • If the properties exist, you are impacted by this KB.

Cause

After upgrading to Bitbucket 9.4 and later, the deprecated search configuration properties

plugin.search.elasticsearch.baseurl= plugin.search.elasticsearch.username= plugin.search.elasticsearch.password=

in the bitbucket.properties file were ignored. As a result, Bitbucket defaulted to using http://localhost:7992 for search, causing connection failures because the search service was not running on localhost.

Solution

Replace the above deprecated entries in the bitbucket.properties file with the following properties as mentioned in the Configuration Properties document:

plugin.search.config.baseurl= plugin.search.config.username= plugin.search.config.password=

After updating the properties file, it is required to restart Bitbucket for the changes to take effect.

Updated on September 26, 2025

Still need help?

The Atlassian Community is here for you.