-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1,398 changed files
with
167,514 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,122 @@ | ||
--- | ||
slug: '/release/v2.9' | ||
title: 'v2.9' | ||
sidebar_position: -2 | ||
hide_title: true | ||
keywords: [] | ||
description: '' | ||
unlist: true | ||
--- | ||
|
||
|
||
|
||
|
||
# 主要内容 | ||
|
||
本次版本变更内容较多,以下为本次版本的主要内容,详细的`Change Log`请参考: | ||
[https://github.com/gogf/gf/releases/tag/v2.9.0](https://github.com/gogf/gf/releases/tag/v2.9.0) | ||
|
||
完整的代码变更请参考:[https://github.com/gogf/gf/compare/v2.8.0...v2.9.0](https://github.com/gogf/gf/compare/v2.8.0...v2.9.0) | ||
|
||
|
||
## 兼容提示 | ||
|
||
## 组件改进 | ||
2. `net/ghttp` | ||
- 新增常用中间件`MiddlewareGzip`支持,用于使用`gzip`算法压缩返回结果:https:// 应当整理提供的中间件文档。 | ||
- 去掉规范路由注册时对`api`定义时输入输出数据结构的`*Req/*Res`命名规则限制。 | ||
- 修复跨域返回`Header`中自动从`Referer`生成`Origin`逻辑不严谨的问题。 | ||
- 修复`BuildParams`方法构建请求参数时针对`json omitempty`标签失效问题。 | ||
- 修复`Logger`设置为`nil`时会引发的空指针`panic`问题。 | ||
|
||
2. `net/client` | ||
- 在全局的服务注册发现组件开启时,该组件创建的`HTTP Client`对象不再默认启用服务发现功能,需要手动开启。 | ||
|
||
1. `database/gdb` | ||
- 新增分库分表特性:https:// | ||
- 新增事务传播特性以及隔离级别、只读模式支持:https:// | ||
- 新增`WhereExists/WhereNotExists`方法支持:https:// | ||
- 新增对`unix socket`数据库链接配置的支持。 | ||
- 修复在`OnDuplicate`方法中使用`gdb.Counter`类型失效问题:https:// | ||
- 修复当用户增加`Select Hook`并修改返回结构后,部分场景下导致`Count/Value/Array`查询结构异常问题。 | ||
- 修复在使用`with`特性时,数据结构中`embedded struct`的元数据标签中的`orm`标签失效问题。 | ||
|
||
3. `net/goai` | ||
- 支持`OpenAPIv3.1`协议。 | ||
- 新增返回数据结构扩展能力:https:// | ||
- 新增自动识别数据校验规则`min/max/length/min-length/max-length/between`为`OpenAPIv3`中对应的校验数据结构。 | ||
- 修复参数数据结构中`embedded struct`数据结构无法扩展为参数结构的问题。 | ||
|
||
4. `errors/gerror` | ||
- 新增`As`方法支持:https:// | ||
|
||
4. `utils/gvalid` | ||
- 修复`enums`参数使用指针时`enums`校验失效的问题。 | ||
|
||
4. `os/glog` | ||
- 日志默认时间打印格式调整为更严谨的`2006-01-02T15:04:05.000Z07:00`。 | ||
|
||
4. `os/gsession` | ||
- 新增`RegenerateId/MustRegenerateId`方法支持,用以手动重新生成`Session ID`:https:// | ||
|
||
|
||
4. `os/gview` | ||
- 修复个别场景下从资源管理器中读取模板文件失败的问题。 | ||
|
||
5. `os/gcmd` | ||
- 命令行参数默认值支持输出到命令帮助界面:https:// | ||
|
||
5. `net/gipv4` | ||
- 改进`ip`地址和`uint32`相互转换实现逻辑。 | ||
|
||
5. `util/gconv` | ||
- 改进`Scan`方法,增加`Scan`到基础数据类型的转换支持:https:// | ||
|
||
6. `test/gtest` | ||
- 改进`AssertNI/AssertIN`方法,增加`map`类型支持:https:// | ||
|
||
## 社区组件 | ||
1. `drivers/pgsql` | ||
- 增加对`pgsql`数组字段类型`varchar[]/text[]`的转换支持,自动转换为Go`[]string`类型。 | ||
- 改进数组类型转换性能。 | ||
|
||
2. `contrib/config/polaris` | ||
- 新增更多的数据格式内容支持,支持`yaml/toml/json/xml/ini/properties`等格式。 | ||
|
||
2. `contrib/registry/consul` | ||
- 新增`consul`服务注册发现组件支持:https:// | ||
|
||
3. `contrib/registry/etcd` | ||
- 新增重试机制,解决`lease`租约过期时的重续问题。 | ||
- 删除默认的`AutoSyncInterval`配置项,解决个别场景下由该默认配置引发的`etcd`阻塞问题。 | ||
|
||
4. `contrib/config/nacos` | ||
- 新增`OnChange`回调配置支持。 | ||
|
||
5. `contrib/metric/otelmetric` | ||
- 新增`WithExemplarFilter`选项支持。 | ||
|
||
## 开发工具 | ||
1. 改进`gf init`命令,初始化项目的模板内容发生了改变。 | ||
2. 改进`gf up`命令,在终端中展示更优雅的`cli`文件下载界面效果。 | ||
3. 改进`gf gen ctrl`命令,`api`中定义的注释将会自动同步到生成的控制器代码中。 | ||
4. 改进`gf gen dao`命令: | ||
- 新增分表选项参数`shardingPattern/sp`,用于定义分表规则,生成支持分库的`dao`代码:https:// | ||
- 改进代码生成模板,支持`Golang Template`语法。 | ||
5. 改进`gf gen enums`命令: | ||
- 修改默认读取的接口数据结构定义目录为`api` | ||
- 修改默认生成代码文件路径为`internal/packed/packed_enums.go` | ||
3. 改进`gf gen genpbentity`命令: | ||
- 增加`TypeMapping`和`FieldMapping`特性支持:https:// | ||
- 增加`TablesEx`支持,用于生成`proto`文件时可以忽略指定的表。 | ||
- 增加`GoPackage`选项用于指定生成`proto`文件中的`go_package`配置项。 | ||
3. 修复`gf build`命令在打印环境变量时不准确的问题,应当打印编译文件时,修改环境变量后,真实使用的环境变量。 | ||
3. 修复`gf gen pb`命令在部分场景下使用`-a`选项时,多次执行命令后,自定义标签重复添加的问题。 | ||
|
||
|
||
## 功能修复 | ||
1. 修复`os/gcache`组件中`Remove`方法返回的数据类型与旧版本不兼容的问题。 | ||
2. 修复`database/gdb`组件中`tinyint(1)/int(1)`类型识别为`bool`类型与旧版本不兼容的问题。 | ||
3. 修复`database/gdb`组件中`Order("id", "dasc")`语句与旧版本不兼容的问题。 | ||
4. 修复`registry/zookeeper`组件中带有额外后缀`-`的服务名称路径监听错误。 | ||
5. 修复`cmd/gf`组件中`make`命令在项目模板中生成的`Makefile`文件中的命令不正确的问题。 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+64.2 KB
i18n/en/docusaurus-plugin-content-docs/version-2.8.x/community/支持我们/img.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
55 changes: 55 additions & 0 deletions
55
i18n/en/docusaurus-plugin-content-docs/version-2.8.x/community/支持我们/代码文档贡献.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
--- | ||
slug: '/supportus/pr' | ||
title: 'Become a Contributor' | ||
sidebar_position: 1 | ||
hide_title: true | ||
keywords: [GoFrame, GoFrame framework, open source, code contribution, documentation contribution, GitHub, gitee, open source project, PR process, framework development] | ||
description: 'GoFrame is an open-source, free framework, welcoming all developers to contribute to its code and documentation. Through the main GitHub repository, you can take part in code contribution and be part of our development history. Additionally, you can help promote the GoFrame framework by improving official documentation, writing blogs, or creating videos.' | ||
--- | ||
|
||
`GoFrame` is open-source, free software, which means anyone can contribute to its development and progress. The project's source code is currently hosted on both `GitHub` (primary repository) and `gitee` (domestic) platforms, with both repositories kept in real-time synchronization. Code contributions are unified through the primary GitHub repository. We warmly welcome more friends to join in the development of the `GoFrame` framework, and any contributions you make will be recorded in the annals of `GoFrame`. | ||
|
||
Contributions can generally be divided into two categories: **code contribution** and **documentation contribution**. | ||
|
||
## 1. Code Contribution | ||
|
||
### 1. Where to Find Tasks | ||
|
||
In the main repository’s `issues`, there are many `issues` labeled with `help wanted`, eagerly awaiting contributions from community members: [Click here for the address](https://github.com/gogf/gf/issues?q=is%3Aissue+is%3Aopen+label%3A%22help+wanted%22) | ||
|
||
 | ||
|
||
### 2. Code Contribution Process | ||
|
||
1. First, `fork` the repository code to your own repository. | ||
2. Create a new development branch in your repository, make changes to the code, and submit the changes to your repository. | ||
3. Create a `pull request` in your repository, selecting your development branch as the source branch and the primary repository's `master` branch as the target branch: [https://help.github.com/en/articles/creating-a-pull-request](https://help.github.com/en/articles/creating-a-pull-request) | ||
4. Submit the `pull request`, then wait for the project developers to do a `code review` on the submission. If the `pull request` is not reviewed for a long time, you can actively follow up and request a `code review` from team members. Once approved, you will become a member of the `GoFrame` framework. | ||
5. Congratulations, your name will be permanently recorded in the list of contributors to the `GoFrame` framework source code. | ||
|
||
### 3. Code Collaboration Conventions | ||
|
||
1. All source code files, types, and methods should have detailed comments. | ||
2. Explanation of implementation ideas is needed for sections with complex logic. | ||
3. All comments should be written in English, not in Chinese. | ||
4. New features/modules must have unit tests, with coverage exceeding `80%`. | ||
|
||
## 2. Documentation Contribution | ||
|
||
### 1. Improving the Official Website | ||
|
||
The documentation of the `GoFrame` framework is mainly concentrated in the `gf-site` repository, address: [https://github.com/gogf/gf-site](https://github.com/gogf/gf-site) | ||
|
||
While reading the documentation, if you find areas that are not quite complete, you can click to edit the page to help improve it. This is especially true for examples on how to use components and functions, which can often be supplemented. | ||
|
||
### 2. Blogs and Video Tutorials | ||
|
||
Community members can write articles or record videos to share, making it easier for other community members to find your share through search engines, facilitating mutual learning, and promoting open-source projects. | ||
|
||
Please keep the framework name keyword unified as `GoFrame` in the articles, and do not use abbreviations. | ||
|
||
## 3. Other Assistance | ||
|
||
Any help can be requested by contacting WeChat `389961817`. I will provide the necessary guidance and assistance. | ||
|
||
 |
74 changes: 74 additions & 0 deletions
74
i18n/en/docusaurus-plugin-content-docs/version-2.8.x/community/支持我们/加入社区团队.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
--- | ||
slug: '/supportus/team' | ||
title: 'Join the Community Team' | ||
sidebar_position: 2 | ||
hide_title: true | ||
keywords: [GoFrame, GoFrame Framework, Open Source Project, Community Team, Technical Sharing, Project Development, Open Source Contribution, Career Competitiveness, Technical Growth, Technical Exchange] | ||
description: 'As the GoFrame framework continues to grow, we are committed to further improvement, enhancing releases to attract more attention. Joining the community team allows you to solve real-world problems, stay updated with the latest developments, participate in internal design and technical discussions, and enjoy a sense of achievement and technical enhancement through occasional sharing. Additionally, you can expand your network with like-minded tech enthusiasts, enhancing your resume competitiveness. Actively participate in project development and promotion, handle community issues together, and share your experiences. Strict criteria ensure the quality of our members, and mature enterprises are welcome to contribute.' | ||
--- | ||
|
||
## 1. Why Recruit for the Community? | ||
|
||
- As the `GoFrame` open source project becomes more robust and comprehensive, we aim to make it even better, more complete, and more powerful! We need more strength! | ||
- With the release of the new `v2` version, `GoFrame` has reached a new milestone, and we want more people to recognize the value created by our relentless efforts! | ||
- Propel `GoFrame` into a community-driven project! | ||
|
||
## 2. What Can You Gain by Joining the Community Team? | ||
|
||
### 1. Solve Real-World Issues in Your Work | ||
By using `GoFrame` and becoming part of its team, you'll gain access to more principles and details than others, helping you solve challenging real-world project issues. | ||
|
||
### 2. Stay Updated with the Latest Development Dynamics of Open Source Projects | ||
In the future, we will distribute first-hand project information within the community team, positioning it as the backbone for `GoFrame`'s external promotion and evangelism. | ||
|
||
### 3. Participate in Internal Project Design and Technical Discussions | ||
We aim to integrate more ideas and experiences into the project's outcomes, collectively setting the direction for the project's future development. | ||
|
||
### 4. Participate Occasionally in Internal Technical Sharing | ||
We hope every team member can share their learning insights and research results both internally and externally. | ||
|
||
### 5. Sense of Achievement and Recognition | ||
Years of dedication and community recognition make us believe that this persistence is valuable. | ||
|
||
### 6. Technical Growth and Enhancement | ||
Enhance your understanding of framework design and underlying principles. You'll also encounter various business requirement scenarios, industry-leading or practical solutions. | ||
|
||
### 7. Resume Enhancement | ||
Increase your competitiveness in the job market. Technical leaders appreciate open-source contributors but focus more on your role in the community, your efforts, and the results of your contributions. | ||
|
||
### 8. Expand Technical Networking | ||
Meet more like-minded experts. | ||
|
||
## 3. We Also Have a Gentleman's Agreement! | ||
|
||
### 1. Actively Participate in Project Development | ||
Any `feature, enhancement, bug fix` is highly welcomed. The `issue` section has an endless flow of community requests, and we hope you'll actively contribute. | ||
|
||
### 2. Actively Promote and Evangelize this Project | ||
Be it videos, articles, or discussions, as the backbone of the community, we expect you to actively promote and share the outstanding content, designs, and ideas of the `GoFrame` community across platforms. | ||
|
||
### 3. Actively Participate in Project `issue` Handling and Community Problem Solving | ||
Actively engage in resolving queries to establish and maintain a positive `GoFrame` community image. You're not fighting alone; when encountering difficulties or tricky issues, you can collaborate with team members to resolve challenges. | ||
|
||
### 4. Actively Participate in Internal Team Communication and Technical Sharing | ||
Whether in the community, workplace, or life, we hope you are proactive and willing to share. We can engage with you during your shares, learning, and growing together. | ||
|
||
## 4. Criteria for Becoming a Community Team Member | ||
|
||
To ensure the quality of the team and project, we have cautiously set some basic criteria for joining. | ||
|
||
- First, you must have already used `GoFrame` in real projects and are eager to deepen your understanding. | ||
- Second, you should be interested in participating in `GoFrame` community building with community members during your spare time. | ||
- Last, recognize that open source is valuable, but like life, it's filled with ups and downs. | ||
|
||
:::tip | ||
Furthermore, coming from and giving back to the community, we warmly welcome contributions from enterprises to jointly build the community, forming a positive cooperation loop between enterprises and the community. Interested enterprises are encouraged to contact us; we will reserve a spot for you. | ||
::: | ||
|
||
## 5. How to Become a Community Team Member | ||
|
||
If you're interested and meet the conditions, please contact the project initiator via WeChat and send a brief self-introduction. | ||
|
||
If you are an open-source veteran, just send your `GitHub` profile link. | ||
|
||
 |
10 changes: 10 additions & 0 deletions
10
i18n/en/docusaurus-plugin-content-docs/version-2.8.x/community/支持我们/支持我们.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
--- | ||
slug: '/supportus' | ||
title: 'Support Us' | ||
sidebar_position: 1 | ||
hide_title: true | ||
--- | ||
|
||
import DocCardList from '@theme/DocCardList'; | ||
|
||
<DocCardList /> |
36 changes: 36 additions & 0 deletions
36
i18n/en/docusaurus-plugin-content-docs/version-2.8.x/community/社区交流/技术交流群.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
--- | ||
slug: '/share/group' | ||
title: 'Online Chat Group' | ||
sidebar_position: 0 | ||
hide_title: true | ||
keywords: [GoFrame, GoFrame Framework, Technical Exchange Group, QQ Group, WeChat Group, Practical Group, Programming Community, Software Development, Developer Communication, GoFrame Official Account] | ||
description: "Join the technical exchange group of the GoFrame framework, participate in the GoFrame practical group and WeChat group, and get the latest updates and technical exchanges on the framework's development. We offer multiple QQ groups and WeChat groups for enthusiasts to share experiences and exchange development insights, while continuously following the latest news about GoFrame." | ||
|
||
--- | ||
|
||
## Join the QQ Group | ||
|
||
Scan or search the group number to add. | ||
|
||
### GoFrame Practical Group 1 | ||
Full | ||
|
||
### GoFrame Practical Group 2 | ||
Full | ||
|
||
### GoFrame Practical Group 3 | ||
<img src="/markdown/qq3.png" style={{width: 200}} /> | ||
|
||
Click the link to join the group chat "GoFrame Practical Group 3": [https://qm.qq.com/q/K7UMKSrVq8](https://qm.qq.com/q/K7UMKSrVq8) | ||
|
||
## Join the WeChat Group | ||
|
||
Scan or add WeChat `389961817`, note `join` to join the group | ||
|
||
<img src="/markdown/57c4df7168f6b77c3442e823b65613f8.png" style={{width: 200}} /> | ||
|
||
## WeChat Official Account | ||
|
||
Follow the development updates of `GoFrame` | ||
|
||
<img src="/markdown/70f36333b6b87dde47e529951ce4dbc4.jpg" style={{width: 200}} /> |
66 changes: 66 additions & 0 deletions
66
...us-plugin-content-docs/version-2.8.x/community/社区交流/技术分享交流/0-2021-03-12 初次见面.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
--- | ||
slug: '/share/2021-03-12' | ||
title: '2021-03-12 First Meeting' | ||
sidebar_position: 0 | ||
hide_title: true | ||
keywords: [GoFrame, GoFrame framework, technical sharing, online meetup, framework introduction, framework design, modular design, unified framework design, code layer design, community-driven development] | ||
description: 'This GoFrame technical sharing introduces its framework design concepts and modular design, including unified framework design and code layer design, without involving specific skills. The event includes an interaction session between developers and the author using Tencent Meeting. We welcome everyone to prepare questions and join the discussion.' | ||
--- | ||
|
||
Hello everyone! | ||
|
||
To fulfill our promise to the community, we plan to hold the first `GoFrame` technical sharing (online meetup)! The theme of this sharing is: **Introduction and Design of the GoFrame Framework**. | ||
|
||
At the same time, we will also have a face-to-face interaction session between developers and the author, with ample time reserved for discussion. Everyone is encouraged to prepare questions they wish to ask. | ||
|
||
To ensure a good discussion experience, the Q&A session will use Tencent Meeting. Please join the meeting in advance if you intend to ask questions. | ||
|
||
## I. Content Outline | ||
|
||
This session will mainly share some design concepts of the framework, without discussing specific usage skills. | ||
|
||
1. [Framework Introduction (Latest Version)](https://goframe.org/) | ||
2. Initial Goals | ||
3. [Framework Design](../../../docs/框架设计/框架设计.md) | ||
- [Modular Design](../../../docs/框架设计/模块化设计.md) | ||
- [Unified Framework Design](../../../docs/框架设计/统一框架设计.md) | ||
- [Code Layering](../../../docs/框架设计/工程开发设计/代码分层设计.md) | ||
4. Other Miscellaneous Items | ||
5. Community-Driven Development Plans | ||
6. Interaction Session | ||
|
||
## II. How to Join | ||
|
||
### Bilibili Live | ||
|
||
[http://live.bilibili.com/22901270](https://live.bilibili.com/22901270) | ||
|
||
### Tencent Meeting | ||
|
||
Guo Qiang invites you to join a Tencent Meeting | ||
|
||
Meeting topic: GoFrame First Meeting | ||
|
||
Meeting time: 2021/03/12 19:00-20:00 (GMT+08:00) China Standard Time - Beijing | ||
|
||
Click the link to join the meeting or add it to your meeting list: | ||
|
||
[https://meeting.tencent.com/s/yNMOX0LDlY8N](https://meeting.tencent.com/s/yNMOX0LDlY8N) | ||
|
||
Meeting ID: **135 616 293** | ||
|
||
Mobile one-tap dialing to join | ||
|
||
+8675536550000,,135616293# (Mainland China) | ||
|
||
+85230018898,,,2,135616293# (Hong Kong, China) | ||
|
||
Dial according to your location | ||
|
||
+8675536550000 (Mainland China) | ||
|
||
+85230018898 (Hong Kong, China) | ||
|
||
PS: | ||
|
||
You can also comment on this article with your questions to allow us to prepare in advance and improve communication efficiency during the event. |
Oops, something went wrong.