Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* add benchmark Signed-off-by: Sandor Szücs <[email protected]> * add map with sync.Mutex % go test -bench=Benchmark_CreateFilter_FullConfigSingleApiNakadi -benchmem ./filters/apiusagemonitoring -count 5 G -vE 'ERRO|INFO|level=info|level=error' goos: linux goarch: amd64 pkg: github.com/zalando/skipper/filters/apiusagemonitoring Benchmark_CreateFilter_FullConfigSingleApiNakadi-4 2590 527939 ns/op 55714 B/op 1379 allocs/op Benchmark_CreateFilter_FullConfigSingleApiNakadi-4 2474 447375 ns/op 55688 B/op 1379 allocs/op Benchmark_CreateFilter_FullConfigSingleApiNakadi-4 2511 525478 ns/op 55711 B/op 1379 allocs/op Benchmark_CreateFilter_FullConfigSingleApiNakadi-4 2509 449144 ns/op 55751 B/op 1379 allocs/op Benchmark_CreateFilter_FullConfigSingleApiNakadi-4 2293 451283 ns/op 55655 B/op 1379 allocs/op PASS ok github.com/zalando/skipper/filters/apiusagemonitoring 8.266s Signed-off-by: Sandor Szücs <[email protected]> * cache based on sync.Map % go test -bench=Benchmark_CreateFilter_FullConfigSingleApiNakadi -benchmem ./filters/apiusagemonitoring -count 5 G -vE 'ERRO|INFO|level=info|level=error' goos: linux goarch: amd64 pkg: github.com/zalando/skipper/filters/apiusagemonitoring Benchmark_CreateFilter_FullConfigSingleApiNakadi-4 2534 446211 ns/op 55806 B/op 1381 allocs/op Benchmark_CreateFilter_FullConfigSingleApiNakadi-4 2520 447876 ns/op 55691 B/op 1381 allocs/op Benchmark_CreateFilter_FullConfigSingleApiNakadi-4 2373 447189 ns/op 55745 B/op 1381 allocs/op Benchmark_CreateFilter_FullConfigSingleApiNakadi-4 2473 438565 ns/op 55700 B/op 1381 allocs/op Benchmark_CreateFilter_FullConfigSingleApiNakadi-4 2491 449118 ns/op 55780 B/op 1381 allocs/op PASS ok github.com/zalando/skipper/filters/apiusagemonitoring 6.833s Signed-off-by: Sandor Szücs <[email protected]> * change as commented Signed-off-by: Sandor Szücs <[email protected]> * no need to store if we have a successful load Signed-off-by: Sandor Szücs <[email protected]> * remove as commented Signed-off-by: Sandor Szücs <[email protected]>
- Loading branch information