How to write a custom trace exporter

    Full example