7ffdff37e4
chore: upgrade golangci-lint configuration and optimize codebase ( #4236 )
...
This PR includes the following changes:
- **Upgrade `.golangci.yml`**: Updated the configuration file to align
with the latest golangci-lint version, ensuring compatibility and
leveraging new features.
- **Refactor GitHub Action workflow**: Modified `golangci-lint.yml` in
the GitHub Actions workflow to reflect the updated configuration and
improve CI performance.
- **Codebase optimization**: Refactored code to address issues and
warnings raised by the updated golangci-lint rules, including:
- Improved function length and complexity.
- Enhanced error handling and variable naming conventions.
- Fixed minor issues such as unused imports and formatting
inconsistencies.
These changes aim to maintain code quality, ensure compatibility with
the latest tools, and improve overall maintainability.
2025-08-22 13:29:09 +08:00
9033ca087b
fix(net/ghttp): improve GetMetaTag method to handle nil and type checks
2025-05-16 17:55:00 +08:00
1534abdb05
feat(util/gpage): marked deprecated ( #4230 )
2025-04-02 19:56:28 +08:00
fee38b4531
feat(net/ghttp): enhance GetHeader method to support default values ( #4210 )
2025-03-25 20:42:30 +08:00
07696fc779
feat(net/ghttp): add GetMetaTag function to retrieve metadata value for HandlerItem ( #4206 )
2025-03-17 09:21:00 +08:00
bc1e1019c5
refract(util/gconv): change Converter interface definition for more convenient usage ( #4202 )
2025-03-14 18:23:07 +08:00
bb696bb281
refract(net/ghttp): move Request.GetMetaTag to HandlerItemParsed.GetMetaTag ( #4191 )
2025-03-12 21:55:35 +08:00
f8331bad6e
feat(net/ghttp): add Request.GetMetaTag to retrieve specific meta tag value ( #4185 )
2025-03-09 11:17:41 +08:00
bcda48bf82
fix(net/ghttp):check parameter existence to determine using default or front-end value. ( #4182 )
2025-03-08 20:56:27 +08:00
dfe088f5cd
refactor(util/gconv): add Converter feature for more flexable and extensible type converting ( #4107 )
2025-03-06 23:04:26 +08:00
63cb3285f8
fix(net/ghttp): update response message handling in MiddlewareHandlerResponse ( #4162 )
2025-02-27 11:59:26 +08:00
6bd15b0796
merge master
2025-01-22 19:17:16 +08:00
99f0fb14a1
fix(net/ghttp): BufferWriter.Flush writes additional information after custom response wrote ( #4116 )
2025-01-22 09:28:06 +08:00
e0f734851e
fix(net/ghttp): MiddlewareHandlerResponse writes additional information after custom response wrote ( #4109 )
2025-01-14 09:28:19 +08:00
89e5285d95
feat(net/ghttp): move plugin remove logic to Shutdown() && call Shutdown() when Run() exits ( #4072 )
2024-12-26 10:18:47 +08:00
594979c5af
fix(net/ghttp): nil pointer panic error when server logger set nil ( #4055 )
2024-12-19 22:31:17 +08:00
00e2f6b5dc
chore: improve golangci-lint.yml, upgrade dependencies, and optimize code and comments ( #4025 )
2024-12-11 10:14:12 +08:00
38bffc77e2
fix(net/ghttp): occasional ci failed by unit testing cases using gctp.GetFreePort ( #3982 )
2024-12-10 09:52:48 +08:00
bae78fbf5b
feat(net/ghttp): add middleware MiddlewareGzip for compressing response content using gzip ( #4008 )
2024-12-09 23:12:09 +08:00
b0b84a3937
ci(gci/import): improve golangci.yml and add gci linter ( #4010 )
2024-12-07 14:17:33 +08:00
5fa33411fc
chore: add example for openapi/swagger authentication ( #4004 )
2024-12-05 15:49:50 +08:00
c0f2ef7348
feat(gctx): rename and remove gctx functions to prevent ambiguity ( #3892 )
2024-12-05 14:47:39 +08:00
e572ed01b3
fix(net/ghttp): get origin through referer ( #3990 )
2024-12-01 10:05:46 +08:00
3d4904eb3d
feat(net/ghttp): remove Req/Res suffix limitation for input/output parameters of strict router handler ( #3848 )
2024-11-14 17:58:39 +08:00
ab3fbddfc7
build(go.mod): upgrade minimum required go version from 1.18 to 1.20 ( #3688 )
2024-09-28 20:58:04 +08:00
55b92151f4
refactor(net/ghttp): enhance ghttp.StartPProfServer ( #3555 )
2024-09-28 18:10:53 +08:00
79451e4624
fix(net/ghttp&gclient,contrib/rpc/grpcx): remove request and response contents in opentelemetry tracing attributes ( #3810 )
2024-09-26 09:50:07 +08:00
9af8393758
fix(net/goai): change default value of RequestBody.Required from true to false, add required tag support for RequestBody ( #3796 )
2024-09-24 11:51:53 +08:00
8a1c97f518
fix(util/gconv): cached field indexes append issue caused incorrect field converting ( #3790 )
2024-09-23 19:05:32 +08:00
c4327f62e7
fix(net/ghttp): server shutdown not graceful using admin api /debug/admin/shutdown ( #3777 )
2024-09-19 14:10:16 +08:00
3d63ebfe81
fix(net/ghttp): skip common response body in common response handler for streaming content types ( #3762 )
2024-09-12 17:50:43 +08:00
dba6c08548
net/ghttp: fix Content-Type for jsonp response from application/json to application/javascript ( #3651 )
2024-06-24 21:37:49 +08:00
7d464d4de2
net/ghttp: fix args issue for forkRestartProcess in graceful restarting of ghttp.Server ( #3661 )
2024-06-24 20:53:37 +08:00
fba878f47a
net/ghttp: update error message for duplicated routes registering ( #3603 )
2024-06-13 21:16:11 +08:00
23df83cb0b
database/gdb: fix deadlock when orm operations perform in cache function from gcache ( #3585 )
2024-05-22 21:14:43 +08:00
d7a0482146
fix : #3465 If the value of a string is null, the value of string is nil after the string is converted to []string ( #3468 )
2024-04-10 20:18:03 +08:00
83ba887df7
fix : #3449 accept slice parameter as json.RawMessage for http request ( #3452 )
2024-04-07 14:09:52 +08:00
1c12f3a30d
fix: http superfluous response.WriteHeader call in some scenario ( #3428 )
2024-03-28 22:08:54 +08:00
3a9e0e34ca
fix : #3432 Add Access-Control-Expose-Headers: Content-Disposition header in ServeFileDownload ( #3433 )
2024-03-28 20:07:56 +08:00
8669512f42
feat: add metric feature support in goframe ( #3138 )
2024-03-24 21:18:30 +08:00
a8713da97f
enhance: cut tracing content as unicode for safety ( #3342 )
2024-03-13 19:21:16 +08:00
df15d70466
enhance: change tracing span name from request uri to router uri for http request ( #3338 )
2024-03-05 21:11:27 +08:00
ce3ef13e6a
fix: otel tracing content contains invalid UTF-8 ( #3340 )
2024-02-29 20:22:42 +08:00
51326f3d02
fix #3245 ( #3298 )
2024-02-06 11:47:25 +08:00
e1fa99013a
use iota to unify the enums definition ( #3305 )
2024-02-06 11:44:29 +08:00
cc79d23334
fix issue #2457 ( #3297 )
2024-02-02 10:57:24 +08:00
b4f6f06ab5
no printing internal middleware for ghttp.Server ( #3271 )
2024-01-22 21:05:40 +08:00
951f8921cd
fix #3237 ( #3267 )
2024-01-17 15:35:48 +08:00
ca242ff401
fix #3251 ( #3254 )
2024-01-11 22:15:22 +08:00
4f4d2c2f8e
add MiddlewareNeverDoneCtx for package ghttp ( #3250 )
2024-01-06 13:03:49 +08:00