PLFENG-1321: do not use shell script, use java source code to replace special character