This homework assignment is about getting our feet wet with modeling concurrent systems! We are going to be simulating the very concurrent and complex nature of making a Pizza from scratch in a Kitchen with multiple chefs!
This simulation is quite intricate and will leverage much of your current Rust knowledge. However, Rust's style of concurrent operation with Tokio and its synchronization primitives is a lot to read through. You will need to make good use of your reading resources to manage them successfully and not get overwhelmed! With what truly little time we have in class, you will need to rely on the reading material to get you the full picture. The sections below give you direct and indirect help with organizing your thoughts about threads, concurrent ownership, and use of synchronization primitives in Rust.
In "The Rust Language Book" read:
Optionally for help with the homework:
While it's not one of your required materials, the Rust by Example docs are associated with the Rust Language Book and are a great resource for understanding the concepts in the book in a more direct programmatic way. You should go through all of it but for now, Read section 18: Error Handling and Section 19: Std Library Types.
Don't read this in its entirety, but the Rust Tokio library is a powerful tool for concurrent programming in Rust. It is a bit different from the standard library and is a bit more complex to understand. However, it is a great resource for looking up details related to the use of Futures, Channels, Async and Await, and more in the codebase.
This programming assignment is about implementing a concurrent pizza-making simulation in Rust!
Your repository will contain the following files:
CMSI-3510-HW2/
āāā .gitignore
āāā life-of-pie/
ā āāā Cargo.toml
ā āāā Cargo.lock
ā āāā src/
ā āāā parallel/
ā ā āāā mod.rs
ā ā āāā data_parallel.rs
ā ā āāā task_parallel.rs
ā āāā chef.rs
ā āāā equipment.rs
ā āāā error.rs
ā āāā fridge.rs
ā āāā ingredients.rs
ā āāā kitchen.rs
ā āāā proving_room.rs
ā āāā lib.rs
ā āāā main.rs
āāā README.md
This programming homework is brought by Babish! Well not directly, but instead it is modeled after the pizza dough making process laid out in the following video linked below! Make sure to watch this as otherwise the simulator you will be programming will be more than a little confusing.
Pizza Dough | Basics with Babish
Need a refresher on how to interact with the HW for this course? Watch the helper video posted to Zoom via the link below!
You can find the GitHub Classroom assignment link and the Brightspace turn in link using the buttons at the top of this section.
In this optional section you will be working on a small beginner Rust project of your choosing! After looking around for some fun project ideas, I found this great article from ZTM.io's Jayson Lennon!
Jayson Lennon's Rust Practice Projects
Whilst the intermediate and advanced projects are certainly "out of our league" at the moment, the beginner projects Jayson lays out are insightful, simple, and fun!
For this optional I want you to read that article and pick one of the beginner projects that Jayson recommends! Complete the basic implementation of the project and then provide at least 5 to 10 unit tests that display your implementations working as expected.
I have made an empty Github assignment for you to pull and create your Rust project from scratch (This is out of convenience so that I can use Github classroom to collate all your projects rather than go through being added to all the repos). Feel free to architect your project as you choose, however at a minimum you must have at least 5 unit tests that are run and pass with the cargo test command.
Additionally, provide a brief README.md file that explains what project you chose and how to interact with it. If you are doing anything "non-standard" that is Ok, just document that in the README.md.
Since the repository is private, feel free after you are done to copy it over into a public repository to show off on your Github!
Earning points in this optional is not as rigid since you may pick your own project. With that said, to earn full points you must fully implement one of the beginner projects as stated by Jayson, have a README.md, and have at a minimum 5 unit tests pass with the cargo test command. You do not have to do any of the add-ons or extensions that Jayson recommends.
As an example, if you did the beginner project about remaking core terminal utilities than I would expect to be able to run your version of echo, cat, ls, find, and grep, that I could figure out where to start by looking at your project README (Your commands don't need to be terminal integrated or anything, but there functionality should be intact through whatever medium you choose), and that I could clone the repository to run cargo test and see at least 5 passes (In this case one for each command).
Below are buttons that link to the Github Optional Assignment repository. The Brightspace submission link is at the top of this section.