Re-add write_to_es function
This commit is contained in:
parent
c31175fea0
commit
be3b97ae42
|
@ -68,6 +68,13 @@ class Money(util.Base):
|
||||||
self.lc_es_checks.start(delay)
|
self.lc_es_checks.start(delay)
|
||||||
self.agora.es = self.es
|
self.agora.es = self.es
|
||||||
|
|
||||||
|
def write_to_es(self, msgtype, cast):
|
||||||
|
if settings.ES.Enabled == "1":
|
||||||
|
cast["type"] = msgtype
|
||||||
|
cast["ts"] = str(datetime.now().isoformat())
|
||||||
|
cast["xtype"] = "tx"
|
||||||
|
self.es.index(index=settings.ES.Index, document=cast)
|
||||||
|
|
||||||
def lookup_rates(self, platform, ads, rates=None):
|
def lookup_rates(self, platform, ads, rates=None):
|
||||||
"""
|
"""
|
||||||
Lookup the rates for a list of public ads.
|
Lookup the rates for a list of public ads.
|
||||||
|
|
Loading…
Reference in New Issue