lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


I am happy to announce the first release of nozzle. It is a library for building filters and chaining them into pipelines.

For instance, validating that some raw data is properly encoded a json, then check that certain members are present, then do some logging and then call a function which does the actual work can be expressed as a pipeline, which you build by concatenating functions, mostly.

check_json .. fields_present .. log_stuff .. actual_function

You can build partial pipelines and reuse them:

local pipeline = check_json .. fields_present .. log_stuff 

pipeline .. actual_function

pipeline .. other_function


Its homepage is on Github [1]. There you can find more information and source code.

I find this helpful mostly when building validations, composing other libraries like valua [2] or tamale [3]. A more detailed document is available at [4].


Install it with LuaRocks, using:

  luarocks install nozzle

The code is MIT licensed and it works with Lua 5.1, 5.2, 5.3 and LuaJIT.

All feedback is welcome!



[1]: https://github.com/ignacio/nozzle
[2]: https://github.com/sailorproject/valua/
[3]: https://github.com/perusio/tamale
[4]: https://github.com/ignacio/nozzle/blob/master/docs/manual.md