# APM tracing from linkerd proxy through OpenCensus (jaeger format) errors

**URL:** https://discuss.elastic.co/t/apm-tracing-from-linkerd-proxy-through-opencensus-jaeger-format-errors/244969
**Category:** APM
**Tags:** server
**Created:** [August 14, 2020, 7:49am UTC](https://discuss.elastic.co/t/apm-tracing-from-linkerd-proxy-through-opencensus-jaeger-format-errors/244969 "2020-08-14T07:49:23Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![hoboroten](https://avatars.discourse-cdn.com/v4/letter/h/8797f3/32.png) [@hoboroten](https://discuss.elastic.co/u/hoboroten)
#### Post date: [August 14, 2020, 7:49am UTC](https://discuss.elastic.co/t/apm-tracing-from-linkerd-proxy-through-opencensus-jaeger-format-errors/244969/1 "2020-08-14T07:49:23Z")

</div>

**Kibana version** :  
7.8.1  
**Elasticsearch version** :  
7.8.1  
**APM Server version** :  
7.8.1  
**Original install method (e.g. download page, yum, deb, from source, etc.) and version**:  
Official docker images  
**Is there anything special in your setup?** For example, are you using the Logstash or Kafka outputs? Are you using a load balancer in front of the APM Servers? Have you changed index pattern, generated custom templates, changed agent configuration etc.  
Installed in k3s  
**Description of the problem including expected versus actual behavior. Please include screenshots (if relevant)**:  
I'm trying to use Elastic APM as backend for distibuted tracing. Using Jaeger agent works well. Now we are adding linkerd service mesh and i want to use APM for capturing trace information from linkerd proxies as well. The proxy use b3 trace format (openzipkin), so I use OpenCensus collector, which can convert traces to jaeger format and send to APM (instead of jaeger-collector). But when the traces start to come - i see none in Kibana. APM Indeices doesn`t change. And i'm geting these errors in APM logs:

> Cannot index event publisher.Event{Content:beat.Event{Timestamp:time.Time{wall:0x11f1fe8, ext:63732871282, loc:(\*time.Location)(nil)}, Meta:{"pipeline":"apm"}, Fields:{"agent":{"name":"Jaeger","version":"unknown"},"ecs":{"version":"1.5.0"},"host":{"hostname":"web-566f6dc5c6-flqvh","name":"web-566f6dc5c6-flqvh"},"labels":{"app":"web-svc","direction":"inbound","http\_host":"web-svc.emojivoto:80","http\_path":"/api/vote?choice=:heart\_eyes\_cat:","http\_status\_code":"200","[linkerd.io/control-plane-ns":"linkerd","linkerd.io/proxy-deployment":"web","linkerd.io/workload-ns":"emojivoto","pid":"1","pod-template-hash":"566f6dc5c6","start.time":"2020-08-12T10:27:13.087407704Z","version":"v10"},"observer":{"ephemeral\_id":"706ebe68-4a10-4e0f-8a95-f7e47464353d","hostname":"apm-app-6688b4fd77-twgfv","id":"f069ce49-de57-4ae2-9cdb-9c007a30edb4","type":"apm-server","version":"7.8.1","version\_major":7},"parent":{"id":"200e567092c4778d"},"processor":{"event":"span","name":"transaction"},"service":{"language":{"name":"unknown"},"name":"linkerd-proxy","node":{"name":"web-566f6dc5c6-flqvh"}},"span":{"duration":{"us":3712},"http":{"method":"GET","response":{"status\_code":200}},"id":"3e037d93c97262db","name":"/api/vote?choice=:heart\_eyes\_cat:","subtype":"http","type":"external"},"timestamp":{"us":1597274482018817},"trace":{"id":"3199c3b23d1e756705d04cf44648b2ea](http://linkerd.io/control-plane-ns%22:%22linkerd%22,%22linkerd.io/proxy-deployment%22:%22web%22,%22linkerd.io/workload-ns%22:%22emojivoto%22,%22pid%22:%221%22,%22pod-template-hash%22:%22566f6dc5c6%22,%22start.time%22:%222020-08-12T10:27:13.087407704Z%22,%22version%22:%22v10%22%7D,%22observer%22:%7B%22ephemeral_id%22:%22706ebe68-4a10-4e0f-8a95-f7e47464353d%22,%22hostname%22:%22apm-app-6688b4fd77-twgfv%22,%22id%22:%22f069ce49-de57-4ae2-9cdb-9c007a30edb4%22,%22type%22:%22apm-server%22,%22version%22:%227.8.1%22,%22version_major%22:7%7D,%22parent%22:%7B%22id%22:%22200e567092c4778d%22%7D,%22processor%22:%7B%22event%22:%22span%22,%22name%22:%22transaction%22%7D,%22service%22:%7B%22language%22:%7B%22name%22:%22unknown%22%7D,%22name%22:%22linkerd-proxy%22,%22node%22:%7B%22name%22:%22web-566f6dc5c6-flqvh%22%7D%7D,%22span%22:%7B%22duration%22:%7B%22us%22:3712%7D,%22http%22:%7B%22method%22:%22GET%22,%22response%22:%7B%22status_code%22:200%7D%7D,%22id%22:%223e037d93c97262db%22,%22name%22:%22/api/vote?choice=:heart_eyes_cat:%22,%22subtype%22:%22http%22,%22type%22:%22external%22%7D,%22timestamp%22:%7B%22us%22:1597274482018817%7D,%22trace%22:%7B%22id%22:%223199c3b23d1e756705d04cf44648b2ea)"}}, Private:interface {}(nil), TimeSeries:false}, Flags:0x1, Cache:publisher.EventCache{m:common.MapStr(nil)}} (status=400): {"type":"mapper\_parsing\_exception","reason":"failed to parse","caused\_by":{"type":"class\_cast\_exception","reason":"class org.elasticsearch.index.mapper.ScaledFloatFieldMapper cannot be cast to class org.elasticsearch.index.mapper.ObjectMapper (org.elasticsearch.index.mapper.ScaledFloatFieldMapper is in unnamed module of loader java.net.FactoryURLClassLoader @dbed7fd; org.elasticsearch.index.mapper.ObjectMapper is in unnamed module of loader 'app')"}}

When i switch to jaeger-collector instead of APM - it gets all the tracing correctly.

Here is my APM config:

> apm-server.yml: |
> 
> ```
> apm-server:
> kibana:
> enabled: true
> host: "http://kibana-svc:5601"
> username: elastic
> password: sOmEpSwD
> jaeger:
> http:
> enabled: true
> host: "0.0.0.0:14268"
> host: 0.0.0.0:8200
> ilm:
> enabled: false
> setup:
> enabled: true
> overwrite: true
> output.elasticsearch:
> hosts: "http://elasticsearch-svc:9200"
> username: "${ES_USR}" 
> password: "${ES_PWD}"
> setup:
> kibana:
> host: '${KIBANA_HOST}'
> logging:
> level: info #warning
> max_proc: 1
> queue.mem:
> events: 8000
> flush.min_events: 500
> 
> ```

**Steps to reproduce** :

1. Install Elasticsearch, Kibana and APM
2. Use OpenCensus collector to send tracing to APM as Jaeger backend

---

<div class="post-metadata">

### Author: ![axw](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/axw/32/28197_2.png) [@axw](https://discuss.elastic.co/u/axw)
#### Post date: [August 14, 2020, 8:25am UTC](https://discuss.elastic.co/t/apm-tracing-from-linkerd-proxy-through-opencensus-jaeger-format-errors/244969/2 "2020-08-14T08:25:19Z")

</div>

Hi @hoboroten, and welcome to the forum!

The problem appears to be a field mapping collision with `labels.app`. I see in the event you have `labels.app:"web-svc"`. I suppose something else has previously populated the "app" label with a number.

Can you check the field mapping for "labels.app" in the Console in Kibana, executing the following query?

```
GET /apm-*/_mapping/field/labels.app

```

What does it output? If it says that the field is `scaled_float` as I expect, then you can work around this issue by setting [`ignored_malformed`](https://www.elastic.co/guide/en/elasticsearch/reference/current/ignore-malformed.html) for that field. Ideally there wouldn't be different types being assigned to the field in the first place, though.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [September 4, 2020, 4:25am UTC](https://discuss.elastic.co/t/apm-tracing-from-linkerd-proxy-through-opencensus-jaeger-format-errors/244969/3 "2020-09-04T04:25:20Z")

</div>

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.
