Re:Show HN: Erlang REST framework
by hlieberman on Tuesday November 14, 2017 @08:34PM
(#15700852)
I'm not sure why you would use this over cowboy's REST handler. Cowboy is the thing that powers Phoenix -- you really can't beat it for concurrent performance.
(Loïc of NineNines is an absolutely incredible guy that does a ton of really important work, and you all should consider supporting him at https://salt.bountysource.com/teams/ninenines)
Re:Show HN: Erlang REST framework
by notamy on Tuesday November 14, 2017 @08:41PM
(#15700867)
Syntax as well as just that it's a really weird way of thinking about things compared to languages like Java, Python, etc. Elixir seems to be helping some with this, so I guess we'll see.
Re:Show HN: Erlang REST framework
by saurik on Wednesday November 15, 2017 @03:10AM
(#15702213)
The canonical argument order in Elixir is backwards from Erlang (and I will argue just "wrong" with respect to the functional programming paradigm: it is essentially object-oriented corruption... the subject pretty much needs to be the final argument for various forms of functional composition to work; the place where this really becomes clear is when trying to call "reduce", which continues to have the "correct" argument ordering even while almost nothing else does <- though watch me be misremembering the exact place where this clicks as it hasn't been years since I spent a lot of time trying to be happy programming with Elixir :/), so there is a massive impedance mismatch tying to reuse functions and primitives codes in one language from the other (and it almost seems like many Elixir wrappers exist only to reverse the argument order). So, sure: they are "interoperable"... but so are C and Python ;P.
Re:Show HN: Erlang REST framework
by filmor on Wednesday November 15, 2017 @03:34AM
(#15702328)
Erlang does not support currying, so having the subject in the last arg does not help much.
Also, the actual ordering is not `func(Args..., Subject)` but instead `func(Args..., Subject, OptionalArgs...)` which bit me more than once.
I like Elixir's consistent use of the first arg for the subject along with the pipe operator, which gives you essentially currying-like behaviour in the first argument.
Re:Show HN: Erlang REST framework
by tazjin on Wednesday November 15, 2017 @09:14AM
(#15703820)
> it's a really weird way of thinking about things compared to languages like Java, Python
This depends on your background. I have a very hard time thinking about procedural behaviour and state mutations, Erlang's (and other functional language's) model is much easier to keep in my head.
(Loïc of NineNines is an absolutely incredible guy that does a ton of really important work, and you all should consider supporting him at https://salt.bountysource.com/teams/ninenines)
You can. Cowboy is not the most performant web server in Erlang.
PS: if anyone is interested in a language-agnostic artifact like cowboy's or webmachine's, see https://github.com/for-GET/http-decision-diagram
The language syntax is small enough that I believe it'll take a short time to learn and get use to the syntax versus other languages.
I'm not sure size of syntax has all that much to do with adoption. Case in point: Lisp.
Also, the actual ordering is not `func(Args..., Subject)` but instead `func(Args..., Subject, OptionalArgs...)` which bit me more than once.
I like Elixir's consistent use of the first arg for the subject along with the pipe operator, which gives you essentially currying-like behaviour in the first argument.
This depends on your background. I have a very hard time thinking about procedural behaviour and state mutations, Erlang's (and other functional language's) model is much easier to keep in my head.
It actually shares a lot of the usecase with golang, I would say, if the program can be distributed as binary, there would probably no golang.
Meaning?
https://github.com/basho/webmachine/wiki
Edit: apparently it's still at least somewhat alive... http://lists.therestfulway.com/pipermail/webmachine_lists.th...
http://absinthe-graphql.org