Remove confusing capturing groups in _rollover index name pattern
This commit is contained in:
parent
6d42e197b8
commit
a6fa96d513
|
@ -61,7 +61,7 @@ import static java.util.Collections.unmodifiableList;
|
||||||
*/
|
*/
|
||||||
public class TransportRolloverAction extends TransportMasterNodeAction<RolloverRequest, RolloverResponse> {
|
public class TransportRolloverAction extends TransportMasterNodeAction<RolloverRequest, RolloverResponse> {
|
||||||
|
|
||||||
private static final Pattern INDEX_NAME_PATTERN = Pattern.compile("^.*-(\\d)+$");
|
private static final Pattern INDEX_NAME_PATTERN = Pattern.compile("^.*-\\d+$");
|
||||||
private final MetaDataCreateIndexService createIndexService;
|
private final MetaDataCreateIndexService createIndexService;
|
||||||
private final MetaDataIndexAliasesService indexAliasesService;
|
private final MetaDataIndexAliasesService indexAliasesService;
|
||||||
private final ActiveShardsObserver activeShardsObserver;
|
private final ActiveShardsObserver activeShardsObserver;
|
||||||
|
@ -186,7 +186,7 @@ public class TransportRolloverAction extends TransportMasterNodeAction<RolloverR
|
||||||
+ (isDateMath ? ">" : "");
|
+ (isDateMath ? ">" : "");
|
||||||
return newName;
|
return newName;
|
||||||
} else {
|
} else {
|
||||||
throw new IllegalArgumentException("index name [" + sourceIndexName + "] does not match pattern '^.*-(\\d)+$'");
|
throw new IllegalArgumentException("index name [" + sourceIndexName + "] does not match pattern '^.*-\\d+$'");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue