reply average-waiting-time while stats-tube

1. add a function to calculate the average waiting time.
2. avoid overflowing while accumulate the create time stamp.
3. if the tube has more than 100 jobs, cal the top 100 jobs, else return
average of all of them.