项目
在 GitHub 查看
campoy/golang-plugins
关于
A simple demo of hot code swapping with Go 1.8 and its plugins feature.
学习与教育实测星标增长
- 24小时
- 0
- 7天
- 0
- 15天
- -1
- 1个月
- 正在收集历史
各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。
README.md
原文golang-plugins
golang-plugins uses the new plugin feature of Go 1.8 to implement hot code swapping in Go.
This is highly experimental and just a way for me to learn how plugins work and what limitations I find.
Run this program and then try editing, adding, or removing
files in the plugins directory.
go run main.go
The entry point to the plugins is the Run function, that
doesn't receive any parameters and returns an error.
Limitations:
- This only works on Linux.
- We poll regularly the plugins directory instead of using fsnotify.
- We recompile every time, even if the code has not changed.
- This causes a continuously growing memory requirement (memory leak?).
Disclaimer
This is not an official Google product (experimental or otherwise), it is just code that happens to be owned by Google.
探索相关项目
加载中…