You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by "bd2019us (JIRA)" <ji...@apache.org> on 2019/04/21 02:06:00 UTC
[jira] [Updated] (HADOOP-16267) Performance gain if you use
replace() instead of replaceAll() for replacing patterns that do not use a
regex
[ https://issues.apache.org/jira/browse/HADOOP-16267?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
bd2019us updated HADOOP-16267:
------------------------------
Description:
Performance gain if you use replace() instead of replaceAll() for replacing patterns that do not use a regex. This happens because replace() does not need to compile the regex pattern like replaceAll() does.
Affected files:
* hadoop-tools/hadoop-distcp/src/main/java/org/apache/hadoop/tools/mapred/CopyCommitter.java
* hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/state/Graph.java
* hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/util/PrintJarMainClass.java
was:
Performance gain if you use replace() instead of replaceAll() for replacing patterns that do not use a regex. This happens because replace() does not need to compile the regex pattern like replaceAll() does.
Affected files:
* hadoop-common/hadoop-tools/hadoop-distcp/src/main/java/org/apache/hadoop/tools/mapred/CopyCommitter.java
* hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/state/Graph.java
* hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/state/Graph.java
> Performance gain if you use replace() instead of replaceAll() for replacing patterns that do not use a regex
> -------------------------------------------------------------------------------------------------------------
>
> Key: HADOOP-16267
> URL: https://issues.apache.org/jira/browse/HADOOP-16267
> Project: Hadoop Common
> Issue Type: Improvement
> Reporter: bd2019us
> Priority: Minor
> Labels: pull-request-available
>
> Performance gain if you use replace() instead of replaceAll() for replacing patterns that do not use a regex. This happens because replace() does not need to compile the regex pattern like replaceAll() does.
> Affected files:
> * hadoop-tools/hadoop-distcp/src/main/java/org/apache/hadoop/tools/mapred/CopyCommitter.java
> * hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/state/Graph.java
> * hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/util/PrintJarMainClass.java
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org