Make default .sincedb location configurable
Description
Gliffy Diagrams
Activity
Show:

Former user January 2, 2012 at 5:13 PM
released ruby-filewatch 0.3.2, integrated into logstash's gemfile, and fixed some default sincedb_path handling in the file input. now working:

Former user January 1, 2012 at 4:13 PM
I'll check a SINCEDB_PATH env variable in filewatch.
Fixed
Details
Details
Assignee

Reporter

Fix versions
Affects versions
Created December 2, 2011 at 9:30 PM
Updated April 19, 2013 at 8:20 PM
Resolved January 2, 2012 at 5:13 PM
The logstash input file plugin currently defaults sincedb_path to #{ENV['HOME']}/.sincedb
It would be very useful to be able to set an environment and/or system variable such as DEFAULT_SINCE_DB_HOME (or DEFAULT_SINCE_DB_PATH) and/or provide a command line argument to specify this.
A cascade of environment variables would work as well. (i.e.: If $DEFAULT_SINCE_DB_HOME is unavailable, then use $HOME, etc.)
Whether this is done via a command line argument, environment variable, java system variable or a single global default section in the configuration file isn't all that important to me. Any of these solutions would solve my problem of providing a simply DRY way of specifying the default .sincedb location.
---------------
MOTIVATION:
When deploying the shipper to a large number of nodes with configuration files monitoring a large number of files, it would be awkward (NOT DRY) to specify the sincedb_path in every single file plugin specification in the config file on every node. At the same time, setting $HOME to the deployment directory (i.e. /opt/logstash-agent) doesn't make a lot of sense either.