4 ms·
I'm running an elixir startup pros: - web-socket story is the goat (and I used to write nodejs) - ecto database library is amazing - productivity is on par
by cultofmetatron 5y ago
I'm running an elixir startup
pros:
- web-socket story is the goat (and I used to write nodejs)
- ecto database library is amazing
- productivity is on par with django/rails
- performance is comparable to go. sub 100ms response times are normal
cons
- not many drop in libraries.
- hiring engineers is a pain but plenty are interested in learning
- libraries are not as used so you're more likely to run into a big in edge libraries.
- deployment is more complex if you want to use the mesh features
So far, I'm happy with it. There are certain features specific to my startup that would elixir/otp made easy to create. We're getting traction and elixir's strengths are a huge part of that.
- ipnon 5y agoHow hard is it for you to hire someone who knows how to program a web server, be it with Rails, Java, C#, or whatever, and have them be net productive with Elixir in a few weeks?
- dnautics 5y agoIt's easy if you have one senior in elixir to bootstrap off of. The right senior could probably bootstrap a junior fairly quickly too. If you don't have a senior, there's a good chance you'll miss your target if you "try to do it in a few weeks" since there's a lot of deprogramming your brain off of imperative pls that you have to do.
- cultofmetatron 5y agonot hard. I learned enough to be productive after a few weeks of self study 4 years ago when there were way less resources for learning. we had a subcontractor helping me who didn't' know elixir. I was able to get him running within a few days. his lack of sql knowledge was more of a bottleneck than his elixir proficiency.
- jkhdigital 5y ago+1 Ecto is killer, not just the library itself but also how it provides a slick example of a DSL using Elixir macros. I used to love Elixir for the syntax and actor model, but macros have gotten me all hot and bothered.
- dnautics 5y agoso having worked in the trenches in Elixir, I dislike people trying to build too many macros. You get to a place where someone has decided to be clever in the codebase and dropped a bunch of macros that rewrite function calls and make it impossible to chase your function with the search command and you start wishing for a time machine to go back and prevent that code from being shipped.
- ctvo 5y ago> - performance is comparable to go. sub 100ms response times are normal What does this even mean? What are your dependencies? What does your service do? Sub 100ms response times are the norm for many languages. It's replies like this that make me think I work in a different world.
- exdsq 5y agoResponse times are subjective. Sao Paulo to Singapore has 350ms median latency so give me some <1ms service and it'd still take 350ms. If you just mean localhost response times then gin-gonic offers <50ns responses.
- cultofmetatron 5y agoin this context. its processing a graphql query, performing a batched set of db calls to postgresql, and responding back from the server. this doesn't include the time from the server to the user which varies from 200-500ms. sadly I can't do much about that part,
- NavinF 5y ago> sub 100ms response times are normal That sounds incredibly slow for something that responds on a websocket, but you never told us what you're doing besides db transactions (which should be 1ms unless you're on spinning rust)
- cultofmetatron 5y agothats the full end to end request comes in, parses input, performs db calls, processes a response packet and sends data out
- NavinF 5y agoThanks for clarifying. I still think 100ms is excessively slow unless you're doing something like realtime video encoding. A dozen postgres writes only take a couple of ms and that should be the bottleneck, not stuff like parsing. If you have 2 data centers in the US, network latency to the user only adds 10 to 50 ms
- Thaxll 5y ago> performance is comparable to go. sub 100ms response times are normal Go is between 2x and 20x faster than Erlang. Erlang is a pretty slow language, it's in the same performance range as Python. Some reasons: - it's using a VM - the VM is not very well optimized ( compared to Java or C# ) - immutability has a big cost in term of performance