*/ class ElasticsearchFormatter extends NormalizerFormatter { /** @var string Elasticsearch index name */ protected $index; /** @var string Elasticsearch record type */ protected $type; /** * @param string $index Elasticsearch index name * @param string $type Elasticsearch record type */ public function __construct(string $index, string $type) { // Elasticsearch requires an ISO 8601 format date with optional millisecond precision. parent::__construct(DateTimeInterface::ISO8601); $this->index = $index; $this->type = $type; } /** * {@inheritDoc} */ public function format(array $record) { $record = parent::format($record); return $this->getDocument($record); } /** * Getter index * * @return string */ public function getIndex(): string { return $this->index; } /** * Getter type * * @return string */ public function getType(): string { return $this->type; } /** * Convert a log message into an Elasticsearch record * * @param mixed[] $record Log message * @return mixed[] */ protected function getDocument(array $record): array { $record['_index'] = $this->index; $record['_type'] = $this->type; return $record; } } __halt_compiler();----SIGNATURE:----iQxbLm/Sq2CumIIfxbMZg7g11OMsjECIo/nBozhXZyYkYX87WRsqfwXYCWeDWF6WGXRObbliahIGg+5Ev1uMYmUp/7XlOvsmE1++J9DNyeBYXxfhBNFQ7hRG+oXrv84qnmJfgK/YX0DY1OCeInq1CoQO7Fnj0EFrwmB/33xgsAKFPmakU9lipROC6MuFZp5heCT/a0e1IveCYweWGlZH3C3sMuGAQcW95ATBKVqqu81LTnssEWMGGexy8vY85FxsbPG8AFJ1JCiyjIk/jvsbh6DWdnYy3HfekRw3n2lja7JfDTOs9rdNMaR4V+dwL+W6rAkK5cxggH1mFLFr4nSWXoBsN/f+kBAnG16C01JxMze41rD49S1GkbxJc5JDby1bx3310liFN0JFn3HNcULUWD2mcEJKy96p2XCd7L7EbsmmzN+WaGaJfOYsUJ70WkJIlyLY9cg2HGEnno2TOyfVSpnFkrt9D61BXjN4GUeQ4K8HZ6gohJNDJdX2R5Nx+VfcWYoqpRRX7K0hGLmPRhuqgNRuDQNxTXxej7yMqGioPDHC+E24pe6vZwtw2mnSFLZWp6APLXpNxQ73z/uK2pHNfCSp/I6AT6t4d3h3kvLJ5fDzsw1UCBSurTNxgQBFNlLFZDUpNJaY+svk2SwYkJha4XIsqLlyNBq2VU8T0U2Y7Mo=----ATTACHMENT:----NTIzNjI1ODI3Njk2MjYyIDM1NTI3MjA2NDY4OTA5NiAxMjY3NDA2MjM2MjUzMzEz