summaryrefslogtreecommitdiff
path: root/vendor/jonahgeorge/jaeger-client-php/src/Jaeger/AgentClient/HttpAgentClient.php
blob: e270b76ac354a6e8aa905f1f2b478d1e9ae12c4e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php

namespace Jaeger\AgentClient;

class HttpAgentClient implements \Jaeger\Thrift\Agent\AgentIf
{
    protected $input_ = null;
    protected $output_ = null;

    protected $seqid_ = 0;

    public function __construct($input, $output = null)
    {
        $this->input_ = $input;
        $this->output_ = $output ? $output : $input;
    }

    public function emitZipkinBatch(array $spans)
    {
    }

    public function emitBatch(\Jaeger\Thrift\Batch $batch)
    {
        $batch->write($this->output_);
        $this->output_->getTransport()->flush();
    }
}