3 ms·
I browsed the docs and found no mention of OTP. I might have missed it but it would be strange to have a language on BEAM with no native interface to those modu
by pmontra 3y ago
I browsed the docs and found no mention of OTP. I might have missed it but it would be strange to have a language on BEAM with no native interface to those modules. I looked for examples of supervision trees and gen servers.
- Ndymium 3y agoOTP is a work in progress available in the gleam_otp [0] package, supplemented with the lower level gleam_erlang [1]. Or you can call OTP things manually with FFI. [0] https://hexdocs.pm/gleam_otp/index.html https://hexdocs.pm/gleam_otp/index.html [1] https://hexdocs.pm/gleam_erlang/index.html https://hexdocs.pm/gleam_erlang/index.html
- ungamedplayer 3y agohttps://github.com/wmealing/gleam-otp-design-principals/blob/main/gleam-otp-design-principals.org https://github.com/wmealing/gleam-otp-design-principals/blob... This is what I wrote regarding using otp in gleam. One of the issues I'm working on next is to send typed messages to processes, which has me a little stumped. At the moment the typed channels work, you can't register () a channel or a pid. I will likely continue working on this document once I have my current project completed.
- kimi 3y agoThey seem to have rewritten/wrapped OTP, but it's not production ready. https://github.com/gleam-lang/otp https://github.com/gleam-lang/otp YMMV, but a BEAM language without OTP severely limits its appeal and usability.
- lpil 3y agoIt is being used in production by a good number of people, and the webserver made using it is faster than Cowboy, the most popular Erlang webserver. All OTP is usable from Gleam.
- kimi 3y agoNot sure I understand then, the OTP library says "This library is experimental and will likely have many breaking changes in the future!". So you can use untyped OTP as you would from (say) Erlang?