-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
43 lines (32 loc) · 1.12 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
proto: # generates the golang code from the .proto file
protoc --go_out=. --go_opt=paths=source_relative \
--go-grpc_out=. --go-grpc_opt=paths=source_relative \
eventstore/event_store.proto
rubyproto: # generates the ruby code from the .proto file
protoc --ruby_out=ruby \
eventstore/event_store.proto
python2proto: # generates the ruby code from the .proto file
protoc --python_out=python2 \
eventstore/event_store.proto
mod:
go mod tidy
go mod vendor
server:
go run cmd/server/main.go
c:
go build -o cl cmd/client/main.go
add-many: # add many events
@go build -o client cmd/client/main.go
@for number in $(shell seq 1 10000); do \
printf "example event $$number $$(date)" | ./client store -t "env:test" -t "ttl:1s"; \
printf "example event $$number $$(date)" | ./client store -t "env:stage" -t "ttl:5s"; \
printf "example event $$number $$(date)" | ./client store -t "env:prod"; \
done
get-prod:
go run cmd/client/main.go get -t "env:prod"
get-stage:
go run cmd/client/main.go get -t "env:stage"
get-test:
go run cmd/client/main.go get -t "env:test"
metric:
go run cmd/client/main.go metric