Live data from Hacker News

Elixir 1.9

elixir-lang.org

161–170 of 174 posts

Re: Elixir 1.9

#161

Earlier quoted context omitted.

> It's a near certainty that I've written an order of magnitude more elixir code than you have and I can say without a shadow of a doubt that elixir's lack of static typing definitely makes it less useful. You should really read that post I linked, and do a bit more research on this topic. The consensus in the Elixir community (where many members have written an order of magnitude more Elixir than you) is that static…

I've done all the research I need to, thank you very much, and I was there when this thread was started and much earlier than that. The consensus in the elixir community is hardly relevant when most of the users aren't experienced enough with type systems to know what they're talking about. If you asked a community of people who primarily have never used languages that don't have garbage collection, they'll likely no…

Friend, you're making a lot of assumptions and claims about people you don't know (including me), and have a certain streak of arrogance that is difficult to get past. This makes it impossible to have a productive conversation, if having a productive conversation is your goal.

I advise some humility, as well as some effort to recognize that your opinions sound very dogmatic. You are of course free to like or dislike any language you want, but it is important to understand that going from one's own preferences to grandiose claims about a language's merits and usefulness is a rather big leap.

Re: Elixir 1.9

#162

Earlier quoted context omitted.

I've done all the research I need to, thank you very much, and I was there when this thread was started and much earlier than that. The consensus in the elixir community is hardly relevant when most of the users aren't experienced enough with type systems to know what they're talking about. If you asked a community of people who primarily have never used languages that don't have garbage collection, they'll likely no…

Friend, you're making a lot of assumptions and claims about people you don't know (including me), and have a certain streak of arrogance that is difficult to get past. This makes it impossible to have a productive conversation, if having a productive conversation is your goal. I advise some humility, as well as some effort to recognize that your opinions sound very dogmatic. You are of course free to like or dislike…

> Friend, you're making a lot of assumptions and claims about people you don't know (including me), and have a certain streak of arrogance that is difficult to get past.

This is rich, coming from someone who claimed that anyone who wants a type system in elixir hasn't actually used elixir.

> You are of course free to like or dislike any language you want, ...

This is the most common reaction within the elixir community, to assume that anyone who doesn't put the language on a pedestal dislikes it or hates it. You might want to consider what that actually says about the community and the atmosphere of near unconditional admiration it displays. It's an extremely distasteful attribute for a community to have.

Elixir is useful for shuffling data from point A to point B... That usefulness has its limits, that's it.

Re: Elixir 1.9

#163
post #60

Earlier quoted context omitted.

yes, but they do come with a lot of cognitive load and sharp edges. For many apps they are simply not worth it.

The cognitive load is quite low when deploying changes which only involve your app code (i.e., no dependency upgrades). My app has a few tens of millions of open websockets at a time, and it's worth it to me to avoid mass reconnects. I'm not everyone, but my use case isn't totally unique either.

"Few tens of millions of open websockets" is more than Slack and Discord combined, not?

BTW: we were the first who did 1M long-living connections load test with Cowboy on a single EC2 instance back in 2011. And 3M long-polling HTTP requests on a single beefy physical server.

It was before WhatsApp upstreamed their optimizations and before Phoenix team made it easy.

Re: Elixir 1.9

#164

Earlier quoted context omitted.

Friend, you're making a lot of assumptions and claims about people you don't know (including me), and have a certain streak of arrogance that is difficult to get past. This makes it impossible to have a productive conversation, if having a productive conversation is your goal. I advise some humility, as well as some effort to recognize that your opinions sound very dogmatic. You are of course free to like or dislike…

> Friend, you're making a lot of assumptions and claims about people you don't know (including me), and have a certain streak of arrogance that is difficult to get past. This is rich, coming from someone who claimed that anyone who wants a type system in elixir hasn't actually used elixir. > You are of course free to like or dislike any language you want, ... This is the most common reaction within the elixir communi…

> This is rich, coming from someone who claimed that anyone who wants a type system in elixir hasn't actually used elixir.

You may want to read my original post more carefully. I said most people who complain about the lack of static typing haven't actually used it. Obviously there are some, like you, who have experience with the language and dislike the lack of static typing. And that is fine.

I mean, you only need to casually browse HN threads about new languages to find posts along the lines of "this looks interesting, but the lack of static typing means I probably won't use it." Instead of taking a holistic view of the language and its merits and researching its design choices and trade-offs, they adopt a dogmatic mindset and dismiss it outright.

>>This is the most common reaction within the elixir community, to assume that anyone who doesn't put the language on a pedestal dislikes it or hates it.

No, that's just me, and it was a figure of speech. Elixir community is very mature and welcoming, and most people in it come from other languages, and are able to objectively discuss the language, its merits and shortcomings. The post I linked in my OP is a great example.

>>Elixir is useful for shuffling data from point A to point B... That usefulness has its limits, that's it.

I mean, again, that's just your opinion, and it's a simplistic one. I obviously don't know the depth and breadth of your experience (and won't make assumptions about it, like you did about mine), but Elixir is useful for, and excels at, more things than simply "shuffling data". That is why there is so much excitement for it: the use cases it enables, and the elegance and simplicity with which it enables them, are nearly unparalleled. The lack of static typing does not change this fact, even if it can make certain things a bit more cumbersome towards the extreme end of the project size and complexity spectrum.

Re: Elixir 1.9

#165
post #39

If anyone is on the fence on learning Elixir / Phoenix (Elixir's most popular web framework library) please do yourself a favor and give it a shot. If you're on a time crunch and want the best bang for your buck on "why bother learning yet another language to write web apps in?" then watch this talk called "The Soul of Erlang and Elixir": https://www.youtube.com/watch?v=JvBT4XBdoUE I'm not affiliated with the languag…

The Authn/Authz story of Phoenix is a joke though compared to Rails/Devise or Django. The framework authors refuse to ship a first party implementation and instead leave it to the community. Problem is, the ones available are mostly extremely low level (ueberauth, guardian etc.) and you have to spend ages customizing it. On Rails it's literally two commands to set up user registration, email confirmation, password re…

>> The framework authors refuse to ship a first party implementation and instead leave it to the community

Maybe for AuthN, but AuthZ is pretty far from the business of a web framework. The framework authors seem, for the most part, to be avoiding first-party endorsement of secondary tooling that doesn't deeply benefit from being first-party. I find it super refreshing coming from Rails where it is either the golden path or good luck.

A lot of the early AuthN libraries seem to target the controller layer, but I've found, having worked on a couple of sizeable Phoenix production codebases, that AuthN at the app domain layer works better. Regular use of channels as an alternate entrypoint to web request controllers means that controller based helper libraries are less valuable. Once you push this logic inside the app domain, it really isn't the business of Phoenix to know or care about it, since you're just working in plain Elixir, probably with some sort of Ecto struct to represent identity.

Re: Elixir 1.9

#166

Earlier quoted context omitted.

> The Authn/Authz story of Phoenix is a joke though compared to Rails/Devise or Django. The framework authors refuse to ship a first party implementation and instead leave it to the community. I agree, but it's not unique to Phoenix. In the PHP world the otherwise excellent Symfony framework is only starting to add generation of authentication/authorization, and email confirmation and password reset remains the devel…

That's partially true because you have FosUserBundle as kind of defacto standard for user facing auth (but yes it's a community package) and many built-in things for APi auth.

FosUserBundle is no longer recommended, and is superseded by Guard. Guard is considerably nicer to work with, and doesn't take long to build the extra bits (password reset etc) but (a) it's not built-in, and (b) if done as a bundle, it doesn't get the same level of support.

Re: Elixir 1.9

#167
post #37

Earlier quoted context omitted.

This is incorrect. I'd feel a lot better if it were true!

Paul went to work for Dockyard with Chris McCord when they started working on this feature for Elixir (and still is). If he isn't the one writing it, he's certainly been highly involved with the conversation.

I was initially hired at DockYard to work specifically on releases and their eventual integration into core, but I am not a member of the Elixir core team itself :). In any case, that in itself is not really a relevant detail, since José and I talked frequently about the core implementation, so being on the core team wouldn't have changed much there.

Re: Elixir 1.9

#168
post #150

Earlier quoted context omitted.

I sometimes joke that microservices are half of Erlang, badly implemented (I guess Greenspun’s Curse is broken?). Elixir has been second or third on my todo list for a long time. With the scary news from Vue, it might have just jumped the queue.

Thanks Robert Virding http://rvirding.blogspot.com/2008/01/virdings-first-rule-of-...

See also, Stigler's Law.

Or Poe's law, thus named in 2005, but based on a phenomenon that was well known by the time of Godwin's law.

Re: Elixir 1.9

#169

Earlier quoted context omitted.

For all that to work you will need: - to understand exactly what your app is doing - to understand exactly what Erlang/Elixir releases are doin - to understand exactly how cod upgrade works - to understand exactly or very damn well how to make the system handle those 1 million connections - to understand exactly how to handle all the things you wrote about And then, and only then will you be able to "think about bein…

Eh...it’s basically a 1 line command with distillery. Another for the rollback capability. It’s pretty magical. There’s a reason people love it. Certainly, don’t use it if you don’t need it...it introduces extra complexity...but if you do it’s really hard to beat.

I was mostly listing things you need for Erlang. Elixir, thankfully, hides a lot of things away in much friendlier packages.

That said, even with Distillery, if something goes awry, you'll need to know the warts behind the magic :)

Re: Elixir 1.9

#170

Earlier quoted context omitted.

I partially agree, but none have the preemptive green threads of the BEAM VM and its amazing tooling around supervisors and worker hierarchies. Trust me, if somebody puts that in Go, Rust or OCaml -- I'd ditch Elixir tomorrow. The BEAM VM is just too good. You can have thousands of smaller tasks running in parallel and nothing lags until you hit the physical limits of the hardware -- which 99% of the apps never do.

I think this is right on point. The BEAM is finely tuned for a specific problem and it solves it beautifully in a way that is extremely hard to replicate unless you actually are willing to invest in some kind of run time (which instantly makes you ineligible for consideration in a lot of peoples' minds). Every language that has tried, as far as I know, has done so as an afterthought and obviously does not end up repl…

> The BEAM is finely tuned for a specific problem and it solves it beautifully...

Not disagreeing with you per se but that was true 10 or 20 years ago. Nowadays the BEAM is very solid general-purpose runtime with the best parallelism on the planet attached.

> Knowing that, it's perhaps more pertinent to talk about what you can actually bring to that VM. Alpaca [0] could potentially be the solution.

Realistically, I'd say that ship has sailed. Elixir has a lot of inertia for that to happen at this point. People focus really hard on improvements over Dialyzer (like Dialyxir + improving warning messages), linting, standard formatting, higher-level code generators and what-have-you.

At this point I'd think an OCaml-to-Elixir transpiler that enforces the compile-time guarantees of OCaml and translates them to Elixir code is the much likelier road to strong static typing on the BEAM. I might be wrong though, it's just a speculation.

Post reply on HN