8 ms·
Use Rust for kernel/system programming, use Lisp/Go/Java/C# for backend, use Typescript+wasm for frontend. We have everything already.
by anonzzzies 2y ago
Use Rust for kernel/system programming, use Lisp/Go/Java/C# for backend, use Typescript+wasm for frontend. We have everything already.
- bigtimesink 2y agoThis, but I'm getting tired of people using Rust for things that really should be in C# or Java.
- laerus 2y ago"really should be" ? "in C# or Java" ? where do you even base these claims? Do you know what C# and Java threads have that Rust doesn't? data races. And don't get me stated on the biggest paradigm failure that is OOP.
- bigtimesink 2y agoProjects I've seen at work. Projects posted on Hacker News. Data races aren't usually an issue for backend services, and modern Java/C# is multi-paradigm.
- pdimitar 2y ago[flagged]
- lostmsu 2y ago> Data races aren't usually an issue for backend services I beg to differ unless all your logic is in the database with strong isolation guarantees. Speaking of C# for backends that are using EF actively, I bet there are bugs in pretty much all of them caused by incorrect applications of optimistic concurrency.
- legulere 2y agoBoth have a garbage collection though that lead to higher developer productivity than compared to rust's affine types.
- brink 2y ago> higher developer productivity Where have you been the past 5 years? Rust developers are insanely productive. Can we put this myth to rest already? Rust being an "unproductive language" is thoroughly dis-proven.
- hello_moto 2y agoRust is the silver bullet we all been waiting for?
- ramon156 2y agoNo, that's the other end of the stick. Its en par with other languages
- hello_moto 2y agoWell, put any language against Rust and Rustaceans would argue Rust is better than those languages so ... Silver bullet no?
- chasd00 2y agoIf the word “Rustaceans” is actually in common use then rust loses by default.
- neonsunset 2y agoThere are domains where C# (and F#) productivity stems from similar reasons why writing a game in something that isn't Rust might be more productive without even sacrificing performance (or, at least, not to the drastic extent). I can give you an example: var number = 0; var delay = Task.Delay(1000); for (var i = 0; i < 10; i++) { Task.Run(() => { while (!delay.IsCompleted) { Interlocked.Increment(ref number); } }); } await delay; How would you write this idiomatically in Rust without using unsafe? To avoid misunderstanding, I think Rust is a great language and even if you are a C# developer who does not plan to actively use it, learning Rust is of great benefit still because it forces you to tackle the concepts that implicitly underpin C#/F# in an explicit way.
- cantalopes 2y ago"Use lisp for backend" lol
- pjmlp 2y agoIt worked for Yahoo early days, SISCOG, ITA Software,... Even a site called HN if you happen to know it.
- worthless-trash 2y agoIts easier and saner than you think. No massive churn, quite performant and the code i wrote 20 years ago runs without modification. Can other blub languages claim this?
- anonzzzies 2y agoWorks well, got problems with it (outside pure ignorance), pick something else; same difference to me. lol.
- NoGravitas 2y agoI do this for my personal hobby projects, but that's as much to deter use by technology enthusiasts as anything.
- pdimitar 2y agoNope, Elixir for backend. We need the BEAM VM's guarantees, not yesterday but like 20 years ago, everywhere. The language itself does not matter. But we need that runtime's guarantees!
- teeray 2y agoWhat is it specifically about the BEAM VM that positions it above, say, Go on K8S?
- BeFlatXIII 2y agoNot having to learn K8s
- pdimitar 2y agoAbility to manage tens of thousands of stateful connections without the 95th percentile requests jumping to 5 seconds. Just to start with.
- Sytten 2y agoI get the appeal, but without strong typing it's a no-go in my book. Get me an elixir with proper types and we can talk.
- pdimitar 2y agoOh I agree. The Erlang/Elixir ecosystem is in danger of Rust inventing a BEAM-like runtime and making it irrelevant.
- Nilithus 2y agoI believe they have already started this effort. https://elixir-lang.org/blog/2023/06/22/type-system-updates-research-dev/ https://elixir-lang.org/blog/2023/06/22/type-system-updates-...
- pdimitar 2y agoThey have but it's mostly a labor of love and it's very difficult to fit a static type system into a dynamically typed language. We already have some false positives. Happily the team is very motivated and is grinding away at them, for which we the community are forever grateful.
- tptacek 2y agoThat doesn't address existing codebases. Neither the Linux kernel nor the Chromium project is going to replace all its memory-unsafe code, so there are design challenges that need to be solved that are more complicated than "these memory-safe languages are available for your problem domain".
- gw2 2y agoWhat is your opinion on deploying C++ codebases with mitigations like CFI and bounds checking? Let us say I have a large C++ codebase which I am unwilling to rewrite in Rust. But I: * Enable STL bounds checking using appropriate flags (like `-DGLIBCXX_ASSERTIONS`). * Enable mitigations like CFI and shadow stacks. How much less safe is "C++ w/ mitigations" than Rust? How much of the "70% CVE" statistic is relevant to my codebase?
- tptacek 2y agoWe recorded an episode (there's a transcript) about this exact issue: https://securitycryptographywhatever.com/2024/10/15/a-little-bit-of-rust-goes-a-long-way/ https://securitycryptographywhatever.com/2024/10/15/a-little...
- gw2 2y agoWith due respect, the blog you have linked looks like the average Rust marketing material. It does absolutely nothing to address my concerns. I did a `Ctrl-F` and found zero hits of any of the following terms: * CFI * isoheaps or type-stable allocators * Shadow stacks (There is just a single hit of "C++"...) Ignoring the appeal to authority, I have a hard time believing that incrementally rewriting my C++ code in Rust or just writing new code in Rust ("vulnerabilities exponentially decay" and all that) is going to give me more actual security than the mitigations stated above. Most, if not all, high-profile exploits stem from out-of-bounds accesses and type confusions, which these mitigations prevent at very low cost. Thanks for replying, though.
- tptacek 2y ago
- J_Shelby_J 2y agoNah, ima use rust for all of that because I’m too lazy to manage multiple tech stacks.