Skip to content

Commit 4b228e0

Browse files
committed
Finishing touches
1 parent a2d2436 commit 4b228e0

File tree

6 files changed

+16
-10003
lines changed

6 files changed

+16
-10003
lines changed

Dockerfile

+2
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,6 @@ WORKDIR /app
2828
ENV http_db_host "0.0.0.0:8000"
2929
ENV mgmt "y"
3030
ENV prometheus-monitoring "y"
31+
ENV indexed "y"
32+
ENV GOGC 65
3133
ENTRYPOINT ["/app/main"]

README.md

+10
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,13 @@ Go over steps below, And see the result in your browser.
2020

2121

2222
11. instructions curl 127.0.0.1:8128/help/ | python -m json.tool
23+
24+
25+
26+
### Running
27+
28+
sudo docker-compose up --no-deps --build
29+
30+
promql {instance="lambdadb:8000"}
31+
32+
python3 extras/ingestion.py -f movies_subset.tsv -format tsv -dbhost 127.0.0.1:8000

docker-compose.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ services:
77
prometheus:
88
image: prom/prometheus:v2.21.0
99
ports:
10-
- 9000:9090
10+
- 9001:9090
1111
volumes:
1212
- ./prometheus:/etc/prometheus
1313
- prometheus-data:/prometheus

http_handlers.go

+2
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,8 @@ func contextAddRest(JWTConig jwtConfig, itemChan ItemsChannel, operations Groupe
137137

138138
func rmRest(w http.ResponseWriter, r *http.Request) {
139139
ITEMS = make(Items, 0, 100*1000)
140+
msg := fmt.Sprint("removed items from database")
141+
fmt.Printf(WarningColorN, msg)
140142
go func() {
141143
time.Sleep(1 * time.Second)
142144
runtime.GC()

0 commit comments

Comments
 (0)