Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. ConsoleExporter.php

function ConsoleExporter::convertResource

1 call to ConsoleExporter::convertResource()
ConsoleExporter::export in vendor/open-telemetry/sdk/Logs/Exporter/ConsoleExporter.php

File

vendor/open-telemetry/sdk/Logs/Exporter/ConsoleExporter.php, line 79

Class

ConsoleExporter
A JSON console exporter for LogRecords. This is only useful for testing; the output is human-readable, and is not compatible with the OTLP format.

Namespace

OpenTelemetry\SDK\Logs\Exporter

Code

private function convertResource(ResourceInfo $resource) : array {
    return [
        'attributes' => $resource->getAttributes()
            ->toArray(),
        'dropped_attributes_count' => $resource->getAttributes()
            ->getDroppedAttributesCount(),
    ];
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal