Download - GOTO Paris | @see Gopher

Transcript
Page 1: GOTO Paris | @see Gopher

GOTO Paris | @see Gopher

JAN KLAT | SKRZ.CZ | @

KLATYS

�1

Page 2: GOTO Paris | @see Gopher
Page 3: GOTO Paris | @see Gopher
Page 4: GOTO Paris | @see Gopher
Page 5: GOTO Paris | @see Gopher

Tools & Libraries | GopherJS

• Compiler of Go code to Javascript

• Similar to CGO

• All Go functionality

�5

Dmitri Shuralyov Go in the browser http://www.thedotpost.com/2016/10/dmitri-shuralyov-go-in-the-browser

Page 6: GOTO Paris | @see Gopher

WHY???

�6

Dmitri Shuralyov Go in the browser http://www.thedotpost.com/2016/10/dmitri-shuralyov-go-in-the-browser

Page 7: GOTO Paris | @see Gopher

Tools & Libraries | Go Mobile

• Export Go packages to Java and Objective C / Swift

• Access Java and Objective C API from Go

• Graddle plugin

• Databinding and other resources available from Go

�7

Elias Naur Make mobile programming fun (again)http://www.thedotpost.com/2016/10/elias-naur-make-mobile-programming-fun-again

Page 8: GOTO Paris | @see Gopher

Tools & Libraries | Small binaries

• $ go build -ldflags="..."

• -s Omit the symbol table and debug information

• -w Omit the DWARF symbol table.

• UPX (goupx for <= 1.6)

• might be marked as virus threat by AV

�8

Javier Provecho Fernández Small binaries https://golang.org/cmd/link/

Page 9: GOTO Paris | @see Gopher

Tools & Libraries | Small binaries

�9

Javier Provecho Fernández Small binaries https://golang.org/cmd/link/

https://blog.filippo.io/shrink-your-go-binaries-with-this-one-weird-trick/

Page 10: GOTO Paris | @see Gopher

Tools & Libraries | Worth mentioning

• Kelsey Hightower Self Deploying Go applications 🔗link 🔗code

• Franz Eichhorn Go machine learning at large scale 🔗link

• Book - Thorsten Ball Writing An Interpreter In Go interpreterbook.com

�10

Page 11: GOTO Paris | @see Gopher

Codebase mess & refactoring | The talk with way too long title to fit here

• No-op No-op No-op Interface maneuver

• Flocking rules

�11

Katrina Owen The Scandalous Story of the Dreadful Code Written by the Best of Us http://www.thedotpost.com/2016/10/katrina-owen-the-scandalous-story-of-the-dreadful-code-written-by-the-best-of-us

Page 12: GOTO Paris | @see Gopher

Codebase mess & refactoring | Plugins

• Proposition on how plugins might communicate

• most used is custom build - gh/mholt/custombuild

• wrap calls to external binaries using "net/rpc" for both os/exec and "docker run”

• see https://github.com/drone/drone/issues/1863

�12

Brad Rydzewski Plugins

Page 13: GOTO Paris | @see Gopher

What else?

• Robert Griesemer Prototype your design! 🔗link 🔗github

“Prototyping raises design questions we didn't even know we should be asking”

• Péter Szilágyi Immutability in Go 🔗link“Opensource means good people find the bugs earlier but also bad people find

bugs earlier. Not so great when memory bug shuts down your network”

�13

Page 14: GOTO Paris | @see Gopher

�14

First class functions

Page 15: GOTO Paris | @see Gopher

�15

First class functions

Dave Cheney Do not fear first class functions http://www.thedotpost.com/2016/10/dave-cheney-do-not-fear-first-class-functions

Page 16: GOTO Paris | @see Gopher

�16

First class functions

Dave Cheney Do not fear first class functions http://www.thedotpost.com/2016/10/dave-cheney-do-not-fear-first-class-functions

Page 17: GOTO Paris | @see Gopher

�17

First class functions

Dave Cheney Do not fear first class functions http://www.thedotpost.com/2016/10/dave-cheney-do-not-fear-first-class-functions

Page 18: GOTO Paris | @see Gopher

JAN KLAT | SKRZ.CZ

@KLATYS

[email protected]

�18

Than

k you

!