miyucy / brotli

MIT License
59 stars 14 forks source link

Release the GVL when deflating #2

Closed thedrow closed 7 years ago

thedrow commented 7 years ago

This will allow threads to run while we're compressing. It's not easy to release the GVL while decompressing since we are streaming the output to a ruby string. Is there any way around that?

thedrow commented 7 years ago

Any idea why the build fails? It compiles fine locally for me.

thedrow commented 7 years ago

Oh right it's C99 syntax. I'll fix that.

miyucy commented 7 years ago

Thanks for PR. I'll look soon.

thedrow commented 7 years ago

I think we can use https://github.com/google/brotli/blob/master/python/_brotli.cc#L90 as a good example. What do you think?

miyucy commented 7 years ago

yes. i think so. this gem still use brotli-v0.4.0 . so we have to upgrade brotli version to v0.5.2.

thedrow commented 7 years ago

Can you merge and release this? I'll work on rewriting the code to the new version later.

miyucy commented 7 years ago

sure sure :+1:

thedrow commented 7 years ago

Ping me when this hits RubyGems. BTW you can setup Travis to publish to rubygems when you tag this repo.

miyucy commented 7 years ago

Ping me when this hits RubyGems. BTW you can setup Travis to publish to rubygems when you tag this repo.

Thanks for this information. it's very helpful!!