Searching txt.sour.is

Twts matching #1:
Sort by: Newest, Oldest, Most Relevant

GoCN 每日新闻 (2022-01-16)

GoCN 每日新闻 (2022-01-16)
  1. Golang 1.18 官方 Tutorial: 开始使用泛型https://juejin.cn/post/7053427624902656030
  2. 使用 Go 语言从 0 到 1 实现一个 CNI 插件https://mp.weixin.qq.com/s/lUsRww74DZlRU3vTYbfFbQ
  3. 深入浅出 Golang 资源嵌入方案:前篇https://mp.weixin.qq.com/s/1wlaGMXvk_uGGjAr7BjjlQ
  4. Go 静态编译机制https://juejin.cn/post/7053450610386468894
  5. Golan … ⌘ Read more

⤋ Read More

GoCN 每日新闻 (2022-1-15)

  1. https://jogendra.dev/writing-maintainable-go-code Writing maintainable Go code
  2. https://mp.weixin.qq.com/s/h8vhy8IJKnA8aNbTlCoQtg 理解 go 中空结构体的应用和实现原理
  3. https://juejin.cn/post/7053109648223633438 Go 并发写 map 产生错误能够通过 recover() 恢复吗?
  4. [https://soulteary.com/2022/01/15/explain-the-golang-resource-embedding-solution-part-1.html](https://soulteary.com/2022/01/15/exp … ⌘ Read more

⤋ Read More

Netflix Raises Monthly Subscription Prices in US, Canada
Netflix has raised its monthly subscription price by $1 to $2 per month in the United States depending on the plan, the company said on Friday, to help pay for new programming to compete in the crowded streaming TV market. From a report: The standard plan, which allows for two simultaneous streams, now costs $15.49 per month, up from $13.99, in the Unite … ⌘ Read more

⤋ Read More

GoCN 每日新闻(2022-01-14)

  1. 《Go 组件设计与实现》-netpoll 的总结https://www.cnblogs.com/codexiaoyi/p/15798780.html
  2. Uber 對 Golang GC 的調整https://blog.gslin.org/archives/2022/01/13/10503/uber-%e5%b0%8d-golang-gc-%e7%9a%84%e8%aa%bf%e6%95%b4/
  3. 基于 etcd 实现大规模服务治理应用实战https://mp.weixin.qq.com/s/zOZrCNZ9X6IyKxzRMeReWg
  4. 勒索软件正在用 Go 重写,用于联合攻击 Window … ⌘ Read more

⤋ Read More

GoCN 每日新闻 (2021-12-31)

  1. 快速了解 “小字端” 和 “大字端” 及 Go 语言中的使用https://developer.51cto.com/art/202112/697505.htm
  2. Golang 与非对称加密https://www.ssgeek.com/post/golang-yu-fei-dui-cheng-jia-mi
  3. 一文搞懂 Docker、Containerd、RunC 间的联系和区别https://mp.weixin.qq.com/s/kVh_EXGeMy_UI6qIgbmsGQ
  4. Golang 项目的配置管理——Viper 简易入门配置[https://www.cnblogs.com/Mrxuexi/p/15750455.html](https://www.cnblogs.com … ⌘ Read more

⤋ Read More

GoCN 每日新闻 (2022-01-13)
GoCN 每日新闻 (2022-01-13)

  1. Golang《基于 MIME 协议的邮件信息解析》部分实现https://gocn.vip/topics/20948
  2. 泛型可以拯救 Golang 笨拙的错误处理吗?https://blog.dnmfarrell.com/post/can-generics-rescue-golangs-clunky-error-handling/
  3. 更多的并行,并不等同更高的性能https://convey.earth/conversation?id=44
  4. 为什么 Go 有两种声明变量的方式,有什么区别,哪种好? [https://mp.weixin.qq.com/s/ADwEhSA1kFOFqzIyWvAqsA](https://mp.weixin.q … ⌘ Read more

⤋ Read More

Go 分布式令牌桶限流 + 兜底策略
上篇文章提到固定时间窗口限流无法处理突然请求洪峰情况,本文讲述的令牌桶线路算法则可以比较好的处理此场景。

工作原理
  1. 单位时间按照一定速率匀速的生产 token 放入桶内,直到达到桶容量上限。
  2. 处理请求,每次尝试获取一个或多个令牌,如果拿到则处理请求,失败则拒绝请求。

Image

优缺点

优点

可以有效处理瞬间的突发流量,桶内存量 token 即可作为流量缓冲区平滑处理突发流量。

缺点

实现较为复杂。

代码实现

core/limit/tokenlimit.go

分布式环境下考虑使用 redis 作为桶和令牌的存储容器,采用 lua 脚本实现整个算法流程。

redis lua 脚本


<span class="c1">-- 每秒生成token数量即token生成速度</span>
<span class="kd">local</span> <span class="n">rate</span> <span cl ... ⌘ [Read more](https://gocn.vip/topics/20950)

⤋ Read More

Go 模糊测试

从 Go 1.18 版本开始,标准工具集开始支持模糊测试。

概述

模糊测试(Fuzzing)是一种自动化测试方法,通过不断地控制程序输入来发现程序错误�� … ⌘ Read more

⤋ Read More

hconfig 一个可插拔的 Golang 配置管理工具 支持(etcd/k8s(kubernetes)/apollo)

hconfig 一个可插拔的 Golang 配置管理工具 支持(etcd/k8s(kubernetes)/apollo) 什么是可插拔式程序
  • 一个统计的可插拔内核
  • 各个组件相互独立
可插拔式程序
  1. 在设计一个可插拔式程序时我们应该想到的是怎么把我们的需求给实现了,然后我们再搞一波抽象(统计的可插拔内核

不同的模块只要实现了� … ⌘ Read more

⤋ Read More

Switching to Purelymail
After long consideration, I have now moved email for all but my main domain (but that’s coming too) to Purelymail. Email without bullshit. And with the “Advanced billing mode” they really only charge by usage or $10 per year with the “Simple billing”, but even with Advanced that shouldn’t be much more than $1 per month for me. ⌘ Read more

⤋ Read More

Switching to Purelymail
After long consideration, I have now moved email for all but my main domain (but that’s coming too) to Purelymail. Email without bullshit. And with the “Advanced billing mode” they really only charge by usage or $10 with the “Simple billing”, but that shouldn’t be much more than $1 per month for me. What I like most is that there is no unnecessary limit on the number of users, aliases or custom domains. 👍 ⌘ Read more

⤋ Read More

Ignite Realtime Blog: Openfire 4.5.6 is released
Openfire 4.5.6 has been released, that addresses an annoying issue that was affecting the earlier 4.5.5 release. We’ve updated the bundled log4j library to version 2.17.1 for good measure.

The changelog denotes the two Jira issues closed by this release. You can find Openfire build artifacts available for download [here](https://github.com/igniterealtime/Openfire/rel … ⌘ Read more

⤋ Read More

GoCN 每日新闻(2022-01-04)

GoCN 每日新闻(2022-01-04)
  1. 「GoCN 酷 Go 推荐」go 语言位操作库 — bitsethttps://mp.weixin.qq.com/s/UcuKgKnt4fwrg3c-UHc3sw
  2. Go 通过 Map/Filter/ForEach 等流式 API 高效处理数据https://mp.weixin.qq.com/s/7ATm_Zu7ib9MXf8ugy3RcA
  3. 优化 Go 二进制文件的大小[https://prog.world/optimizing-the-size-of-the-go-binary](https://prog.world/optimizing-the-si … ⌘ Read more

⤋ Read More

What’s new in dubbo-go-pixiu 0.4.0
Dubbo-go-pixiu 是一款高性能 API 网关,支持 Dubbo 和 Http 等多种协议。具体介绍文章可以参考 《Dubbo 跨语言调用神兽:dubbo-go-pixiu》

近期社区发布了 0.4.0 版本,具体请查看 v0.4.0。相关改进实在太多,本文只列出相关重大 feature、bugfix 、 性能提升项。

1 动态从 Spring Cloud 和 Dubbo 注册中心拉取路由和集群配置数据

Pixiu 原本依赖本� … ⌘ Read more

⤋ Read More

潘娟:Keep open,Stay tuned 开源为我打开的全新世界 | TiDB Hackathon 2021 评委访谈
距离 2022.1.8-9 比赛日,已不到两周时间,想必各位参赛选手已经摩拳擦掌,开始准备自己的项目了。\
在等待最终比赛日的这段时间,TiDB 社区采访了本届 Hackathon 中的一位女性评委,她在数据库领域中耕耘多年,从 DBA 到创业者,具有着传奇色彩的人生经历。\
我们通过访谈记录了她对开源的理解与感悟,同时探讨 Hackathon 活动的� … ⌘ Read more

⤋ Read More

Ignite Realtime Blog: Openfire 4.6.7 released (Log4j 2.17.1 only change)
Openfire 4.6.7 has been released with only a single change to bump the bundled log4j library to version 2.17.1. Whilst we do not believe Openfire to be vulnerable to the CVEs associated with the log4j 2.17.0 and 2.17.1 releases, we realize that many folks are running naive security scanners that are simply checking for bundled jar versions.

The [changelog](https://download.igniterealtime.org/open … ⌘ Read more

⤋ Read More

GinAdmin 后台管理模板

GinAdmin

这个项目是以 Gin 框架为基础搭建的后台管理平台,虽然很多人都认为 go 是用来开发高性能服务端项目的,但是也难免有要做 web 管理端的需求,总不能再使用别的语言来开发吧。所以整合出了 GinAdmin 项目,请大家多提意见指正!欢迎 star ⭐⭐

Image

Image

依赖
  • golang > 1.8
  • Gin
  • BootStrap
  • LayUi
  • WebUpload
  • [Light Year Admin Using Ifra … ⌘ Read more

⤋ Read More

go 语言位操作库 bitset
bitset库 实现了 bitsets 数据结构,这是一种正整数和布尔值映射关系的结构,它比 map[uint]bool 更高效

什么是 bitsets

bitsets 基本思想是用一个 bit 位来标记某个元素对应的 Value,每一位表示一个数,1 表示存在,0 表示不存在
比如我要表示 1, 3, 7 这 3 个数

  1. 构造一个空白 bitsets:00000000
  2. 每位代表的值如下:76543210
  3. 想要表示的值标记 1:10001010
有什么好处?

�� … ⌘ Read more

⤋ Read More

GoCN 每日新闻 (2021-12-30)
GoCN 每日新闻 (2021-12-30)

  1. 如何在 Go 中将 [] byte 转换为 io.Reader?https://mp.weixin.qq.com/s/nFkob92GOs6Gp75pxA5wCQ
  2. 彻底搞懂 Kubernetes 中的 Eventshttps://mp.weixin.qq.com/s/QRIck4M1-CJVrVDoJEsjQA
  3. 对比 Rust 和 Go 对二进制数据处理[https://medium.com/@protiumx/advent-of-code-rust-go-and-binary-operators-7dd03057c134](https://medium.com/@protiumx/advent-o … ⌘ Read more

⤋ Read More

Paul Schaub: PGPainless 1.0.0 Released!
Close to the end of 2021 I’m excited to announce the release of PGPainless version 1.0.0! After a series of release candidates, it is finally time to party! The OpenPGP library successfully underwent a security audit in late November and I feel like it finally reached a state of sufficient maturity to be worthy of a major release with a “1” at the front.

![](https://blog.jabberhead.tk/wp-content/uploads/2021/12/francesco- … ⌘ Read more

⤋ Read More

参加过 4 届 TiDB Hackathon 是一种什么体验? | TiDB Hackathon 选手访谈

Image

TiDB Hackathon 2021 自 12 月 9 日开启报名至今,已经收到 259 名参赛者报名,组队 64 支,光是队名就脑洞大开,如:渡渡鸟复兴会、LET ETL ROCK、队长负责带饭、小母牛坐飞机、双呆、OneLastCode、TiDB 十年老粉等等,项目 idea 也充满各种奇思妙想。

目前�� … ⌘ Read more

⤋ Read More

GoCN 每日新闻 (2021-12-24)
GoCN 每日新闻 (2021-12-24)

  1. ccgo 更新添加 macOS clang 支持https://pkg.go.dev/modernc.org/ccgo/v3
  2. 一个简单强大的 SSH 秘钥管理器https://golangexample.com/skm-a-simple-and-powerful-ssh-keys-manager/
  3. golang 会缓存 dns 吗[https://www.reddit.com/r/golang/comments/rn9b6d/is_golang_caching_dns/](https://www.reddit.com/r/golang/comments/rn9b6d/is_golang_ca … ⌘ Read more

⤋ Read More

《真·简单》Golang 轻量级桌面程序 wails 库(圣诞节限定)

Golang 轻量级桌面程序 wails2 教学 推荐理由

不依赖 cgo! 不依赖 cgo! 不依赖 cgo!真的不依赖 cgo,且跨平台,原生渲染 无嵌入式浏览器,轻量级,生成的文件很小,而且只有一个可执行文件就可运行。

功能介绍
  1. 后端使用标准 Go
  2. 使用任意前端技术构建 UI 界面
  3. 快速为您的 Go 应用生成 Vue、Vuetify、React 前端代码
  4. 通过简 … ⌘ Read more

⤋ Read More

GoCN 每日新闻(2021-12-22)

GoCN 每日新闻(2021-12-22)
  1. 使用 Go 和 SQLite 构建生产应用程序
  2. 使用 context.Context 模拟 API 客户端https://incident.io/blog/golang-client-mocks
  3. 一种可嵌入的 Go 脚本语言,实现了逻辑编程语言 Prologhttps://github.com/ichiban/prolog
  4. SSA:终于知道编译器偷摸做了哪些事[https://mp.weixin.qq.com/s/nOhMsMeP1pUFEXKAMUzbWg](https://mp.weixin.qq.com/ … ⌘ Read more

⤋ Read More

干货来了!神州数码 CIO 沈旸揭秘 Hackathon 背后的 TiDB 生态丨 TiDB Hackathon 评委访谈

Image

你多久没仅为 Have fun 去写一段代码?
你多久没为实现一个天马行空的 idea 而兴奋不已?你又多久没为和团队一起 Coding 而干劲十足了?来 TiDB Hackathon 吧,这些体验都能找到!
TiDB Hackathon 2021 已于 12 月 9 日起正式开启报名,我们已经� … ⌘ Read more

⤋ Read More

全文检索库 bluge

全文检索库 bluge 推荐理由

提到全文检索库,第一个想到的就是 Java 实现的 lucene,今天介绍一款 Golang 实现的全文检索库 bluge。bluge 脱胎于 Bleve,是当前 Github 比较火的搜索引擎项目 zinc 的底层索引检索库。

功能介绍

bluge 索引存储支持内存,本地文件,以及扩展云存储等方式,文档字段类型支持 Text, Numeric, Date, Geo Point 等。

查询检索支持如下特性:

  1. 支持多种�� … ⌘ Read more

⤋ Read More

『央视新闻』武汉洪山哪有 snsz《手机搜狐网》
武汉洪山哪有 snsz[電维√I73-433O-3I64√],更多关于武汉洪山哪有 snsz 资讯如下:
股,副总经理兼董事会秘书叶继德 2 万股,其他激励对象共 108.45 万股。
而与激励计划同一天发布的回购方案中,苏泊尔称公司拟使用自有资金以集中竞价交易方式回购部分社会公众股份用以实施股权激励计划,回购股份的最高价不超过 67.68 元/股。
苏泊尔每股 1 元的限制性股� … ⌘ Read more

⤋ Read More

「央视网」武汉洪山关山哪 sn《手机新浪网》
武汉洪山关山哪 sn[電维√I73-433O-3I64√],更多关于武汉洪山关山哪 sn 资讯如下:
B 集团持有的 2.06 亿股股份将被解禁,解禁市值超 120 亿元。在此之前,“公募一哥” 张坤已于近期大规模减持其股份。
这一减持数据的披露源自于 12 月 14 日苏泊尔发布的 “每股 1 元” 的股权激励计划。按照最新发布数据,截至 12 月 13 日,张坤管理的易方达优质精选已不在苏 … ⌘ Read more

⤋ Read More

「2021 央视新闻」武汉武昌南湖哪家丝足_新浪微博
武汉武昌南湖哪家丝足 [電维√I73-433O-3I64√],更多关于武汉武昌南湖哪家丝足资讯如下:
心,而按照双汇创始人万隆长子万洪建 7 月 16 日接受媒体采访时的说法,“父子不和的理由” 其一就是万洪建更想发展中式产品。
值得一提的是,随着双汇发展推广新式产品,今年前三季度,双汇发展的销售费用也出现大幅增加,达到 22.63 亿元,较去年同期增长 1 … ⌘ Read more

⤋ Read More

go 1.18 泛型初体验

go 1.18 泛型初体验

go.1.18beta 版发布,众所周知这个 go.1.18 版本会默认启用 go 泛型。这个版本也号称 go 最大的版本改动。

初识 golang 的泛型

我们写一个 demo 来看看 go 的泛型是长啥样

”`

package main

import (

<span class="s">"fmt"</span>

)

type OrderTypesRead more”`

⤋ Read More