<p>My application code follows W3C Trace Context Standard for distributed tracing. But by default, Istio follows a different standard. I need to make istio to follow W3C Trace Standard. After some research I found istio supports OpenCensus trace provider which follows  W3C Trace Standard. When I add</p>
<p>How to use OpenCensusAgent in istio? to follow W3C Trace Context Standard</p>
<p>I have installed the below configuration (on top of <em>demo</em> profile) but still doesn't recognize <code>traceparent</code> header that is passed in the request.</p>
<pre class="lang-yaml prettyprint-override"><code># openCensus.yaml
apiVersion: install.istio.io/v1alpha1
kind: IstioOperator
spec:
  values:
    global: 
      proxy: 
        tracer: openCensusAgent
</code></pre>
<p>Install using below command</p>
<pre class="lang-sh prettyprint-override"><code>istioctl install -f openCensus.yaml
</code></pre>
<p>When I check in jagger, it shows it's still using zipkin</p>
<p><a href="https://i.stack.imgur.com/0XECg.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/0XECg.png" alt="enter image description here" /></a></p>
<p>Here is the whole configuration of istio</p>
<pre class="lang-yaml prettyprint-override"><code>apiVersion: install.istio.io/v1alpha1
kind: IstioOperator
metadata:
  annotations:
    install.istio.io/ignoreReconcile: &quot;true&quot;
    kubectl.kubernetes.io/last-applied-configuration: |
      {&quot;apiVersion&quot;:&quot;install.istio.io/v1alpha1&quot;,&quot;kind&quot;:&quot;IstioOperator&quot;,&quot;metadata&quot;:{&quot;annotations&quot;:{&quot;install.istio.io/ignoreReconcile&quot;:&quot;true&quot;},&quot;creationTimestamp&quot;:null,&quot;name&quot;:&quot;installed-state&quot;,&quot;namespace&quot;:&quot;istio-system&quot;},&quot;spec&quot;:{&quot;components&quot;:{&quot;base&quot;:{&quot;enabled&quot;:true},&quot;cni&quot;:{&quot;enabled&quot;:false},&quot;egressGateways&quot;:[{&quot;enabled&quot;:false,&quot;name&quot;:&quot;istio-egressgateway&quot;}],&quot;ingressGateways&quot;:[{&quot;enabled&quot;:true,&quot;name&quot;:&quot;istio-ingressgateway&quot;}],&quot;istiodRemote&quot;:{&quot;enabled&quot;:false},&quot;pilot&quot;:{&quot;enabled&quot;:true}},&quot;hub&quot;:&quot;docker.io/istio&quot;,&quot;meshConfig&quot;:{&quot;defaultConfig&quot;:{&quot;proxyMetadata&quot;:{}},&quot;enablePrometheusMerge&quot;:true},&quot;tag&quot;:&quot;1.10.1&quot;,&quot;values&quot;:{&quot;base&quot;:{&quot;enableCRDTemplates&quot;:false,&quot;validationURL&quot;:&quot;&quot;},&quot;gateways&quot;:{&quot;istio-egressgateway&quot;:{&quot;autoscaleEnabled&quot;:true,&quot;env&quot;:{},&quot;name&quot;:&quot;istio-egressgateway&quot;,&quot;secretVolumes&quot;:[{&quot;mountPath&quot;:&quot;/etc/istio/egressgateway-certs&quot;,&quot;name&quot;:&quot;egressgateway-certs&quot;,&quot;secretName&quot;:&quot;istio-egressgateway-certs&quot;},{&quot;mountPath&quot;:&quot;/etc/istio/egressgateway-ca-certs&quot;,&quot;name&quot;:&quot;egressgateway-ca-certs&quot;,&quot;secretName&quot;:&quot;istio-egressgateway-ca-certs&quot;}],&quot;type&quot;:&quot;ClusterIP&quot;,&quot;zvpn&quot;:{}},&quot;istio-ingressgateway&quot;:{&quot;autoscaleEnabled&quot;:true,&quot;env&quot;:{},&quot;name&quot;:&quot;istio-ingressgateway&quot;,&quot;secretVolumes&quot;:[{&quot;mountPath&quot;:&quot;/etc/istio/ingressgateway-certs&quot;,&quot;name&quot;:&quot;ingressgateway-certs&quot;,&quot;secretName&quot;:&quot;istio-ingressgateway-certs&quot;},{&quot;mountPath&quot;:&quot;/etc/istio/ingressgateway-ca-certs&quot;,&quot;name&quot;:&quot;ingressgateway-ca-certs&quot;,&quot;secretName&quot;:&quot;istio-ingressgateway-ca-certs&quot;}],&quot;type&quot;:&quot;LoadBalancer&quot;,&quot;zvpn&quot;:{}}},&quot;global&quot;:{&quot;configValidation&quot;:true,&quot;defaultNodeSelector&quot;:{},&quot;defaultPodDisruptionBudget&quot;:{&quot;enabled&quot;:true},&quot;defaultResources&quot;:{&quot;requests&quot;:{&quot;cpu&quot;:&quot;10m&quot;}},&quot;imagePullPolicy&quot;:&quot;&quot;,&quot;imagePullSecrets&quot;:[],&quot;istioNamespace&quot;:&quot;istio-system&quot;,&quot;istiod&quot;:{&quot;enableAnalysis&quot;:false},&quot;jwtPolicy&quot;:&quot;third-party-jwt&quot;,&quot;logAsJson&quot;:false,&quot;logging&quot;:{&quot;level&quot;:&quot;default:info&quot;},&quot;meshNetworks&quot;:{},&quot;mountMtlsCerts&quot;:false,&quot;multiCluster&quot;:{&quot;clusterName&quot;:&quot;&quot;,&quot;enabled&quot;:false},&quot;network&quot;:&quot;&quot;,&quot;omitSidecarInjectorConfigMap&quot;:false,&quot;oneNamespace&quot;:false,&quot;operatorManageWebhooks&quot;:false,&quot;pilotCertProvider&quot;:&quot;istiod&quot;,&quot;priorityClassName&quot;:&quot;&quot;,&quot;proxy&quot;:{&quot;autoInject&quot;:&quot;enabled&quot;,&quot;clusterDomain&quot;:&quot;cluster.local&quot;,&quot;componentLogLevel&quot;:&quot;misc:error&quot;,&quot;enableCoreDump&quot;:false,&quot;excludeIPRanges&quot;:&quot;&quot;,&quot;excludeInboundPorts&quot;:&quot;&quot;,&quot;excludeOutboundPorts&quot;:&quot;&quot;,&quot;image&quot;:&quot;proxyv2&quot;,&quot;includeIPRanges&quot;:&quot;*&quot;,&quot;logLevel&quot;:&quot;warning&quot;,&quot;privileged&quot;:false,&quot;readinessFailureThreshold&quot;:30,&quot;readinessInitialDelaySeconds&quot;:1,&quot;readinessPeriodSeconds&quot;:2,&quot;resources&quot;:{&quot;limits&quot;:{&quot;cpu&quot;:&quot;2000m&quot;,&quot;memory&quot;:&quot;1024Mi&quot;},&quot;requests&quot;:{&quot;cpu&quot;:&quot;100m&quot;,&quot;memory&quot;:&quot;128Mi&quot;}},&quot;statusPort&quot;:15020,&quot;tracer&quot;:&quot;openCensusAgent&quot;},&quot;proxy_init&quot;:{&quot;image&quot;:&quot;proxyv2&quot;,&quot;resources&quot;:{&quot;limits&quot;:{&quot;cpu&quot;:&quot;2000m&quot;,&quot;memory&quot;:&quot;1024Mi&quot;},&quot;requests&quot;:{&quot;cpu&quot;:&quot;10m&quot;,&quot;memory&quot;:&quot;10Mi&quot;}}},&quot;sds&quot;:{&quot;token&quot;:{&quot;aud&quot;:&quot;istio-ca&quot;}},&quot;sts&quot;:{&quot;servicePort&quot;:0},&quot;tracer&quot;:{&quot;datadog&quot;:{},&quot;lightstep&quot;:{},&quot;stackdriver&quot;:{},&quot;zipkin&quot;:{}},&quot;useMCP&quot;:false},&quot;istiodRemote&quot;:{&quot;injectionURL&quot;:&quot;&quot;},&quot;pilot&quot;:{&quot;autoscaleEnabled&quot;:true,&quot;autoscaleMax&quot;:5,&quot;autoscaleMin&quot;:1,&quot;configMap&quot;:true,&quot;cpu&quot;:{&quot;targetAverageUtilization&quot;:80},&quot;deploymentLabels&quot;:null,&quot;enableProtocolSniffingForInbound&quot;:true,&quot;enableProtocolSniffingForOutbound&quot;:true,&quot;env&quot;:{&quot;ENABLE_LEGACY_FSGROUP_INJECTION&quot;:false},&quot;image&quot;:&quot;pilot&quot;,&quot;keepaliveMaxServerConnectionAge&quot;:&quot;30m&quot;,&quot;nodeSelector&quot;:{},&quot;replicaCount&quot;:1,&quot;traceSampling&quot;:1},&quot;telemetry&quot;:{&quot;enabled&quot;:true,&quot;v2&quot;:{&quot;enabled&quot;:true,&quot;metadataExchange&quot;:{&quot;wasmEnabled&quot;:false},&quot;prometheus&quot;:{&quot;enabled&quot;:true,&quot;wasmEnabled&quot;:false},&quot;stackdriver&quot;:{&quot;configOverride&quot;:{},&quot;enabled&quot;:false,&quot;logging&quot;:false,&quot;monitoring&quot;:false,&quot;topology&quot;:false}}}}}}
  creationTimestamp: &quot;2021-06-15T14:27:44Z&quot;
  generation: 2
  name: installed-state
  namespace: istio-system
  resourceVersion: &quot;137011&quot;
  uid: 6e6efc43-515a-4fdb-9681-329678d98a7d
spec:
  components:
    base:
      enabled: true
    cni:
      enabled: false
    egressGateways:
    - enabled: false
      name: istio-egressgateway
    ingressGateways:
    - enabled: true
      name: istio-ingressgateway
    istiodRemote:
      enabled: false
    pilot:
      enabled: true
      k8s:
        env:
        - name: PILOT_TRACE_SAMPLING
          value: &quot;100&quot;
        resources:
          requests:
            cpu: 10m
            memory: 100Mi
  hub: docker.io/istio
  meshConfig:
    accessLogFile: /dev/stdout
    defaultConfig:
      proxyMetadata: {}
    enablePrometheusMerge: true
  profile: demo
  tag: 1.10.1
  values:
    base:
      enableCRDTemplates: false
      validationURL: &quot;&quot;
    gateways:
      istio-egressgateway:
        autoscaleEnabled: true
        env: {}
        name: istio-egressgateway
        secretVolumes:
        - mountPath: /etc/istio/egressgateway-certs
          name: egressgateway-certs
          secretName: istio-egressgateway-certs
        - mountPath: /etc/istio/egressgateway-ca-certs
          name: egressgateway-ca-certs
          secretName: istio-egressgateway-ca-certs
        type: ClusterIP
        zvpn: {}
      istio-ingressgateway:
        autoscaleEnabled: true
        env: {}
        name: istio-ingressgateway
        secretVolumes:
        - mountPath: /etc/istio/ingressgateway-certs
          name: ingressgateway-certs
          secretName: istio-ingressgateway-certs
        - mountPath: /etc/istio/ingressgateway-ca-certs
          name: ingressgateway-ca-certs
          secretName: istio-ingressgateway-ca-certs
        type: LoadBalancer
        zvpn: {}
    global:
      configValidation: true
      defaultNodeSelector: {}
      defaultPodDisruptionBudget:
        enabled: true
      defaultResources:
        requests:
          cpu: 10m
      imagePullPolicy: &quot;&quot;
      imagePullSecrets: []
      istioNamespace: istio-system
      istiod:
        enableAnalysis: false
      jwtPolicy: third-party-jwt
      logAsJson: false
      logging:
        level: default:info
      meshNetworks: {}
      mountMtlsCerts: false
      multiCluster:
        clusterName: &quot;&quot;
        enabled: false
      network: &quot;&quot;
      omitSidecarInjectorConfigMap: false
      oneNamespace: false
      operatorManageWebhooks: false
      pilotCertProvider: istiod
      priorityClassName: &quot;&quot;
      proxy:
        autoInject: enabled
        clusterDomain: cluster.local
        componentLogLevel: misc:error
        enableCoreDump: false
        excludeIPRanges: &quot;&quot;
        excludeInboundPorts: &quot;&quot;
        excludeOutboundPorts: &quot;&quot;
        image: proxyv2
        includeIPRanges: '*'
        logLevel: warning
        privileged: false
        readinessFailureThreshold: 30
        readinessInitialDelaySeconds: 1
        readinessPeriodSeconds: 2
        resources:
          limits:
            cpu: 2000m
            memory: 1024Mi
          requests:
            cpu: 100m
            memory: 128Mi
        statusPort: 15020
        tracer: openCensusAgent
      proxy_init:
        image: proxyv2
        resources:
          limits:
            cpu: 2000m
            memory: 1024Mi
          requests:
            cpu: 10m
            memory: 10Mi
      sds:
        token:
          aud: istio-ca
      sts:
        servicePort: 0
      tracer:
        datadog: {}
        lightstep: {}
        stackdriver: {}
        zipkin: {}
      useMCP: false
    istiodRemote:
      injectionURL: &quot;&quot;
    pilot:
      autoscaleEnabled: true
      autoscaleMax: 5
      autoscaleMin: 1
      configMap: true
      cpu:
        targetAverageUtilization: 80
      enableProtocolSniffingForInbound: true
      enableProtocolSniffingForOutbound: true
      env:
        ENABLE_LEGACY_FSGROUP_INJECTION: false
      image: pilot
      keepaliveMaxServerConnectionAge: 30m
      nodeSelector: {}
      replicaCount: 1
      traceSampling: 1
    telemetry:
      enabled: true
      v2:
        enabled: true
        metadataExchange:
          wasmEnabled: false
        prometheus:
          enabled: true
          wasmEnabled: false
        stackdriver:
          configOverride: {}
          enabled: false
          logging: false
          monitoring: false
          topology: false
</code></pre>

Vijay Nirmal
<p>Need to set some additional properties in order to work</p>
<pre class="lang-yaml prettyprint-override"><code>apiVersion: install.istio.io/v1alpha1
kind: IstioOperator
spec:
  components:
    pilot:
      enabled: true
      k8s:
        env:
        - name: PILOT_TRACE_SAMPLING
          value: &quot;100&quot;
  values:
    global:
      proxy:
        tracer: openCensusAgent 
  meshConfig:
    enableTracing: true
    defaultConfig:
      tracing:
        openCensusAgent:
          address: &quot;dns:opentelemetry-collector.istio-system.svc:55678&quot;
          context: [W3C_TRACE_CONTEXT]
</code></pre>
