基于gRPC go实现消息发布订阅## 使用gRPC go实现 基于Topic的高效消息订阅发布模型  姓名:___ 张凯 中国电子云  gRPC go 介绍 01 gRPC 四种通信模式及落地场景 02 根据 proto 生成 go 桩代码 03 订阅者动态注册 04 发布者消息推送 05 现场案例演示 06 ## gRPC go介绍 ## gRPC是什么? 1. 什么是gRPC?gRPC go与gRPC的关系是什么? 2. gRPC与HTTP相比优势是什么?能否使用HTTP平替gRPC的实现? 相比HTTP的Swagger,gRPC为什么没有Swagger? 4. 如何判断一个项目是否适合用qRPC来做实现? 5. 如果要使用gRPC实现,有没有什么快速学习的方法? 1. 什么是gRPC?gRPC go与gRPC的关系是什么? -- gRPC是2015年Google开源,RPC的一种,底层基于HTTP2传输 -- gRPC是一种框架,gRPC go是gRPC的一种实现;同理有其他各语言的实现。0 码力 | 31 页 | 2.42 MB | 2 年前3
Iteratively Migrating an HTTP Service to Go and gRPC Using grpc-gateway and httputil.ReverseProxyIteratively Migrating an HTTP Service to Go and gRPC Using grpc-gateway and httputil.ReverseProxy Igor Dubinskiy  GitHub: eef9/p2_1.jpg) OR GRPC BEHIND GRPC-GATEWAY ngflip.com ## Options to migrate a service from HTTP to gRPC • Everything but the browser a. Modify clients to use gRPC b. Use grpc-gateway; see below • Browser (using grpc-gateway) a. Modify clients to call new service per route as each required RPC is implemented b. Modify clients to call new service for all routes once all required RPCs are implemented0 码力 | 6 页 | 740.76 KB | 2 年前3
Go 入门指南(The way to Go)Go入门指南 书栈(BookStack.CN) ## 目录 致谢 阅前必读 内容介绍 前言 第1章:Go 语言的起源,发展与普及 1.1 起源与发展 1.2 语言的主要特性与发展的环境和影响因素 第2章:安装与运行环境 2.1 平台与架构 2.2 Go 环境变量 2.3 在 Linux 上安装 Go 2.4 在 Mac OS OS X 上安装 Go 2.5 在 Windows 上安装 Go 2.6 安装目录清单 2.7 Go 运行时(runtime) 2.8 Go 解释器 第3章:编辑器、集成开发环境与其它工具 3.1 Go 开发环境的基本要求 3.2 编辑器和集成开发环境 3.3 调试器 3.4 构建并运行 Go 程序 3.5 格式化代码 3.6 生成代码文档 3 3.7 其它工具 3.8 Go 性能说明 3.9 与其它语言进行交互 第4章:基本结构和基本数据类型 4.1 文件名、关键字与标识符 4.2 Go 程序的基本结构和要素 4.3 常量 4.4 变量 4.5 基本类型和运算符 4.6 字符串 4.7 strings 和 strconv 包 4.8 时间和日期 4.9 指针 第5章:控制结构0 码力 | 466 页 | 4.44 MB | 2 年前3
Go 入门指南(The way to Go)1986bf1/p1_3.jpg) The Way to Go Go入门指南 Ivo Balbaert 著 陈佳桦 译 ## 前言 原文出处:https://github.com/Unknwon/the-way-to-go_ZH_CN ## 用更少的代码,更短的编译时间,创建运行更快的程序,享受更多的乐趣 对于学习 Go 编程语言的爱好者来说,这本书无疑是最适合你的一本书籍,这里包 开发出的软件能够很好地在现代的多核计算机上工作 - 开发出的软件能够很好地在网络环境下工作 • 使人们能够享受软件开发的过程 Go 语言就在这样的环境下诞生了,它让人感觉像是 Python 或 Ruby 这样的动态语言,但却又拥有像 C 或者 Java 这类语言的高性能和安全性。 Go 语言出现的目的是希望在编程领域创造最实用的方式来进行软件开发。它并不是要用奇怪的语法和晦涩难懂的概念来从根本上推翻已有的编程语言,而是建立并改善了 来支持并发和并行编程。 这本书是为那些想要学习 Go 这门全新的,迷人的和充满希望的编程语言的开发者量身定做的。当然,你在学习 Go 语言之前需要具备一些关于编程的基础知识和经验,并且拥有合适的学习环境,但你并不需要对 C 或者 Java 或其它类似的语言有非常深入的了解。 对于那些熟悉 C 或者面向对象编程语言的开发者,我们将会在本书中用 Go 和一些编程语言的相关概念进行比较(书中会使用大家所熟知的缩写0 码力 | 380 页 | 2.97 MB | 2 年前3
1.3 Go coding in go wayprint $ sieve [2..n] [2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97] sieve.go//并发组合 (borrowed from Rob Pike’s slide) func generate(ch chan<- int) { for i := 2; ; i++ { channel. go generate(ch) // Start generate() as a subprocess. for { prime := <-ch fmt.Print(prime, "\n") ch1 := make(chan int) go filter(ch, } sieve.go (cont.) From divan’s blog (http://divan.github.io/posts/go_concurrency_visualize/) ’ alt=‘OCR图片’/> 思考 面对同一个问题,来自不同编程语言的程序员给出了思维方式截然不同的解决方法 一定程度上印证了前面的假说:编程语言影响编程思维 避免Go coding in0 码力 | 69 页 | 1.24 MB | 1 月前3
Go vs. GoPlus(Go+)## GCN ### Go vs. GoPlus(Go+)  许式伟 x@goplus.org 2021-6-27 北京 ## 话外:模板 ## Go 篇 ## 谁是最成功的语言? • 1970 – 至今 - 什么语言是最成功的 什么语言是最成功的? • C (1970) • C++ (1979) • Objective-C (1986) • Java (1994) • C# (2002) • Go (2009)  |Position Aug 2012|Position Aug 53%| |13|10|✓|R|1.38%|-0.46%| |14|38|A|Groovy|1.25%|+0.96%| |15|13|✓|MATLAB|1.23%|+0.06%| |16|12|✓|Go|1.22%|-0.05%| |17|23|A|Delphi/Object Pascal|1.21%|+0.60%| |18|11|✓|Swift|1.14%|-0.65%| |19|18|✓|Perl|10 码力 | 54 页 | 1.82 MB | 2 年前3
The Go Handbook## GO HANDBOOK # Table of Contents Preface The Go Handbook Conclusion ## Preface The Go Handbook follows the 80/20 rule: learn in 20% of the time the 80% of a topic. In particular, the goal is to to get you up to speed quickly with Go. This book is written by Flavio Copes. I publish programming tutorials on my blog flaviocopes.com and I organize a yearly bootcamp at bootcamp.dev. You can reach @flaviocopes. Enjoy! ## The Go Handbook • 1. Preface • 2. Getting started with Go • 3. Install Go • 4. Setup your editor • 5. Hello, World! • 6. Compiling and running the Go program • 7. The workspace0 码力 | 44 页 | 4.30 MB | 2 年前3
Exporting Go## Exporting Go Robert Griesemer GopherCon Singapore, 2017 ## I ntro ## • Go package o Namespace Interface (export) o Import ## • Implementation ☐ Export/import (this talk) ☐ Linker (not this 2^2 * 3 ... 996 == 2^2 * 3 * 83 997 == 997 prime 998 == 2 * 499 999 == 3^3 * 37 1000 == 2^3 * 5^3 ## Go package main import "fmt" type List struct { Factor, Power int Link *List } func [Image](/uploads/documents/1/6/4/5/16456415890ad5304784a63d5c72f275/p17_1.jpg) #### lib.o before Go 1.7 go object darwin amd64 go1.5 X:none $$ package lib import runtime "runtime" import fmt "fmt"0 码力 | 34 页 | 2.29 MB | 2 年前3
The Expressiveness of Go[Image](/uploads/documents/f/b/c/8/fbc8faeb9182189853827de4c2f92561/p1_1.jpg) ## The Expressiveness of Go Rob Pike JAOO Oct 5, 2010  ## Why Go? A response to Google’s internal needs: - efficient large scale programming - speed of compilation pick one.” - complexity, weight, noise (C++, Java) vs. - no static checking (JavaScript, Python) Go is statically typed and compiled, like C++ or Java (with no VM), but in many ways feels as lightweight0 码力 | 49 页 | 839.26 KB | 2 年前3
Go ProgrammingGoogle $ ^{™} $ 10  ## Go Programming Russ Cox and Rob Pike May 20, 2010  ## Go is different Go is more unusual than you might first think. Programming in Go is different Java $ ^{*} $ programs in Go, you may become frustrated. If you write Go programs in Go, you will be much more productive. Our goal today is to teach you to think like a Go programmer. *Sometimes we'll0 码力 | 60 页 | 1.04 MB | 2 年前3
共 1000 条
- 1
- 2
- 3
- 4
- 5
- 6
- 100
相关搜索词
gRPC goTopic消息订阅发布模型protoPublisherSubscribergrpc-gatewayhttputil.ReverseProxygRPCGoIterative migrationGo语言安装运行环境基本语法数据类型控制结构函数结构体接口并发编程错误处理网络编程Web应用开发编程语言并发标准库函数式编程Go coding in go way编程语言思维组合goroutinesGo+静态语言语法兼容数学运算支持C语言支持编译设置语法导出机制导出数据序列化二进制导出orthogonal compositionexpressivenesssimple constructssafetyconcurrency类型方法













