Skip to content
This repository was archived by the owner on Oct 3, 2023. It is now read-only.

Commit 94d73b2

Browse files
Bogdan Drutuchingor13
authored andcommitted
Change the agent label to be g.co/agent and have the format opencensus-php[version] (#105)
1 parent d685620 commit 94d73b2

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/Trace/Exporter/StackdriverExporter.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ class StackdriverExporter implements ExporterInterface
7373
const VERSION = '0.1.0';
7474

7575
// These are Stackdriver Trace's common attributes
76-
const AGENT = '/agent';
76+
const AGENT = 'g.co/agent';
7777
const COMPONENT = '/component';
7878
const ERROR_MESSAGE = '/error/message';
7979
const ERROR_NAME = '/error/name';
@@ -255,7 +255,7 @@ private function addCommonAttributes(&$tracer, $headers = null)
255255
}
256256
}
257257
$tracer->addAttribute(self::PID, '' . getmypid(), ['span' => $rootSpan]);
258-
$tracer->addAttribute(self::AGENT, 'opencensus-php ' . self::VERSION, ['span' => $rootSpan]);
258+
$tracer->addAttribute(self::AGENT, 'opencensus-php [' . self::VERSION . ']', ['span' => $rootSpan]);
259259
}
260260

261261
private function detectKey(array $keys, array $array)

0 commit comments

Comments
 (0)