mirror of
https://github.com/gohugoio/hugo.git
synced 2024-11-21 20:46:30 -05:00
98ee69bce2
This commit adds the interface ContentReWriter in the tranformer chain. This is backed by two pooled byte buffers, alternating between being the reader or the writer. This keeps the performance characteristic of the old implementation, but in a thread safe way. Fixes #911 Benchmark old vs new: benchmark old ns/op new ns/op delta BenchmarkAbsURL 17614 17384 -1.31% BenchmarkXMLAbsURL 9431 9248 -1.94% benchmark old allocs new allocs delta BenchmarkAbsURL 24 28 +16.67% BenchmarkXMLAbsURL 12 14 +16.67% benchmark old bytes new bytes delta BenchmarkAbsURL 3295 3424 +3.92% BenchmarkXMLAbsURL 1954 1987 +1.69% |
||
---|---|---|
.. | ||
absurl.go | ||
absurlreplacer.go | ||
chain.go | ||
chain_test.go | ||
livereloadinject.go |