Skip to content

Commit

Permalink
Merge pull request #7 from strangemonad/shawn/protobuf
Browse files Browse the repository at this point in the history
Shawn/protobuf
  • Loading branch information
spencerkimball committed Feb 16, 2014
2 parents 530931a + bef894c commit a58ab01
Show file tree
Hide file tree
Showing 4 changed files with 1,339 additions and 0 deletions.
5 changes: 5 additions & 0 deletions proto/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
all:
protoc --go_out=. *.proto

clean:
rm *.go
13 changes: 13 additions & 0 deletions proto/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Cockroach Protobuffer API

This defines the low-level key-value API

## Hacking

The Go build tools don't support code generation very well. The approach taken here is to commit the Go generated sources along side the .proto files. This is modeled after https://github.com/golang/groupcache/blob/master/groupcachepb/groupcache.pb.go by @bradfitz

To change the API, update the proto file, run make in this directory, commit both the proto and go files.

Other references to Go code generation:
* http://jteeuwen.nl/code/go/automatic_code_generation.html
* https://plus.google.com/u/0/105521491106709880714/posts/bnUmdCGgJKD
Loading

0 comments on commit a58ab01

Please sign in to comment.