Mugsy

View Original

Brew Service Update

Hey folks, hope all is well out there. I have continued working on the brew service and it has been going very well. There is still a few more things to complete before release and brew demos.

Current Status:

  • The DECAF brew endpoint is now up and running and communicating with Operator’s brew service. The endpoint receives a recipeId then pulls the recipe details and all related steps from the db.

  • DECAF opens up a websocket connection to Operator and does the following:

    • Checks Operator’s status and confirms the hardware and services are all ready to brew.

    • Sends the first step.

    • Operator completes the step, and sends the completion status back to DECAF. If that status is OK, Operator is ready for the next step and DECAF sends it.

    • DECAF updates the machine status endpoint with info about the current step and its status for the UI to consume.

  • DECAF runs through all the steps, continually monitoring machine state and updating the current status for the UI.

  • I’ve done a lot of stress testing today, sending hundreds of steps, some steps including a 100 individual commands. There have been zero issues and zero downtime. It’s working extremely well and Im really stoked.

What’s left:

  • Add some additional protections on Operator’s command processing. Most malformed commands are skipped and logged correctly, but certain ones have resulted in the brew service crashing. DECAF is using types and Zod, so it’s unlikely it would send a malformed command. But Operator should not have to rely on the requesting system for it’s own protections.

  • Operators brew service is currently just processing move commands, so I need to add the additional commandTypes to the main loop.

  • The endpoint that accepts the connection from DECAF is not actually integrated into Operator yet.

This is just a few hours work and I will likely be able to complete it on Wednesday or Thursday of this week.

What’s next:

  1. I will work through the remaining tasks with the goal of completing it before the end of the work week.

  2. I will release these updated versions of Operator and DECAF along with a small update confirming completion before by Friday.

  3. This should get me into a position to some brew demos this weekend. I will have an update out on Sunday covering this, and a timeline update.

Ok, that is all for now. Cheers!