added dump events to stdout as an option