Invalid composable template

Hi

We are using Elasticsearch - 8.18.1

kibana - 8.18.6

APM-server - 8.18.1 in linux server - 22.04

We have upgraded Elasticsearch,kibana and APM-server from 7.17.27 to 8.18.1 after some time we are getting below error

[ERROR][o.e.x.c.t.IndexTemplateRegistry] [TEST02] error adding index template [logs-apm.error@mappings] for [apm]
java.lang.IllegalArgumentException: updating component template [logs-apm.error@mappings] results in invalid composable template [logs-apm.error] after templates are merged
at org.elasticsearch.cluster.metadata.MetadataIndexTemplateService.addComponentTemplate(MetadataIndexTemplateService.java:350) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.metadata.MetadataIndexTemplateService$3.execute(MetadataIndexTemplateService.java:250) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.metadata.MetadataIndexTemplateService$1.executeTask(MetadataIndexTemplateService.java:150) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.metadata.MetadataIndexTemplateService$1.executeTask(MetadataIndexTemplateService.java:147) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.SimpleBatchedExecutor.execute(SimpleBatchedExecutor.java:71) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.service.MasterService.innerExecuteTasks(MasterService.java:1075) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.service.MasterService.executeTasks(MasterService.java:1038) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.service.MasterService.executeAndPublishBatch(MasterService.java:245) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.service.MasterService$BatchingTaskQueue$Processor.lambda$run$2(MasterService.java:1691) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.action.ActionListener.run(ActionListener.java:454) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.service.MasterService$BatchingTaskQueue$Processor.run(MasterService.java:1688) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.service.MasterService$5.lambda$doRun$0(MasterService.java:1283) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.action.ActionListener.run(ActionListener.java:454) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.cluster.service.MasterService$5.doRun(MasterService.java:1262) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingAbstractRunnable.doRun(ThreadContext.java:1044) ~[elasticsearch-8.18.1.jar:?]
at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:27) ~[elasticsearch-8.18.1.jar:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
at java.lang.Thread.run(Thread.java:840) ~[?:?]
Caused by: java.lang.IllegalArgumentException: composable template [logs-apm.error] template after composition with component templates [logs-apm.error@mappings, logs-apm.error@settings, logs-apm.error@custom, .fleet_component_template-1] is invalid

Can any help here what we can do over here?

Hi @Ekta ,

Are you using any extra component templates? It may be that the templates aren’t valid.

When I get detail with below API GET _index_template/traces-apm I got below detail
"template": {

      "settings": {

        "index": {

          "default_pipeline": "traces-apm-7.17.0"

        }

      },

but my apm-server version is 8.18.1 so what to do?

Hi

Is there any things is used to ingest pipeline manually for 8.18.1?

Have you tried to simulate the teamplate

Also Elastic and Kibana should be at the same version Kibana ahead of Elastic is not really a good thing.

It looks to me perhaps the upgrade of APM (and are you using the server binary of the APM Integration), perhaps did not complete.

@stephenb we have upgrade apm-server from 7.17.20 to 8.18.1 using dpkg -i pkgname.deb, nothing extra we did over here

Is there any extra we need to do over here?

Is there any how to reload templates in apm-server-8.18.1?