This is to track the evolution of attester into a modular system.
The base need is to let user extend attester behavior without modifying the core structure. A source of inspiration is grunt and its plugin system.
The main idea is to shift from a command line utility to a generic module.
Similar to grunt we can have two packages attester and attester-cli. The command line interface would
Attester module will have the following API (stealing from grunt)
It'll be an EventEmitter raising at least the following events
Regarding th extensibility on the output, it might be a good idea to have a two-tier system. What is now the json logger is the first layer, a module that receives any possible update from the slaves and from attester itself.
Output plugins might benefit from a filtered and structured output, things like
From a user perspective there shouldn't be any difference in the command line nor in the maven plugin.
If needed for more complex behaviors she might write an attester file instead of a plain configuration object.
attesterFile.js might look like this
var attester = require("attester");
// directly a json file
// an alternative could be
attester.initConfig("a file path"); // to read directly from the file system
// If a plugin requires configuration it should be in the configuration file / object passed to initConfig
attester now have even plugins, I guess this can be closed