Open iapicca opened 4 years ago
@jayjah
I'm not sure the article is still reliable (2018) anyhow I believe c/c++ and rust are an easier for dart:ffi
that's the only reason why I mentioned specifically quiche
but if you are able to run quick
that would be awesome, I have no clue how to do that
@iapicca I think the 2nd solution is better. Because the targets of Flutter are not only on iOS and Android but also on other platforms.
for my understanding isar from excellent @leisim binds a rust base db using dart:ffi for both web and native borrowing this approach could make the second option quite realistic
- QUICHE + dart:ffi (resource for rust + dart:ffi) could work from both android, ios, desktop and maybe in the future for web
@iapicca No, Isar will use the Rust engine for mobile and desktop targets and a custom typescript db engine for web. The reason is that WASM has no access to Browser APIs (IndexedDB) and has to communicate via JavaScript. Depending on the use case, this can be a lot slower than using JavaScript in the first place.
Edit: Also, Dart FFI cannot communicate with Rust on the web (WASM) so you need to use JavaScript to communicate with WASM.
@iapicca Unfortunately I don't think that would solve the performance problems. There are some outstanding WASM proposals that will significantly improve the situation but they will need years until all browsers ship them.
this feature request could help help implementing the feature
If anyone interested, cronet_flutter is the origin PoC of google/cronet.dart, and could run in Android/iOS
and Windows/macOS/Linux
i understand a native implementation might be difficult but a binding to quiche or ms-quic is not out of reach ... where are we +2 years lates ?
Who is using what solutions now as an HTTP/3 server and client?
We have started a pure dart dtls implementation on this repo:
Given that
HTTP3 QUIC are very promising, but Flutter Team has, legitimately, too much on its plate to take craft a dart package (references 1, 2, 3) and even react native approach seems to be through native clients (source)
It would be great if the community could come out with a plugin to support this feature, I don't have the brain muscles or the expertise to deal with it myself, but I'd be happy to help.
I believe there are 2 possible strategies to support
QUIC
:CRONET on the native side for android and ios
QUICHE + dart:ffi (resource for rust + dart:ffi) could work from both android, ios, desktop and maybe in the future for web
there will be probably some js package to use for web, but I haven't located it
Do you think such plugin could be useful for the community?