imzhenyu / rDSN.dist.service

Service frameworks targeting high availability, reliability, scalability, and consistency for micro services and storages
MIT License
1 stars 3 forks source link

add learn_stat.py for replica learning statistics #9

Closed qinzuoyan closed 8 years ago

qinzuoyan commented 8 years ago

This can help profiling learning performance.

USAGE: python learn_stat.py

For example: python learn_stat.py ./onebox/replica1/data/logs

Sample output:

{'completed': True, 'meta_size': 32578, 'gpid': '1.1', 'duration': 644, 'increased_decree': 214, 'start_decree': 57464, 'log_file': 'log.15.txt', 'end_decree': 57677, 'learner': '10.235.114.26:34801', 'learn_round': 2, 'file_count': 1, 'signature': '0000002200000003', 'learnee': '10.235.114.26:34802'}
{'completed': True, 'meta_size': 33300, 'gpid': '1.2', 'duration': 1237, 'increased_decree': 904, 'start_decree': 62431, 'log_file': 'log.19.txt', 'end_decree': 63334, 'learner': '10.235.114.26:34801', 'learn_round': 2, 'file_count': 1, 'signature': '0000001200000003', 'learnee': '10.235.114.26:34802'}