Commit Graph

21 Commits

Author SHA1 Message Date
pj 6fcfcb1ac0 export ErrConnectionClosed (#2152) 2026-03-04 08:40:34 +09:00
Erik Dubbelboer 0ad54a45d9 Update lint and fix new lint errors 2025-09-28 02:59:00 +02:00
Erik Dubbelboer d356cacd84 Implement io.StringWriter on some more types (#2023)
In theory this can optimize some code paths where a string first needs
to be converted to a []byte to use the normal Write method. By
implementing WriteString this extra copy isn't needed. Internall we
don't do the copy and just use s2b instead.
2025-06-19 08:59:25 +02:00
Juan Calderon-Perez 1fb3453165 Use Named Fields and Align Structures to Reduce Memory Usage (#1814)
* Use Named fields and Align Structures to Reduce Memory Usage

* Remove extra spaces
2024-08-02 22:26:52 +02:00
Oleksandr Redko f196617f55 chore: Use 'any' instead of 'interface{}' (#1666)
gofmt -w -r "interface{} -> any" -l .
2023-11-24 11:33:04 +01:00
Oleksandr Redko ffdf59d04c Enable gofumpt linter; format code gofumpt -w . (#1576) 2023-06-13 15:18:59 +02:00
Tobias Krischer 951f5a154c add optional simulated addresses to pipeconn and inmemorylistener (#1449)
* add optional simulated addresses to pipeconn and inmemorylistener

* add mutexes to addresses of pipeConn and InmemoryListener
2022-12-07 13:31:42 +08:00
Andy Pan b32a3dda13 Use time.Until(deadline) instead of -time.Since(deadline) (#1434) 2022-11-16 06:13:29 +02:00
Aoang ea6052464e Add Go 1.19 Support (#1355)
* Update Go Version to Go1.19.x And add cache

* Fix CI Line endings

* Update test CI Go Version to Go1.19.x And add cache

* Update Gosec Security Scanner CI to securego/gosec@v2.12.0

* Format comment

Go 1.19 adds support for links, lists, and clearer headings in doc comments. As part of this change, gofmt now reformats doc comments to make their rendered meaning clearer. See “Go Doc Comments” for syntax details and descriptions of common mistakes now highlighted by gofmt. As another part of this change, the new package go/doc/comment provides parsing and reformatting of doc comments as well as support for rendering them to HTML, Markdown, and text.

ref: https://tip.golang.org/doc/go1.19
ref: https://tip.golang.org/doc/comment

* Fix doc structure
2022-08-14 11:31:57 +02:00
Erik Dubbelboer 69d5c3721a Client should return ErrTimeout on timeout (#736)
Not ErrConnectionClosed which is incorrect.

Fixes: https://github.com/valyala/fasthttp/issues/355
2020-01-31 22:21:00 +01:00
Erik Dubbelboer 32793db72d Run golangci-lint using a Github Action 2019-11-16 18:09:28 +01:00
Erik Dubbelboer 4ebe993965 Document PipeConns not being safe for concurrent use 2019-10-16 10:20:13 +02:00
rogercarter1 044d35e5ef fix 664 (#674) 2019-10-16 16:18:52 +08:00
Kazushi Kitaya 8713335f54 Fix data race in fasthttputil.pipeConn (#645)
* add tests for fasthttputil.InmemoryListener
* fix data race in pipeConn
* update use of readDeadlineChLock
2019-09-04 17:57:51 +02:00
xPushkin f24d00fcc6 A lot of typo fixes 2017-10-08 13:30:35 +01:00
Aliaksandr Valialkin 31a397777b fasthttputil.PipeConns: add read/write deadline support 2016-09-26 18:09:21 +03:00
Aliaksandr Valialkin c665919a09 Fixed a race when reading data from pipe. This fixes flacky tests involving fasthttputil.PipeConns: TestResponseGzipStream and TestWorkerPoolMaxWorkersCountSerial 2016-08-17 17:42:10 +03:00
Aliaksandr Valialkin 80af8b2b97 Simplified PipeConns - now they properly handle the case when reader side is closed 2016-06-10 19:56:11 +03:00
Aliaksandr Valialkin 69793f7224 Fixed data races in PipeConns 2016-03-01 02:03:26 +02:00
Aliaksandr Valialkin ec922ac0b8 typo fix 2016-02-05 17:46:49 +02:00
Aliaksandr Valialkin 6723a2a0fc fasthttputil: renamed files: pipe -> pipeconns 2016-02-05 16:41:32 +02:00