Go lang microservices project for shipping containers
Install:
- MongoDB
Use the make file for common tasks
- Build the proto files
make proto
- Build the service
make build
- Build the Docker container
make docker
This can be use to test the microservices
Start the service you want to test, then also boot the micro web service using the micro
cli.
$> micro cli
View in browser at http://127.0.0.1:8082/client
Example JSON payloads that can be sent to services
{
"description": "This is a test consignment",
"weight": 55000,
"containers": [
{ "customer_id": "cust001", "user_id": "user001", "origin": "Manchester, United Kingdom" },
{ "customer_id": "cust002", "user_id": "user001", "origin": "Derby, United Kingdom" },
{ "customer_id": "cust005", "user_id": "user001", "origin": "Sheffield, United Kingdom" }
]
}
{
"id": "vessel001",
"name": "Boaty McBoatFace",
"max_weight": 200000,
"capacity": 500
}