app = faust.App(
'streamapp-dev-10',
broker='kafka://*.*.*.*:9092',
store = 'rocksdb://'
)
new_events_counts_year = app.Table('new_events_counts_year', default=int,partitions=1).hopping(timedelta(days=365),timedelta(days=30),expires=timedelta(days=2),key_index=True)
print("{},{},{}".format(value.now(),value.value(),value.current()))
[2020-04-24 15:33:31,042] [82296] [WARNING] {'aggregation_type': 'day', 'count': 0, 'user': 'Sync_GURWPAYUADCON01_d085a0aef643', 'service': 'Core Directory', 'account_id': '******', 'operation_type': 'Update user', 'operation_resource': 'User-sakshi.jhalani@payu.in'}
[2020-04-24 15:33:31,042] [82296] [WARNING] 0,0,0
[2020-04-24 15:33:31,098] [82296] [WARNING] {'aggregation_type': 'hour', 'count': 0, 'user': 'Sync_GURWPAYUADCON01_d085a0aef643', 'service': 'Core Directory', 'account_id': '*******', 'operation_type': 'Update user', 'operation_resource': 'User-sakshi.jhalani@payu.in'}
[2020-04-24 15:33:31,099] [82296] [WARNING] 0,