bitemyapp / bloodhound

Haskell Elasticsearch client and query DSL
bitemyapp.com
BSD 3-Clause "New" or "Revised" License
424 stars 118 forks source link

add ability to change compression codec. This allows us to use DEFLATE instead of lz4. #216

Closed andrewthad closed 6 years ago

andrewthad commented 6 years ago

…E instead of lz4.

bitemyapp commented 6 years ago

Are you trying to save CPU time? I'm curious what triggered this.

andrewthad commented 6 years ago

Other way around. I'm trying to save disk space. According to the disk tuning docs:

The _source and stored fields can easily take a non negligible amount of disk space. They can be compressed more aggressively by using the best_compression codec.

andrewthad commented 6 years ago

I've improved the docs. Also, I forgot to mention that the feature added in this PR cannot be used without first merging https://github.com/bitemyapp/bloodhound/pull/209. This index setting cannot actually be updated dynamically, so it needs createIndexWith from the other PR.

bitemyapp commented 6 years ago

@andrewthad could you add the compression setting to the createIndexWith test case? If Elastic changes the API I'd like the tests to go red.

andrewthad commented 6 years ago

when has elastic ever made haphazardly documented breaking changes to their api? ;) I'll close this PR and rebase on top of https://github.com/bitemyapp/bloodhound/pull/209 and then add the tests there.

andrewthad commented 6 years ago

Ah, you just merged it. Nevermind, I'll just rebase this on top of master and add the test.

bitemyapp commented 6 years ago

Gah, sorry if I'm making this difficult for you!

andrewthad commented 6 years ago

No worries. There's now a test for both compression codecs.

bitemyapp commented 6 years ago

@andrewthad okay, should I merge this one then?

andrewthad commented 6 years ago

Yes, this one's got everything now.

bitemyapp commented 6 years ago

@andrewthad thank you for everything!