M
Modular14mo ago
Hammad

Writing a server in mojo

Hi - I want to expose a mojo program via a small http server. Is there a way to do this natively in mojo (i.e do the networking stdlibs exist)? If not, can I use python to do this within mojo?
8 Replies
Kushagra
Kushagra14mo ago
I believe you can use Python-interop to use Django in Mojo
Hammad
HammadOP14mo ago
Does that work by calling back into mojo from python (Sorry, not actually familiar with how mojo interops with python)?
Sardor
Sardor14mo ago
You can call sockets from libc.
Sardor
Sardor14mo ago
GitHub
GitHub - crisadamo/mojo-libc: mojo-libc
mojo-libc. Contribute to crisadamo/mojo-libc development by creating an account on GitHub.
Sardor
Sardor14mo ago
This is example of using libc
Hammad
HammadOP14mo ago
Oh wow. That is lower level than I'd prefer to be but interesting thanks. Do you/anyone know of the long term plan for how mojo intends to support this?
TheCodeMeister
TheCodeMeister13mo ago
I am a Software developer in python django, and i love how the python ecosystem provides packages to develop backend applications seemingly fast. but it does have bottlenecks as well. It is not as high performing as its competitors like in Java/Go also there are certain needs in todays world where we need concurrency and it is only going to grow in the future. is there a plan for atleast a backend application stack (including, web server, caching, <u>concurrency (MUST HAVE) </u>, ORMs) ?
Kushagra
Kushagra13mo ago
Well, I'm working to build a server using C ffi Also there is firedis repo that is redis implemented in mojo
Want results from more Discord servers?
Add your server