add event rewriter