Log template creation and deletion (#29027)
These can be seen at the debug level via cluster state update logging but really they should be more visible like index creation and deletion. This commit adds info-level logging for template puts and deletes.
This commit is contained in:
parent
697b9f8b82
commit
c8e71327ab
|
@ -117,6 +117,7 @@ public class MetaDataIndexTemplateService extends AbstractComponent {
|
|||
}
|
||||
MetaData.Builder metaData = MetaData.builder(currentState.metaData());
|
||||
for (String templateName : templateNames) {
|
||||
logger.info("removing template [{}]", templateName);
|
||||
metaData.removeTemplate(templateName);
|
||||
}
|
||||
return ClusterState.builder(currentState).metaData(metaData).build();
|
||||
|
@ -185,6 +186,7 @@ public class MetaDataIndexTemplateService extends AbstractComponent {
|
|||
|
||||
MetaData.Builder builder = MetaData.builder(currentState.metaData()).put(template);
|
||||
|
||||
logger.info("adding template [{}] for index patterns {}", request.name, request.indexPatterns);
|
||||
return ClusterState.builder(currentState).metaData(builder).build();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue