add stack trace processor and refactor introspection processor to reduce code duplication