Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Search for code in files larger than 512kib

Can we configure BitBucket Server Code Search to index files larger than 512 KiB?

Here it mentions: "Only files smaller than 512 KiB are searchable."

https://confluence.atlassian.com/bitbucketserver/search-for-code-in-bitbucket-server-814204781.html

My git repository contains many .sql files at around 10mb.

Is this 512 kib limit hardcoded or configurable?

1 answer

0 votes

Hi @RyanM 

I looked at https://confluence.atlassian.com/bitbucketserver/bitbucket-server-config-properties-776640155.html and I guess this limit isn't configuration. If you need to search only one Git repository, will cloning the repository locally and running a "grep" work for you?

I have over 200 repositories

Like DEBS likes this

I agree with the OP that while a clone/grep could work for those large files, it is not ideal if you need to know which repository to clone in the first place.  In fact, it is our goal to use Bitbucket search instead of our gaggle of command line driven grep scripts.  And you have to admit that the Bitbucket interface is much prettier than the scrolling output of a shell screen.  Besides, isn't that the premise behind the birth of Bitbucket - a pretty interface?

I realize this was probably a performance decision made when git and Bitbucket were only being used for the storage of actual source.  And quite honestly source code shouldn't grow greater than 512k or you probably aren't following good coding practices.  However, with the open-door flexibility of git and Bitbucket, we have been treating our repositories like a bucket and putting everything in there.  This includes sql output like the OP, svg files, and some rather large libraries (which are probably overdue for a code review).

It would be wonderful if someone could find that bit to change or point us to an addon that can increase or get around the size limit.  Alternately, if this setting is hard coded, is it a possibility to be considered in a future feature request and what would be the proper venue for such a request?

Like Ryan Monk likes this

I received reply back from the maker of Smarter Search for Bitbucket.  He confirms it has its own settings for indexing files and claims his search can handle indexing files up to 150mb, if not more, depending on available ram to the Bitbucket instance (and ElasticSearch if external).  He recommended minimum 16mb dedicated to the server.  Great and fast support I might add.  I wasn't expecting a response so quickly.

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Bitbucket

📣 Calling Bitbucket Data Center customers to participate in research

Hi everyone, Are you Bitbucket DC customer? If so, we'd love to talk to you! Our team wants to dive deep to understand your long-term plans regarding Bitbucket DC and Atlassian Cloud. Do you plan...

118 views 2 4
Read article

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you