dependabot[bot]
f2cc873888
build(deps): bump github.com/tinylib/msgp from 1.2.5 to 1.3.0
...
Bumps [github.com/tinylib/msgp](https://github.com/tinylib/msgp ) from 1.2.5 to 1.3.0.
- [Release notes](https://github.com/tinylib/msgp/releases )
- [Commits](https://github.com/tinylib/msgp/compare/v1.2.5...v1.3.0 )
---
updated-dependencies:
- dependency-name: github.com/tinylib/msgp
dependency-version: 1.3.0
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2025-05-13 12:26:12 +00:00
Jason McNeil
4aae3271af
📝 docs: Document usage of Custom Tags in Logger middleware ( #3446 )
...
* 📝 docs: Update logger middleware documentation to include CustomTags for logging Request ID
* 📚 docs: fix markdown lint errors
2025-05-13 08:42:46 +02:00
RW
ab7f949382
📒 docs: Idempotency add more detailed description for next method ( #3443 )
...
* add more detailed description for next method
2025-05-12 14:59:42 +02:00
Isaac Andrade
4321dfed55
♻️ refactor: Change c.Redirect() default status ( #3415 )
...
* Set default redirect response status to 303 SeeOther
Closes #3405
In some browsers, redirect status 302 Found sometimes is used to change
the HTTP verb of the response from what the user set to what was used in
the request. Changing to 303 SeeOther in the default works more like
expected: it defaults to GET and can be overriden by the user.
* Add tests to Redirect default status change.
* Update docs.
* Fix remaining tests to reflect redirect 303 status as the new default. Reflect that in docs/whats_new.md
* Update redirect_test.go
* Fix code review hints
---------
Co-authored-by: Juan Calderon-Perez <835733+gaby@users.noreply.github.com>
Co-authored-by: René <rene@gofiber.io>
2025-05-12 14:56:23 +02:00
Yorick de Wid
057647a579
🔥 feat: Add support for ForceColors in Logger middleware ( #3428 )
...
* Force the use of terminal colors via config option
* docs: add example for forcing terminal colors in logger middleware
* test: add benchmarks for logger middleware with forced colors
* Add ForceColors field to 'whats new'
* Show example in 'whats new'
2025-05-09 13:58:41 +02:00
KatzuYoru
bfef962d86
🐛 fix: Handling of next param position ( #3418 )
...
* fix: the non updating found
* Update path.go
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* comment: describing the conditional breaking
* fix: incorrect logic in finding the cluster start chars
* refactor:comment update
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* fix: lint issue
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: RW <rene@gofiber.io>
Co-authored-by: Juan Calderon-Perez <835733+gaby@users.noreply.github.com>
2025-05-07 09:16:45 +02:00
Juan Calderon-Perez
ec4b5437e2
Merge pull request #3438 from gofiber/dependabot/go_modules/golang.org/x/crypto-0.38.0
...
build(deps): bump golang.org/x/crypto from 0.37.0 to 0.38.0
2025-05-06 20:24:02 -04:00
dependabot[bot]
c309971ed1
build(deps): bump golang.org/x/crypto from 0.37.0 to 0.38.0
...
Bumps [golang.org/x/crypto](https://github.com/golang/crypto ) from 0.37.0 to 0.38.0.
- [Commits](https://github.com/golang/crypto/compare/v0.37.0...v0.38.0 )
---
updated-dependencies:
- dependency-name: golang.org/x/crypto
dependency-version: 0.38.0
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2025-05-06 12:19:16 +00:00
AuroraTea
2ef852e1a9
📚 Doc: Fix examples in middleware/session ( #3435 )
...
📚 Doc: Fix example in middleware/session
2025-05-06 08:33:12 +02:00
Muhammad Saleh Solahudin
3f7f48e9f9
🧹 chore: Adjust Funding Custom URL ( #3432 )
...
* chore: adjust funding custom url
* chore: adjust funding custom url to github sponsors
2025-05-03 07:46:59 +02:00
Juan Calderon-Perez
85cce3c434
Merge pull request #3413 from gofiber/dependabot/github_actions/codecov/codecov-action-5.4.2
...
build(deps): bump codecov/codecov-action from 5.4.0 to 5.4.2
2025-04-15 08:15:36 -04:00
dependabot[bot]
9ed1ce1d3e
build(deps): bump codecov/codecov-action from 5.4.0 to 5.4.2
...
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action ) from 5.4.0 to 5.4.2.
- [Release notes](https://github.com/codecov/codecov-action/releases )
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md )
- [Commits](https://github.com/codecov/codecov-action/compare/v5.4.0...v5.4.2 )
---
updated-dependencies:
- dependency-name: codecov/codecov-action
dependency-version: 5.4.2
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2025-04-15 12:05:34 +00:00
Jason McNeil
6eba33af25
📒 docs: fix CSRF handler example ( #3412 )
...
docs(middleware/csrf): fix handler example
2025-04-15 08:03:30 +02:00
René
1a17500efc
repair readme benchmarks
2025-04-13 18:38:39 +02:00
René
eebe63dfd5
update benchmarks.md
2025-04-09 15:38:57 +02:00
Jason McNeil
b3e84860d2
Revert " 🔥 feat: Add Context Support to RequestID Middleware" ( #3365 )
...
Revert "🔥 feat: Add Context Support to RequestID Middleware (#3200 )"
This reverts commit f725ded92bac13e773f92ff478e1a461c160abd3.
Co-authored-by: Juan Calderon-Perez <835733+gaby@users.noreply.github.com>
2025-04-08 08:59:24 +02:00
dependabot[bot]
417dffed0e
build(deps): bump golang.org/x/crypto from 0.36.0 to 0.37.0 ( #3395 )
...
Bumps [golang.org/x/crypto](https://github.com/golang/crypto ) from 0.36.0 to 0.37.0.
- [Commits](https://github.com/golang/crypto/compare/v0.36.0...v0.37.0 )
---
updated-dependencies:
- dependency-name: golang.org/x/crypto
dependency-version: 0.37.0
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-08 08:58:31 +02:00
René
551570326c
fix go 1.24 toolchain problem
2025-04-03 14:31:59 +02:00
dependabot[bot]
694f0d77d6
build(deps): bump github.com/valyala/fasthttp from 1.59.0 to 1.60.0 ( #3391 )
...
Bumps [github.com/valyala/fasthttp](https://github.com/valyala/fasthttp ) from 1.59.0 to 1.60.0.
- [Release notes](https://github.com/valyala/fasthttp/releases )
- [Commits](https://github.com/valyala/fasthttp/compare/v1.59.0...v1.60.0 )
---
updated-dependencies:
- dependency-name: github.com/valyala/fasthttp
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-04-03 14:11:29 +02:00
RW
62b099879a
🧪 fix: Logger Middleware tests to use regex for time validation ( #3392 )
...
* test: rewrite logger format tests to use regex for time validation
* test: rewrite logger format tests to use regex for time validation
2025-04-03 13:36:30 +02:00
Juan Calderon-Perez
e7681ee402
Merge pull request #3389 from gofiber/dependabot/go_modules/github.com/gofiber/utils/v2-2.0.0-beta.8
...
build(deps): bump github.com/gofiber/utils/v2 from 2.0.0-beta.7 to 2.0.0-beta.8
2025-04-01 08:57:14 -04:00
Juan Calderon-Perez
4ad9a89e53
Update go.mod
2025-04-01 08:52:24 -04:00
dependabot[bot]
94a9496558
build(deps): bump github.com/gofiber/utils/v2
...
Bumps [github.com/gofiber/utils/v2](https://github.com/gofiber/utils ) from 2.0.0-beta.7 to 2.0.0-beta.8.
- [Release notes](https://github.com/gofiber/utils/releases )
- [Commits](https://github.com/gofiber/utils/compare/v2.0.0-beta.7...v2.0.0-beta.8 )
---
updated-dependencies:
- dependency-name: github.com/gofiber/utils/v2
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
2025-04-01 12:49:30 +00:00
Juan Calderon-Perez
d7e6413aa9
📒 docs: Update docs for State Management ( #3388 )
...
Update docs for State Management
2025-04-01 14:31:29 +02:00
JIeJaitt
c5c7f86d85
🔥 Feature: Enhance CheckConstraint method for improved error handling ( #3356 )
...
* 🔥 Feature: Enhance CheckConstraint method for improved error handling
* Revert "🔥 Feature: Enhance CheckConstraint method for improved error handling"
This reverts commit 68e8777b4cdb10702c3511a65ba76986a379a188.
* Reapply "🔥 Feature: Enhance CheckConstraint method for improved error handling"
This reverts commit 9e6c8e68df5ad43d869b6a7494e93b6fc41b4a40.
* 🚨 Test: Add comprehensive tests for CheckConstraint method with various constraint scenarios
* 🩹 Fix: lint error
* 🩹 Fix: Update CheckConstraint method to return true for noConstraint and improve error handling
* ♻️ Refactor: Remove unused CheckConstraint test cases and reorganize benchmark test cases for clarity
* ♻️ Refactor: Remove outdated test cases from path_testcases_test.go and clean up CheckConstraint method in path.go
* 📚 Doc: Update custom constraints section to clarify overriding behavior
* 🔥 Feature: Enhance CheckConstraint method for improved error handling
* Revert "🔥 Feature: Enhance CheckConstraint method for improved error handling"
This reverts commit 68e8777b4cdb10702c3511a65ba76986a379a188.
* Reapply "🔥 Feature: Enhance CheckConstraint method for improved error handling"
This reverts commit 9e6c8e68df5ad43d869b6a7494e93b6fc41b4a40.
* 🚨 Test: Add comprehensive tests for CheckConstraint method with various constraint scenarios
* 🩹 Fix: lint error
* 🩹 Fix: Update CheckConstraint method to return true for noConstraint and improve error handling
* ♻️ Refactor: Remove unused CheckConstraint test cases and reorganize benchmark test cases for clarity
* ♻️ Refactor: Remove outdated test cases from path_testcases_test.go and clean up CheckConstraint method in path.go
* 📚 Doc: Update custom constraints section to clarify overriding behavior
* 📚 Doc: Add caution note about custom constraints overriding built-in constraints in routing guide
---------
Co-authored-by: Juan Calderon-Perez <835733+gaby@users.noreply.github.com>
Co-authored-by: RW <rene@gofiber.io>
2025-04-01 08:48:19 +02:00
Jason McNeil
bb12633c8b
Revert " 🔥 feat: Add support for context.Context in keyauth middleware" ( #3364 )
...
Revert "🔥 feat: Add support for context.Context in keyauth middleware (#3287 )"
This reverts commit 4177ab4086a97648553f34bcff2ff81a137d31f3.
Co-authored-by: Juan Calderon-Perez <835733+gaby@users.noreply.github.com>
2025-03-31 16:55:01 +02:00
Juan Calderon-Perez
36b93818f9
Merge pull request #3384 from gofiber/dependabot/go_modules/github.com/fxamacker/cbor/v2-2.8.0
...
build(deps): bump github.com/fxamacker/cbor/v2 from 2.7.0 to 2.8.0
2025-03-31 08:26:44 -04:00
Juan Calderon-Perez
dec28010e9
Update go.mod
2025-03-31 08:14:32 -04:00
Juan Calderon-Perez
2f794d9f88
Update go.mod
2025-03-31 08:14:18 -04:00
dependabot[bot]
d8f9548650
build(deps): bump github.com/fxamacker/cbor/v2 from 2.7.0 to 2.8.0
...
Bumps [github.com/fxamacker/cbor/v2](https://github.com/fxamacker/cbor ) from 2.7.0 to 2.8.0.
- [Release notes](https://github.com/fxamacker/cbor/releases )
- [Commits](https://github.com/fxamacker/cbor/compare/v2.7.0...v2.8.0 )
---
updated-dependencies:
- dependency-name: github.com/fxamacker/cbor/v2
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
2025-03-31 12:07:59 +00:00
Kashiwa
c2e39b7570
♻️ Refactor: Add findNextNonEscapedCharPosition for single-byte charset cases ( #3378 )
...
♻️ Refactor: add findNextNonEscapedCharsetPosition to process a single-byte parameter
```
goos: linux
goarch: amd64
pkg: github.com/gofiber/fiber/v3
cpu: AMD EPYC 9J14 96-Core Processor
│ old.txt │ new.txt │
│ sec/op │ sec/op vs base │
_RoutePatternMatch//api/v1/const_|_match_|_/api/v1/const-16 160.4n ± 1% 159.0n ± 0% -0.84% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1-16 151.6n ± 0% 150.8n ± 0% -0.53% (p=0.005 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/-16 151.7n ± 0% 150.6n ± 0% -0.73% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/something-16 162.3n ± 0% 160.8n ± 0% -0.96% (p=0.000 n=20)
_RoutePatternMatch//api/:param/fixedEnd_|_match_|_/api/abc/fixedEnd-16 452.9n ± 1% 435.8n ± 0% -3.79% (p=0.000 n=20)
_RoutePatternMatch//api/:param/fixedEnd_|_not_match_|_/api/abc/def/fixedEnd-16 455.6n ± 1% 435.7n ± 0% -4.38% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity-16 524.4n ± 1% 507.6n ± 1% -3.19% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/-16 528.2n ± 0% 508.7n ± 0% -3.69% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/1-16 528.1n ± 0% 510.6n ± 0% -3.31% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v-16 500.3n ± 0% 489.0n ± 0% -2.27% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v2-16 502.1n ± 0% 489.9n ± 0% -2.44% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v1/-16 515.5n ± 0% 498.8n ± 0% -3.24% (p=0.000 n=20)
geomean 339.4n 331.1n -2.46%
│ old.txt │ new.txt │
│ B/op │ B/op vs base │
_RoutePatternMatch//api/v1/const_|_match_|_/api/v1/const-16 144.0 ± 0% 144.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1-16 136.0 ± 0% 136.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/-16 136.0 ± 0% 136.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/something-16 152.0 ± 0% 152.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/:param/fixedEnd_|_match_|_/api/abc/fixedEnd-16 368.0 ± 0% 368.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/:param/fixedEnd_|_not_match_|_/api/abc/def/fixedEnd-16 368.0 ± 0% 368.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity-16 432.0 ± 0% 432.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/-16 432.0 ± 0% 432.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/1-16 432.0 ± 0% 432.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v-16 424.0 ± 0% 424.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v2-16 424.0 ± 0% 424.0 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v1/-16 424.0 ± 0% 424.0 ± 0% ~ (p=1.000 n=20) ¹
geomean 288.8 288.8 +0.00%
¹ all samples are equal
│ old.txt │ new.txt │
│ allocs/op │ allocs/op vs base │
_RoutePatternMatch//api/v1/const_|_match_|_/api/v1/const-16 4.000 ± 0% 4.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1-16 4.000 ± 0% 4.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/-16 4.000 ± 0% 4.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/something-16 4.000 ± 0% 4.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/:param/fixedEnd_|_match_|_/api/abc/fixedEnd-16 9.000 ± 0% 9.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/:param/fixedEnd_|_not_match_|_/api/abc/def/fixedEnd-16 9.000 ± 0% 9.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity-16 9.000 ± 0% 9.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/-16 9.000 ± 0% 9.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/1-16 9.000 ± 0% 9.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v-16 9.000 ± 0% 9.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v2-16 9.000 ± 0% 9.000 ± 0% ~ (p=1.000 n=20) ¹
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v1/-16 9.000 ± 0% 9.000 ± 0% ~ (p=1.000 n=20) ¹
geomean 6.868 6.868 +0.00%
¹ all samples are equal
```
2025-03-31 09:49:40 +02:00
M. Efe Çetin
d19e993597
✨ feat: Add support for application state management ( #3360 )
...
* ✨ feat: add support for application state management
* increase test coverage
* fix linter
* Fix typo
* add GetStateWithDefault helper
* add docs
* update what's new
* add has method
* fix linter
* update
* Add missing helpers for golang built-in types
* Fix lint issues
* Fix unit-tests. Update documentation
* Fix docs, add missing benchmarks
* Fix tests file
* Update default example and test
* Apply suggestions from code review
---------
Co-authored-by: Juan Calderon-Perez <835733+gaby@users.noreply.github.com>
Co-authored-by: Juan Calderon-Perez <jgcalderonperez@protonmail.com>
Co-authored-by: RW <rene@gofiber.io>
2025-03-31 09:31:59 +02:00
Juan Calderon-Perez
75281bd874
🧹 chore: Simplify HealthCheck middleware ( #3380 )
...
* Simplify middleware
* Rename default endpoints
2025-03-30 11:46:52 +02:00
Kashiwa
e90fe8afbc
♻️ Refactor: remove redundant field method
in DefaultCtx
( #3372 )
...
* ♻️ Refactor: remove redundant field method in defaultCtx
* ♻️ Refactor: rename getMethodINT to getMethodInt
2025-03-26 13:16:53 +01:00
Juan Calderon-Perez
dab20c9df5
🧹 chore: Add Immutable benchmarks for default case ( #3374 )
...
Add benchmarks for default case with Immutable
2025-03-26 13:09:43 +01:00
Kashiwa
4bf292945d
♻️ Refactor: reduce DefaultCtx from 736 to 728 bytes ( #3368 )
2025-03-25 08:30:41 +01:00
Mazyar Yousefiniyae shad
7606c618d3
📚 Doc: Add more validation examples ( #3369 )
...
* add examples on valudator guid
* ref: return prev validation comment
2025-03-25 08:25:56 +01:00
Kashiwa
ef40c04ede
♻️ Refactor: reduce DefaultCtx from 768 bytes to 736 bytes ( #3353 )
...
* ♻️ Refactor: reduce DefaultCtx from 768 bytes to 736 bytes
* ♻️ Refactor: add comments
---------
Co-authored-by: Juan Calderon-Perez <835733+gaby@users.noreply.github.com>
2025-03-23 16:58:43 +01:00
Edvard
e947e03ed2
🔥 feat(logger): Add predefined log formats ( #3359 )
...
* feat(logger): Add predefined log formats
This commit introduces predefined log formats for the logger middleware, enhancing its flexibility and ease of use. Users can now specify formats like "common", "combined", and "json" in addition to the default format.
Changes:
- Added a `format.go` file to store predefined log format constants.
- Updated `config.go` to include documentation for the `Format` configuration option, explaining the available placeholders and predefined formats.
- Modified `logger.go` to utilize the predefined formats based on the `Format` configuration.
- Added a new test case `Test_Logger_CLF` in `logger_test.go` to verify the "common" log format.
* feat(logger): Use predefined formats and fix default format
This commit updates the logger middleware to utilize the predefined log formats introduced in a previous commit. It also fixes the default format to use the `FormatDefault` constant.
Changes:
- Updated `config.go` to use `FormatDefault` constant for the default format.
- Updated `default_logger.go` to use `FormatDefault` constant for the default format.
- Added new test cases in `logger_test.go` to verify the "common", "combined" and "json" log formats.
- Updated `format.go` to add newline character to the end of the default format.
* feat(logger): Document and exemplify predefined formats
* fix(logger): Improve test assertions based on golangci-lint
* docs(logger): Improve documentation and formatting logger.md based on markdownlint-cli2
* docs(logger): Improve documentation based on markdownlint-cli2
* fix(logger): Improve combined and JSON format tests
* feat(logger): Add ECS log format
* feat(logger): Add CustomFormat option
This commit introduces a `CustomFormat` option to the `Config` struct, allowing users to specify a predefined format (like "common", "combined", "json", or "ecs")
* feat(logger): Add ECS log format to examples and config
* docs(logger): Update examples in whats_new.md
* feat(logger): Remove CustomFormat option and renamed Format consts
- Removed `CustomFormat` field from `Config`.
- Removed `LoggerConfig` map.
- Rename predefined formats constants.
* docs(logger): Update documentation and examples after format refactor
---------
Co-authored-by: Juan Calderon-Perez <835733+gaby@users.noreply.github.com>
2025-03-21 16:13:21 +01:00
Oleksandr Redko
f6ac929fde
🧹 chore: Mark unused tests with t.SkipNow ( #3366 )
...
* 🚨 test: uncomment test and mark it with t.SkipNow
* fix lint issues
2025-03-20 14:35:59 +01:00
M. Efe Çetin
87f3f0c8b6
🐛 bug: fix client iterators when using break statement ( #3357 )
...
* 🐛 bug: fix client iterators when using break statement
* fix linter
2025-03-19 11:00:16 +01:00
Juan Calderon-Perez
395c8fafa9
🧹 chore: Fix linter workflow failures ( #3354 )
...
* Fix linter workflow failures
* Bump golang.org/x/net to v0.36.0
* Try skipping golangci-lint cache
* Update linter.yml
* fix: directives and spaces
* fix: better configuration
* fix: golangci-lint install
* Update golangci-lint version
* Enable SA4023
* Update golangci-lint config
* Remove duplicated rule
---------
Co-authored-by: Fernandez Ludovic <ldez@users.noreply.github.com>
2025-03-17 08:29:51 +01:00
Juan Calderon-Perez
b56a141d59
docs: Update helmet.md default values ( #3350 )
...
Update helmet.md
2025-03-14 07:51:34 +01:00
Juan Calderon-Perez
ef4437cd65
Merge pull request #3348 from devhaozi/patch-1
...
docs: Update Helmet Middleware default values
2025-03-12 19:20:10 -04:00
耗子
eb7b00b4fb
fix: default value comment
2025-03-13 01:44:57 +08:00
JIeJaitt
c0599ee1d4
🔥 feat: Add Skip function to logger middleware ( #3333 )
...
* 🔥 Feature(logger): Add Filter option to logger middleware
* 📚 Doc(logger): Clarify Filter middleware description
* 🚨 Test(logger): Enhance logger filter test with parallel subtests
* 🔒 Test(logger): Add mutex to prevent race conditions in logger test
* 🔥 Feature(logger): Add Filter option to logger middleware
* 📚 Doc(logger): Clarify Filter middleware description
* 🚨 Test(logger): Enhance logger filter test with parallel subtests
* 🔒 Test(logger): Add mutex to prevent race conditions in logger test
* 🚨 Test(logger): Refactor logger test to improve test isolation
* Fix issue with unit-tests
* Update middleware/logger/logger_test.go
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
* Apply logger filter as soon as possible
* 📚 Doc: Add logger filter configuration example to whats_new.md
* 📚 Doc: Update logger filter documentation in whats_new.md
* 📚 Doc: Update logger filter documentation and examples
* 🩹 Fix: improve what_new.md
* Update logic for Filter() in Logger middleware. Add more unit-tests
* Rename fields to match expressjs/morgan
* Update middleware/logger/default_logger.go
---------
Co-authored-by: Juan Calderon-Perez <jgcalderonperez@protonmail.com>
Co-authored-by: Juan Calderon-Perez <835733+gaby@users.noreply.github.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: RW <rene@gofiber.io>
2025-03-10 09:06:11 +01:00
Kashiwa
1b26cf6b5e
♻️ Refactor: optimize routeParser by using sync.Pool ( #3343 )
...
* ♻️ Refactor: add routerParser pool
```
goos: linux
goarch: amd64
pkg: github.com/gofiber/fiber/v3
cpu: AMD EPYC 9J14 96-Core Processor
│ ori.txt │ pool.txt │
│ sec/op │ sec/op vs base │
_RoutePatternMatch//api/v1/const_|_match_|_/api/v1/const-16 173.9n ± 0% 159.3n ± 1% -8.37% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1-16 163.9n ± 0% 150.9n ± 0% -7.90% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/-16 165.4n ± 1% 150.6n ± 1% -8.95% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/something-16 174.9n ± 0% 160.6n ± 0% -8.15% (p=0.000 n=20)
_RoutePatternMatch//api/:param/fixedEnd_|_match_|_/api/abc/fixedEnd-16 520.2n ± 0% 438.1n ± 1% -15.78% (p=0.000 n=20)
_RoutePatternMatch//api/:param/fixedEnd_|_not_match_|_/api/abc/def/fixedEnd-16 521.8n ± 0% 436.8n ± 0% -16.29% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity-16 630.0n ± 0% 525.0n ± 0% -16.67% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/-16 633.3n ± 0% 526.4n ± 0% -16.89% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/1-16 627.8n ± 0% 527.5n ± 0% -15.97% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v-16 602.1n ± 0% 501.9n ± 0% -16.65% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v2-16 604.9n ± 0% 504.3n ± 0% -16.62% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v1/-16 616.7n ± 0% 512.8n ± 1% -16.86% (p=0.000 n=20)
geomean 390.5n 336.5n -13.84%
│ ori.txt │ pool.txt │
│ B/op │ B/op vs base │
_RoutePatternMatch//api/v1/const_|_match_|_/api/v1/const-16 152.0 ± 0% 144.0 ± 0% -5.26% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1-16 144.0 ± 0% 136.0 ± 0% -5.56% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/-16 144.0 ± 0% 136.0 ± 0% -5.56% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/something-16 160.0 ± 0% 152.0 ± 0% -5.00% (p=0.000 n=20)
_RoutePatternMatch//api/:param/fixedEnd_|_match_|_/api/abc/fixedEnd-16 440.0 ± 0% 368.0 ± 0% -16.36% (p=0.000 n=20)
_RoutePatternMatch//api/:param/fixedEnd_|_not_match_|_/api/abc/def/fixedEnd-16 440.0 ± 0% 368.0 ± 0% -16.36% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity-16 536.0 ± 0% 432.0 ± 0% -19.40% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/-16 536.0 ± 0% 432.0 ± 0% -19.40% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/1-16 536.0 ± 0% 432.0 ± 0% -19.40% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v-16 528.0 ± 0% 424.0 ± 0% -19.70% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v2-16 528.0 ± 0% 424.0 ± 0% -19.70% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v1/-16 528.0 ± 0% 424.0 ± 0% -19.70% (p=0.000 n=20)
geomean 337.9 288.8 -14.52%
│ ori.txt │ pool.txt │
│ allocs/op │ allocs/op vs base │
_RoutePatternMatch//api/v1/const_|_match_|_/api/v1/const-16 5.000 ± 0% 4.000 ± 0% -20.00% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1-16 5.000 ± 0% 4.000 ± 0% -20.00% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/-16 5.000 ± 0% 4.000 ± 0% -20.00% (p=0.000 n=20)
_RoutePatternMatch//api/v1/const_|_not_match_|_/api/v1/something-16 5.000 ± 0% 4.000 ± 0% -20.00% (p=0.000 n=20)
_RoutePatternMatch//api/:param/fixedEnd_|_match_|_/api/abc/fixedEnd-16 13.000 ± 0% 9.000 ± 0% -30.77% (p=0.000 n=20)
_RoutePatternMatch//api/:param/fixedEnd_|_not_match_|_/api/abc/def/fixedEnd-16 13.000 ± 0% 9.000 ± 0% -30.77% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity-16 14.000 ± 0% 9.000 ± 0% -35.71% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/-16 14.000 ± 0% 9.000 ± 0% -35.71% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_match_|_/api/v1/entity/1-16 14.000 ± 0% 9.000 ± 0% -35.71% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v-16 14.000 ± 0% 9.000 ± 0% -35.71% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v2-16 14.000 ± 0% 9.000 ± 0% -35.71% (p=0.000 n=20)
_RoutePatternMatch//api/v1/:param/*_|_not_match_|_/api/v1/-16 14.000 ± 0% 9.000 ± 0% -35.71% (p=0.000 n=20)
geomean 9.811 6.868 -29.99%
```
* 🩹 Fix: golangci-lint problem
2025-03-10 09:04:04 +01:00
Kashiwa
600ebd95ce
♻️ Refactor: replace isInCharset with bytes.IndexByte ( #3342 )
2025-03-07 15:33:22 +01:00
vinicius
4177ab4086
🔥 feat: Add support for context.Context in keyauth middleware ( #3287 )
...
* feat(middleware): add support to context.Context in keyauth middleware
pretty straightforward option to use context.Context instead of just
fiber.Ctx, tests added accordingly.
* fix(middleware): include import that was missing from previous commit
* fix(middleware): include missing import
* Replace logger with panic
* Update keyauth_test.go
* Update keyauth_test.go
---------
Co-authored-by: Juan Calderon-Perez <835733+gaby@users.noreply.github.com>
2025-03-07 08:23:24 +01:00
Juan Calderon-Perez
208b9e36ba
Merge pull request #3341 from gofiber/dependabot/go_modules/golang.org/x/crypto-0.36.0
...
build(deps): bump golang.org/x/crypto from 0.35.0 to 0.36.0
2025-03-06 07:43:17 -05:00