If you're interested in #Rust 🦀, #ActixWeb ⚙️, or just want to lend a hand, feel free to check out the repo! Any suggestions, comments, or PRs would be greatly appreciated. 🙌
#htmx is really awesome! Yesterday, I was able to replace ~100 lines of #JavaScript with ~60 lines of #rustlang code for rendering the same content. At the same time I even got small UX-improvements (i.e. hx-trigger provides many more features than I could implement correvtly myself)
The huge benefit: I am 1000 times more *confident* in the correctness & robustness of my Rust code (mainly because I am much more experienced in Rust) compared to js.
Продолжаем работать с Actix Web (часть 1)
Продолжим работу с Actix Web и сделаем реальный пример мессенджера В этой статье также покроются темы jwt и raw sql в rust
Начало работы с Actix Web
Actix Web или как влиться в производительность. В этой статье есть все необходимое, чтобы начать писать на actix web
@d2718 ooh thanks!
I actually found a different one (rust_cgi), but yours might be better because I can (probably, for example) make an #ActixWeb project and then have a custom executable that receives the call through CGI instead of the regular server.
The other one already uses hyper's http library, but an outdated version, so I'm not sure how that'll play with whatever Actix expects. Since dumb_cgi is nearly nothing, I can see myself fitting it onto whatever :rust:
Написать X-docker-isolation-provider сложно — но не невозможно
Вы когда-нибудь чувствовали себя пионерами? Вот именно так я себя и ощущал, когда писал docker-isolation-provider для платформы ассоциативного программирования Deep . Все было так: в один прекрасный день у нас на платформе связей решили - было бы славно портировать нашего бота в Deep . А для этого нужно было написать так называемые провайдеры . Провайдеры нужны лишь для одной цели - дать возможность пользователю выполнять пользовательские хэндлеры на любом языке. Тогда я просто подумал, что было бы неплохо помочь парням, которые вероятно Rust никогда в жизни не видели . Ох, как же я тогда ошибался…
https://habr.com/ru/articles/822093/
#deepfoundation #программирование #история_разработки #rust #actixweb #serde #wasm
I’ve been looking into whether it is realistic to replace nginx with a Rust-based web server at this point. First finding: there aren’t any usable configurable web servers written in Rust, but there are some very advanced frameworks if you are willing to write Rust code.
Now I wouldn’t mind turning the nginx configuration into Rust code, provided that this doesn’t add too much complexity. I had to solve quite a few things in a suboptimal fashion in the nginx configuration, this could be done properly in a real programming language. And the prospect of converting some small Python-based applications into integral parts of the web server by rewriting them in Rust is tempting.
Unfortunately, I found that things aren’t quite there yet. In particular, TLS configuration with multiple certificates (SNI) isn’t a supported scenario: Actix, Axum and Warp all expect you to access Rustls directly for that and write code that isn’t exactly trivial.
Logging is another sore point. Axum has a logging approach that is really alien for web servers. If you want the standard logging format, you have to implement it yourself. And while the other two support the standard logging format out of the box, delivering log entries to log files is your responsibility with all three libraries.
Finally, there is the matter of pre-compressed static files, a very useful feature to achieve best performance – at least if you serve lots of static files, which my server does. Yet only Axum currently supports it. Actix has a pull request adding this feature which has been ignored for the past two years, and adding it without patching the library seems to involve completely reimplementing handling of static files. It’s the same situation with Warp, minus the pull request.
Yes, it was probably naive of me to expect these frameworks to cover my use case properly. But they are really close…
Solid documentation is key when collaborating with other developers. Easily describe your API endpoints and data types using Swagger.
https://bocksdincoding.com/blog/api-documentation-made-easy-with-swagger
#rust #rustlang #actixweb #rest #api #tutorial #programming #documentation
Discover the essential steps to enhance the security of your Actix Web API in Rust by implementing both Basic and Bearer authentication mechanisms for robust protection against unauthorized access.
https://bocksdincoding.com/blog/securing-your-actix-web-api-with-basic-bearer-authentication
#rust #rustlang #programming #tutorial #actixweb #rest #api #security
Elevate your Rust REST API development by seamlessly integrating SQLx, unraveling the simplicity and effectiveness of connecting to and managing databases.
https://bocksdincoding.com/blog/connect-your-rust-rest-api-and-db-with-sqlx
#rust #rustlang #actixweb #rest #api #sqlx #db #sql #programming #tutorial
Creating a REST API with Rust and the Actix Web framework is a breeze.
In this tutorial, we're going to walk through setting up your project and creating your first CRUD routes.
https://bocksdincoding.com/blog/fast-rest-api-rust-actix-web
Finally had time to update rust-embed-for-web and actix-web-rust-embed-responder. I made these for embedding files into rust programs and serving them with actix web servers. Extremely efficient: 0 copy, headers and compression computed at compile time.
No changes with this update, just brought all the dependencies up to date. I might make an update later to use Cow if I can figure out how to use it :blobfoxlurk2glare:
https://crates.io/crates/rust-embed-for-web
If anyone out there is using both #actixweb and #htmx (there must be dozens of us!) then I’ve just released the first version of a crate that might be useful to you: https://crates.io/crates/actix-htmx. Feedback & pull requests welcome at https://github.com/welshdave/actix-htmx #rustlang #actix
@stvm #reactjs is extremely flexible and easy to get started with, so I definitely recommend checking out their getting started docs!
Using #rustlang with #actixweb is an ultra fast and powerful backend to be sure! However, if your web app doesn't require squeezing every single bit of performance out of your device, I HIGHLY recommend using a #golang backend! @golang is extremely performant language and simple to learn. It would serve a React page w/ ease! 😎 :golang: :react: 🤘