4 ms·
Ask HN: Should I choose NJS or Lua to extend Nginx
I am working on a simple key value store for a project. I want to avoid messing with python server like uwsgi and having a reverse proxy and would like to take this opportunity to work with nginx.
I noticed that they added NJS, and they are heavily promoting that. Which one should I use? I will be saving and retrieving files from a disk (cca 200mb per file).
- smt88 5y agoNginx does that natively. The key is the file name and the store is the disk. You can transform URLs using config files, if needed.
- phillipseamore 5y agoThere are nginx modules for interacting with Redis and memcached.
- mitjafelicijan 5y agoI know about the ngx_http_keyval_module. I, however, would need to make this distributable with something like Raft consensus protocol. Or something similar to that, and I would like to avoid coding this in C if possible. Maybe the solution could be something hybrid between already existing plugins and then do only the distribution part of the thing.