Rust
Rust
  • 788
  • 3 618 642
Diplomat - Idiomatic Multi-Language APIs - Robert Bastian - Rust Zürisee March 2024
Join us at RustFest.ch in Zürich, the ultimate event for Rust enthusiasts and newcomers alike. Learn, share, and celebrate the power and beauty of the Rust programming language. Connect with the global Rust community on June 19-24, 2024. Get your ticket today! 🎟️
In this talk, Robert introduces diplomat: Experimental Rust tool for generating FFI definitions allowing many other languages to call Rust code.
With Diplomat, you can simply define Rust APIs to be exposed over FFI and get high-level C, C++, and JavaScript bindings automatically!
Project: github.com/robertbastian/diplomat
Simons's Github: github.com/robertbastian
Would you like to chat or give a talk? Join us in our Matrix room:
matrix.to/#/#rust-zuerisee:matrix.coredump.ch
Support the Zürich community: estada.ch/support-my-work/
Chapters:
00:00 Introduction & Motivation
02:08 What is Diplomat?
07:37 Bindings generator
10:29 Lifetimes
11:42 Current & Future work
Переглядів: 4 349

Відео

new trait solver walkthrough - lcnr - 2024.02.26
Переглядів 2,8 тис.4 місяці тому
new trait solver walkthrough - lcnr - 2024.02.26
Project Syn - Simon Gerber - Rust Zürisee March 2024
Переглядів 5 тис.4 місяці тому
Join us at RustFest Zürich, the ultimate event for Rust enthusiasts and newcomers alike. Learn, share, and celebrate the power and beauty of the Rust programming language. Don’t miss this opportunity to connect with the global Rust community on June 19-24, 2024. Get your ticket today! 🎟️ rustfest.ch In this talk, I'll walk you through the migration of a key component of Project Syn - our Kubern...
Rust Vienna Jan 2024 - Serverless Data Pipelines in Rust by Michele Vigilante
Переглядів 5 тис.4 місяці тому
Michele Vigilante - Serverless Data Pipelines in Rust At the Rust Vienna Meetup in January 2024 Michele, explores Rust in the field of data engineering, where you are usually stuck with writing Python code. Luckily, this does not always have to be the case, as we'll explore in this talk! The focus of this talk is building data pipelines in Rust using crates like DataFusion, object store and dep...
RustConf 2023 - Rustacean Community Interfaces: A Tale of Many Hats
Переглядів 2,5 тис.5 місяців тому
RustConf 2023 - Rustacean Community Interfaces: A Tale of Many Hats
RustConf 2023 - Rusty Genomics: Rust in the Biosciences
Переглядів 1,8 тис.5 місяців тому
RustConf 2023 - Rusty Genomics: Rust in the Biosciences
RustConf 2023 - The standard library is special. Let's change that.
Переглядів 11 тис.5 місяців тому
RustConf 2023 - The standard library is special. Let's change that.
RustConf 2023 - Too many cooks or not enough kitchens?
Переглядів 3,3 тис.5 місяців тому
RustConf 2023 - Too many cooks or not enough kitchens?
RustConf 2023 - Using Rust and Battlesnake to never stop learning
Переглядів 3,1 тис.5 місяців тому
RustConf 2023 - Using Rust and Battlesnake to never stop learning
RustConf 2023 - Rust in the skies over Antarctica
Переглядів 1,2 тис.5 місяців тому
RustConf 2023 - Rust in the skies over Antarctica
RustConf 2023 - The Art and Science of Teaching Rust
Переглядів 6 тис.5 місяців тому
RustConf 2023 - The Art and Science of Teaching Rust
RustConf 2023 - Rust in the Wild: A Factory Control System from Scratch
Переглядів 4,5 тис.5 місяців тому
RustConf 2023 - Rust in the Wild: A Factory Control System from Scratch
RustConf 2023 - Infrastructure for Rust
Переглядів 1,9 тис.5 місяців тому
RustConf 2023 - Infrastructure for Rust
RustConf 2023 - How Powerful is Const
Переглядів 14 тис.5 місяців тому
RustConf 2023 - How Powerful is Const
RustConf 2023 - Anything you can do, I can do worse with macro_rules!
Переглядів 4,3 тис.5 місяців тому
RustConf 2023 - Anything you can do, I can do worse with macro_rules!
RustConf 2023 - Integrating Rust and Go: Lessons from Github Code Search
Переглядів 2,3 тис.5 місяців тому
RustConf 2023 - Integrating Rust and Go: Lessons from Github Code Search
RustConf 2023 - Rewrite it in Objective-C?
Переглядів 1,1 тис.5 місяців тому
RustConf 2023 - Rewrite it in Objective-C?
RustConf 2023 - Async building blocks: A streaming Data Drama in Three Acts
Переглядів 2 тис.5 місяців тому
RustConf 2023 - Async building blocks: A streaming Data Drama in Three Acts
RustConf 2023 - Rust Foundation: Demystified
Переглядів 1,5 тис.5 місяців тому
RustConf 2023 - Rust Foundation: Demystified
RustConf 2023 - GUI Accessibility Across Platforms and Programming Languages Using Rust
Переглядів 1,7 тис.5 місяців тому
RustConf 2023 - GUI Accessibility Across Platforms and Programming Languages Using Rust
RustConf 2023 - A Rust-based garbage collector for Python
Переглядів 1,1 тис.5 місяців тому
RustConf 2023 - A Rust-based garbage collector for Python
RustConf 2023 - Beyond Ctrl-C the dark corners of Unix signal handling
Переглядів 2,3 тис.5 місяців тому
RustConf 2023 - Beyond Ctrl-C the dark corners of Unix signal handling
RustConf 2023 - Profiling async applications in Rust
Переглядів 3,7 тис.5 місяців тому
RustConf 2023 - Profiling async applications in Rust
RustConf 2023 - Fine! I'll just make my own stable ABI!
Переглядів 3,4 тис.5 місяців тому
RustConf 2023 - Fine! I'll just make my own stable ABI!
RustConf 2023 - Implementing a Blazingly Fast Quantum State Simulator in Rust
Переглядів 2,2 тис.5 місяців тому
RustConf 2023 - Implementing a Blazingly Fast Quantum State Simulator in Rust
RustConf 2023 - Extending Rust's Effect System
Переглядів 7 тис.5 місяців тому
RustConf 2023 - Extending Rust's Effect System
Stefan Baumgartner - Trials, Traits, and Tribulations
Переглядів 3,8 тис.5 місяців тому
Stefan Baumgartner - Trials, Traits, and Tribulations
Rainer Stropek - Memory Management in Rust
Переглядів 11 тис.5 місяців тому
Rainer Stropek - Memory Management in Rust
Massimiliano Mantione - Object Oriented Programming, and Rust - Rust Linz
Переглядів 4,2 тис.5 місяців тому
Massimiliano Mantione - Object Oriented Programming, and Rust - Rust Linz
Shachar Langbeheim - async & FFI - not exactly a love story - Rust Linz
Переглядів 2,6 тис.5 місяців тому
Shachar Langbeheim - async & FFI - not exactly a love story - Rust Linz

КОМЕНТАРІ

  • @guylandry9257
    @guylandry9257 18 днів тому

    Very informative.

  • @Tigregalis
    @Tigregalis 22 дні тому

    This talk was awesome. Would love to see an updated version 5 years later: what's changed since?

  • @russtaylor4242
    @russtaylor4242 24 дні тому

    Are there any newer Sōzu related videos please? I would like to write some custom features for a reverse proxy, and Sōzu looks like a good place to start.

  • @thanhtan030t
    @thanhtan030t Місяць тому

    the presentation skill is impressive. thank you, sir!

  • @cvrptn
    @cvrptn Місяць тому

    I like the talk a lot, and it's made me reconsider the design for my own lightweight game engine written in Rust. However, I'm wondering whether the whole generational indexes approach is the best way to go. Either you have very sparse entities with lots of different component arrangements (in which case you'll be allocating a lot of memory in your EntityMap component stores for entities not using these components), or your entites all have sort of the same set of components (in which case you might wonder if it's not better to just have a single Entity struct that contains all your components and store it in a large Vec<Entity>). Granted, the EntityMap pattern allows for very fast O(1) lookups of your components but it comes at the cost of wasted memory.

  • @artxiom
    @artxiom Місяць тому

    Really good talk and perspective! It reminds me btw a lot of the functional core, imperative shell approach (afaik Gary Bernhardt coined this concept). To be honest I'm not a big fan of OOP myself but it seems you use it in a very similar way I've been doing it: for "big" stateful services (aka actors). I also use it for "small things" that don't depend on anything else but contain a lot of state and functions on this state - so mostly container-like types. My main issue with OOP was always how bad it is at modelling domain problems and how OOP-abstraction increases actually tight coupling and decreases modularity. With data and functions it's simple: they are already "objects"/atoms/... so you model the data with these atoms, and you write the functions that transform this data and you put everything into modules to logically group it - everything is nicely separated and decoupled but logically grouped. Every function can work on a variety of data, so it's easier to model transformations between a variety of data - you don't have to think: where does function A belong? to object B,C or D? With objects on the other hand you create a "functional" relationship - data and functions are tightly coupled. In some cases that's perfectly valid, but more often it's not and you just created an abstraction over an abstraction for no reason. I often compare it to database relationships: in OOP you can only model 1:n relationships (1 class, which is also the state/data : n functions. I'm talking purely about the modeling side, so not how it is at runtime where you can have multiple objects for the same class). Most systems have a lot of n:m relationships though (n state/data : m functions, e.g. some_function(data a, data b, data c, ...)). So in OOP you need an extra layer of abstraction to "translate" to this n:m relationship. That's why I often see things like e.g. *Manager classes in OOP code. Nowadays whenever I encounter a "SomethingManager" class I consider it code-smell. The moment I have some inter-dependency of objects like: obj1.method(obj2) I usually refactor it so that they all depend only on pure data/functions not objects, like: obj1.method(just_some_simple_data). After all every dependency on an object makes it automatically depend on everything(!) else that object depends on: it's internal state, all the methods, class hierarchy, etc. You literally got the banana together with the gorilla and the jungle! Passing references to objects between objects is just crazy and I'm pretty sure that's not what Alan Kay had in mind. It's the lazy developers way of pulling in dependencies without specifying them explicitly, cheap in the beginning, but you pay double (and more) later. Some OOP-purists call me crazy but I have a very good track record of systems that are well designed this way - while they still discuss how to use design patterns to somehow manage their OOP mess ;)

  • @CjqNslXUcM
    @CjqNslXUcM Місяць тому

    I like that he basically gives therapy for people with impostor syndrome for the first few minutes.

  • @jooonmantv
    @jooonmantv Місяць тому

    Amazing video

  • @johanneslade2830
    @johanneslade2830 Місяць тому

    Thank you so much for all the rust content you produce. It helped me understand a lot of the more complicated corners of rust❤

  • @linkernick5379
    @linkernick5379 Місяць тому

    Are named arguments abandoned forever? 😢

  • @tiagocerqueira9459
    @tiagocerqueira9459 Місяць тому

    I have some concerns about the Rust "weirdness budget" running out, where people look at this think "what the f" and walk away. I'd say a priority is to don't let this leak too much in application code.

  • @CGMossa
    @CGMossa Місяць тому

    Is there a CRDT library in Rust that is actively developed?

  • @datathings
    @datathings Місяць тому

    This is wonderful! Thanks for this information. Had no idea about DataFusion before this.

  • @Ic3q4
    @Ic3q4 Місяць тому

    this is rustastic

  • @scosminv
    @scosminv 2 місяці тому

    What if the answer for "The internet is highly concurrent and highly security-conscious" is not a programming language but Webassembly runtime which is sandboxed ? Now if I write in C and compile to webassembly... can NSA say C is insecure ?

  • @santip.1910
    @santip.1910 2 місяці тому

    Magnífica exposición! Un gran saludo.

  • @bolekjakistam1018
    @bolekjakistam1018 2 місяці тому

    Great talk!

  • @laciferin
    @laciferin 2 місяці тому

    Amazing talk!! Very inspiring !! I chose Go over Rust 6 years ago cuz Rust didn't support async await natively at the time.Wish I had watched this video some time down the road. In 2024, i m starting with Rust.. Gotto to say its an amazing language for all people who consider coding as their passion.

  • @NickDrian
    @NickDrian 2 місяці тому

    U r great teacher

  •  2 місяці тому

    Great talk ! So good to hear people working on such an important tools !

  • @FortnitePro-kf9wl
    @FortnitePro-kf9wl 2 місяці тому

    Has any of this progressed?

  • @Heater-v1.0.0
    @Heater-v1.0.0 2 місяці тому

    "Rust in the Linux kernel"? Of course it turns out people did ask Linus about this and his response after looking at Rust was something like "It's not an entirely terrible idea". Which coming from Linus is high praise indeed. So now we do have Rust in the kernel. This talk is pretty amazing in that describes a lot of work done at MS that incorporated a lot of the ideas the Rust guys came up with and apparently was successful even if never adopted. So Rust is on the right track and this talk is a great sales pitch for it.

  • @ryanlog
    @ryanlog 2 місяці тому

    SIMDeez nuts

  • @olafschluter706
    @olafschluter706 2 місяці тому

    BTW: what is the extension of VSCode you are using that gives you the full explanation of the error cause in the text without the need to hover over the red curly underline? Atomic reference counting (ARC) - and Rust has an atomic variant of Rc called Arc (which means that only one thread at the same time may increment the count) in its arsenal which is very much needed in multi-threaded applications - does a nice job in Objective-C for memory management without garbage collection. Clone becomes cheap on an Arc as it just increments the reference count. I am glad that Rust offers it. But as you can only get immutable access to the data pointed to by an Arc, don't get over your head using it. If you want concurrent mutable access to data, you need a Mutex (or its more relaxed variant RwLock, which allows for multiple readers or one single writer at the same time), which is another smart pointer in Rust's arsenal. Packed into an Arc it can be cloned cheaply and distributed among threads, but only one thread at the same time will be able to read or alter the data protected by the Mutex (more readers are allowed with RwLock, but once a thread wants to write, it has to wait for all other readers or writers to release the lock). So don't be surprised if you see a lot of Arc<Mutex<Type>> declarations in multithreaded rust code. It's always a mouthful, but surprisingly efficient in the resulting machine code. But a mutual exclusive lock is never without costs. It depends on the nature of the task you want to compute using multiple threads and the way you organise the work - if locking happens often, the result may be (often much) slower than a single-threaded implementation.

  • @OSSMaxB
    @OSSMaxB 2 місяці тому

    Interesting. I was about to complain that the size of `Foo` isn't 5 but should be 8 because of padding. But then I actually tried it out and it turns out it is actually 4. I guess `char` has some niche values that are used. (Unicode code points only go up to 2^21 not 2^32, so there's a lot of values to choose from).

  • @hanyanglee9018
    @hanyanglee9018 3 місяці тому

    42 Comments 😆

  • @alexpyattaev
    @alexpyattaev 3 місяці тому

    Alice please persent more!

  • @StupidusMaximusTheFirst
    @StupidusMaximusTheFirst 3 місяці тому

    Linux decided to sprinkle some rust on the kernel, though there's nothing better than embedded rust. 😃

  • @langhistruk
    @langhistruk 3 місяці тому

    Not only he’s a very skilled and smart professional, but also an awesome human being

  • @DavidAlsh
    @DavidAlsh 3 місяці тому

    I found Stabby randomly on a Reddit post and I friggen love it. I opened this video because the topic is relevant to the work I am doing now, pleasantly surprised to see that this is an explainer on Stabby!

  • @yailkalaf8542
    @yailkalaf8542 3 місяці тому

    Cleared a lot of doubts . Thanks!

  • @flwi
    @flwi 3 місяці тому

    That's an excellent talk! So glad it popped up in my timeline. Will watch it again after reading through the article and experimenting a bit.

  • @kurkdebraine8139
    @kurkdebraine8139 3 місяці тому

    Rayner always good! Greetings from Argentina.

  • @flwi
    @flwi 3 місяці тому

    Great talk! I just started with rust and learned a lot!

  • @returncode0000
    @returncode0000 3 місяці тому

    Great talk, really useful, thanks!

  • @arubaga
    @arubaga 4 місяці тому

    Stabby is such a good name!

  • @geodesic98
    @geodesic98 4 місяці тому

    great talk, i found this haphazardly and was immediately drawn in

  • @Vagelis_Prokopiou
    @Vagelis_Prokopiou 4 місяці тому

    Very useful library. This will push Rust forward a lot.

  • @MrMrCraftmine
    @MrMrCraftmine 4 місяці тому

    This is amazing

  • @1Erledus1
    @1Erledus1 4 місяці тому

    if you make RUST -> JS is it plain JS (ES6) or does it need node.js

    • @Mankepanke
      @Mankepanke Місяць тому

      It's a wrapper around FFI, so it's very likely to need Node. You can't load and call system libraries from any JS runtime.

  • @dmitriidemenev5258
    @dmitriidemenev5258 4 місяці тому

    You just got another core maintainer on board. Let's move Rust forward!

  • @notcrediblesolipsism3851
    @notcrediblesolipsism3851 4 місяці тому

    Thanks for this, I've been playing around with smart pointers and refcells and probably used them excessively, i can simplify some of what I've done with Box<>.

  • @flwi
    @flwi 4 місяці тому

    Wow, this was a great presentation! I just started learning rust this month learned a lot by this look behind the scenes. Well done!

  • @kurkdebraine8139
    @kurkdebraine8139 4 місяці тому

    Mr Stropek you are one of the best exposer i“ve ever heard on the topic. This talk was invaluable for me! Thanks a lot. Rust, give this man more talks please. And ty you too.

  • @awnion
    @awnion 4 місяці тому

    The exposed API should be Pythonic, not Rustonic. E.g. as_dict() should be called implicitly on e.g. get(key) call.

  • @MuscleTeamOfficial
    @MuscleTeamOfficial 4 місяці тому

    Thx Michele

  • @jocketf3083
    @jocketf3083 4 місяці тому

    Nice! Seems like a great use-case.

  • @StylishHobo
    @StylishHobo 4 місяці тому

    I was literally reading the new solver code yesterday! Thank you for the walkthrough.

    • @Andrii-zc4dp
      @Andrii-zc4dp 4 місяці тому

      the one person who has a chance of understanding this xD