LogAn::Inc::Main: uses new SBDB::Env#[]-API
This commit is contained in:
parent
d49ab73666
commit
9fb86ef146
|
@ -43,11 +43,11 @@ module LogAn::Inc
|
||||||
# Set inc-config - stored in etc/inc.cnf
|
# Set inc-config - stored in etc/inc.cnf
|
||||||
@conf[:inc] = {}
|
@conf[:inc] = {}
|
||||||
%w[hosts files fileparser].each {|key| @conf[:inc][key.to_sym] = config( @etc, key) }
|
%w[hosts files fileparser].each {|key| @conf[:inc][key.to_sym] = config( @etc, key) }
|
||||||
@store = Cache.new AutoValueConvertHash.new( @etc[ 'sids.store', 'seeks', SBDB::CREATE | SBDB::AUTO_COMMIT]), 3
|
@store = Cache.new AutoValueConvertHash.new( @etc[ 'sids.store', 'seeks', SBDB::Recno, SBDB::CREATE | SBDB::AUTO_COMMIT]), 3
|
||||||
# Prepare Inc-server - create server
|
# Prepare Inc-server - create server
|
||||||
LogAn::Inc::Fileparser::Base.logdb = @logs
|
LogAn::Inc::Fileparser::Base.logdb = @logs
|
||||||
LogAn::Inc::Fileparser::Base.store = @store
|
LogAn::Inc::Fileparser::Base.store = @store
|
||||||
@serv = LogAn::Inc.new :sock => TCPServer.new( *@conf[:server]), :config => @conf[:inc]
|
@serv = LogAn::Inc::Server.new :sock => TCPServer.new( *@conf[:server]), :config => @conf[:inc]
|
||||||
# Shutdown on signals
|
# Shutdown on signals
|
||||||
@sigs[:INT] = @sigs[:TERM] = method( :shutdown)
|
@sigs[:INT] = @sigs[:TERM] = method( :shutdown)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue