7 Commits

Author SHA1 Message Date
Kévin Dunglas
f4bf4e0097
perf: use zap's Check() to prevent useless allocs (#6560)
Some checks failed
Tests / test (s390x on IBM Z) (push) Has been skipped
Tests / goreleaser-check (push) Successful in 40s
Cross-Build / build (~1.22.3, 1.22, aix) (push) Successful in 2m55s
Cross-Build / build (~1.22.3, 1.22, dragonfly) (push) Successful in 3m1s
Cross-Build / build (~1.22.3, 1.22, freebsd) (push) Successful in 3m1s
Cross-Build / build (~1.22.3, 1.22, netbsd) (push) Successful in 3m1s
Cross-Build / build (~1.22.3, 1.22, windows) (push) Successful in 3m1s
Cross-Build / build (~1.22.3, 1.22, darwin) (push) Failing after 13m23s
Cross-Build / build (~1.23.0, 1.23, aix) (push) Successful in 2m40s
Cross-Build / build (~1.22.3, 1.22, illumos) (push) Failing after 11m51s
Cross-Build / build (~1.22.3, 1.22, linux) (push) Failing after 11m47s
Cross-Build / build (~1.23.0, 1.23, darwin) (push) Successful in 2m29s
Cross-Build / build (~1.23.0, 1.23, linux) (push) Successful in 2m39s
Cross-Build / build (~1.22.3, 1.22, openbsd) (push) Failing after 13m27s
Cross-Build / build (~1.22.3, 1.22, solaris) (push) Failing after 13m27s
Cross-Build / build (~1.23.0, 1.23, netbsd) (push) Successful in 2m41s
Cross-Build / build (~1.23.0, 1.23, openbsd) (push) Successful in 2m54s
Cross-Build / build (~1.23.0, 1.23, solaris) (push) Successful in 2m40s
Cross-Build / build (~1.23.0, 1.23, dragonfly) (push) Failing after 14m19s
Cross-Build / build (~1.23.0, 1.23, freebsd) (push) Failing after 14m10s
Cross-Build / build (~1.23.0, 1.23, illumos) (push) Failing after 14m2s
Cross-Build / build (~1.23.0, 1.23, windows) (push) Failing after 11m58s
Lint / lint (ubuntu-latest, linux) (push) Failing after 3m44s
Lint / govulncheck (push) Successful in 2m18s
Tests / test (./cmd/caddy/caddy, ~1.22.3, macos-14, 0, 1.22, mac) (push) Has been cancelled
Tests / test (./cmd/caddy/caddy, ~1.23.0, macos-14, 0, 1.23, mac) (push) Has been cancelled
Tests / test (./cmd/caddy/caddy.exe, ~1.22.3, windows-latest, True, 1.22, windows) (push) Has been cancelled
Tests / test (./cmd/caddy/caddy.exe, ~1.23.0, windows-latest, True, 1.23, windows) (push) Has been cancelled
Lint / lint (macos-14, mac) (push) Has been cancelled
Lint / lint (windows-latest, windows) (push) Has been cancelled
* perf: use zap's Check() to prevent useless allocs

* fix

* fix

* fix

* fix

* restore previous replacer behavior

* fix linter
2024-09-13 11:16:37 -06:00
Jacob Gadikian
d6f86cccf5
ci: use gci linter (#5708)
* use gofmput to format code

* use gci to format imports

* reconfigure gci

* linter autofixes

* rearrange imports a little

* export GOOS=windows golangci-lint run ./... --fix
2023-08-14 09:41:15 -06:00
Francis Lavoie
cd486c25d1
caddyhttp: Make use of http.ResponseController (#5654)
* caddyhttp: Make use of http.ResponseController

Also syncs the reverseproxy implementation with stdlib's which now uses ResponseController as well 2449bbb5e6

* Enable full-duplex for HTTP/1.1

* Appease linter

* Add warning for builds with Go 1.20, so it's less surprising to users

* Improved godoc for EnableFullDuplex, copied text from stdlib

* Only wrap in encode if not already wrapped
2023-08-02 20:03:26 +00:00
Matthew Holt
e43b6d8178 core: Variadic Context.Logger(); soft deprecation
Ideally I'd just remove the parameter to caddy.Context.Logger(), but
this would break most Caddy plugins.

Instead, I'm making it variadic and marking it as partially deprecated.
In the future, I might completely remove the parameter once most
plugins have updated.
2022-09-16 16:55:36 -06:00
Matt Holt
ca4fae64d9
caddyhttp: Support respond with HTTP 103 Early Hints (#5006)
* caddyhttp: Support sending HTTP 103 Early Hints

This adds support for early hints in the static_response handler.

* caddyhttp: Don't record 1xx responses
2022-09-05 13:50:44 -06:00
Francis Lavoie
5bf0adad87
caddyhttp: Make logging of credential headers opt-in (#4438) 2021-12-02 13:26:24 -07:00
Matt Holt
6cea1f239d
push: Implement HTTP/2 server push (#3573)
* push: Implement HTTP/2 server push (close #3551)

* push: Abstract header ops by embedding into new struct type

This will allow us to add more fields to customize headers in
push-specific ways in the future.

* push: Ensure Link resources are pushed before response is written

* Change header name from X-Caddy-Push to Caddy-Push
2020-07-20 12:28:40 -06:00