Memory usage is now lower.
Parameters added for default span and threshold.