Hello everyone ! (New nauplius onboard :))

@2ndTaleStudio I am very nervous to write stupid things in front of so knowledgeable people :upside_down_face: . I am still doing my research about literaly everything. I even needed to look up crate in my language before using "cargo" for "crates" made sense haha.

@ZiCog This is really exciting and I am glad you detailed it for me. I love to read how Rust is used in a professional context to help see the application beyond the learning phase/hobby-project I am at right now. I see you integrated it in the whole chain of from data collection, db, dataviz, serving clients to the final site. Specially nice to read because one of the numerous confusions I have is, if Rust takes so long time for my computer to compile, how is it managed at a bigger scale (I am still reading on that)?

1 Like

We are pretty amateur at cloud deployment. No containers, kubernettes or whatever. Just get the code onto the server(s) and and have a systemd service run it.

Mostly slow build times are not an issue. Yes it can take minutes to do a release build from scratch as cargo downloads and compiles all the dependencies of your project. But after that builds are much faster. Mostly when working on Rust code I find myself doing a lot of "cargo check" rather than a compilation. That is pretty quick. The if it checks it will generally build in debug mode for testing occasionally.

Don't forget whatever time you lose on Rust compilation you get back, and more, on testing and debugging and random down time.

Here is how it goes around here:

  1. Create / modify Rust code on a local PC.
  2. Test the completed code on a local PC. Generally data comes in and goes out via our NATS messaging servers and/or REST APIs, so tests are done on live data even at home. Or we have our remote embedded systems in the lab to test on.
  3. Push tested code to github/bitbucket
  4. Pull code to production server.
  5. "Cargo build --release" it.
  6. Restart the service with systemctl.

Amazingly, as rude an crude as this is, it has worked flawlessly for a year now.

Actually so far dashboards/visualizations in the browser are all still Javascript. I'm looking into that.

If you want to talk about Rust at scale, then Cloudflare offers their "Cloud Workers". Write some code, push it to Cloudflare, boom, you have a web server up and running, globally deployed, no server to worry about at all!

1 Like

I have learned the basics of Rust, but I am a nauplius when it comes to more advanced features. When I make mistakes with them, others help me learn by pointing out my mistakes. So don't be afraid to write :slight_smile:

1 Like

@ZiCog yes that's pretty amazing!
@L.F au nauplius! good to know! Let me update my title hehe.

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.