[ https://issues.apache.org/jira/browse/CALCITE-3823?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
ASF GitHub Bot updated CALCITE-3823: ------------------------------------ Labels: pull-request-available (was: ) > Do not use String.replaceAll > ---------------------------- > > Key: CALCITE-3823 > URL: https://issues.apache.org/jira/browse/CALCITE-3823 > Project: Calcite > Issue Type: Bug > Reporter: Julian Hyde > Assignee: Julian Hyde > Priority: Major > Labels: pull-request-available > > We use JDK's {{String.replaceAll(String regex, String replacement)}} about 60 > times in the code, but most of these should probably use > {{String.replace(CharSequence target, CharSequence replacement)}}. > {{replaceAll}} uses regex semantics, which is slow (it compiles a pattern > each call) and probably not desired behavior. > Consider adding to {{forbidden-apis/signatures.txt}} to prevent it from being > accidentally used in future. > See tweet "[String.replaceAll is the most invisible java perf issue I end up > finding out of > profiles|https://twitter.com/t3rmin4t0r/status/1232353433371336704]". -- This message was sent by Atlassian Jira (v8.3.4#803005)