Run the following from the root dir:
docker-compose up
# If using Docker Compose Engine V2:
docker compose upEndpoint testing is supplied through bash:
bash curl_test_go_mongo.sh
bash curl_test_rust_actix.sh
bash curl_test_rust_mongo.sh
bash curl_test_workers.sh
# bash curl_test_all.sh- https://localhost:443/public/
- https://localhost:443/public/queryworker.html
- https://localhost:443/public/querystatus.html
- https://localhost:443/public/querystatuses.html
- https://localhost:443/public/addworker.html
- https://localhost:443/public/stopworker.html
Defaults:
- User and password for basic auth:
test,test aandbare commands that are supplied in the request - they correspond to the bash scripts in /go/bin- Simple password auth isn't enterprise-grade security (obviously) but is added to demonstrate basic auth checking
POSThttps://localhost:443/api/create?user=test&password=test&cmd=a&scheduled=2024-05-08T15:04:05ZGEThttps://localhost:443/api/status?user=test&password=test&uuid=5e44e582-7af4-4751-9dd8-9385c25e1e99GEThttps://localhost:443/api/workers?user=test&password=testGEThttps://localhost:443/api/jobs?user=test&password=test&uuid=5e44e582-7af4-4751-9dd8-9385c25e1e99POSThttps://localhost:443/api/stop?user=test&password=test&uuid=5e44e582-7af4-4751-9dd8-9385c25e1e99
Mongo DB:
GEThttps://localhost:443/api/examplesGEThttps://localhost:443/api/example/one?id=1DELETEhttps://localhost:443/api/example/delete?id=1POSThttps://localhost:443/api/example/create?id=1&name=a&val=aPUThttps://localhost:443/api/example/update?id=1&name=c&val=c
Working my way through some Rust and Actix Server documentation.
GEThttp://localhost:8000/examplesGEThttp://localhost:8000/example/one?id=1DELETEhttp://localhost:8000/example/delete?id=1POSThttp://localhost:8000/example/create?id=1&name=a&val=aPUThttp://localhost:8000/example/update?id=1&name=c&val=c
- https://doc.rust-lang.org/rust-by-example/index.html
- https://ntex.rs/docs/application
- https://hub.qovery.com/guides/tutorial/create-a-blazingly-fast-api-in-rust-part-1/#overview
- https://actix.rs/docs/getting-started
- https://github.com/tfogo/mongodb-go-tutorial/blob/master/main.go
- https://pkg.go.dev/net/url#URL.Query
- https://stackoverflow.com/questions/55564562/what-is-the-bson-syntax-for-set-in-updateone-for-the-official-mongo-go-driver
- https://github.com/Mr-Malomz/actix-mongo-api/blob/main/src/repository/mongodb_repo.rs
- https://crates.io/crates/mongodb