add System.out and System.err to output the log.