Refactoring TraceProvider