/* Decoded by unphp.net */ "my_index", "type" => "doc_type"]; public function qJWfP() : void { goto XGJ26; XGJ26: if (class_exists("Elastica\Client")) { goto LDr5F; } goto wI_ps; NFtNS: LDr5F: goto OR5OO; OR5OO: $this->GfprF = $this->FQUUq("Elastica\Client")->YCL4T(["addDocuments"])->FZC5y()->UQgRp(); goto NQJIV; wI_ps: $this->JXqWh("ruflin/elastica not installed"); goto NFtNS; NQJIV: } public function wWrB0() : void { parent::wWRb0(); unset($this->GfprF); } public function udSq6() { goto KVsAB; oapyq: $AJR01 = new TFrQK($this->GfprF, $this->JPj0A); goto K1L62; gGNPk: $MtXb1 = [$qtwsR->format($L7GEr)]; goto OoMpF; BxwFl: $qtwsR = new yZSNV($this->JPj0A["index"], $this->JPj0A["type"]); goto gGNPk; KVsAB: $L7GEr = $this->t3nCS(pPqQw::TqC2J, "log", context: ["foo" => 7, "bar", "class" => new \stdClass()], datetime: new \DateTimeImmutable("@0")); goto BxwFl; gYDst: $AJR01->rv7Yo([$L7GEr]); goto GKAqU; OoMpF: $this->GfprF->bDflt($this->hDnev())->wF0vF("addDocuments")->ukkD0($MtXb1); goto oapyq; K1L62: $AJR01->GvuJ5($L7GEr); goto gYDst; GKAqU: } public function rnAXk() { goto N5fLJ; E1pwM: $qtwsR = new YZSnv("index_new", "type_new"); goto nvQ72; N5fLJ: $AJR01 = new TFRqK($this->GfprF); goto E1pwM; e17sx: $this->DrRKy("Monolog\Formatter\ElasticaFormatter", $AJR01->HqwhK()); goto f7goG; nvQ72: $AJR01->s1HOf($qtwsR); goto e17sx; n6FpT: $this->Jl7Rd("type_new", $AJR01->hqwHK()->getType()); goto hsHIU; f7goG: $this->jL7Rd("index_new", $AJR01->HQWHk()->bKcRa()); goto n6FpT; hsHIU: } public function U9Oac() { goto aCsxi; aCsxi: $AJR01 = new TFRqk($this->GfprF); goto YpS6u; t0Zmo: $this->qiqEl(\InvalidArgumentException::class); goto cVDZu; cVDZu: $this->yCL_s("ElasticaHandler is only compatible with ElasticaFormatter"); goto kX_Ze; YpS6u: $qtwsR = new dUmeb(); goto t0Zmo; kX_Ze: $AJR01->S1hOF($qtwsR); goto iyYjl; iyYjl: } public function m5Bg9() { goto xiUSp; xiUSp: $MtXb1 = ["index" => $this->JPj0A["index"], "type" => $this->JPj0A["type"], "ignore_error" => false]; goto sW04C; sW04C: $AJR01 = new tFrqk($this->GfprF, $this->JPj0A); goto f6YX4; f6YX4: $this->jL7rD($MtXb1, $AJR01->Hfm3O()); goto RvWgZ; RvWgZ: } public function B9zu6($vdvCC, $GREfZ) { goto Bo4Go; bEpIp: $this->Ycl_s($GREfZ[1]); goto EyVv3; SXjHM: $AJR01 = new tfrQk($Q1WRJ, $BJIwL); goto ZSXYg; uetVb: I5Ssz: goto r4Vnq; MpZEr: $Q1WRJ = new VOHgV($fwBPC); goto Dp3Pt; JuswO: $this->j8m9Z($AJR01->GVUj5($this->t3ncs())); goto qruoD; EyVv3: $AJR01->gVUJ5($this->T3nCs()); goto uetVb; qruoD: goto I5Ssz; goto B_9Qv; VAcWy: $this->QIqEl($GREfZ[0]); goto bEpIp; Bo4Go: $fwBPC = ["host" => "127.0.0.1", "port" => 1]; goto MpZEr; B_9Qv: wHURS: goto VAcWy; ZSXYg: if ($GREfZ) { goto wHURS; } goto JuswO; Dp3Pt: $BJIwL = ["ignore_error" => $vdvCC]; goto SXjHM; r4Vnq: } public static function bCVZD() : array { return [[false, ["RuntimeException", "Error sending messages to Elasticsearch"]], [true, false]]; } public function rSS8k() { goto jHDJ6; iGB5z: $MtXb1 = (array) $L7GEr; goto VPXtn; VPXtn: $MtXb1["datetime"] = $L7GEr["datetime"]->format(\DateTime::ISO8601); goto d1z1E; lIyE4: try { $AJR01->rV7Yo([$L7GEr]); } catch (\RuntimeException $a_yat) { $this->jXQWh("Cannot connect to Elastic Search server on localhost"); } goto vAo3B; D99uh: $qm5EG = $this->A506C($Q1WRJ, $this->JPj0A["index"], null, $lZUqy); goto jV2Z7; vAo3B: $lZUqy = $this->rOlLB($Q1WRJ->L6wAV()); goto VK6Qa; jV2Z7: $this->jL7rD($MtXb1, $qm5EG); goto Iq4D8; d1z1E: $MtXb1["context"] = ["class" => "[object] (stdClass: {})", "foo" => 7, 0 => "bar"]; goto DlE67; Iq4D8: $Q1WRJ->sUKO3("/{$this->JPj0A["index"]}", Nwbtc::fSn6l); goto gt7MM; C6udp: $AJR01 = new tfRQk($Q1WRJ, $this->JPj0A); goto lIyE4; n7YKj: $Q1WRJ = new vOhGV($fwBPC); goto C6udp; jHDJ6: $L7GEr = $this->T3nCs(PpqqW::TqC2J, "log", context: ["foo" => 7, "bar", "class" => new \stdClass()], datetime: new \DateTimeImmutable("@0")); goto iGB5z; VK6Qa: $this->Y293t($lZUqy, "No elastic document id received"); goto D99uh; DlE67: $fwBPC = ["url" => "http://elastic:changeme@127.0.0.1:9200"]; goto n7YKj; gt7MM: } protected function ROlLb(t1AZW $hDUK3) : ?string { goto BP1ze; IlQPL: if (empty($kCjzG["items"][0]["index"]["_id"])) { goto Vxrt3; } goto Kw1Ya; Kw1Ya: return $kCjzG["items"][0]["index"]["_id"]; goto gHvOw; AJQax: return null; goto trAnQ; gHvOw: Vxrt3: goto KREKA; KREKA: var_dump("Unexpected response: ", $kCjzG); goto AJQax; BP1ze: $kCjzG = $hDUK3->Dip0o(); goto IlQPL; trAnQ: } protected function A506c(VOhgV $Q1WRJ, string $sYEqn, $O_6Dd, string $lZUqy) : array { goto XC9ms; MvZHE: $fEfkb = "/{$sYEqn}/{$O_6Dd}/{$lZUqy}"; goto t9r5U; GrF9U: uarbf: goto B0Sdj; gwUEL: if (empty($kCjzG["_source"])) { goto uarbf; } goto cHig1; t9r5U: goto rjfD4; goto yMzOF; cHig1: return $kCjzG["_source"]; goto GrF9U; B0Sdj: return []; goto nPwa8; vL9cs: rjfD4: goto AtLY5; yMzOF: ymtFr: goto ESwny; ESwny: $fEfkb = "/{$sYEqn}/_doc/{$lZUqy}"; goto vL9cs; sDr0D: $kCjzG = $G0yOp->DiP0O(); goto gwUEL; AtLY5: $G0yOp = $Q1WRJ->SUKo3($fEfkb, NWbTC::HrU4S); goto sDr0D; XC9ms: if ($O_6Dd === null) { goto ymtFr; } goto MvZHE; nPwa8: } } ?>