4 ms·
I've often wondered why nginx decided to implement their own njs Javascript instead of just embracing lua/luajit which already has a very healthy ecosystem in n
by VWWHFSfQ 5y ago
I've often wondered why nginx decided to implement their own njs Javascript instead of just embracing lua/luajit which already has a very healthy ecosystem in nginx and, as far as I know, is still orders of magnitude faster than even the fastest Javascript implementations.
- masklinn 5y agoAccording to Igor Sysoev’s 2015 presentation, they disliked Lua’s divergences from the C-style (e.g. begin/end, 1-indexing) as well as the “non-standard” syntax for regex (which would be pretty important for scripting nginx). And while he acknowledged that javascript has its own oddities, as far as he was concerned people are used to those from their use in other contexts. If you want to watch the entire thing, it’s “A new and powerful way to configure nginx” on youtube.