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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
|
<?php
namespace Jaeger\Thrift\Agent;
/**
* Autogenerated by Thrift Compiler (0.11.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
use Thrift\Base\TBase;
use Thrift\Type\TType;
use Thrift\Type\TMessageType;
use Thrift\Exception\TException;
use Thrift\Exception\TProtocolException;
use Thrift\Protocol\TProtocol;
use Thrift\Protocol\TBinaryProtocolAccelerated;
use Thrift\Exception\TApplicationException;
class AgentClient 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)
{
$this->send_emitZipkinBatch($spans);
}
public function send_emitZipkinBatch(array $spans)
{
$args = new \Jaeger\Thrift\Agent\Agent_emitZipkinBatch_args();
$args->spans = $spans;
$bin_accel = ($this->output_ instanceof TBinaryProtocolAccelerated) && function_exists('thrift_protocol_write_binary');
if ($bin_accel)
{
thrift_protocol_write_binary($this->output_, 'emitZipkinBatch', TMessageType::ONEWAY, $args, $this->seqid_, $this->output_->isStrictWrite());
}
else
{
$this->output_->writeMessageBegin('emitZipkinBatch', TMessageType::ONEWAY, $this->seqid_);
$args->write($this->output_);
$this->output_->writeMessageEnd();
$this->output_->getTransport()->flush();
}
}
public function emitBatch(\Jaeger\Thrift\Batch $batch)
{
$this->send_emitBatch($batch);
}
public function send_emitBatch(\Jaeger\Thrift\Batch $batch)
{
$args = new \Jaeger\Thrift\Agent\Agent_emitBatch_args();
$args->batch = $batch;
$bin_accel = ($this->output_ instanceof TBinaryProtocolAccelerated) && function_exists('thrift_protocol_write_binary');
if ($bin_accel)
{
thrift_protocol_write_binary($this->output_, 'emitBatch', TMessageType::ONEWAY, $args, $this->seqid_, $this->output_->isStrictWrite());
}
else
{
$this->output_->writeMessageBegin('emitBatch', TMessageType::ONEWAY, $this->seqid_);
$args->write($this->output_);
$this->output_->writeMessageEnd();
$this->output_->getTransport()->flush();
}
}
}
|