1
0
mirror of https://github.com/gofiber/fiber.git synced 2025-02-24 05:43:57 +00:00

3003 Commits

Author SHA1 Message Date
RW
4b62cfbb61
Add test run for go1.17 (#1501)
* Add test run for go1.17

default type for yaml is changed to „application/x-yaml"
-> instead of the yaml´s we use the html and json files for the test
2021-08-22 09:48:07 +02:00
Pranay
670170f7c5
📝 Update: Add JSONDecoder to config (#1489)
* 📝 Update: Add JSONDecoder to config
2021-08-18 14:26:07 +02:00
RW
385c94adcd
prepare release 2.17.0
prepare release 2.17.0
v2.17.0
2021-08-12 08:20:49 +02:00
Pranay
f014d143ac
Update README.md (#1477) 2021-08-07 21:20:26 +02:00
Paul Cento
15987a2677
♻️ Refactor: remove use of deprecated functions (#1474) 2021-08-06 07:56:36 +02:00
thinklucrative
9a7b08ee23
Update README.md (#1472)
Typo:
var ConfigDefault = Config{
	KeyLookUp:    "cookie:session_id",
}

should be:
var ConfigDefault = Config{
	KeyLookup:    "cookie:session_id",
}
2021-08-05 20:14:32 +02:00
ProExpertProg
dd153adfdb
Fix route.Path on copy (#1471) 2021-08-05 07:32:05 +02:00
András Czigány
5f1acd3c56
🔥 Feature: Add Skip middleware (#1465)
* add Skip middleware

* middleware/skip: fix test expectations
2021-08-04 10:05:29 +02:00
goldwind-ting
846d5a5b38
[Logger]: add tag for response header (#1446)
* add TagRespHeader to get response header

* #1422:add unittest

* #1422:adjust docs for logger middleware

* #1422:adjust docs for logger middleware
2021-08-04 08:19:41 +02:00
RW
7ad55451a0
Fix: Fiber Client does multiple requests when using Timeout() and MaxRedirectsCount() #1457 (#1464)
* Fiber Client does multiple requests when using Timeout() and MaxRedirectsCount() 🐛 #1457
2021-08-02 10:43:10 +02:00
RW
5636441fe5
prepare release 2.16.0
prepare release 2.16.0
v2.16.0
2021-07-30 20:40:44 +02:00
RW
34520e75f8
Fix - 🐛 The escape of special characters in route path does not work properly #1454 (#1462)
* Fix - 🐛 The escape of special characters in route path does not work properly #1454
2021-07-30 20:39:10 +02:00
RW
d777d889bb
Fix cache expired test (#1461)
* Improve/Stabilize the "Test_Cache_Expired" test run
2021-07-30 20:19:18 +02:00
faceair
1e0d4d3b1c
🐛 fix parse gzipped body (#1458) 2021-07-30 08:02:02 +02:00
Vahagn Mkrtchyan
f0ab2a5433
Add option to specify default values for ParamsInt (#1453) 2021-07-26 19:50:56 +02:00
Marcos de Oliveira
30ba99425f
Add ${port} logger variable (#1448)
* Add c.Addr() and c.Port() functions and logger port variable

* Add gofmt suggestion, README.md description and test

* Remove c.Addr() func and use c.fasthttp.RemoteAddr() instead
2021-07-22 17:42:29 +02:00
HugHunter
7cd8219420
Update README.md (#1444)
spotted a small mistake in the docs
2021-07-19 12:51:03 +02:00
Kazumasa Takenaka (Bamboo)
f5338266e3
fix typo (#1442)
paramters -> parameters
avilable  -> available
seperated -> separated
2021-07-17 17:20:14 +02:00
wja513
dd45be693a
cookie: add possibility to disable same site attribute (#1428)
* fix some old browsers cann't set the cookie if it contains SameSite property.

* add "SameSite" attribute constants and test case.

Co-authored-by: wangjiangao <wangjiangao@360.cn>
2021-07-16 20:08:17 +02:00
RW
005471d7ca
prepare release 2.15.0 v2.15.0 2021-07-16 08:45:10 +02:00
Sujit Baniya
8ab5c657c6
🔥 FEATURE: Allow adding App Name to customizing the startup message (#1418)
* Add Global Layout for view render

* Add test case for Views Layout

* Update ctx_test.go

* Add App Name function to pass custom app name

* Remove json tag for function

* Change func to string

* Add test for AppName

Co-authored-by: RW <rene@gofiber.io>
2021-07-16 08:44:11 +02:00
wernerr
c8d0a0c2ae 📚 Correct order of the basic routing example 2021-07-14 08:00:33 +02:00
Spedoske
cd802dfead
Fix: copy the data in buffer instead of using original data. (#1425) 2021-07-11 12:35:02 +02:00
Troy
08b2b71197
Add support for streaming the request body. (#1423)
* update fasthttp

* allow req body streaming

* multipart form streaming

* update fasthttp

* allow req body streaming

* multipart form streaming

* Testing
2021-07-11 11:45:46 +02:00
tuhao1020
a109dc6c68
Schema parser: use full match instead of strings.HasPrefix (#1424)
* #1414 use full match instead of strings.HasPrefix

* update for  nested or recursive structs

* replace strings.Contains with strings.IndexByte
2021-07-11 11:45:15 +02:00
Jefferson Maia
b5cb8549e0
fix: Installation section translation correction (#1432) 2021-07-11 11:42:29 +02:00
RW
ff57431cde
prepare release 2.14.0 v2.14.0 2021-07-01 14:10:54 +02:00
Oleg Roshnivskyy
5ba78cd24a
🔥 Feature: Add TrustedProxies feature (#1397)
* 🔥 Feature: Add TrustedProxies feature

Add TrustedProxies feature to prevent HTTP header spoofing.

* Update ctx.go

* Update app.go

* Update app.go

Co-authored-by: hi019 <65871571+hi019@users.noreply.github.com>
2021-06-30 08:03:45 +02:00
Spedoske
e082880297
Fix: Session middleware issues (#1407)
* Update session.go

Fix: Session.Regenerate does not set Session.fresh to be true.

* Fix: Session should be regenerated if the session can not be found in the storage
https://github.com/gofiber/fiber/issues/1408

* Add test for session and store in session middleware.

* Clean up code

* Update middleware/session/session.go

Co-authored-by: hi019 <65871571+hi019@users.noreply.github.com>
2021-06-30 08:01:22 +02:00
alfuhigi
28ba42a6fd
✏️ fix [🔑gosec|passing] icon -> README_*.md (#1405)
* ✏️ fix [🔑 gosec|passing] icon -> README_*.md that not show correctly

* 🚩  drop .PNG, use SVG base64 for Flag
2021-06-25 08:25:38 +02:00
alfuhigi
43876dad8f
🧹 remove duplicate in test (#1404) 2021-06-24 12:29:48 +02:00
tuhao1020
93dc33ad89
add tls config for http client in proxy middleware (#1393)
* add tls config for http client in proxy middleware

* update exmaple and make tls.config also affects to proxy.Balancer

* add Test_Proxy_Forward_WithTlsConfig

* add a variable of type *tls.Config

* add a RWMutex for clientTlsConfig

* remove global tls config

* Update README.md

* Update proxy.go

Co-authored-by: RW <rene@gofiber.io>
2021-06-24 08:13:18 +02:00
Andreas
2703e92c5d
Added decompression cases for Body function (#1402)
* Added decompression cases for Body function

* Fixed signature of Body() function

* Removed regex, added Header.Peek

* Added test case with compression

* Added Benchmark, moved compression names to helpers and made them constants

* Added long brotli as a constant

* Update ctx.go

improve Body function

* Update ctx.go

improve performance

* Fixed formatting

* Update helpers.go

Co-authored-by: RW <rene@gofiber.io>
2021-06-24 07:47:21 +02:00
Joey
843fab720e
📝 update license 2021-06-23 06:28:46 +02:00
Tomás Warynyca
b72297ee66
fix readme zh-CN (#1400) 2021-06-22 12:10:04 -04:00
Wei Lun
41b642fbd3
deprecate feature-policy (#1392) 2021-06-21 08:49:49 +02:00
Javad Rajabzade
7609117cec
Improved some conditions (#1386)
* simplify `u <= (1<<7)-1` to `u < (1 << 7)`

* It's not recommended to use `len` for empty string, we can check with string with ""

* It's not recommended to use `len` for empty string, we can check with string with ""

* It's not recommended to use `len` for empty string, we can check with string with ""

* It's not recommended to use `len` for empty string, we can check with string with ""

* Instead Bool comparison can using simplified bool check if !var = false checking

* Unnecessary use of fmt.Sprintf for value without format

* For check condition two value not required ! method

* nil check may not be enough for slice, better check with len

* function parameters combined

* When the form returns error information, the text content should not start with a capital letter or end with a punctuation mark

* error var invalidPath should have name of the form errFoo, It is recommended that the error variables that are part of an API should be named

* change to condition len(x), it's faster https://github.com/gofiber/fiber/pull/1386#discussion_r652369520

* Update write.go

* Update write_bytes.go

* Update store.go

Co-authored-by: RW <rene@gofiber.io>
2021-06-17 22:03:59 +02:00
RW
1def652e57
prepare release 2.13.0
prepare release 2.13.0
v2.13.0
2021-06-16 19:57:55 +02:00
George Goranov
1852224001
Expose internal errors. (#1387) 2021-06-16 10:58:22 +02:00
Sujit Baniya
cb5f2f7eab
🔥 Add Global ViewLayout (#1384)
* Add Global Layout for view render

* Add test case for Views Layout

* Update ctx_test.go
2021-06-14 11:10:49 +02:00
João Victor Santos
c08568e247
🔥 feat: expiration per session (#1363)
* feat(middlewares): expiration per session

* test(middlewares): session with expiration

* docs(middlewares): session

* chore: apply suggestions from code review
2021-06-13 12:39:19 +02:00
Ilya Chukov
89fdbcf036
Improve errors handling (#1381)
* replace `fmt.Errorf` to `errors.New`

* changed once `Sprintf` to `Join`
2021-06-13 11:11:42 +02:00
Wei Lun
bca01cc9cc
🔥 Feature: add cache header to show cache status (#1368)
* add cache header to show cache status

* update default CacheHeader to X-Cache

* add CacheHeader test

* Update cache_test.go

use constants in test

Co-authored-by: RW <rene@gofiber.io>
2021-06-13 10:52:03 +02:00
Javad Rajabzade
6da6678325
Fixed Grammar (#1373)
* Add README_fa.md for persian users

* Add flag IR for fix Error: URI Too Long

* Modfied flag image png to svg

* Modified IR flag url for src

* Fixed grammar
2021-06-09 08:29:44 +02:00
Javad Rajabzade
556df42956
Add README_fa.md for Persian users (#1370)
* Add README_fa.md for persian users

* Add flag IR for fix Error: URI Too Long

* Modfied flag image png to svg

* Modified IR flag url for src
2021-06-08 23:09:20 +02:00
Dio Rovelino
eaf35e9e55
Update Readme ID (#1372) 2021-06-08 23:05:10 +02:00
RW
3698ed6ddd
prepare release 2.12.0 v2.12.0 2021-06-06 09:51:58 +02:00
hi019
a7d9c6816e
Fix session delete when there is one key (#1366)
* Add regression test, attempt solution

* Attempt 2
2021-06-05 20:15:06 +02:00
RW
8e89949381
🚀 Configure proxy.Balancer with custom timeout #1362 (#1364)
* 🚀 new possibility to escape special routing parameters, which gives the possibility to follow the google api design guide https://cloud.google.com/apis/design/custom_methods

* 🚀 new possibility to escape special routing parameters, which gives the possibility to follow the google api design guide https://cloud.google.com/apis/design/custom_methods

* 🚀 Configure proxy.Balancer with custom timeout or client #1362

* 🚀 Configure proxy.Balancer with custom timeout or client #1362
2021-06-04 16:54:03 +02:00
bestgopher
2d6323c197
:fix #1360 (#1361) 2021-06-03 16:02:17 +02:00