Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Compile Time Code Weaving with Go
Search
Ian Eyberg
July 10, 2015
Technology
390
0
Share
Compile Time Code Weaving with Go
Goweave is a project to implement compile-time code weaving with go.
Ian Eyberg
July 10, 2015
More Decks by Ian Eyberg
See All by Ian Eyberg
Creating Open Source Unikernel Packages
eyberg
0
69
Challenges and Opportunities - Unikernels in HPC && Cloud
eyberg
0
110
Climbing Out From the Digital Mud with Unikernels - HL2017
eyberg
0
180
Using Unikernels in Production Today
eyberg
0
250
Adventures In Building Unikernel Clouds
eyberg
0
130
No Parachute Introduction into Unikernel Orchestration
eyberg
0
270
You Say MicroServices - I say Unikernels
eyberg
1
220
The Current State of C++ Unikernels
eyberg
1
260
UniKernel Workflows
eyberg
0
110
Other Decks in Technology
See All in Technology
サイボウズ 開発本部採用ピッチ / Cybozu Engineer Recruit
cybozuinsideout
PRO
10
78k
AI와 협업하는 조직으로의 여정
arawn
0
410
AWS認定資格は本当に意味があるのか?
nrinetcom
PRO
2
270
コミュニティ・勉強会を作るのは目的じゃない
ohmori_yusuke
0
200
Do Ruby::Box dream of Modular Monolith?
joker1007
1
340
AI バイブコーティングでキーボード不要?!
samakada
0
560
Introduction to Sansan for Engineers / エンジニア向け会社紹介
sansan33
PRO
6
74k
EarthCopilotに学ぶマルチエージェントオーケストレーション
nakasho
0
290
Amazon S3 Filesについて
yama3133
2
210
Standards et agents IA : un tour d’horizon de MCP, A2A, ADK et plus encore
glaforge
0
170
20年前の「OSS革命」に学ぶ AI時代の生存戦略
samakada
0
430
最近の技術系の話題で気になったもの色々(IoT系以外も) / IoTLT 花見予定会(たぶんBBQ) @都立潮風公園バーベキュー広場
you
PRO
1
240
Featured
See All Featured
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
11
890
Git: the NoSQL Database
bkeepers
PRO
432
67k
How to build a perfect <img>
jonoalderson
1
5.4k
svc-hook: hooking system calls on ARM64 by binary rewriting
retrage
2
210
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
260
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
270
How to Think Like a Performance Engineer
csswizardry
28
2.5k
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
1
190
The SEO Collaboration Effect
kristinabergwall1
1
420
The Art of Programming - Codeland 2020
erikaheidi
57
14k
Leveraging Curiosity to Care for An Aging Population
cassininazir
1
220
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
2.9k
Transcript
Compile Time Code Weaving with Go https://github.com/deferpanic/goweave
I like your software but…
What sucks about Go?
Do you know about aspectj?
Really?
I’m not a code purist
“which is our full time job . write a program
to write a program” - rob pike / gopherfest 2015
None
Go is Actually a Decent Fit
Prior Art go fmt go fix go generate
go fix
No Wrapping I don’t want to update code && leave
the refs in it’s non-trivial I don’t want to hack it in/out each time I could forget in the future or not find all in the past
Aspect Contains behavior that is prominent in many places but
don’t really have anything to do with your business logic. Logging is a canonical example.
Pointcut an expression that details where to apply your behavior
CALL Before, after or wrap around calling a method. EXECUTE Before or after inside executing a method. WITHIN Every single call within a method.
Advice fmt.Println("Hello, 世界")
Logging
Monitoring
Performance Analysis
Debugging & Tracing
Undo Functionality
None
Behavior Mutation
Security
Transactions
Log every call to Itoa
Validation
Time Database Query Latencies
Ensure we log every panic in a goroutine
loom central place for storing .weave files you don’t have
to re-invent the wheel more eyes - better software
it’s really
HACKY
https://github.com/deferpanic/goweave https://github.com/deferpanic/loom