add todo
flush data periodically
move sources to src