mirror of
https://github.com/lukaszraczylo/graphql-monitoring-proxy.git
synced 2026-10-12 05:32:36 +00:00
improvements mid may 2025 (#24)
* General improvements and bug fixes. * Improve tests coverage. * fixup! Improve tests coverage. * Update README.md with latest changes. * Fix the uint32 * Resolve issue with race condition for logging. * fixup! Merge remote-tracking branch 'origin/main' into improvements-mid-apr-2025 * Fix the test of the rate limiter * Add default ratelimit.json file * Update dependencies. * Significant refactor. * fixup! Significant refactor. * fixup! Merge remote-tracking branch 'origin/main' into improvements-mid-apr-2025 * fixup! fixup! Merge remote-tracking branch 'origin/main' into improvements-mid-apr-2025 * fixup! fixup! fixup! Merge remote-tracking branch 'origin/main' into improvements-mid-apr-2025 * fixup! fixup! fixup! fixup! fixup! Merge remote-tracking branch 'origin/main' into improvements-mid-apr-2025 * fixup! fixup! fixup! fixup! fixup! fixup! Merge remote-tracking branch 'origin/main' into improvements-mid-apr-2025 * fixup! fixup! fixup! fixup! fixup! fixup! fixup! Merge remote-tracking branch 'origin/main' into improvements-mid-apr-2025 * fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! Merge remote-tracking branch 'origin/main' into improvements-mid-apr-2025 * fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! Merge remote-tracking branch 'origin/main' into improvements-mid-apr-2025 * fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! fixup! Merge remote-tracking branch 'origin/main' into improvements-mid-apr-2025
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"compress/gzip"
|
||||
"io"
|
||||
|
||||
"github.com/lukaszraczylo/graphql-monitoring-proxy/pkg/pools"
|
||||
)
|
||||
|
||||
// Legacy compatibility layer - delegates to unified pool implementation
|
||||
|
||||
// GetHTTPBuffer gets a buffer from the global pool
|
||||
func GetHTTPBuffer() *bytes.Buffer {
|
||||
return pools.GetBuffer()
|
||||
}
|
||||
|
||||
// PutHTTPBuffer returns a buffer to the global pool
|
||||
func PutHTTPBuffer(buf *bytes.Buffer) {
|
||||
pools.PutBuffer(buf)
|
||||
}
|
||||
|
||||
// GetGzipWriter gets a gzip writer from the global pool
|
||||
func GetGzipWriter(w io.Writer) *gzip.Writer {
|
||||
return pools.GetGzipWriter(w)
|
||||
}
|
||||
|
||||
// PutGzipWriter returns a gzip writer to the global pool
|
||||
func PutGzipWriter(gz *gzip.Writer) {
|
||||
pools.PutGzipWriter(gz)
|
||||
}
|
||||
|
||||
// GetGzipReader gets a gzip reader from the global pool
|
||||
func GetGzipReader(r io.Reader) (*gzip.Reader, error) {
|
||||
return pools.GetGzipReader(r)
|
||||
}
|
||||
|
||||
// PutGzipReader returns a gzip reader to the global pool
|
||||
func PutGzipReader(gr *gzip.Reader) {
|
||||
pools.PutGzipReader(gr)
|
||||
}
|
||||
Reference in New Issue
Block a user