Documentation ¶
Index ¶
Constants ¶
const ( //Connect mqtt connect Connect = "connect" //Publish mqtt publish Publish = "publish" //Subscribe mqtt sub Subscribe = "subscribe" //Unsubscribe mqtt sub Unsubscribe = "unsubscribe" //Disconnect mqtt disconenct Disconnect = "disconnect" PingReq = "ping" )
const ( //Kafka plugin name Kafka = "kafka" CSVLog = "csvlog" )
Variables ¶
This section is empty.
Functions ¶
func InitCSVLog ¶ added in v0.0.8
func InitCSVLog() *csvLog
InitCSVLog initialises a CSVLOG plugin It does this by loading a config file if one can be found. The default filename follows the same convention as the kafka plugin - ie it's in "./plugins/csvlog/csvlogconfig.json" but an environment var - CSVLOGCONFFILE - can be set to provide a different location.
Once the config is set the worker is started
func LoadCSVLogConfig ¶ added in v0.0.8
func LoadCSVLogConfig() csvBridgeConfig
LoadCSVLogConfig loads the configuration file - it currently looks in "./plugins/csvlog/csvlogconfig.json" (following the example of the default location of the kafka plugin config file) if it doesn't find it there it looks in two further places - the current directory and an "assets" folder under the current directory (This is for compatibility with a couple of deployed) implementations.