swaggest / rest

Web services with OpenAPI and JSON Schema done quick in Go
https://pkg.go.dev/github.com/swaggest/rest
MIT License
335 stars 17 forks source link

Update jsonschema-go to inline trivial scalar references #163

Closed vearutop closed 1 year ago

vearutop commented 1 year ago

Fixes https://github.com/swaggest/rest/issues/161.

github-actions[bot] commented 1 year ago

Lines Of Code

Language Files Lines Code Comments Blanks Complexity Bytes
github-actions[bot] commented 1 year ago

Go API Changes

# summary
Inferred base version: v0.2.51
Suggested version: v0.2.52
github-actions[bot] commented 1 year ago

Unit Test Coverage

total: (statements) 83.7%

Coverage of changed lines No changes in testable statements.
Coverage diff with base branch No changes in coverage.
codecov[bot] commented 1 year ago

Codecov Report

Merging #163 (b7194ec) into master (279131d) will not change coverage. The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #163   +/-   ##
=======================================
  Coverage   78.04%   78.04%           
=======================================
  Files          28       28           
  Lines        1608     1608           
=======================================
  Hits         1255     1255           
  Misses        232      232           
  Partials      121      121           
Flag Coverage Δ
unittests 78.04% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

github-actions[bot] commented 1 year ago

Benchmark Result

Benchmark diff with base branch ``` name old time/op new time/op delta pkg:github.com/swaggest/rest/jsonschema goos:linux goarch:amd64 RequestValidator_ValidateRequestData-2 1.34µs ± 0% 1.34µs ± 1% ~ (p=0.802 n=5+5) pkg:github.com/swaggest/rest/request goos:linux goarch:amd64 Decoder_Decode-2 666ns ± 1% 663ns ± 0% -0.56% (p=0.011 n=6+6) DecoderFunc_Decode-2 1.97µs ± 1% 1.96µs ± 2% ~ (p=0.558 n=6+6) Decoder_Decode_json-2 22.9µs ± 0% 22.6µs ± 0% -0.98% (p=0.008 n=5+5) Decoder_Decode_queryObject-2 5.37µs ± 0% 5.34µs ± 0% -0.61% (p=0.008 n=5+5) Decoder_Decode_jsonParam-2 1.93µs ± 0% 1.92µs ± 1% -0.91% (p=0.013 n=6+6) DecoderFactory_SetDecoderFunc-2 1.68µs ± 1% 1.68µs ± 0% ~ (p=0.079 n=5+4) pkg:github.com/swaggest/rest/response/gzip goos:linux goarch:amd64 Middleware-2 11.6µs ± 1% 11.5µs ± 2% ~ (p=0.394 n=6+6) Middleware_control-2 3.27µs ± 1% 3.32µs ± 2% +1.52% (p=0.015 n=6+6) name old alloc/op new alloc/op delta pkg:github.com/swaggest/rest/jsonschema goos:linux goarch:amd64 RequestValidator_ValidateRequestData-2 2.46kB ± 0% 2.46kB ± 0% ~ (all equal) pkg:github.com/swaggest/rest/request goos:linux goarch:amd64 Decoder_Decode-2 440B ± 0% 440B ± 0% ~ (all equal) DecoderFunc_Decode-2 1.51kB ± 0% 1.51kB ± 0% ~ (all equal) Decoder_Decode_json-2 12.2kB ± 0% 12.2kB ± 0% ~ (all equal) Decoder_Decode_queryObject-2 2.00kB ± 0% 2.00kB ± 0% ~ (all equal) Decoder_Decode_jsonParam-2 736B ± 0% 736B ± 0% ~ (all equal) DecoderFactory_SetDecoderFunc-2 1.02kB ± 0% 1.02kB ± 0% ~ (all equal) pkg:github.com/swaggest/rest/response/gzip goos:linux goarch:amd64 Middleware-2 1.15kB ± 3% 1.15kB ± 3% ~ (p=0.619 n=6+6) Middleware_control-2 11.2kB ± 0% 11.2kB ± 0% ~ (all equal) name old allocs/op new allocs/op delta pkg:github.com/swaggest/rest/jsonschema goos:linux goarch:amd64 RequestValidator_ValidateRequestData-2 8.00 ± 0% 8.00 ± 0% ~ (all equal) pkg:github.com/swaggest/rest/request goos:linux goarch:amd64 Decoder_Decode-2 4.00 ± 0% 4.00 ± 0% ~ (all equal) DecoderFunc_Decode-2 12.0 ± 0% 12.0 ± 0% ~ (all equal) Decoder_Decode_json-2 177 ± 0% 177 ± 0% ~ (all equal) Decoder_Decode_queryObject-2 36.0 ± 0% 36.0 ± 0% ~ (all equal) Decoder_Decode_jsonParam-2 13.0 ± 0% 13.0 ± 0% ~ (all equal) DecoderFactory_SetDecoderFunc-2 16.0 ± 0% 16.0 ± 0% ~ (all equal) pkg:github.com/swaggest/rest/response/gzip goos:linux goarch:amd64 Middleware-2 11.0 ± 0% 11.0 ± 0% ~ (all equal) Middleware_control-2 9.00 ± 0% 9.00 ± 0% ~ (all equal) ```
Benchmark result ``` name time/op pkg:github.com/swaggest/rest/jsonschema goos:linux goarch:amd64 RequestValidator_ValidateRequestData-2 1.34µs ± 1% pkg:github.com/swaggest/rest/request goos:linux goarch:amd64 Decoder_Decode-2 663ns ± 0% DecoderFunc_Decode-2 1.96µs ± 2% Decoder_Decode_json-2 22.6µs ± 0% Decoder_Decode_queryObject-2 5.34µs ± 0% Decoder_Decode_jsonParam-2 1.92µs ± 1% DecoderFactory_SetDecoderFunc-2 1.68µs ± 0% pkg:github.com/swaggest/rest/response/gzip goos:linux goarch:amd64 Middleware-2 11.5µs ± 2% Middleware_control-2 3.32µs ± 2% name alloc/op pkg:github.com/swaggest/rest/jsonschema goos:linux goarch:amd64 RequestValidator_ValidateRequestData-2 2.46kB ± 0% pkg:github.com/swaggest/rest/request goos:linux goarch:amd64 Decoder_Decode-2 440B ± 0% DecoderFunc_Decode-2 1.51kB ± 0% Decoder_Decode_json-2 12.2kB ± 0% Decoder_Decode_queryObject-2 2.00kB ± 0% Decoder_Decode_jsonParam-2 736B ± 0% DecoderFactory_SetDecoderFunc-2 1.02kB ± 0% pkg:github.com/swaggest/rest/response/gzip goos:linux goarch:amd64 Middleware-2 1.15kB ± 3% Middleware_control-2 11.2kB ± 0% name allocs/op pkg:github.com/swaggest/rest/jsonschema goos:linux goarch:amd64 RequestValidator_ValidateRequestData-2 8.00 ± 0% pkg:github.com/swaggest/rest/request goos:linux goarch:amd64 Decoder_Decode-2 4.00 ± 0% DecoderFunc_Decode-2 12.0 ± 0% Decoder_Decode_json-2 177 ± 0% Decoder_Decode_queryObject-2 36.0 ± 0% Decoder_Decode_jsonParam-2 13.0 ± 0% DecoderFactory_SetDecoderFunc-2 16.0 ± 0% pkg:github.com/swaggest/rest/response/gzip goos:linux goarch:amd64 Middleware-2 11.0 ± 0% Middleware_control-2 9.00 ± 0% ```
github-actions[bot] commented 1 year ago

Examples Benchmark Result

Benchmark diff with base branch ``` name old time/op new time/op delta pkg:github.com/swaggest/rest/_examples/advanced goos:linux goarch:amd64 _directGzip-2 23.2µs ± 1% 24.2µs ±11% ~ (p=0.548 n=5+5) _directGzipHead-2 23.2µs ± 1% 23.1µs ± 2% ~ (p=0.905 n=4+5) _noDirectGzip-2 125µs ± 2% 126µs ± 2% ~ (p=0.310 n=5+5) _directGzip_decode-2 462µs ± 1% 470µs ± 5% ~ (p=0.222 n=5+5) _noDirectGzip_decode-2 126µs ± 1% 127µs ± 1% ~ (p=0.222 n=5+5) _jsonBody-2 46.6µs ± 1% 48.6µs ± 4% +4.43% (p=0.016 n=5+5) _jsonBodyValidation-2 55.6µs ± 1% 56.8µs ± 5% ~ (p=0.310 n=5+5) _outputHeaders-2 24.0µs ± 2% 24.2µs ± 1% ~ (p=0.222 n=5+5) _requestResponseMapping-2 47.5µs ± 1% 49.3µs ± 5% +3.91% (p=0.008 n=5+5) _validation-2 52.8µs ± 3% 52.8µs ± 1% ~ (p=0.841 n=5+5) _noValidation-2 36.3µs ± 1% 36.8µs ± 1% +1.39% (p=0.016 n=5+5) pkg:github.com/swaggest/rest/_examples/advanced-generic goos:linux goarch:amd64 _directGzip-2 23.5µs ± 1% 23.7µs ± 1% ~ (p=0.057 n=4+4) _directGzipHead-2 23.7µs ± 1% 24.5µs ± 4% +3.41% (p=0.032 n=5+5) _noDirectGzip-2 133µs ± 2% 134µs ± 1% ~ (p=0.222 n=5+5) _directGzip_decode-2 476µs ± 1% 493µs ± 3% +3.37% (p=0.016 n=5+5) _noDirectGzip_decode-2 135µs ± 1% 135µs ± 1% ~ (p=1.000 n=5+5) _htmlResponse-2 41.3µs ± 2% 41.0µs ± 2% ~ (p=0.690 n=5+5) _jsonBodyManual-2 28.9µs ± 1% 28.9µs ± 2% ~ (p=0.421 n=5+5) _jsonBody-2 43.3µs ± 3% 43.5µs ± 2% ~ (p=0.548 n=5+5) _jsonBodyValidation-2 58.4µs ± 2% 59.8µs ± 1% +2.35% (p=0.016 n=5+5) _outputHeaders-2 41.1µs ± 2% 43.4µs ± 2% +5.41% (p=0.008 n=5+5) _requestResponseMapping-2 49.7µs ± 2% 50.3µs ± 2% ~ (p=0.421 n=5+5) _validation-2 54.5µs ±10% 53.3µs ± 2% ~ (p=0.841 n=5+5) _noValidation-2 37.7µs ± 3% 37.2µs ± 2% ~ (p=0.421 n=5+5) pkg:github.com/swaggest/rest/_examples/task-api/internal/infra/nethttp goos:linux goarch:amd64 _notFoundSrv-2 25.9µs ± 1% 25.9µs ± 1% ~ (p=0.905 n=4+5) _ok-2 26.4µs ± 2% 26.1µs ± 0% ~ (p=0.413 n=5+4) _invalidBody-2 40.6µs ± 6% 40.1µs ± 5% ~ (p=0.690 n=5+5) name old 50%:ms new 50%:ms delta pkg:github.com/swaggest/rest/_examples/advanced goos:linux goarch:amd64 _directGzip-2 1.12 ± 3% 1.12 ± 6% ~ (p=0.794 n=5+5) _directGzipHead-2 1.11 ± 6% 1.10 ± 3% ~ (p=1.000 n=5+5) _noDirectGzip-2 6.07 ± 5% 6.09 ± 3% ~ (p=0.548 n=5+5) _directGzip_decode-2 17.4 ± 7% 17.1 ± 8% ~ (p=0.548 n=5+5) _noDirectGzip_decode-2 6.00 ± 1% 6.27 ± 5% ~ (p=0.056 n=5+5) _jsonBody-2 2.06 ± 1% 2.20 ± 5% +7.07% (p=0.008 n=5+5) _jsonBodyValidation-2 2.56 ± 4% 2.73 ± 7% ~ (p=0.056 n=5+5) _outputHeaders-2 1.12 ± 6% 1.14 ± 4% ~ (p=0.310 n=5+5) _requestResponseMapping-2 2.13 ± 3% 2.19 ± 6% ~ (p=0.421 n=5+5) _validation-2 2.42 ± 6% 2.37 ± 4% ~ (p=1.000 n=5+5) _noValidation-2 1.63 ± 4% 1.60 ±10% ~ (p=0.397 n=5+5) pkg:github.com/swaggest/rest/_examples/advanced-generic goos:linux goarch:amd64 _directGzip-2 1.13 ± 6% 1.17 ± 7% ~ (p=0.206 n=5+5) _directGzipHead-2 1.11 ± 3% 1.10 ± 2% ~ (p=0.548 n=5+5) _noDirectGzip-2 6.41 ± 5% 6.51 ± 5% ~ (p=0.548 n=5+5) _directGzip_decode-2 19.0 ± 3% 18.8 ± 6% ~ (p=0.310 n=5+5) _noDirectGzip_decode-2 6.54 ± 3% 6.58 ± 1% ~ (p=0.690 n=5+5) _htmlResponse-2 1.91 ± 8% 1.88 ± 5% ~ (p=0.548 n=5+5) _jsonBodyManual-2 1.36 ± 6% 1.35 ± 4% ~ (p=1.000 n=5+5) _jsonBody-2 1.95 ± 8% 1.96 ± 6% ~ (p=1.000 n=5+5) _jsonBodyValidation-2 2.68 ± 8% 2.69 ± 5% ~ (p=1.000 n=5+5) _outputHeaders-2 1.75 ± 4% 1.88 ± 6% +7.63% (p=0.032 n=5+5) _requestResponseMapping-2 2.17 ± 4% 2.27 ± 6% ~ (p=0.079 n=5+5) _validation-2 2.36 ± 3% 2.31 ± 7% ~ (p=0.730 n=5+5) _noValidation-2 1.63 ± 4% 1.64 ± 6% ~ (p=0.548 n=5+5) pkg:github.com/swaggest/rest/_examples/task-api/internal/infra/nethttp goos:linux goarch:amd64 _notFoundSrv-2 1.30 ± 9% 1.30 ± 3% ~ (p=0.548 n=5+5) _ok-2 1.29 ± 5% 1.25 ± 7% ~ (p=0.222 n=5+5) _invalidBody-2 1.78 ± 7% 1.78 ± 5% ~ (p=1.000 n=5+5) name old 90%:ms new 90%:ms delta pkg:github.com/swaggest/rest/_examples/advanced goos:linux goarch:amd64 _directGzip-2 1.96 ± 5% 2.07 ±12% ~ (p=0.310 n=5+5) _directGzipHead-2 1.99 ± 6% 1.94 ± 3% ~ (p=0.198 n=5+5) _noDirectGzip-2 10.8 ± 2% 10.7 ± 4% ~ (p=0.421 n=5+5) _directGzip_decode-2 39.8 ± 3% 41.5 ± 5% ~ (p=0.151 n=5+5) _noDirectGzip_decode-2 10.8 ± 3% 11.1 ± 2% ~ (p=0.151 n=5+5) _jsonBody-2 4.20 ± 4% 4.37 ± 6% ~ (p=0.095 n=5+5) _jsonBodyValidation-2 4.87 ± 3% 4.96 ± 4% ~ (p=0.421 n=5+5) _outputHeaders-2 2.05 ± 5% 2.00 ± 5% ~ (p=0.421 n=5+5) _requestResponseMapping-2 4.22 ± 4% 4.48 ± 6% +6.21% (p=0.032 n=5+5) _validation-2 4.81 ± 5% 4.72 ± 3% ~ (p=0.222 n=5+5) _noValidation-2 3.35 ± 4% 3.42 ± 3% ~ (p=0.421 n=5+5) pkg:github.com/swaggest/rest/_examples/advanced-generic goos:linux goarch:amd64 _directGzip-2 2.06 ± 9% 2.05 ± 3% ~ (p=0.651 n=5+5) _directGzipHead-2 2.05 ± 5% 2.06 ± 3% ~ (p=0.841 n=5+5) _noDirectGzip-2 11.3 ± 2% 11.4 ± 3% ~ (p=0.690 n=5+5) _directGzip_decode-2 40.1 ±10% 40.1 ± 8% ~ (p=1.000 n=5+5) _noDirectGzip_decode-2 11.4 ± 4% 11.6 ± 2% ~ (p=0.198 n=5+5) _htmlResponse-2 3.68 ± 4% 3.62 ± 3% ~ (p=0.341 n=5+5) _jsonBodyManual-2 2.45 ± 5% 2.47 ± 6% ~ (p=1.000 n=5+5) _jsonBody-2 4.09 ± 7% 3.95 ± 2% ~ (p=0.095 n=5+5) _jsonBodyValidation-2 5.13 ± 5% 5.39 ± 5% ~ (p=0.151 n=5+5) _outputHeaders-2 3.93 ± 8% 4.16 ± 3% ~ (p=0.151 n=5+5) _requestResponseMapping-2 4.62 ± 3% 4.57 ± 5% ~ (p=0.690 n=5+5) _validation-2 4.93 ± 7% 4.93 ± 2% ~ (p=1.000 n=5+5) _noValidation-2 3.63 ± 7% 3.53 ± 3% ~ (p=0.222 n=5+5) pkg:github.com/swaggest/rest/_examples/task-api/internal/infra/nethttp goos:linux goarch:amd64 _notFoundSrv-2 2.24 ± 6% 2.22 ± 5% ~ (p=1.000 n=5+5) _ok-2 2.22 ± 3% 2.23 ± 4% ~ (p=0.952 n=5+5) _invalidBody-2 3.88 ± 9% 3.79 ±13% ~ (p=0.310 n=5+5) name old 99%:ms new 99%:ms delta pkg:github.com/swaggest/rest/_examples/advanced goos:linux goarch:amd64 _directGzip-2 3.32 ± 6% 3.29 ± 7% ~ (p=0.857 n=5+4) _directGzipHead-2 3.30 ± 7% 3.29 ± 5% ~ (p=0.905 n=4+5) _noDirectGzip-2 14.6 ± 4% 15.1 ± 8% ~ (p=0.310 n=5+5) _directGzip_decode-2 66.5 ±11% 70.0 ±10% ~ (p=0.548 n=5+5) _noDirectGzip_decode-2 15.0 ± 5% 14.5 ± 4% ~ (p=0.198 n=5+5) _jsonBody-2 6.34 ± 9% 7.02 ±26% ~ (p=0.548 n=5+5) _jsonBodyValidation-2 6.87 ± 6% 7.41 ±38% ~ (p=1.000 n=5+5) _outputHeaders-2 3.62 ±10% 3.77 ±10% ~ (p=0.500 n=5+5) _requestResponseMapping-2 6.60 ±10% 7.83 ±16% ~ (p=0.095 n=5+5) _validation-2 8.42 ±12% 8.68 ±15% ~ (p=0.690 n=5+5) _noValidation-2 6.28 ±14% 6.41 ±17% ~ (p=0.690 n=5+5) pkg:github.com/swaggest/rest/_examples/advanced-generic goos:linux goarch:amd64 _directGzip-2 3.22 ± 4% 3.29 ± 4% ~ (p=0.686 n=4+4) _directGzipHead-2 3.46 ± 7% 3.86 ±26% ~ (p=0.056 n=5+5) _noDirectGzip-2 15.8 ± 7% 16.0 ± 7% ~ (p=0.841 n=5+5) _directGzip_decode-2 68.0 ± 6% 65.9 ±11% ~ (p=0.278 n=5+5) _noDirectGzip_decode-2 15.7 ± 5% 15.6 ± 8% ~ (p=0.841 n=5+5) _htmlResponse-2 6.20 ± 9% 6.03 ± 5% ~ (p=1.000 n=5+5) _jsonBodyManual-2 4.60 ± 6% 4.43 ±13% ~ (p=0.690 n=5+5) _jsonBody-2 7.24 ±27% 6.53 ±10% ~ (p=0.151 n=5+5) _jsonBodyValidation-2 9.06 ±19% 8.36 ±19% ~ (p=0.421 n=5+5) _outputHeaders-2 6.18 ±10% 6.92 ± 8% +12.08% (p=0.032 n=5+5) _requestResponseMapping-2 7.10 ±15% 7.18 ± 4% ~ (p=1.000 n=5+5) _validation-2 8.20 ±50% 7.49 ±10% ~ (p=0.548 n=5+5) _noValidation-2 6.27 ± 9% 5.84 ± 4% -6.86% (p=0.032 n=5+5) pkg:github.com/swaggest/rest/_examples/task-api/internal/infra/nethttp goos:linux goarch:amd64 _notFoundSrv-2 3.52 ± 4% 3.43 ± 2% ~ (p=0.111 n=4+5) _ok-2 3.67 ± 7% 3.52 ± 6% ~ (p=0.413 n=5+4) _invalidBody-2 7.02 ±15% 7.14 ±21% ~ (p=1.000 n=5+5) name old 99.9%:ms new 99.9%:ms delta pkg:github.com/swaggest/rest/_examples/advanced goos:linux goarch:amd64 _directGzip-2 6.45 ±37% 5.54 ± 9% ~ (p=0.286 n=5+4) _directGzipHead-2 8.85 ±68% 6.31 ±43% ~ (p=0.421 n=5+5) _noDirectGzip-2 18.5 ±15% 19.0 ±10% ~ (p=0.548 n=5+5) _directGzip_decode-2 91.9 ±12% 89.6 ± 4% ~ (p=0.548 n=5+5) _noDirectGzip_decode-2 18.3 ±11% 21.4 ±34% ~ (p=0.151 n=5+5) _jsonBody-2 9.67 ±15% 12.54 ±41% ~ (p=0.151 n=5+5) _jsonBodyValidation-2 11.5 ±29% 10.6 ±38% ~ (p=0.548 n=5+5) _outputHeaders-2 9.35 ±40% 9.22 ±12% ~ (p=1.000 n=5+5) _requestResponseMapping-2 11.7 ±33% 12.9 ±21% ~ (p=0.222 n=5+5) _validation-2 13.2 ±21% 15.0 ±22% ~ (p=0.310 n=5+5) _noValidation-2 12.2 ±39% 12.5 ±41% ~ (p=0.690 n=5+5) pkg:github.com/swaggest/rest/_examples/advanced-generic goos:linux goarch:amd64 _directGzip-2 4.69 ± 8% 7.67 ±96% ~ (p=0.111 n=4+5) _directGzipHead-2 6.80 ±69% 7.48 ±54% ~ (p=0.548 n=5+5) _noDirectGzip-2 19.6 ± 3% 20.1 ± 8% ~ (p=0.421 n=5+5) _directGzip_decode-2 97.1 ±34% 86.3 ± 9% ~ (p=0.310 n=5+5) _noDirectGzip_decode-2 19.8 ± 3% 20.3 ± 8% ~ (p=0.381 n=5+5) _htmlResponse-2 11.2 ±24% 10.6 ±25% ~ (p=0.690 n=5+5) _jsonBodyManual-2 8.66 ±25% 8.82 ±40% ~ (p=1.000 n=5+5) _jsonBody-2 14.4 ±28% 13.3 ±28% ~ (p=0.690 n=5+5) _jsonBodyValidation-2 18.3 ±45% 14.1 ±31% ~ (p=0.341 n=5+5) _outputHeaders-2 10.4 ±37% 14.7 ±24% ~ (p=0.063 n=5+5) _requestResponseMapping-2 12.2 ±37% 12.9 ±17% ~ (p=0.690 n=5+5) _validation-2 14.6 ±43% 13.6 ±27% ~ (p=0.548 n=5+5) _noValidation-2 11.7 ±25% 11.4 ±46% ~ (p=0.841 n=5+5) pkg:github.com/swaggest/rest/_examples/task-api/internal/infra/nethttp goos:linux goarch:amd64 _notFoundSrv-2 8.23 ±55% 5.42 ±18% ~ (p=0.095 n=5+5) _ok-2 6.10 ±20% 8.55 ±110% ~ (p=0.841 n=5+5) _invalidBody-2 12.6 ±42% 13.3 ±43% ~ (p=0.841 n=5+5) name old B:rcvd/op new B:rcvd/op delta pkg:github.com/swaggest/rest/_examples/advanced goos:linux goarch:amd64 _directGzip-2 630 ± 0% 630 ± 0% ~ (all equal) _directGzipHead-2 174 ± 0% 174 ± 0% ~ (all equal) _noDirectGzip-2 1.03k ± 0% 1.03k ± 0% ~ (all equal) _directGzip_decode-2 630 ± 0% 630 ± 0% ~ (all equal) _noDirectGzip_decode-2 1.03k ± 0% 1.03k ± 0% ~ (all equal) _jsonBody-2 199 ± 0% 199 ± 0% ~ (all equal) _jsonBodyValidation-2 185 ± 0% 185 ± 0% ~ (all equal) _outputHeaders-2 146 ± 0% 146 ± 0% ~ (all equal) _requestResponseMapping-2 94.0 ± 0% 94.0 ± 0% ~ (all equal) _validation-2 168 ± 0% 168 ± 0% ~ (all equal) _noValidation-2 168 ± 0% 168 ± 0% ~ (all equal) pkg:github.com/swaggest/rest/_examples/advanced-generic goos:linux goarch:amd64 _directGzip-2 638 ± 0% 638 ± 0% ~ (all equal) _directGzipHead-2 182 ± 0% 182 ± 0% ~ (all equal) _noDirectGzip-2 1.04k ± 0% 1.04k ± 0% ~ (all equal) _directGzip_decode-2 638 ± 0% 638 ± 0% ~ (all equal) _noDirectGzip_decode-2 1.04k ± 0% 1.04k ± 0% ~ (all equal) _htmlResponse-2 355 ± 0% 355 ± 0% ~ (all equal) _jsonBodyManual-2 207 ± 0% 207 ± 0% ~ (all equal) _jsonBody-2 207 ± 0% 207 ± 0% ~ (all equal) _jsonBodyValidation-2 193 ± 0% 193 ± 0% ~ (all equal) _outputHeaders-2 214 ± 0% 214 ± 0% ~ (all equal) _requestResponseMapping-2 108 ± 0% 108 ± 0% ~ (all equal) _validation-2 176 ± 0% 176 ± 0% ~ (all equal) _noValidation-2 176 ± 0% 176 ± 0% ~ (all equal) pkg:github.com/swaggest/rest/_examples/task-api/internal/infra/nethttp goos:linux goarch:amd64 _notFoundSrv-2 322 ± 0% 322 ± 0% ~ (all equal) _ok-2 344 ± 0% 344 ± 0% ~ (all equal) _invalidBody-2 420 ± 0% 420 ± 0% ~ (all equal) name old B:sent/op new B:sent/op delta pkg:github.com/swaggest/rest/_examples/advanced goos:linux goarch:amd64 _directGzip-2 103 ± 0% 103 ± 0% ~ (all equal) _directGzipHead-2 104 ± 0% 104 ± 0% ~ (all equal) _noDirectGzip-2 117 ± 0% 117 ± 0% ~ (all equal) _directGzip_decode-2 116 ± 0% 116 ± 0% ~ (all equal) _noDirectGzip_decode-2 130 ± 0% 130 ± 0% ~ (all equal) _jsonBody-2 188 ± 0% 188 ± 0% ~ (all equal) _jsonBodyValidation-2 192 ± 0% 192 ± 0% ~ (all equal) _outputHeaders-2 77.0 ± 0% 77.0 ± 0% ~ (all equal) _requestResponseMapping-2 169 ± 0% 169 ± 0% ~ (all equal) _validation-2 170 ± 0% 170 ± 0% ~ (all equal) _noValidation-2 173 ± 0% 173 ± 0% ~ (all equal) pkg:github.com/swaggest/rest/_examples/advanced-generic goos:linux goarch:amd64 _directGzip-2 103 ± 0% 103 ± 0% ~ (all equal) _directGzipHead-2 104 ± 0% 104 ± 0% ~ (all equal) _noDirectGzip-2 117 ± 0% 117 ± 0% ~ (all equal) _directGzip_decode-2 116 ± 0% 116 ± 0% ~ (all equal) _noDirectGzip_decode-2 130 ± 0% 130 ± 0% ~ (all equal) _htmlResponse-2 108 ± 0% 108 ± 0% ~ (all equal) _jsonBodyManual-2 195 ± 0% 195 ± 0% ~ (all equal) _jsonBody-2 188 ± 0% 188 ± 0% ~ (all equal) _jsonBodyValidation-2 192 ± 0% 192 ± 0% ~ (all equal) _outputHeaders-2 88.0 ± 0% 88.0 ± 0% ~ (all equal) _requestResponseMapping-2 169 ± 0% 169 ± 0% ~ (all equal) _validation-2 170 ± 0% 170 ± 0% ~ (all equal) _noValidation-2 173 ± 0% 173 ± 0% ~ (all equal) pkg:github.com/swaggest/rest/_examples/task-api/internal/infra/nethttp goos:linux goarch:amd64 _notFoundSrv-2 74.0 ± 0% 74.0 ± 0% ~ (all equal) _ok-2 74.0 ± 0% 74.0 ± 0% ~ (all equal) _invalidBody-2 137 ± 0% 137 ± 0% ~ (all equal) name old rps new rps delta pkg:github.com/swaggest/rest/_examples/advanced goos:linux goarch:amd64 _directGzip-2 43.0k ± 1% 41.4k ±10% ~ (p=0.548 n=5+5) _directGzipHead-2 43.2k ± 1% 43.3k ± 2% ~ (p=0.841 n=4+5) _noDirectGzip-2 8.03k ± 2% 7.96k ± 2% ~ (p=0.310 n=5+5) _directGzip_decode-2 2.16k ± 1% 2.13k ± 5% ~ (p=0.222 n=5+5) _noDirectGzip_decode-2 7.94k ± 1% 7.89k ± 1% ~ (p=0.222 n=5+5) _jsonBody-2 21.5k ± 1% 20.6k ± 4% -4.18% (p=0.016 n=5+5) _jsonBodyValidation-2 18.0k ± 1% 17.6k ± 5% ~ (p=0.310 n=5+5) _outputHeaders-2 41.7k ± 2% 41.3k ± 1% ~ (p=0.222 n=5+5) _requestResponseMapping-2 21.1k ± 1% 20.3k ± 4% -3.69% (p=0.008 n=5+5) _validation-2 18.9k ± 3% 18.9k ± 1% ~ (p=0.841 n=5+5) _noValidation-2 27.6k ± 1% 27.2k ± 1% -1.37% (p=0.016 n=5+5) pkg:github.com/swaggest/rest/_examples/advanced-generic goos:linux goarch:amd64 _directGzip-2 42.5k ± 1% 42.2k ± 1% ~ (p=0.057 n=4+4) _directGzipHead-2 42.2k ± 1% 40.9k ± 4% -3.25% (p=0.032 n=5+5) _noDirectGzip-2 7.51k ± 2% 7.45k ± 1% ~ (p=0.222 n=5+5) _directGzip_decode-2 2.10k ± 1% 2.03k ± 3% -3.23% (p=0.016 n=5+5) _noDirectGzip_decode-2 7.41k ± 1% 7.41k ± 1% ~ (p=1.000 n=5+5) _htmlResponse-2 24.2k ± 2% 24.4k ± 2% ~ (p=0.690 n=5+5) _jsonBodyManual-2 34.6k ± 1% 34.6k ± 2% ~ (p=0.421 n=5+5) _jsonBody-2 23.1k ± 3% 23.0k ± 2% ~ (p=0.548 n=5+5) _jsonBodyValidation-2 17.1k ± 2% 16.7k ± 1% -2.31% (p=0.016 n=5+5) _outputHeaders-2 24.3k ± 2% 23.1k ± 2% -5.11% (p=0.008 n=5+5) _requestResponseMapping-2 20.1k ± 2% 19.9k ± 2% ~ (p=0.333 n=5+5) _validation-2 18.4k ± 9% 18.8k ± 2% ~ (p=0.841 n=5+5) _noValidation-2 26.5k ± 3% 26.9k ± 2% ~ (p=0.421 n=5+5) pkg:github.com/swaggest/rest/_examples/task-api/internal/infra/nethttp goos:linux goarch:amd64 _notFoundSrv-2 38.7k ± 1% 38.7k ± 1% ~ (p=0.905 n=4+5) _ok-2 37.9k ± 2% 38.4k ± 0% ~ (p=0.413 n=5+4) _invalidBody-2 24.7k ± 6% 25.0k ± 5% ~ (p=0.690 n=5+5) name old alloc/op new alloc/op delta pkg:github.com/swaggest/rest/_examples/advanced goos:linux goarch:amd64 _directGzip-2 3.85kB ± 0% 3.85kB ± 0% ~ (p=0.556 n=5+5) _directGzipHead-2 3.84kB ± 0% 3.84kB ± 0% ~ (p=0.238 n=4+5) _noDirectGzip-2 6.43kB ±26% 6.66kB ±19% ~ (p=0.841 n=5+5) _directGzip_decode-2 403kB ± 0% 403kB ± 0% ~ (p=0.841 n=5+5) _noDirectGzip_decode-2 5.80kB ±11% 5.74kB ± 3% ~ (p=0.841 n=5+5) _jsonBody-2 13.1kB ± 0% 13.1kB ± 0% ~ (p=0.341 n=5+5) _jsonBodyValidation-2 18.9kB ± 0% 18.9kB ± 0% ~ (p=0.690 n=5+5) _outputHeaders-2 3.56kB ± 0% 3.56kB ± 0% ~ (p=0.952 n=5+5) _requestResponseMapping-2 16.6kB ± 0% 16.6kB ± 0% ~ (p=0.341 n=5+5) _validation-2 16.5kB ± 0% 16.5kB ± 0% ~ (p=0.643 n=5+5) _noValidation-2 7.75kB ± 0% 7.75kB ± 0% ~ (p=0.952 n=5+5) pkg:github.com/swaggest/rest/_examples/advanced-generic goos:linux goarch:amd64 _directGzip-2 3.88kB ± 0% 3.88kB ± 0% ~ (p=0.802 n=5+5) _directGzipHead-2 3.88kB ± 0% 3.88kB ± 0% ~ (p=0.492 n=5+5) _noDirectGzip-2 6.75kB ±20% 6.63kB ±15% ~ (p=0.841 n=5+5) _directGzip_decode-2 403kB ± 0% 403kB ± 0% ~ (p=0.690 n=5+5) _noDirectGzip_decode-2 5.81kB ±10% 5.73kB ± 6% ~ (p=1.000 n=5+5) _htmlResponse-2 8.02kB ± 0% 8.02kB ± 0% ~ (p=0.175 n=5+5) _jsonBodyManual-2 4.48kB ± 0% 4.48kB ± 0% ~ (p=1.000 n=5+5) _jsonBody-2 10.2kB ± 0% 10.2kB ± 0% ~ (p=0.833 n=5+5) _jsonBodyValidation-2 19.0kB ± 0% 19.0kB ± 0% ~ (p=0.706 n=5+5) _outputHeaders-2 10.4kB ± 0% 10.4kB ± 0% ~ (p=0.087 n=5+5) _requestResponseMapping-2 16.6kB ± 0% 16.6kB ± 0% ~ (p=0.722 n=5+5) _validation-2 16.5kB ± 0% 16.5kB ± 0% ~ (p=0.984 n=5+5) _noValidation-2 7.81kB ± 0% 7.81kB ± 0% ~ (p=0.865 n=5+5) pkg:github.com/swaggest/rest/_examples/task-api/internal/infra/nethttp goos:linux goarch:amd64 _notFoundSrv-2 4.63kB ± 0% 4.63kB ± 0% ~ (p=0.683 n=5+5) _ok-2 4.53kB ± 0% 4.53kB ± 0% ~ (p=0.743 n=4+4) _invalidBody-2 8.25kB ± 0% 8.25kB ± 0% ~ (p=0.886 n=4+4) name old allocs/op new allocs/op delta pkg:github.com/swaggest/rest/_examples/advanced goos:linux goarch:amd64 _directGzip-2 42.0 ± 0% 42.0 ± 0% ~ (all equal) _directGzipHead-2 42.0 ± 0% 42.0 ± 0% ~ (all equal) _noDirectGzip-2 49.4 ± 3% 49.4 ± 3% ~ (p=1.000 n=5+5) _directGzip_decode-2 504 ± 0% 504 ± 0% ~ (p=1.000 n=5+4) _noDirectGzip_decode-2 50.0 ± 0% 50.0 ± 0% ~ (all equal) _jsonBody-2 128 ± 0% 128 ± 0% ~ (all equal) _jsonBodyValidation-2 185 ± 0% 185 ± 0% ~ (all equal) _outputHeaders-2 36.0 ± 0% 36.0 ± 0% ~ (all equal) _requestResponseMapping-2 124 ± 0% 124 ± 0% ~ (all equal) _validation-2 154 ± 0% 154 ± 0% ~ (all equal) _noValidation-2 91.0 ± 0% 91.0 ± 0% ~ (all equal) pkg:github.com/swaggest/rest/_examples/advanced-generic goos:linux goarch:amd64 _directGzip-2 44.0 ± 0% 44.0 ± 0% ~ (all equal) _directGzipHead-2 44.0 ± 0% 44.0 ± 0% ~ (all equal) _noDirectGzip-2 51.6 ± 3% 51.6 ± 3% ~ (p=1.000 n=5+5) _directGzip_decode-2 505 ± 0% 505 ± 0% ~ (p=1.000 n=5+5) _noDirectGzip_decode-2 52.0 ± 0% 52.0 ± 0% ~ (all equal) _htmlResponse-2 145 ± 0% 145 ± 0% ~ (all equal) _jsonBodyManual-2 49.0 ± 0% 49.0 ± 0% ~ (all equal) _jsonBody-2 100 ± 0% 100 ± 0% ~ (all equal) _jsonBodyValidation-2 187 ± 0% 187 ± 0% ~ (all equal) _outputHeaders-2 113 ± 0% 113 ± 0% ~ (all equal) _requestResponseMapping-2 126 ± 0% 126 ± 0% ~ (all equal) _validation-2 156 ± 0% 156 ± 0% ~ (all equal) _noValidation-2 93.0 ± 0% 93.0 ± 0% ~ (all equal) pkg:github.com/swaggest/rest/_examples/task-api/internal/infra/nethttp goos:linux goarch:amd64 _notFoundSrv-2 53.0 ± 0% 53.0 ± 0% ~ (all equal) _ok-2 49.0 ± 0% 49.0 ± 0% ~ (all equal) _invalidBody-2 97.0 ± 0% 97.0 ± 0% ~ (all equal) ```