Running our Hyper HTTP server
When we run our server, we first need to export the URL that we are going to send batched chat logs to with the following command:
export SERVER_URL="https://httpbin.org/post"
This means that we just need to send our HTTP requests to an HTTPBin and get a standard response back. We can then run our server with the following command:
cargo run
Our server is now running with the following printouts:
state actor is running runner actor is running
Our intervals are every 30 seconds for the runner actor to send a message to the state actor. If we just leave our server running, we will get the following printout:
state is empty state actor is receiving a message {} [] state is empty state actor is receiving a message {} [] state is empty state actor is receiving a message {} []
Here we can see that the chat state and queue are empty and that both of our actors are running in their threads! We can then get our Postman application...