@vercel/otel 1.8.0-8f4c4475-20240327181540 → 1.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/edge/index.js +6 -6
- package/dist/node/index.js +6 -6
- package/dist/types/types.d.ts +12 -1
- package/package.json +1 -1
package/dist/edge/index.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
if (globalThis.performance === undefined) {
|
|
2
2
|
globalThis.performance = { timeOrigin: 0, now: () => Date.now() };
|
|
3
3
|
}
|
|
4
|
-
var Gl=Object.create;var Jr=Object.defineProperty;var Hl=Object.getOwnPropertyDescriptor;var jl=Object.getOwnPropertyNames;var Fl=Object.getPrototypeOf,ql=Object.prototype.hasOwnProperty;var zr=(a,n)=>()=>(a&&(n=a(a=0)),n);var m=(a,n)=>()=>(n||a((n={exports:{}}).exports,n),n.exports);var Ce=(a,n,o,c)=>{if(n&&typeof n=="object"||typeof n=="function")for(let l of jl(n))!ql.call(a,l)&&l!==o&&Jr(a,l,{get:()=>n[l],enumerable:!(c=Hl(n,l))||c.enumerable});return a},tt=(a,n,o)=>(Ce(a,n,"default"),o&&Ce(o,n,"default")),N=(a,n,o)=>(o=a!=null?Gl(Fl(a)):{},Ce(n||!a||!a.__esModule?Jr(o,"default",{value:a,enumerable:!0}):o,a)),D=a=>Ce(Jr({},"__esModule",{value:!0}),a);var y={};import*as $f from"@opentelemetry/api";var b=zr(()=>{tt(y,$f)});var pe=m(Et=>{"use strict";Object.defineProperty(Et,"__esModule",{value:!0});Et.isTracingSuppressed=Et.unsuppressTracing=Et.suppressTracing=void 0;var Kl=(b(),D(y)),Wr=(0,Kl.createContextKey)("OpenTelemetry SDK Context Key SUPPRESS_TRACING");function Xl(a){return a.setValue(Wr,!0)}Et.suppressTracing=Xl;function Yl(a){return a.deleteValue(Wr)}Et.unsuppressTracing=Yl;function Jl(a){return a.getValue(Wr)===!0}Et.isTracingSuppressed=Jl});var $r=m(q=>{"use strict";Object.defineProperty(q,"__esModule",{value:!0});q.BAGGAGE_MAX_TOTAL_LENGTH=q.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS=q.BAGGAGE_MAX_NAME_VALUE_PAIRS=q.BAGGAGE_HEADER=q.BAGGAGE_ITEMS_SEPARATOR=q.BAGGAGE_PROPERTIES_SEPARATOR=q.BAGGAGE_KEY_PAIR_SEPARATOR=void 0;q.BAGGAGE_KEY_PAIR_SEPARATOR="=";q.BAGGAGE_PROPERTIES_SEPARATOR=";";q.BAGGAGE_ITEMS_SEPARATOR=",";q.BAGGAGE_HEADER="baggage";q.BAGGAGE_MAX_NAME_VALUE_PAIRS=180;q.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS=4096;q.BAGGAGE_MAX_TOTAL_LENGTH=8192});var Qr=m(lt=>{"use strict";Object.defineProperty(lt,"__esModule",{value:!0});lt.parseKeyPairsIntoRecord=lt.parsePairKeyValue=lt.getKeyPairs=lt.serializeKeyPairs=void 0;var zl=(b(),D(y)),Ut=$r();function Wl(a){return a.reduce((n,o)=>{let c=`${n}${n!==""?Ut.BAGGAGE_ITEMS_SEPARATOR:""}${o}`;return c.length>Ut.BAGGAGE_MAX_TOTAL_LENGTH?n:c},"")}lt.serializeKeyPairs=Wl;function $l(a){return a.getAllEntries().map(([n,o])=>{let c=`${encodeURIComponent(n)}=${encodeURIComponent(o.value)}`;return o.metadata!==void 0&&(c+=Ut.BAGGAGE_PROPERTIES_SEPARATOR+o.metadata.toString()),c})}lt.getKeyPairs=$l;function Ro(a){let n=a.split(Ut.BAGGAGE_PROPERTIES_SEPARATOR);if(n.length<=0)return;let o=n.shift();if(!o)return;let c=o.indexOf(Ut.BAGGAGE_KEY_PAIR_SEPARATOR);if(c<=0)return;let l=decodeURIComponent(o.substring(0,c).trim()),i=decodeURIComponent(o.substring(c+1).trim()),e;return n.length>0&&(e=(0,zl.baggageEntryMetadataFromString)(n.join(Ut.BAGGAGE_PROPERTIES_SEPARATOR))),{key:l,value:i,metadata:e}}lt.parsePairKeyValue=Ro;function Ql(a){return typeof a!="string"||a.length===0?{}:a.split(Ut.BAGGAGE_ITEMS_SEPARATOR).map(n=>Ro(n)).filter(n=>n!==void 0&&n.value.length>0).reduce((n,o)=>(n[o.key]=o.value,n),{})}lt.parseKeyPairsIntoRecord=Ql});var Lo=m(Ue=>{"use strict";Object.defineProperty(Ue,"__esModule",{value:!0});Ue.W3CBaggagePropagator=void 0;var Zr=(b(),D(y)),Zl=pe(),Mt=$r(),tn=Qr(),en=class{inject(n,o,c){let l=Zr.propagation.getBaggage(n);if(!l||(0,Zl.isTracingSuppressed)(n))return;let i=(0,tn.getKeyPairs)(l).filter(t=>t.length<=Mt.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS).slice(0,Mt.BAGGAGE_MAX_NAME_VALUE_PAIRS),e=(0,tn.serializeKeyPairs)(i);e.length>0&&c.set(o,Mt.BAGGAGE_HEADER,e)}extract(n,o,c){let l=c.get(o,Mt.BAGGAGE_HEADER),i=Array.isArray(l)?l.join(Mt.BAGGAGE_ITEMS_SEPARATOR):l;if(!i)return n;let e={};return i.length===0||(i.split(Mt.BAGGAGE_ITEMS_SEPARATOR).forEach(r=>{let u=(0,tn.parsePairKeyValue)(r);if(u){let s={value:u.value};u.metadata&&(s.metadata=u.metadata),e[u.key]=s}}),Object.entries(e).length===0)?n:Zr.propagation.setBaggage(n,Zr.propagation.createBaggage(e))}fields(){return[Mt.BAGGAGE_HEADER]}};Ue.W3CBaggagePropagator=en});var Io=m(Me=>{"use strict";Object.defineProperty(Me,"__esModule",{value:!0});Me.AnchoredClock=void 0;var rn=class{constructor(n,o){this._monotonicClock=o,this._epochMillis=n.now(),this._performanceMillis=o.now()}now(){let n=this._monotonicClock.now()-this._performanceMillis;return this._epochMillis+n}};Me.AnchoredClock=rn});var Do=m(bt=>{"use strict";Object.defineProperty(bt,"__esModule",{value:!0});bt.isAttributeValue=bt.isAttributeKey=bt.sanitizeAttributes=void 0;var wo=(b(),D(y));function tc(a){let n={};if(typeof a!="object"||a==null)return n;for(let[o,c]of Object.entries(a)){if(!Co(o)){wo.diag.warn(`Invalid attribute key: ${o}`);continue}if(!Uo(c)){wo.diag.warn(`Invalid attribute value set for key: ${o}`);continue}Array.isArray(c)?n[o]=c.slice():n[o]=c}return n}bt.sanitizeAttributes=tc;function Co(a){return typeof a=="string"&&a.length>0}bt.isAttributeKey=Co;function Uo(a){return a==null?!0:Array.isArray(a)?ec(a):Mo(a)}bt.isAttributeValue=Uo;function ec(a){let n;for(let o of a)if(o!=null){if(!n){if(Mo(o)){n=typeof o;continue}return!1}if(typeof o!==n)return!1}return!0}function Mo(a){switch(typeof a){case"number":case"boolean":case"string":return!0}return!1}});var nn=m(De=>{"use strict";Object.defineProperty(De,"__esModule",{value:!0});De.loggingErrorHandler=void 0;var rc=(b(),D(y));function nc(){return a=>{rc.diag.error(oc(a))}}De.loggingErrorHandler=nc;function oc(a){return typeof a=="string"?a:JSON.stringify(ic(a))}function ic(a){let n={},o=a;for(;o!==null;)Object.getOwnPropertyNames(o).forEach(c=>{if(n[c])return;let l=o[c];l&&(n[c]=String(l))}),o=Object.getPrototypeOf(o);return n}});var on=m(qt=>{"use strict";Object.defineProperty(qt,"__esModule",{value:!0});qt.globalErrorHandler=qt.setGlobalErrorHandler=void 0;var ac=nn(),ko=(0,ac.loggingErrorHandler)();function uc(a){ko=a}qt.setGlobalErrorHandler=uc;function lc(a){try{ko(a)}catch{}}qt.globalErrorHandler=lc});var an=m(fe=>{"use strict";Object.defineProperty(fe,"__esModule",{value:!0});fe.TracesSamplerValues=void 0;var cc;(function(a){a.AlwaysOff="always_off",a.AlwaysOn="always_on",a.ParentBasedAlwaysOff="parentbased_always_off",a.ParentBasedAlwaysOn="parentbased_always_on",a.ParentBasedTraceIdRatio="parentbased_traceidratio",a.TraceIdRatio="traceidratio"})(cc=fe.TracesSamplerValues||(fe.TracesSamplerValues={}))});var Be=m(ke=>{"use strict";Object.defineProperty(ke,"__esModule",{value:!0});ke._globalThis=void 0;ke._globalThis=typeof globalThis=="object"?globalThis:typeof self=="object"?self:typeof window=="object"?window:typeof global=="object"?global:{}});var Ve=m(U=>{"use strict";Object.defineProperty(U,"__esModule",{value:!0});U.getEnvWithoutDefaults=U.parseEnvironment=U.DEFAULT_ENVIRONMENT=U.DEFAULT_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT=U.DEFAULT_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT=U.DEFAULT_ATTRIBUTE_COUNT_LIMIT=U.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT=void 0;var St=(b(),D(y)),sc=an(),pc=Be(),fc=",",dc=["OTEL_SDK_DISABLED"];function yc(a){return dc.indexOf(a)>-1}var hc=["OTEL_BSP_EXPORT_TIMEOUT","OTEL_BSP_MAX_EXPORT_BATCH_SIZE","OTEL_BSP_MAX_QUEUE_SIZE","OTEL_BSP_SCHEDULE_DELAY","OTEL_BLRP_EXPORT_TIMEOUT","OTEL_BLRP_MAX_EXPORT_BATCH_SIZE","OTEL_BLRP_MAX_QUEUE_SIZE","OTEL_BLRP_SCHEDULE_DELAY","OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_EVENT_COUNT_LIMIT","OTEL_SPAN_LINK_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT","OTEL_EXPORTER_OTLP_TIMEOUT","OTEL_EXPORTER_OTLP_TRACES_TIMEOUT","OTEL_EXPORTER_OTLP_METRICS_TIMEOUT","OTEL_EXPORTER_OTLP_LOGS_TIMEOUT","OTEL_EXPORTER_JAEGER_AGENT_PORT"];function mc(a){return hc.indexOf(a)>-1}var vc=["OTEL_NO_PATCH_MODULES","OTEL_PROPAGATORS"];function _c(a){return vc.indexOf(a)>-1}U.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT=1/0;U.DEFAULT_ATTRIBUTE_COUNT_LIMIT=128;U.DEFAULT_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT=128;U.DEFAULT_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT=128;U.DEFAULT_ENVIRONMENT={OTEL_SDK_DISABLED:!1,CONTAINER_NAME:"",ECS_CONTAINER_METADATA_URI_V4:"",ECS_CONTAINER_METADATA_URI:"",HOSTNAME:"",KUBERNETES_SERVICE_HOST:"",NAMESPACE:"",OTEL_BSP_EXPORT_TIMEOUT:3e4,OTEL_BSP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BSP_MAX_QUEUE_SIZE:2048,OTEL_BSP_SCHEDULE_DELAY:5e3,OTEL_BLRP_EXPORT_TIMEOUT:3e4,OTEL_BLRP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BLRP_MAX_QUEUE_SIZE:2048,OTEL_BLRP_SCHEDULE_DELAY:5e3,OTEL_EXPORTER_JAEGER_AGENT_HOST:"",OTEL_EXPORTER_JAEGER_AGENT_PORT:6832,OTEL_EXPORTER_JAEGER_ENDPOINT:"",OTEL_EXPORTER_JAEGER_PASSWORD:"",OTEL_EXPORTER_JAEGER_USER:"",OTEL_EXPORTER_OTLP_ENDPOINT:"",OTEL_EXPORTER_OTLP_TRACES_ENDPOINT:"",OTEL_EXPORTER_OTLP_METRICS_ENDPOINT:"",OTEL_EXPORTER_OTLP_LOGS_ENDPOINT:"",OTEL_EXPORTER_OTLP_HEADERS:"",OTEL_EXPORTER_OTLP_TRACES_HEADERS:"",OTEL_EXPORTER_OTLP_METRICS_HEADERS:"",OTEL_EXPORTER_OTLP_LOGS_HEADERS:"",OTEL_EXPORTER_OTLP_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_TRACES_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_METRICS_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_LOGS_TIMEOUT:1e4,OTEL_EXPORTER_ZIPKIN_ENDPOINT:"http://localhost:9411/api/v2/spans",OTEL_LOG_LEVEL:St.DiagLogLevel.INFO,OTEL_NO_PATCH_MODULES:[],OTEL_PROPAGATORS:["tracecontext","baggage"],OTEL_RESOURCE_ATTRIBUTES:"",OTEL_SERVICE_NAME:"",OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT:U.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT,OTEL_ATTRIBUTE_COUNT_LIMIT:U.DEFAULT_ATTRIBUTE_COUNT_LIMIT,OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT:U.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT,OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT:U.DEFAULT_ATTRIBUTE_COUNT_LIMIT,OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT:U.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT,OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT:U.DEFAULT_ATTRIBUTE_COUNT_LIMIT,OTEL_SPAN_EVENT_COUNT_LIMIT:128,OTEL_SPAN_LINK_COUNT_LIMIT:128,OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT:U.DEFAULT_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT,OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT:U.DEFAULT_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT,OTEL_TRACES_EXPORTER:"",OTEL_TRACES_SAMPLER:sc.TracesSamplerValues.ParentBasedAlwaysOn,OTEL_TRACES_SAMPLER_ARG:"",OTEL_LOGS_EXPORTER:"",OTEL_EXPORTER_OTLP_INSECURE:"",OTEL_EXPORTER_OTLP_TRACES_INSECURE:"",OTEL_EXPORTER_OTLP_METRICS_INSECURE:"",OTEL_EXPORTER_OTLP_LOGS_INSECURE:"",OTEL_EXPORTER_OTLP_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_COMPRESSION:"",OTEL_EXPORTER_OTLP_TRACES_COMPRESSION:"",OTEL_EXPORTER_OTLP_METRICS_COMPRESSION:"",OTEL_EXPORTER_OTLP_LOGS_COMPRESSION:"",OTEL_EXPORTER_OTLP_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_TRACES_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_LOGS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE:"cumulative"};function Ec(a,n,o){if(typeof o[a]>"u")return;let c=String(o[a]);n[a]=c.toLowerCase()==="true"}function bc(a,n,o,c=-1/0,l=1/0){if(typeof o[a]<"u"){let i=Number(o[a]);isNaN(i)||(i<c?n[a]=c:i>l?n[a]=l:n[a]=i)}}function Sc(a,n,o,c=fc){let l=o[a];typeof l=="string"&&(n[a]=l.split(c).map(i=>i.trim()))}var Tc={ALL:St.DiagLogLevel.ALL,VERBOSE:St.DiagLogLevel.VERBOSE,DEBUG:St.DiagLogLevel.DEBUG,INFO:St.DiagLogLevel.INFO,WARN:St.DiagLogLevel.WARN,ERROR:St.DiagLogLevel.ERROR,NONE:St.DiagLogLevel.NONE};function Oc(a,n,o){let c=o[a];if(typeof c=="string"){let l=Tc[c.toUpperCase()];l!=null&&(n[a]=l)}}function un(a){let n={};for(let o in U.DEFAULT_ENVIRONMENT){let c=o;switch(c){case"OTEL_LOG_LEVEL":Oc(c,n,a);break;default:if(yc(c))Ec(c,n,a);else if(mc(c))bc(c,n,a);else if(_c(c))Sc(c,n,a);else{let l=a[c];typeof l<"u"&&l!==null&&(n[c]=String(l))}}}return n}U.parseEnvironment=un;function gc(){return typeof process<"u"&&process&&process.env?un(process.env):un(pc._globalThis)}U.getEnvWithoutDefaults=gc});var Vo=m(Ge=>{"use strict";Object.defineProperty(Ge,"__esModule",{value:!0});Ge.getEnv=void 0;var Bo=Ve(),Ac=Be();function Nc(){let a=(0,Bo.parseEnvironment)(Ac._globalThis);return Object.assign({},Bo.DEFAULT_ENVIRONMENT,a)}Ge.getEnv=Nc});var Go=m(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.hexToBase64=void 0;function Pc(a){let n=a.length,o="";for(let c=0;c<n;c+=2){let l=a.substring(c,c+2),i=parseInt(l,16);o+=String.fromCharCode(i)}return btoa(o)}He.hexToBase64=Pc});var jo=m(Fe=>{"use strict";Object.defineProperty(Fe,"__esModule",{value:!0});Fe.RandomIdGenerator=void 0;var xc=8,Rc=16,ln=class{constructor(){this.generateTraceId=Ho(Rc),this.generateSpanId=Ho(xc)}};Fe.RandomIdGenerator=ln;var je=Array(32);function Ho(a){return function(){for(let o=0;o<a*2;o++)je[o]=Math.floor(Math.random()*16)+48,je[o]>=58&&(je[o]+=39);return String.fromCharCode.apply(null,je.slice(0,a*2))}}});var Fo=m(qe=>{"use strict";Object.defineProperty(qe,"__esModule",{value:!0});qe.otperformance=void 0;qe.otperformance=performance});var cn=m(Ke=>{"use strict";Object.defineProperty(Ke,"__esModule",{value:!0});Ke.VERSION=void 0;Ke.VERSION="1.19.0"});var qo=m(P=>{"use strict";Object.defineProperty(P,"__esModule",{value:!0});P.MessageTypeValues=P.RpcGrpcStatusCodeValues=P.MessagingOperationValues=P.MessagingDestinationKindValues=P.HttpFlavorValues=P.NetHostConnectionSubtypeValues=P.NetHostConnectionTypeValues=P.NetTransportValues=P.FaasInvokedProviderValues=P.FaasDocumentOperationValues=P.FaasTriggerValues=P.DbCassandraConsistencyLevelValues=P.DbSystemValues=P.SemanticAttributes=void 0;P.SemanticAttributes={AWS_LAMBDA_INVOKED_ARN:"aws.lambda.invoked_arn",DB_SYSTEM:"db.system",DB_CONNECTION_STRING:"db.connection_string",DB_USER:"db.user",DB_JDBC_DRIVER_CLASSNAME:"db.jdbc.driver_classname",DB_NAME:"db.name",DB_STATEMENT:"db.statement",DB_OPERATION:"db.operation",DB_MSSQL_INSTANCE_NAME:"db.mssql.instance_name",DB_CASSANDRA_KEYSPACE:"db.cassandra.keyspace",DB_CASSANDRA_PAGE_SIZE:"db.cassandra.page_size",DB_CASSANDRA_CONSISTENCY_LEVEL:"db.cassandra.consistency_level",DB_CASSANDRA_TABLE:"db.cassandra.table",DB_CASSANDRA_IDEMPOTENCE:"db.cassandra.idempotence",DB_CASSANDRA_SPECULATIVE_EXECUTION_COUNT:"db.cassandra.speculative_execution_count",DB_CASSANDRA_COORDINATOR_ID:"db.cassandra.coordinator.id",DB_CASSANDRA_COORDINATOR_DC:"db.cassandra.coordinator.dc",DB_HBASE_NAMESPACE:"db.hbase.namespace",DB_REDIS_DATABASE_INDEX:"db.redis.database_index",DB_MONGODB_COLLECTION:"db.mongodb.collection",DB_SQL_TABLE:"db.sql.table",EXCEPTION_TYPE:"exception.type",EXCEPTION_MESSAGE:"exception.message",EXCEPTION_STACKTRACE:"exception.stacktrace",EXCEPTION_ESCAPED:"exception.escaped",FAAS_TRIGGER:"faas.trigger",FAAS_EXECUTION:"faas.execution",FAAS_DOCUMENT_COLLECTION:"faas.document.collection",FAAS_DOCUMENT_OPERATION:"faas.document.operation",FAAS_DOCUMENT_TIME:"faas.document.time",FAAS_DOCUMENT_NAME:"faas.document.name",FAAS_TIME:"faas.time",FAAS_CRON:"faas.cron",FAAS_COLDSTART:"faas.coldstart",FAAS_INVOKED_NAME:"faas.invoked_name",FAAS_INVOKED_PROVIDER:"faas.invoked_provider",FAAS_INVOKED_REGION:"faas.invoked_region",NET_TRANSPORT:"net.transport",NET_PEER_IP:"net.peer.ip",NET_PEER_PORT:"net.peer.port",NET_PEER_NAME:"net.peer.name",NET_HOST_IP:"net.host.ip",NET_HOST_PORT:"net.host.port",NET_HOST_NAME:"net.host.name",NET_HOST_CONNECTION_TYPE:"net.host.connection.type",NET_HOST_CONNECTION_SUBTYPE:"net.host.connection.subtype",NET_HOST_CARRIER_NAME:"net.host.carrier.name",NET_HOST_CARRIER_MCC:"net.host.carrier.mcc",NET_HOST_CARRIER_MNC:"net.host.carrier.mnc",NET_HOST_CARRIER_ICC:"net.host.carrier.icc",PEER_SERVICE:"peer.service",ENDUSER_ID:"enduser.id",ENDUSER_ROLE:"enduser.role",ENDUSER_SCOPE:"enduser.scope",THREAD_ID:"thread.id",THREAD_NAME:"thread.name",CODE_FUNCTION:"code.function",CODE_NAMESPACE:"code.namespace",CODE_FILEPATH:"code.filepath",CODE_LINENO:"code.lineno",HTTP_METHOD:"http.method",HTTP_URL:"http.url",HTTP_TARGET:"http.target",HTTP_HOST:"http.host",HTTP_SCHEME:"http.scheme",HTTP_STATUS_CODE:"http.status_code",HTTP_FLAVOR:"http.flavor",HTTP_USER_AGENT:"http.user_agent",HTTP_REQUEST_CONTENT_LENGTH:"http.request_content_length",HTTP_REQUEST_CONTENT_LENGTH_UNCOMPRESSED:"http.request_content_length_uncompressed",HTTP_RESPONSE_CONTENT_LENGTH:"http.response_content_length",HTTP_RESPONSE_CONTENT_LENGTH_UNCOMPRESSED:"http.response_content_length_uncompressed",HTTP_SERVER_NAME:"http.server_name",HTTP_ROUTE:"http.route",HTTP_CLIENT_IP:"http.client_ip",AWS_DYNAMODB_TABLE_NAMES:"aws.dynamodb.table_names",AWS_DYNAMODB_CONSUMED_CAPACITY:"aws.dynamodb.consumed_capacity",AWS_DYNAMODB_ITEM_COLLECTION_METRICS:"aws.dynamodb.item_collection_metrics",AWS_DYNAMODB_PROVISIONED_READ_CAPACITY:"aws.dynamodb.provisioned_read_capacity",AWS_DYNAMODB_PROVISIONED_WRITE_CAPACITY:"aws.dynamodb.provisioned_write_capacity",AWS_DYNAMODB_CONSISTENT_READ:"aws.dynamodb.consistent_read",AWS_DYNAMODB_PROJECTION:"aws.dynamodb.projection",AWS_DYNAMODB_LIMIT:"aws.dynamodb.limit",AWS_DYNAMODB_ATTRIBUTES_TO_GET:"aws.dynamodb.attributes_to_get",AWS_DYNAMODB_INDEX_NAME:"aws.dynamodb.index_name",AWS_DYNAMODB_SELECT:"aws.dynamodb.select",AWS_DYNAMODB_GLOBAL_SECONDARY_INDEXES:"aws.dynamodb.global_secondary_indexes",AWS_DYNAMODB_LOCAL_SECONDARY_INDEXES:"aws.dynamodb.local_secondary_indexes",AWS_DYNAMODB_EXCLUSIVE_START_TABLE:"aws.dynamodb.exclusive_start_table",AWS_DYNAMODB_TABLE_COUNT:"aws.dynamodb.table_count",AWS_DYNAMODB_SCAN_FORWARD:"aws.dynamodb.scan_forward",AWS_DYNAMODB_SEGMENT:"aws.dynamodb.segment",AWS_DYNAMODB_TOTAL_SEGMENTS:"aws.dynamodb.total_segments",AWS_DYNAMODB_COUNT:"aws.dynamodb.count",AWS_DYNAMODB_SCANNED_COUNT:"aws.dynamodb.scanned_count",AWS_DYNAMODB_ATTRIBUTE_DEFINITIONS:"aws.dynamodb.attribute_definitions",AWS_DYNAMODB_GLOBAL_SECONDARY_INDEX_UPDATES:"aws.dynamodb.global_secondary_index_updates",MESSAGING_SYSTEM:"messaging.system",MESSAGING_DESTINATION:"messaging.destination",MESSAGING_DESTINATION_KIND:"messaging.destination_kind",MESSAGING_TEMP_DESTINATION:"messaging.temp_destination",MESSAGING_PROTOCOL:"messaging.protocol",MESSAGING_PROTOCOL_VERSION:"messaging.protocol_version",MESSAGING_URL:"messaging.url",MESSAGING_MESSAGE_ID:"messaging.message_id",MESSAGING_CONVERSATION_ID:"messaging.conversation_id",MESSAGING_MESSAGE_PAYLOAD_SIZE_BYTES:"messaging.message_payload_size_bytes",MESSAGING_MESSAGE_PAYLOAD_COMPRESSED_SIZE_BYTES:"messaging.message_payload_compressed_size_bytes",MESSAGING_OPERATION:"messaging.operation",MESSAGING_CONSUMER_ID:"messaging.consumer_id",MESSAGING_RABBITMQ_ROUTING_KEY:"messaging.rabbitmq.routing_key",MESSAGING_KAFKA_MESSAGE_KEY:"messaging.kafka.message_key",MESSAGING_KAFKA_CONSUMER_GROUP:"messaging.kafka.consumer_group",MESSAGING_KAFKA_CLIENT_ID:"messaging.kafka.client_id",MESSAGING_KAFKA_PARTITION:"messaging.kafka.partition",MESSAGING_KAFKA_TOMBSTONE:"messaging.kafka.tombstone",RPC_SYSTEM:"rpc.system",RPC_SERVICE:"rpc.service",RPC_METHOD:"rpc.method",RPC_GRPC_STATUS_CODE:"rpc.grpc.status_code",RPC_JSONRPC_VERSION:"rpc.jsonrpc.version",RPC_JSONRPC_REQUEST_ID:"rpc.jsonrpc.request_id",RPC_JSONRPC_ERROR_CODE:"rpc.jsonrpc.error_code",RPC_JSONRPC_ERROR_MESSAGE:"rpc.jsonrpc.error_message",MESSAGE_TYPE:"message.type",MESSAGE_ID:"message.id",MESSAGE_COMPRESSED_SIZE:"message.compressed_size",MESSAGE_UNCOMPRESSED_SIZE:"message.uncompressed_size"};P.DbSystemValues={OTHER_SQL:"other_sql",MSSQL:"mssql",MYSQL:"mysql",ORACLE:"oracle",DB2:"db2",POSTGRESQL:"postgresql",REDSHIFT:"redshift",HIVE:"hive",CLOUDSCAPE:"cloudscape",HSQLDB:"hsqldb",PROGRESS:"progress",MAXDB:"maxdb",HANADB:"hanadb",INGRES:"ingres",FIRSTSQL:"firstsql",EDB:"edb",CACHE:"cache",ADABAS:"adabas",FIREBIRD:"firebird",DERBY:"derby",FILEMAKER:"filemaker",INFORMIX:"informix",INSTANTDB:"instantdb",INTERBASE:"interbase",MARIADB:"mariadb",NETEZZA:"netezza",PERVASIVE:"pervasive",POINTBASE:"pointbase",SQLITE:"sqlite",SYBASE:"sybase",TERADATA:"teradata",VERTICA:"vertica",H2:"h2",COLDFUSION:"coldfusion",CASSANDRA:"cassandra",HBASE:"hbase",MONGODB:"mongodb",REDIS:"redis",COUCHBASE:"couchbase",COUCHDB:"couchdb",COSMOSDB:"cosmosdb",DYNAMODB:"dynamodb",NEO4J:"neo4j",GEODE:"geode",ELASTICSEARCH:"elasticsearch",MEMCACHED:"memcached",COCKROACHDB:"cockroachdb"};P.DbCassandraConsistencyLevelValues={ALL:"all",EACH_QUORUM:"each_quorum",QUORUM:"quorum",LOCAL_QUORUM:"local_quorum",ONE:"one",TWO:"two",THREE:"three",LOCAL_ONE:"local_one",ANY:"any",SERIAL:"serial",LOCAL_SERIAL:"local_serial"};P.FaasTriggerValues={DATASOURCE:"datasource",HTTP:"http",PUBSUB:"pubsub",TIMER:"timer",OTHER:"other"};P.FaasDocumentOperationValues={INSERT:"insert",EDIT:"edit",DELETE:"delete"};P.FaasInvokedProviderValues={ALIBABA_CLOUD:"alibaba_cloud",AWS:"aws",AZURE:"azure",GCP:"gcp"};P.NetTransportValues={IP_TCP:"ip_tcp",IP_UDP:"ip_udp",IP:"ip",UNIX:"unix",PIPE:"pipe",INPROC:"inproc",OTHER:"other"};P.NetHostConnectionTypeValues={WIFI:"wifi",WIRED:"wired",CELL:"cell",UNAVAILABLE:"unavailable",UNKNOWN:"unknown"};P.NetHostConnectionSubtypeValues={GPRS:"gprs",EDGE:"edge",UMTS:"umts",CDMA:"cdma",EVDO_0:"evdo_0",EVDO_A:"evdo_a",CDMA2000_1XRTT:"cdma2000_1xrtt",HSDPA:"hsdpa",HSUPA:"hsupa",HSPA:"hspa",IDEN:"iden",EVDO_B:"evdo_b",LTE:"lte",EHRPD:"ehrpd",HSPAP:"hspap",GSM:"gsm",TD_SCDMA:"td_scdma",IWLAN:"iwlan",NR:"nr",NRNSA:"nrnsa",LTE_CA:"lte_ca"};P.HttpFlavorValues={HTTP_1_0:"1.0",HTTP_1_1:"1.1",HTTP_2_0:"2.0",SPDY:"SPDY",QUIC:"QUIC"};P.MessagingDestinationKindValues={QUEUE:"queue",TOPIC:"topic"};P.MessagingOperationValues={RECEIVE:"receive",PROCESS:"process"};P.RpcGrpcStatusCodeValues={OK:0,CANCELLED:1,UNKNOWN:2,INVALID_ARGUMENT:3,DEADLINE_EXCEEDED:4,NOT_FOUND:5,ALREADY_EXISTS:6,PERMISSION_DENIED:7,RESOURCE_EXHAUSTED:8,FAILED_PRECONDITION:9,ABORTED:10,OUT_OF_RANGE:11,UNIMPLEMENTED:12,INTERNAL:13,UNAVAILABLE:14,DATA_LOSS:15,UNAUTHENTICATED:16};P.MessageTypeValues={SENT:"SENT",RECEIVED:"RECEIVED"}});var Ko=m(Dt=>{"use strict";var Lc=Dt&&Dt.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),Ic=Dt&&Dt.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&Lc(n,a,o)};Object.defineProperty(Dt,"__esModule",{value:!0});Ic(qo(),Dt)});var Xo=m(K=>{"use strict";Object.defineProperty(K,"__esModule",{value:!0});K.TelemetrySdkLanguageValues=K.OsTypeValues=K.HostArchValues=K.AwsEcsLaunchtypeValues=K.CloudPlatformValues=K.CloudProviderValues=K.SemanticResourceAttributes=void 0;K.SemanticResourceAttributes={CLOUD_PROVIDER:"cloud.provider",CLOUD_ACCOUNT_ID:"cloud.account.id",CLOUD_REGION:"cloud.region",CLOUD_AVAILABILITY_ZONE:"cloud.availability_zone",CLOUD_PLATFORM:"cloud.platform",AWS_ECS_CONTAINER_ARN:"aws.ecs.container.arn",AWS_ECS_CLUSTER_ARN:"aws.ecs.cluster.arn",AWS_ECS_LAUNCHTYPE:"aws.ecs.launchtype",AWS_ECS_TASK_ARN:"aws.ecs.task.arn",AWS_ECS_TASK_FAMILY:"aws.ecs.task.family",AWS_ECS_TASK_REVISION:"aws.ecs.task.revision",AWS_EKS_CLUSTER_ARN:"aws.eks.cluster.arn",AWS_LOG_GROUP_NAMES:"aws.log.group.names",AWS_LOG_GROUP_ARNS:"aws.log.group.arns",AWS_LOG_STREAM_NAMES:"aws.log.stream.names",AWS_LOG_STREAM_ARNS:"aws.log.stream.arns",CONTAINER_NAME:"container.name",CONTAINER_ID:"container.id",CONTAINER_RUNTIME:"container.runtime",CONTAINER_IMAGE_NAME:"container.image.name",CONTAINER_IMAGE_TAG:"container.image.tag",DEPLOYMENT_ENVIRONMENT:"deployment.environment",DEVICE_ID:"device.id",DEVICE_MODEL_IDENTIFIER:"device.model.identifier",DEVICE_MODEL_NAME:"device.model.name",FAAS_NAME:"faas.name",FAAS_ID:"faas.id",FAAS_VERSION:"faas.version",FAAS_INSTANCE:"faas.instance",FAAS_MAX_MEMORY:"faas.max_memory",HOST_ID:"host.id",HOST_NAME:"host.name",HOST_TYPE:"host.type",HOST_ARCH:"host.arch",HOST_IMAGE_NAME:"host.image.name",HOST_IMAGE_ID:"host.image.id",HOST_IMAGE_VERSION:"host.image.version",K8S_CLUSTER_NAME:"k8s.cluster.name",K8S_NODE_NAME:"k8s.node.name",K8S_NODE_UID:"k8s.node.uid",K8S_NAMESPACE_NAME:"k8s.namespace.name",K8S_POD_UID:"k8s.pod.uid",K8S_POD_NAME:"k8s.pod.name",K8S_CONTAINER_NAME:"k8s.container.name",K8S_REPLICASET_UID:"k8s.replicaset.uid",K8S_REPLICASET_NAME:"k8s.replicaset.name",K8S_DEPLOYMENT_UID:"k8s.deployment.uid",K8S_DEPLOYMENT_NAME:"k8s.deployment.name",K8S_STATEFULSET_UID:"k8s.statefulset.uid",K8S_STATEFULSET_NAME:"k8s.statefulset.name",K8S_DAEMONSET_UID:"k8s.daemonset.uid",K8S_DAEMONSET_NAME:"k8s.daemonset.name",K8S_JOB_UID:"k8s.job.uid",K8S_JOB_NAME:"k8s.job.name",K8S_CRONJOB_UID:"k8s.cronjob.uid",K8S_CRONJOB_NAME:"k8s.cronjob.name",OS_TYPE:"os.type",OS_DESCRIPTION:"os.description",OS_NAME:"os.name",OS_VERSION:"os.version",PROCESS_PID:"process.pid",PROCESS_EXECUTABLE_NAME:"process.executable.name",PROCESS_EXECUTABLE_PATH:"process.executable.path",PROCESS_COMMAND:"process.command",PROCESS_COMMAND_LINE:"process.command_line",PROCESS_COMMAND_ARGS:"process.command_args",PROCESS_OWNER:"process.owner",PROCESS_RUNTIME_NAME:"process.runtime.name",PROCESS_RUNTIME_VERSION:"process.runtime.version",PROCESS_RUNTIME_DESCRIPTION:"process.runtime.description",SERVICE_NAME:"service.name",SERVICE_NAMESPACE:"service.namespace",SERVICE_INSTANCE_ID:"service.instance.id",SERVICE_VERSION:"service.version",TELEMETRY_SDK_NAME:"telemetry.sdk.name",TELEMETRY_SDK_LANGUAGE:"telemetry.sdk.language",TELEMETRY_SDK_VERSION:"telemetry.sdk.version",TELEMETRY_AUTO_VERSION:"telemetry.auto.version",WEBENGINE_NAME:"webengine.name",WEBENGINE_VERSION:"webengine.version",WEBENGINE_DESCRIPTION:"webengine.description"};K.CloudProviderValues={ALIBABA_CLOUD:"alibaba_cloud",AWS:"aws",AZURE:"azure",GCP:"gcp"};K.CloudPlatformValues={ALIBABA_CLOUD_ECS:"alibaba_cloud_ecs",ALIBABA_CLOUD_FC:"alibaba_cloud_fc",AWS_EC2:"aws_ec2",AWS_ECS:"aws_ecs",AWS_EKS:"aws_eks",AWS_LAMBDA:"aws_lambda",AWS_ELASTIC_BEANSTALK:"aws_elastic_beanstalk",AZURE_VM:"azure_vm",AZURE_CONTAINER_INSTANCES:"azure_container_instances",AZURE_AKS:"azure_aks",AZURE_FUNCTIONS:"azure_functions",AZURE_APP_SERVICE:"azure_app_service",GCP_COMPUTE_ENGINE:"gcp_compute_engine",GCP_CLOUD_RUN:"gcp_cloud_run",GCP_KUBERNETES_ENGINE:"gcp_kubernetes_engine",GCP_CLOUD_FUNCTIONS:"gcp_cloud_functions",GCP_APP_ENGINE:"gcp_app_engine"};K.AwsEcsLaunchtypeValues={EC2:"ec2",FARGATE:"fargate"};K.HostArchValues={AMD64:"amd64",ARM32:"arm32",ARM64:"arm64",IA64:"ia64",PPC32:"ppc32",PPC64:"ppc64",X86:"x86"};K.OsTypeValues={WINDOWS:"windows",LINUX:"linux",DARWIN:"darwin",FREEBSD:"freebsd",NETBSD:"netbsd",OPENBSD:"openbsd",DRAGONFLYBSD:"dragonflybsd",HPUX:"hpux",AIX:"aix",SOLARIS:"solaris",Z_OS:"z_os"};K.TelemetrySdkLanguageValues={CPP:"cpp",DOTNET:"dotnet",ERLANG:"erlang",GO:"go",JAVA:"java",NODEJS:"nodejs",PHP:"php",PYTHON:"python",RUBY:"ruby",WEBJS:"webjs"}});var Yo=m(kt=>{"use strict";var wc=kt&&kt.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),Cc=kt&&kt.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&wc(n,a,o)};Object.defineProperty(kt,"__esModule",{value:!0});Cc(Xo(),kt)});var Ot=m(Tt=>{"use strict";var Uc=Tt&&Tt.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),Jo=Tt&&Tt.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&Uc(n,a,o)};Object.defineProperty(Tt,"__esModule",{value:!0});Jo(Ko(),Tt);Jo(Yo(),Tt)});var zo=m(Xe=>{"use strict";Object.defineProperty(Xe,"__esModule",{value:!0});Xe.SDK_INFO=void 0;var Mc=cn(),de=Ot();Xe.SDK_INFO={[de.SemanticResourceAttributes.TELEMETRY_SDK_NAME]:"opentelemetry",[de.SemanticResourceAttributes.PROCESS_RUNTIME_NAME]:"browser",[de.SemanticResourceAttributes.TELEMETRY_SDK_LANGUAGE]:de.TelemetrySdkLanguageValues.WEBJS,[de.SemanticResourceAttributes.TELEMETRY_SDK_VERSION]:Mc.VERSION}});var Wo=m(Ye=>{"use strict";Object.defineProperty(Ye,"__esModule",{value:!0});Ye.unrefTimer=void 0;function Dc(a){}Ye.unrefTimer=Dc});var sn=m(z=>{"use strict";var kc=z&&z.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),Bt=z&&z.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&kc(n,a,o)};Object.defineProperty(z,"__esModule",{value:!0});Bt(Vo(),z);Bt(Be(),z);Bt(Go(),z);Bt(jo(),z);Bt(Fo(),z);Bt(zo(),z);Bt(Wo(),z)});var ti=m(w=>{"use strict";Object.defineProperty(w,"__esModule",{value:!0});w.addHrTimes=w.isTimeInput=w.isTimeInputHrTime=w.hrTimeToMicroseconds=w.hrTimeToMilliseconds=w.hrTimeToNanoseconds=w.hrTimeToTimeStamp=w.hrTimeDuration=w.timeInputToHrTime=w.hrTime=w.getTimeOrigin=w.millisToHrTime=void 0;var pn=sn(),$o=9,Bc=6,Vc=Math.pow(10,Bc),Je=Math.pow(10,$o);function ye(a){let n=a/1e3,o=Math.trunc(n),c=Math.round(a%1e3*Vc);return[o,c]}w.millisToHrTime=ye;function fn(){let a=pn.otperformance.timeOrigin;if(typeof a!="number"){let n=pn.otperformance;a=n.timing&&n.timing.fetchStart}return a}w.getTimeOrigin=fn;function Qo(a){let n=ye(fn()),o=ye(typeof a=="number"?a:pn.otperformance.now());return Zo(n,o)}w.hrTime=Qo;function Gc(a){if(dn(a))return a;if(typeof a=="number")return a<fn()?Qo(a):ye(a);if(a instanceof Date)return ye(a.getTime());throw TypeError("Invalid input type")}w.timeInputToHrTime=Gc;function Hc(a,n){let o=n[0]-a[0],c=n[1]-a[1];return c<0&&(o-=1,c+=Je),[o,c]}w.hrTimeDuration=Hc;function jc(a){let n=$o,o=`${"0".repeat(n)}${a[1]}Z`,c=o.substr(o.length-n-1);return new Date(a[0]*1e3).toISOString().replace("000Z",c)}w.hrTimeToTimeStamp=jc;function Fc(a){return a[0]*Je+a[1]}w.hrTimeToNanoseconds=Fc;function qc(a){return a[0]*1e3+a[1]/1e6}w.hrTimeToMilliseconds=qc;function Kc(a){return a[0]*1e6+a[1]/1e3}w.hrTimeToMicroseconds=Kc;function dn(a){return Array.isArray(a)&&a.length===2&&typeof a[0]=="number"&&typeof a[1]=="number"}w.isTimeInputHrTime=dn;function Xc(a){return dn(a)||typeof a=="number"||a instanceof Date}w.isTimeInput=Xc;function Zo(a,n){let o=[a[0]+n[0],a[1]+n[1]];return o[1]>=Je&&(o[1]-=Je,o[0]+=1),o}w.addHrTimes=Zo});var ri=m(ei=>{"use strict";Object.defineProperty(ei,"__esModule",{value:!0})});var ni=m(he=>{"use strict";Object.defineProperty(he,"__esModule",{value:!0});he.ExportResultCode=void 0;var Yc;(function(a){a[a.SUCCESS=0]="SUCCESS",a[a.FAILED=1]="FAILED"})(Yc=he.ExportResultCode||(he.ExportResultCode={}))});var ii=m(ze=>{"use strict";Object.defineProperty(ze,"__esModule",{value:!0});ze.CompositePropagator=void 0;var oi=(b(),D(y)),yn=class{constructor(n={}){var o;this._propagators=(o=n.propagators)!==null&&o!==void 0?o:[],this._fields=Array.from(new Set(this._propagators.map(c=>typeof c.fields=="function"?c.fields():[]).reduce((c,l)=>c.concat(l),[])))}inject(n,o,c){for(let l of this._propagators)try{l.inject(n,o,c)}catch(i){oi.diag.warn(`Failed to inject with ${l.constructor.name}. Err: ${i.message}`)}}extract(n,o,c){return this._propagators.reduce((l,i)=>{try{return i.extract(l,o,c)}catch(e){oi.diag.warn(`Failed to inject with ${i.constructor.name}. Err: ${e.message}`)}return l},n)}fields(){return this._fields.slice()}};ze.CompositePropagator=yn});var ai=m(Kt=>{"use strict";Object.defineProperty(Kt,"__esModule",{value:!0});Kt.validateValue=Kt.validateKey=void 0;var hn="[_0-9a-z-*/]",Jc=`[a-z]${hn}{0,255}`,zc=`[a-z0-9]${hn}{0,240}@[a-z]${hn}{0,13}`,Wc=new RegExp(`^(?:${Jc}|${zc})$`),$c=/^[ -~]{0,255}[!-~]$/,Qc=/,|=/;function Zc(a){return Wc.test(a)}Kt.validateKey=Zc;function ts(a){return $c.test(a)&&!Qc.test(a)}Kt.validateValue=ts});var vn=m(We=>{"use strict";Object.defineProperty(We,"__esModule",{value:!0});We.TraceState=void 0;var ui=ai(),li=32,es=512,ci=",",si="=",mn=class a{constructor(n){this._internalState=new Map,n&&this._parse(n)}set(n,o){let c=this._clone();return c._internalState.has(n)&&c._internalState.delete(n),c._internalState.set(n,o),c}unset(n){let o=this._clone();return o._internalState.delete(n),o}get(n){return this._internalState.get(n)}serialize(){return this._keys().reduce((n,o)=>(n.push(o+si+this.get(o)),n),[]).join(ci)}_parse(n){n.length>es||(this._internalState=n.split(ci).reverse().reduce((o,c)=>{let l=c.trim(),i=l.indexOf(si);if(i!==-1){let e=l.slice(0,i),t=l.slice(i+1,c.length);(0,ui.validateKey)(e)&&(0,ui.validateValue)(t)&&o.set(e,t)}return o},new Map),this._internalState.size>li&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,li))))}_keys(){return Array.from(this._internalState.keys()).reverse()}_clone(){let n=new a;return n._internalState=new Map(this._internalState),n}};We.TraceState=mn});var fi=m(X=>{"use strict";Object.defineProperty(X,"__esModule",{value:!0});X.W3CTraceContextPropagator=X.parseTraceParent=X.TRACE_STATE_HEADER=X.TRACE_PARENT_HEADER=void 0;var $e=(b(),D(y)),rs=pe(),ns=vn();X.TRACE_PARENT_HEADER="traceparent";X.TRACE_STATE_HEADER="tracestate";var os="00",is="(?!ff)[\\da-f]{2}",as="(?![0]{32})[\\da-f]{32}",us="(?![0]{16})[\\da-f]{16}",ls="[\\da-f]{2}",cs=new RegExp(`^\\s?(${is})-(${as})-(${us})-(${ls})(-.*)?\\s?$`);function pi(a){let n=cs.exec(a);return!n||n[1]==="00"&&n[5]?null:{traceId:n[2],spanId:n[3],traceFlags:parseInt(n[4],16)}}X.parseTraceParent=pi;var _n=class{inject(n,o,c){let l=$e.trace.getSpanContext(n);if(!l||(0,rs.isTracingSuppressed)(n)||!(0,$e.isSpanContextValid)(l))return;let i=`${os}-${l.traceId}-${l.spanId}-0${Number(l.traceFlags||$e.TraceFlags.NONE).toString(16)}`;c.set(o,X.TRACE_PARENT_HEADER,i),l.traceState&&c.set(o,X.TRACE_STATE_HEADER,l.traceState.serialize())}extract(n,o,c){let l=c.get(o,X.TRACE_PARENT_HEADER);if(!l)return n;let i=Array.isArray(l)?l[0]:l;if(typeof i!="string")return n;let e=pi(i);if(!e)return n;e.isRemote=!0;let t=c.get(o,X.TRACE_STATE_HEADER);if(t){let r=Array.isArray(t)?t.join(","):t;e.traceState=new ns.TraceState(typeof r=="string"?r:void 0)}return $e.trace.setSpanContext(n,e)}fields(){return[X.TRACE_PARENT_HEADER,X.TRACE_STATE_HEADER]}};X.W3CTraceContextPropagator=_n});var yi=m(di=>{"use strict";Object.defineProperty(di,"__esModule",{value:!0})});var hi=m(et=>{"use strict";Object.defineProperty(et,"__esModule",{value:!0});et.getRPCMetadata=et.deleteRPCMetadata=et.setRPCMetadata=et.RPCType=void 0;var ss=(b(),D(y)),En=(0,ss.createContextKey)("OpenTelemetry SDK Context Key RPC_METADATA"),ps;(function(a){a.HTTP="http"})(ps=et.RPCType||(et.RPCType={}));function fs(a,n){return a.setValue(En,n)}et.setRPCMetadata=fs;function ds(a){return a.deleteValue(En)}et.deleteRPCMetadata=ds;function ys(a){return a.getValue(En)}et.getRPCMetadata=ys});var Sn=m(Qe=>{"use strict";Object.defineProperty(Qe,"__esModule",{value:!0});Qe.AlwaysOffSampler=void 0;var hs=(b(),D(y)),bn=class{shouldSample(){return{decision:hs.SamplingDecision.NOT_RECORD}}toString(){return"AlwaysOffSampler"}};Qe.AlwaysOffSampler=bn});var On=m(Ze=>{"use strict";Object.defineProperty(Ze,"__esModule",{value:!0});Ze.AlwaysOnSampler=void 0;var ms=(b(),D(y)),Tn=class{shouldSample(){return{decision:ms.SamplingDecision.RECORD_AND_SAMPLED}}toString(){return"AlwaysOnSampler"}};Ze.AlwaysOnSampler=Tn});var vi=m(er=>{"use strict";Object.defineProperty(er,"__esModule",{value:!0});er.ParentBasedSampler=void 0;var tr=(b(),D(y)),vs=on(),mi=Sn(),gn=On(),An=class{constructor(n){var o,c,l,i;this._root=n.root,this._root||((0,vs.globalErrorHandler)(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new gn.AlwaysOnSampler),this._remoteParentSampled=(o=n.remoteParentSampled)!==null&&o!==void 0?o:new gn.AlwaysOnSampler,this._remoteParentNotSampled=(c=n.remoteParentNotSampled)!==null&&c!==void 0?c:new mi.AlwaysOffSampler,this._localParentSampled=(l=n.localParentSampled)!==null&&l!==void 0?l:new gn.AlwaysOnSampler,this._localParentNotSampled=(i=n.localParentNotSampled)!==null&&i!==void 0?i:new mi.AlwaysOffSampler}shouldSample(n,o,c,l,i,e){let t=tr.trace.getSpanContext(n);return!t||!(0,tr.isSpanContextValid)(t)?this._root.shouldSample(n,o,c,l,i,e):t.isRemote?t.traceFlags&tr.TraceFlags.SAMPLED?this._remoteParentSampled.shouldSample(n,o,c,l,i,e):this._remoteParentNotSampled.shouldSample(n,o,c,l,i,e):t.traceFlags&tr.TraceFlags.SAMPLED?this._localParentSampled.shouldSample(n,o,c,l,i,e):this._localParentNotSampled.shouldSample(n,o,c,l,i,e)}toString(){return`ParentBased{root=${this._root.toString()}, remoteParentSampled=${this._remoteParentSampled.toString()}, remoteParentNotSampled=${this._remoteParentNotSampled.toString()}, localParentSampled=${this._localParentSampled.toString()}, localParentNotSampled=${this._localParentNotSampled.toString()}}`}};er.ParentBasedSampler=An});var _i=m(rr=>{"use strict";Object.defineProperty(rr,"__esModule",{value:!0});rr.TraceIdRatioBasedSampler=void 0;var Nn=(b(),D(y)),Pn=class{constructor(n=0){this._ratio=n,this._ratio=this._normalize(n),this._upperBound=Math.floor(this._ratio*4294967295)}shouldSample(n,o){return{decision:(0,Nn.isValidTraceId)(o)&&this._accumulate(o)<this._upperBound?Nn.SamplingDecision.RECORD_AND_SAMPLED:Nn.SamplingDecision.NOT_RECORD}}toString(){return`TraceIdRatioBased{${this._ratio}}`}_normalize(n){return typeof n!="number"||isNaN(n)?0:n>=1?1:n<=0?0:n}_accumulate(n){let o=0;for(let c=0;c<n.length/8;c++){let l=c*8,i=parseInt(n.slice(l,l+8),16);o=(o^i)>>>0}return o}};rr.TraceIdRatioBasedSampler=Pn});var Oi=m(nr=>{"use strict";Object.defineProperty(nr,"__esModule",{value:!0});nr.isPlainObject=void 0;var _s="[object Object]",Es="[object Null]",bs="[object Undefined]",Ss=Function.prototype,Ei=Ss.toString,Ts=Ei.call(Object),Os=gs(Object.getPrototypeOf,Object),bi=Object.prototype,Si=bi.hasOwnProperty,Vt=Symbol?Symbol.toStringTag:void 0,Ti=bi.toString;function gs(a,n){return function(o){return a(n(o))}}function As(a){if(!Ns(a)||Ps(a)!==_s)return!1;let n=Os(a);if(n===null)return!0;let o=Si.call(n,"constructor")&&n.constructor;return typeof o=="function"&&o instanceof o&&Ei.call(o)===Ts}nr.isPlainObject=As;function Ns(a){return a!=null&&typeof a=="object"}function Ps(a){return a==null?a===void 0?bs:Es:Vt&&Vt in Object(a)?xs(a):Rs(a)}function xs(a){let n=Si.call(a,Vt),o=a[Vt],c=!1;try{a[Vt]=void 0,c=!0}catch{}let l=Ti.call(a);return c&&(n?a[Vt]=o:delete a[Vt]),l}function Rs(a){return Ti.call(a)}});var xi=m(ar=>{"use strict";Object.defineProperty(ar,"__esModule",{value:!0});ar.merge=void 0;var gi=Oi(),Ls=20;function Is(...a){let n=a.shift(),o=new WeakMap;for(;a.length>0;)n=Ni(n,a.shift(),0,o);return n}ar.merge=Is;function xn(a){return ir(a)?a.slice():a}function Ni(a,n,o=0,c){let l;if(!(o>Ls)){if(o++,or(a)||or(n)||Pi(n))l=xn(n);else if(ir(a)){if(l=a.slice(),ir(n))for(let i=0,e=n.length;i<e;i++)l.push(xn(n[i]));else if(me(n)){let i=Object.keys(n);for(let e=0,t=i.length;e<t;e++){let r=i[e];l[r]=xn(n[r])}}}else if(me(a))if(me(n)){if(!ws(a,n))return n;l=Object.assign({},a);let i=Object.keys(n);for(let e=0,t=i.length;e<t;e++){let r=i[e],u=n[r];if(or(u))typeof u>"u"?delete l[r]:l[r]=u;else{let s=l[r],d=u;if(Ai(a,r,c)||Ai(n,r,c))delete l[r];else{if(me(s)&&me(d)){let v=c.get(s)||[],g=c.get(d)||[];v.push({obj:a,key:r}),g.push({obj:n,key:r}),c.set(s,v),c.set(d,g)}l[r]=Ni(l[r],u,o,c)}}}}else l=n;return l}}function Ai(a,n,o){let c=o.get(a[n])||[];for(let l=0,i=c.length;l<i;l++){let e=c[l];if(e.key===n&&e.obj===a)return!0}return!1}function ir(a){return Array.isArray(a)}function Pi(a){return typeof a=="function"}function me(a){return!or(a)&&!ir(a)&&!Pi(a)&&typeof a=="object"}function or(a){return typeof a=="string"||typeof a=="number"||typeof a=="boolean"||typeof a>"u"||a instanceof Date||a instanceof RegExp||a===null}function ws(a,n){return!(!(0,gi.isPlainObject)(a)||!(0,gi.isPlainObject)(n))}});var Ri=m(Xt=>{"use strict";Object.defineProperty(Xt,"__esModule",{value:!0});Xt.callWithTimeout=Xt.TimeoutError=void 0;var ur=class a extends Error{constructor(n){super(n),Object.setPrototypeOf(this,a.prototype)}};Xt.TimeoutError=ur;function Cs(a,n){let o,c=new Promise(function(i,e){o=setTimeout(function(){e(new ur("Operation timed out."))},n)});return Promise.race([a,c]).then(l=>(clearTimeout(o),l),l=>{throw clearTimeout(o),l})}Xt.callWithTimeout=Cs});var Ii=m(Yt=>{"use strict";Object.defineProperty(Yt,"__esModule",{value:!0});Yt.isUrlIgnored=Yt.urlMatches=void 0;function Li(a,n){return typeof n=="string"?a===n:!!a.match(n)}Yt.urlMatches=Li;function Us(a,n){if(!n)return!1;for(let o of n)if(Li(a,o))return!0;return!1}Yt.isUrlIgnored=Us});var wi=m(lr=>{"use strict";Object.defineProperty(lr,"__esModule",{value:!0});lr.isWrapped=void 0;function Ms(a){return typeof a=="function"&&typeof a.__original=="function"&&typeof a.__unwrap=="function"&&a.__wrapped===!0}lr.isWrapped=Ms});var Ci=m(cr=>{"use strict";Object.defineProperty(cr,"__esModule",{value:!0});cr.Deferred=void 0;var Rn=class{constructor(){this._promise=new Promise((n,o)=>{this._resolve=n,this._reject=o})}get promise(){return this._promise}resolve(n){this._resolve(n)}reject(n){this._reject(n)}};cr.Deferred=Rn});var Ui=m(sr=>{"use strict";Object.defineProperty(sr,"__esModule",{value:!0});sr.BindOnceFuture=void 0;var Ds=Ci(),Ln=class{constructor(n,o){this._callback=n,this._that=o,this._isCalled=!1,this._deferred=new Ds.Deferred}get isCalled(){return this._isCalled}get promise(){return this._deferred.promise}call(...n){if(!this._isCalled){this._isCalled=!0;try{Promise.resolve(this._callback.call(this._that,...n)).then(o=>this._deferred.resolve(o),o=>this._deferred.reject(o))}catch(o){this._deferred.reject(o)}}return this._deferred.promise}};sr.BindOnceFuture=Ln});var Di=m(pr=>{"use strict";Object.defineProperty(pr,"__esModule",{value:!0});pr._export=void 0;var Mi=(b(),D(y)),ks=pe();function Bs(a,n){return new Promise(o=>{Mi.context.with((0,ks.suppressTracing)(Mi.context.active()),()=>{a.export(n,c=>{o(c)})})})}pr._export=Bs});var k=m(O=>{"use strict";var Vs=O&&O.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),L=O&&O.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&Vs(n,a,o)};Object.defineProperty(O,"__esModule",{value:!0});O.internal=O.baggageUtils=void 0;L(Lo(),O);L(Io(),O);L(Do(),O);L(on(),O);L(nn(),O);L(ti(),O);L(ri(),O);L(ni(),O);O.baggageUtils=Qr();L(sn(),O);L(ii(),O);L(fi(),O);L(yi(),O);L(hi(),O);L(Sn(),O);L(On(),O);L(vi(),O);L(_i(),O);L(pe(),O);L(vn(),O);L(Ve(),O);L(xi(),O);L(an(),O);L(Ri(),O);L(Ii(),O);L(wi(),O);L(Ui(),O);L(cn(),O);var Gs=Di();O.internal={_export:Gs._export}});var na=m(xt=>{"use strict";Object.defineProperty(xt,"__esModule",{value:!0});xt.disableInstrumentations=xt.enableInstrumentations=xt.parseInstrumentationOptions=void 0;function ra(a=[]){let n=[];for(let o=0,c=a.length;o<c;o++){let l=a[o];if(Array.isArray(l)){let i=ra(l);n=n.concat(i.instrumentations)}else typeof l=="function"?n.push(new l):l.instrumentationName&&n.push(l)}return{instrumentations:n}}xt.parseInstrumentationOptions=ra;function np(a,n,o){for(let c=0,l=a.length;c<l;c++){let i=a[c];n&&i.setTracerProvider(n),o&&i.setMeterProvider(o),i.getConfig().enabled||i.enable()}}xt.enableInstrumentations=np;function op(a){a.forEach(n=>n.disable())}xt.disableInstrumentations=op});var ia=m(vr=>{"use strict";Object.defineProperty(vr,"__esModule",{value:!0});vr.registerInstrumentations=void 0;var oa=(b(),D(y)),wn=na();function ip(a){let{instrumentations:n}=(0,wn.parseInstrumentationOptions)(a.instrumentations),o=a.tracerProvider||oa.trace.getTracerProvider(),c=a.meterProvider||oa.metrics.getMeterProvider();return(0,wn.enableInstrumentations)(n,o,c),()=>{(0,wn.disableInstrumentations)(n)}}vr.registerInstrumentations=ip});var Ee={};import*as xm from"async_hooks";var tu=zr(()=>{tt(Ee,xm)});var be={};import*as Rm from"events";var eu=zr(()=>{tt(be,Rm)});var ru=m(Pr=>{"use strict";Object.defineProperty(Pr,"__esModule",{value:!0});Pr.AbstractAsyncHooksContextManager=void 0;var Up=(eu(),D(be)),Mp=["addListener","on","once","prependListener","prependOnceListener"],qn=class{constructor(){this._kOtListeners=Symbol("OtListeners"),this._wrapped=!1}bind(n,o){return o instanceof Up.EventEmitter?this._bindEventEmitter(n,o):typeof o=="function"?this._bindFunction(n,o):o}_bindFunction(n,o){let c=this,l=function(...i){return c.with(n,()=>o.apply(this,i))};return Object.defineProperty(l,"length",{enumerable:!1,configurable:!0,writable:!1,value:o.length}),l}_bindEventEmitter(n,o){return this._getPatchMap(o)!==void 0||(this._createPatchMap(o),Mp.forEach(l=>{o[l]!==void 0&&(o[l]=this._patchAddListener(o,o[l],n))}),typeof o.removeListener=="function"&&(o.removeListener=this._patchRemoveListener(o,o.removeListener)),typeof o.off=="function"&&(o.off=this._patchRemoveListener(o,o.off)),typeof o.removeAllListeners=="function"&&(o.removeAllListeners=this._patchRemoveAllListeners(o,o.removeAllListeners))),o}_patchRemoveListener(n,o){let c=this;return function(l,i){var e;let t=(e=c._getPatchMap(n))===null||e===void 0?void 0:e[l];if(t===void 0)return o.call(this,l,i);let r=t.get(i);return o.call(this,l,r||i)}}_patchRemoveAllListeners(n,o){let c=this;return function(l){let i=c._getPatchMap(n);return i!==void 0&&(arguments.length===0?c._createPatchMap(n):i[l]!==void 0&&delete i[l]),o.apply(this,arguments)}}_patchAddListener(n,o,c){let l=this;return function(i,e){if(l._wrapped)return o.call(this,i,e);let t=l._getPatchMap(n);t===void 0&&(t=l._createPatchMap(n));let r=t[i];r===void 0&&(r=new WeakMap,t[i]=r);let u=l.bind(c,e);r.set(e,u),l._wrapped=!0;try{return o.call(this,i,u)}finally{l._wrapped=!1}}}_createPatchMap(n){let o=Object.create(null);return n[this._kOtListeners]=o,o}_getPatchMap(n){return n[this._kOtListeners]}};Pr.AbstractAsyncHooksContextManager=qn});var nu=m(xr=>{"use strict";Object.defineProperty(xr,"__esModule",{value:!0});xr.AsyncLocalStorageContextManager=void 0;var Dp=(b(),D(y)),kp=(tu(),D(Ee)),Bp=ru(),Kn=class extends Bp.AbstractAsyncHooksContextManager{constructor(){super(),this._asyncLocalStorage=new kp.AsyncLocalStorage}active(){var n;return(n=this._asyncLocalStorage.getStore())!==null&&n!==void 0?n:Dp.ROOT_CONTEXT}with(n,o,c,...l){let i=c==null?o:o.bind(c);return this._asyncLocalStorage.run(n,i,...l)}enable(){return this}disable(){return this._asyncLocalStorage.disable(),this}};xr.AsyncLocalStorageContextManager=Kn});var zn=m(Rt=>{"use strict";Object.defineProperty(Rt,"__esModule",{value:!0});Rt.toAnyValue=Rt.toKeyValue=Rt.toAttributes=void 0;function jp(a){return Object.keys(a).map(n=>Yn(n,a[n]))}Rt.toAttributes=jp;function Yn(a,n){return{key:a,value:Jn(n)}}Rt.toKeyValue=Yn;function Jn(a){let n=typeof a;return n==="string"?{stringValue:a}:n==="number"?Number.isInteger(a)?{intValue:a}:{doubleValue:a}:n==="boolean"?{boolValue:a}:a instanceof Uint8Array?{bytesValue:a}:Array.isArray(a)?{arrayValue:{values:a.map(Jn)}}:n==="object"&&a!=null?{kvlistValue:{values:Object.entries(a).map(([o,c])=>Yn(o,c))}}:{}}Rt.toAnyValue=Jn});var cu=m(Lt=>{"use strict";Object.defineProperty(Lt,"__esModule",{value:!0});Lt.toOtlpSpanEvent=Lt.toOtlpLink=Lt.sdkSpanToOtlpSpan=void 0;var Wn=zn();function Fp(a,n){var o;let c=a.spanContext(),l=a.status;return{traceId:n.encodeSpanContext(c.traceId),spanId:n.encodeSpanContext(c.spanId),parentSpanId:n.encodeOptionalSpanContext(a.parentSpanId),traceState:(o=c.traceState)===null||o===void 0?void 0:o.serialize(),name:a.name,kind:a.kind==null?0:a.kind+1,startTimeUnixNano:n.encodeHrTime(a.startTime),endTimeUnixNano:n.encodeHrTime(a.endTime),attributes:(0,Wn.toAttributes)(a.attributes),droppedAttributesCount:a.droppedAttributesCount,events:a.events.map(i=>lu(i,n)),droppedEventsCount:a.droppedEventsCount,status:{code:l.code,message:l.message},links:a.links.map(i=>uu(i,n)),droppedLinksCount:a.droppedLinksCount}}Lt.sdkSpanToOtlpSpan=Fp;function uu(a,n){var o;return{attributes:a.attributes?(0,Wn.toAttributes)(a.attributes):[],spanId:n.encodeSpanContext(a.context.spanId),traceId:n.encodeSpanContext(a.context.traceId),traceState:(o=a.context.traceState)===null||o===void 0?void 0:o.serialize(),droppedAttributesCount:a.droppedAttributesCount||0}}Lt.toOtlpLink=uu;function lu(a,n){return{attributes:a.attributes?(0,Wn.toAttributes)(a.attributes):[],name:a.name,timeUnixNano:n.encodeHrTime(a.time),droppedAttributesCount:a.droppedAttributesCount||0}}Lt.toOtlpSpanEvent=lu});var yu=m(Q=>{"use strict";Object.defineProperty(Q,"__esModule",{value:!0});Q.getOtlpEncoder=Q.encodeAsString=Q.encodeAsLongBits=Q.toLongBits=Q.hrTimeToNanos=void 0;var Ir=k(),qp=BigInt(1e9);function $n(a){return BigInt(a[0])*qp+BigInt(a[1])}Q.hrTimeToNanos=$n;function pu(a){let n=Number(BigInt.asUintN(32,a)),o=Number(BigInt.asUintN(32,a>>BigInt(32)));return{low:n,high:o}}Q.toLongBits=pu;function Qn(a){let n=$n(a);return pu(n)}Q.encodeAsLongBits=Qn;function fu(a){return $n(a).toString()}Q.encodeAsString=fu;var Kp=typeof BigInt<"u"?fu:Ir.hrTimeToNanoseconds;function su(a){return a}function du(a){if(a!==void 0)return(0,Ir.hexToBase64)(a)}var Xp={encodeHrTime:Qn,encodeSpanContext:Ir.hexToBase64,encodeOptionalSpanContext:du};function Yp(a){var n,o;if(a===void 0)return Xp;let c=(n=a.useLongBits)!==null&&n!==void 0?n:!0,l=(o=a.useHex)!==null&&o!==void 0?o:!1;return{encodeHrTime:c?Qn:Kp,encodeSpanContext:l?su:Ir.hexToBase64,encodeOptionalSpanContext:l?su:du}}Q.getOtlpEncoder=Yp});var Zn=m(wr=>{"use strict";Object.defineProperty(wr,"__esModule",{value:!0});wr.createExportTraceServiceRequest=void 0;var Jp=zn(),zp=cu(),Wp=yu();function $p(a,n){let o=(0,Wp.getOtlpEncoder)(n);return{resourceSpans:Zp(a,o)}}wr.createExportTraceServiceRequest=$p;function Qp(a){let n=new Map;for(let o of a){let c=n.get(o.resource);c||(c=new Map,n.set(o.resource,c));let l=`${o.instrumentationLibrary.name}@${o.instrumentationLibrary.version||""}:${o.instrumentationLibrary.schemaUrl||""}`,i=c.get(l);i||(i=[],c.set(l,i)),i.push(o)}return n}function Zp(a,n){let o=Qp(a),c=[],l=o.entries(),i=l.next();for(;!i.done;){let[e,t]=i.value,r=[],u=t.values(),s=u.next();for(;!s.done;){let v=s.value;if(v.length>0){let{name:g,version:x,schemaUrl:I}=v[0].instrumentationLibrary,F=v.map(R=>(0,zp.sdkSpanToOtlpSpan)(R,n));r.push({scope:{name:g,version:x},spans:F,schemaUrl:I})}s=u.next()}let d={resource:{attributes:(0,Jp.toAttributes)(e.attributes),droppedAttributesCount:0},scopeSpans:r,schemaUrl:void 0};c.push(d),i=l.next()}return c}});var Te=m(M=>{"use strict";Object.defineProperty(M,"__esModule",{value:!0});M.parseRetryAfterToMills=M.isExportRetryable=M.invalidTimeout=M.configureExporterTimeout=M.appendRootPathToUrlIfNeeded=M.appendResourcePathToUrl=M.parseHeaders=M.DEFAULT_EXPORT_BACKOFF_MULTIPLIER=M.DEFAULT_EXPORT_MAX_BACKOFF=M.DEFAULT_EXPORT_INITIAL_BACKOFF=M.DEFAULT_EXPORT_MAX_ATTEMPTS=void 0;var to=(b(),D(y)),hu=k(),mu=1e4;M.DEFAULT_EXPORT_MAX_ATTEMPTS=5;M.DEFAULT_EXPORT_INITIAL_BACKOFF=1e3;M.DEFAULT_EXPORT_MAX_BACKOFF=5e3;M.DEFAULT_EXPORT_BACKOFF_MULTIPLIER=1.5;function tf(a={}){let n={};return Object.entries(a).forEach(([o,c])=>{typeof c<"u"?n[o]=String(c):to.diag.warn(`Header "${o}" has wrong value and will be ignored`)}),n}M.parseHeaders=tf;function ef(a,n){return a.endsWith("/")||(a=a+"/"),a+n}M.appendResourcePathToUrl=ef;function rf(a){try{let n=new URL(a);return n.pathname===""&&(n.pathname=n.pathname+"/"),n.toString()}catch{return to.diag.warn(`Could not parse export URL: '${a}'`),a}}M.appendRootPathToUrlIfNeeded=rf;function nf(a){return typeof a=="number"?a<=0?eo(a,mu):a:of()}M.configureExporterTimeout=nf;function of(){var a;let n=Number((a=(0,hu.getEnv)().OTEL_EXPORTER_OTLP_TRACES_TIMEOUT)!==null&&a!==void 0?a:(0,hu.getEnv)().OTEL_EXPORTER_OTLP_TIMEOUT);return n<=0?eo(n,mu):n}function eo(a,n){return to.diag.warn("Timeout must be greater than 0",a),n}M.invalidTimeout=eo;function af(a){return[429,502,503,504].includes(a)}M.isExportRetryable=af;function uf(a){if(a==null)return-1;let n=Number.parseInt(a,10);if(Number.isInteger(n))return n>0?n*1e3:-1;let o=new Date(a).getTime()-Date.now();return o>=0?o:0}M.parseRetryAfterToMills=uf});var Ur=m(Cr=>{"use strict";Object.defineProperty(Cr,"__esModule",{value:!0});Cr.OTLPExporterBase=void 0;var vu=(b(),D(y)),Oe=k(),lf=Te(),ro=class{constructor(n={}){this._sendingPromises=[],this.url=this.getDefaultUrl(n),typeof n.hostname=="string"&&(this.hostname=n.hostname),this.shutdown=this.shutdown.bind(this),this._shutdownOnce=new Oe.BindOnceFuture(this._shutdown,this),this._concurrencyLimit=typeof n.concurrencyLimit=="number"?n.concurrencyLimit:30,this.timeoutMillis=(0,lf.configureExporterTimeout)(n.timeoutMillis),this.onInit(n)}export(n,o){if(this._shutdownOnce.isCalled){o({code:Oe.ExportResultCode.FAILED,error:new Error("Exporter has been shutdown")});return}if(this._sendingPromises.length>=this._concurrencyLimit){o({code:Oe.ExportResultCode.FAILED,error:new Error("Concurrent export limit reached")});return}this._export(n).then(()=>{o({code:Oe.ExportResultCode.SUCCESS})}).catch(c=>{o({code:Oe.ExportResultCode.FAILED,error:c})})}_export(n){return new Promise((o,c)=>{try{vu.diag.debug("items to be sent",n),this.send(n,o,c)}catch(l){c(l)}})}shutdown(){return this._shutdownOnce.call()}forceFlush(){return Promise.all(this._sendingPromises).then(()=>{})}_shutdown(){return vu.diag.debug("shutdown started"),this.onShutdown(),this.forceFlush()}};Cr.OTLPExporterBase=ro});var io=m(Dr=>{"use strict";Object.defineProperty(Dr,"__esModule",{value:!0});Dr.OTLPExporterError=void 0;var oo=class extends Error{constructor(n,o,c){super(n),this.name="OTLPExporterError",this.data=c,this.code=o}};Dr.OTLPExporterError=oo});var ao=m(oe=>{"use strict";Object.defineProperty(oe,"__esModule",{value:!0});oe.sendWithXhr=oe.sendWithBeacon=void 0;var bu=(b(),D(y)),ge=io(),ne=Te();function pf(a,n,o,c,l){if(navigator.sendBeacon(n,new Blob([a],o)))bu.diag.debug("sendBeacon - can send",a),c();else{let i=new ge.OTLPExporterError(`sendBeacon - cannot send ${a}`);l(i)}}oe.sendWithBeacon=pf;function ff(a,n,o,c,l,i){let e,t,r=!1,u=setTimeout(()=>{if(clearTimeout(e),r=!0,t.readyState===XMLHttpRequest.DONE){let d=new ge.OTLPExporterError("Request Timeout");i(d)}else t.abort()},c),s=(d=ne.DEFAULT_EXPORT_MAX_ATTEMPTS,v=ne.DEFAULT_EXPORT_INITIAL_BACKOFF)=>{t=new XMLHttpRequest,t.open("POST",n),Object.entries(Object.assign(Object.assign({},{Accept:"application/json","Content-Type":"application/json"}),o)).forEach(([x,I])=>{t.setRequestHeader(x,I)}),t.send(a),t.onreadystatechange=()=>{if(t.readyState===XMLHttpRequest.DONE&&r===!1)if(t.status>=200&&t.status<=299)bu.diag.debug("xhr success",a),l(),clearTimeout(u),clearTimeout(e);else if(t.status&&(0,ne.isExportRetryable)(t.status)&&d>0){let x;v=ne.DEFAULT_EXPORT_BACKOFF_MULTIPLIER*v,t.getResponseHeader("Retry-After")?x=(0,ne.parseRetryAfterToMills)(t.getResponseHeader("Retry-After")):x=Math.round(Math.random()*(ne.DEFAULT_EXPORT_MAX_BACKOFF-v)+v),e=setTimeout(()=>{s(d-1,v)},x)}else{let x=new ge.OTLPExporterError(`Failed to export with XHR (status: ${t.status})`,t.status);i(x),clearTimeout(u),clearTimeout(e)}},t.onabort=()=>{if(r){let x=new ge.OTLPExporterError("Request Timeout");i(x)}clearTimeout(u),clearTimeout(e)},t.onerror=()=>{if(r){let x=new ge.OTLPExporterError("Request Timeout");i(x)}clearTimeout(u),clearTimeout(e)}};s()}oe.sendWithXhr=ff});var Tu=m(Br=>{"use strict";Object.defineProperty(Br,"__esModule",{value:!0});Br.OTLPExporterBrowserBase=void 0;var df=Ur(),yf=Te(),Su=ao(),hf=(b(),D(y)),kr=k(),uo=class extends df.OTLPExporterBase{constructor(n={}){super(n),this._useXHR=!1,this._useXHR=!!n.headers||typeof navigator.sendBeacon!="function",this._useXHR?this._headers=Object.assign({},(0,yf.parseHeaders)(n.headers),kr.baggageUtils.parseKeyPairsIntoRecord((0,kr.getEnv)().OTEL_EXPORTER_OTLP_HEADERS)):this._headers={}}onInit(){kr._globalThis.addEventListener("unload",this.shutdown)}onShutdown(){kr._globalThis.removeEventListener("unload",this.shutdown)}send(n,o,c){if(this._shutdownOnce.isCalled){hf.diag.debug("Shutdown already started. Cannot send objects");return}let l=this.convert(n),i=JSON.stringify(l),e=new Promise((r,u)=>{this._useXHR?(0,Su.sendWithXhr)(i,this.url,this._headers,this.timeoutMillis,r,u):(0,Su.sendWithBeacon)(i,this.url,{type:"application/json"},r,u)}).then(o,c);this._sendingPromises.push(e);let t=()=>{let r=this._sendingPromises.indexOf(e);this._sendingPromises.splice(r,1)};e.then(t,t)}};Br.OTLPExporterBrowserBase=uo});var Ou=m(ie=>{"use strict";Object.defineProperty(ie,"__esModule",{value:!0});ie.sendWithXhr=ie.OTLPExporterBrowserBase=void 0;var mf=Tu();Object.defineProperty(ie,"OTLPExporterBrowserBase",{enumerable:!0,get:function(){return mf.OTLPExporterBrowserBase}});var vf=ao();Object.defineProperty(ie,"sendWithXhr",{enumerable:!0,get:function(){return vf.sendWithXhr}})});var gu=m(B=>{"use strict";var _f=B&&B.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),Ef=B&&B.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&_f(n,a,o)};Object.defineProperty(B,"__esModule",{value:!0});B.invalidTimeout=B.configureExporterTimeout=B.appendRootPathToUrlIfNeeded=B.appendResourcePathToUrl=B.parseHeaders=B.OTLPExporterError=B.OTLPExporterBase=void 0;Ef(Ou(),B);var bf=Ur();Object.defineProperty(B,"OTLPExporterBase",{enumerable:!0,get:function(){return bf.OTLPExporterBase}});var Sf=io();Object.defineProperty(B,"OTLPExporterError",{enumerable:!0,get:function(){return Sf.OTLPExporterError}});var Ae=Te();Object.defineProperty(B,"parseHeaders",{enumerable:!0,get:function(){return Ae.parseHeaders}});Object.defineProperty(B,"appendResourcePathToUrl",{enumerable:!0,get:function(){return Ae.appendResourcePathToUrl}});Object.defineProperty(B,"appendRootPathToUrlIfNeeded",{enumerable:!0,get:function(){return Ae.appendRootPathToUrlIfNeeded}});Object.defineProperty(B,"configureExporterTimeout",{enumerable:!0,get:function(){return Ae.configureExporterTimeout}});Object.defineProperty(B,"invalidTimeout",{enumerable:!0,get:function(){return Ae.invalidTimeout}})});var Nu=m((cv,Au)=>{"use strict";Au.exports=Tf;function Tf(a,n){for(var o=new Array(arguments.length-1),c=0,l=2,i=!0;l<arguments.length;)o[c++]=arguments[l++];return new Promise(function(t,r){o[c]=function(s){if(i)if(i=!1,s)r(s);else{for(var d=new Array(arguments.length-1),v=0;v<d.length;)d[v++]=arguments[v];t.apply(null,d)}};try{a.apply(n||null,o)}catch(u){i&&(i=!1,r(u))}})}});var Lu=m(Ru=>{"use strict";var Vr=Ru;Vr.length=function(n){var o=n.length;if(!o)return 0;for(var c=0;--o%4>1&&n.charAt(o)==="=";)++c;return Math.ceil(n.length*3)/4-c};var ae=new Array(64),xu=new Array(123);for(ot=0;ot<64;)xu[ae[ot]=ot<26?ot+65:ot<52?ot+71:ot<62?ot-4:ot-59|43]=ot++;var ot;Vr.encode=function(n,o,c){for(var l=null,i=[],e=0,t=0,r;o<c;){var u=n[o++];switch(t){case 0:i[e++]=ae[u>>2],r=(u&3)<<4,t=1;break;case 1:i[e++]=ae[r|u>>4],r=(u&15)<<2,t=2;break;case 2:i[e++]=ae[r|u>>6],i[e++]=ae[u&63],t=0;break}e>8191&&((l||(l=[])).push(String.fromCharCode.apply(String,i)),e=0)}return t&&(i[e++]=ae[r],i[e++]=61,t===1&&(i[e++]=61)),l?(e&&l.push(String.fromCharCode.apply(String,i.slice(0,e))),l.join("")):String.fromCharCode.apply(String,i.slice(0,e))};var Pu="invalid encoding";Vr.decode=function(n,o,c){for(var l=c,i=0,e,t=0;t<n.length;){var r=n.charCodeAt(t++);if(r===61&&i>1)break;if((r=xu[r])===void 0)throw Error(Pu);switch(i){case 0:e=r,i=1;break;case 1:o[c++]=e<<2|(r&48)>>4,e=r,i=2;break;case 2:o[c++]=(e&15)<<4|(r&60)>>2,e=r,i=3;break;case 3:o[c++]=(e&3)<<6|r,i=0;break}}if(i===1)throw Error(Pu);return c-l};Vr.test=function(n){return/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(n)}});var wu=m((pv,Iu)=>{"use strict";Iu.exports=Gr;function Gr(){this._listeners={}}Gr.prototype.on=function(n,o,c){return(this._listeners[n]||(this._listeners[n]=[])).push({fn:o,ctx:c||this}),this};Gr.prototype.off=function(n,o){if(n===void 0)this._listeners={};else if(o===void 0)this._listeners[n]=[];else for(var c=this._listeners[n],l=0;l<c.length;)c[l].fn===o?c.splice(l,1):++l;return this};Gr.prototype.emit=function(n){var o=this._listeners[n];if(o){for(var c=[],l=1;l<arguments.length;)c.push(arguments[l++]);for(l=0;l<o.length;)o[l].fn.apply(o[l++].ctx,c)}return this}});var Vu=m((fv,Bu)=>{"use strict";Bu.exports=Cu(Cu);function Cu(a){return typeof Float32Array<"u"?function(){var n=new Float32Array([-0]),o=new Uint8Array(n.buffer),c=o[3]===128;function l(r,u,s){n[0]=r,u[s]=o[0],u[s+1]=o[1],u[s+2]=o[2],u[s+3]=o[3]}function i(r,u,s){n[0]=r,u[s]=o[3],u[s+1]=o[2],u[s+2]=o[1],u[s+3]=o[0]}a.writeFloatLE=c?l:i,a.writeFloatBE=c?i:l;function e(r,u){return o[0]=r[u],o[1]=r[u+1],o[2]=r[u+2],o[3]=r[u+3],n[0]}function t(r,u){return o[3]=r[u],o[2]=r[u+1],o[1]=r[u+2],o[0]=r[u+3],n[0]}a.readFloatLE=c?e:t,a.readFloatBE=c?t:e}():function(){function n(c,l,i,e){var t=l<0?1:0;if(t&&(l=-l),l===0)c(1/l>0?0:2147483648,i,e);else if(isNaN(l))c(2143289344,i,e);else if(l>34028234663852886e22)c((t<<31|2139095040)>>>0,i,e);else if(l<11754943508222875e-54)c((t<<31|Math.round(l/1401298464324817e-60))>>>0,i,e);else{var r=Math.floor(Math.log(l)/Math.LN2),u=Math.round(l*Math.pow(2,-r)*8388608)&8388607;c((t<<31|r+127<<23|u)>>>0,i,e)}}a.writeFloatLE=n.bind(null,Uu),a.writeFloatBE=n.bind(null,Mu);function o(c,l,i){var e=c(l,i),t=(e>>31)*2+1,r=e>>>23&255,u=e&8388607;return r===255?u?NaN:t*(1/0):r===0?t*1401298464324817e-60*u:t*Math.pow(2,r-150)*(u+8388608)}a.readFloatLE=o.bind(null,Du),a.readFloatBE=o.bind(null,ku)}(),typeof Float64Array<"u"?function(){var n=new Float64Array([-0]),o=new Uint8Array(n.buffer),c=o[7]===128;function l(r,u,s){n[0]=r,u[s]=o[0],u[s+1]=o[1],u[s+2]=o[2],u[s+3]=o[3],u[s+4]=o[4],u[s+5]=o[5],u[s+6]=o[6],u[s+7]=o[7]}function i(r,u,s){n[0]=r,u[s]=o[7],u[s+1]=o[6],u[s+2]=o[5],u[s+3]=o[4],u[s+4]=o[3],u[s+5]=o[2],u[s+6]=o[1],u[s+7]=o[0]}a.writeDoubleLE=c?l:i,a.writeDoubleBE=c?i:l;function e(r,u){return o[0]=r[u],o[1]=r[u+1],o[2]=r[u+2],o[3]=r[u+3],o[4]=r[u+4],o[5]=r[u+5],o[6]=r[u+6],o[7]=r[u+7],n[0]}function t(r,u){return o[7]=r[u],o[6]=r[u+1],o[5]=r[u+2],o[4]=r[u+3],o[3]=r[u+4],o[2]=r[u+5],o[1]=r[u+6],o[0]=r[u+7],n[0]}a.readDoubleLE=c?e:t,a.readDoubleBE=c?t:e}():function(){function n(c,l,i,e,t,r){var u=e<0?1:0;if(u&&(e=-e),e===0)c(0,t,r+l),c(1/e>0?0:2147483648,t,r+i);else if(isNaN(e))c(0,t,r+l),c(2146959360,t,r+i);else if(e>17976931348623157e292)c(0,t,r+l),c((u<<31|2146435072)>>>0,t,r+i);else{var s;if(e<22250738585072014e-324)s=e/5e-324,c(s>>>0,t,r+l),c((u<<31|s/4294967296)>>>0,t,r+i);else{var d=Math.floor(Math.log(e)/Math.LN2);d===1024&&(d=1023),s=e*Math.pow(2,-d),c(s*4503599627370496>>>0,t,r+l),c((u<<31|d+1023<<20|s*1048576&1048575)>>>0,t,r+i)}}}a.writeDoubleLE=n.bind(null,Uu,0,4),a.writeDoubleBE=n.bind(null,Mu,4,0);function o(c,l,i,e,t){var r=c(e,t+l),u=c(e,t+i),s=(u>>31)*2+1,d=u>>>20&2047,v=4294967296*(u&1048575)+r;return d===2047?v?NaN:s*(1/0):d===0?s*5e-324*v:s*Math.pow(2,d-1075)*(v+4503599627370496)}a.readDoubleLE=o.bind(null,Du,0,4),a.readDoubleBE=o.bind(null,ku,4,0)}(),a}function Uu(a,n,o){n[o]=a&255,n[o+1]=a>>>8&255,n[o+2]=a>>>16&255,n[o+3]=a>>>24}function Mu(a,n,o){n[o]=a>>>24,n[o+1]=a>>>16&255,n[o+2]=a>>>8&255,n[o+3]=a&255}function Du(a,n){return(a[n]|a[n+1]<<8|a[n+2]<<16|a[n+3]<<24)>>>0}function ku(a,n){return(a[n]<<24|a[n+1]<<16|a[n+2]<<8|a[n+3])>>>0}});var Hu=m((dv,Gu)=>{"use strict";Gu.exports=Of;function Of(a){return null}});var Fu=m(ju=>{"use strict";var lo=ju;lo.length=function(n){for(var o=0,c=0,l=0;l<n.length;++l)c=n.charCodeAt(l),c<128?o+=1:c<2048?o+=2:(c&64512)===55296&&(n.charCodeAt(l+1)&64512)===56320?(++l,o+=4):o+=3;return o};lo.read=function(n,o,c){var l=c-o;if(l<1)return"";for(var i=null,e=[],t=0,r;o<c;)r=n[o++],r<128?e[t++]=r:r>191&&r<224?e[t++]=(r&31)<<6|n[o++]&63:r>239&&r<365?(r=((r&7)<<18|(n[o++]&63)<<12|(n[o++]&63)<<6|n[o++]&63)-65536,e[t++]=55296+(r>>10),e[t++]=56320+(r&1023)):e[t++]=(r&15)<<12|(n[o++]&63)<<6|n[o++]&63,t>8191&&((i||(i=[])).push(String.fromCharCode.apply(String,e)),t=0);return i?(t&&i.push(String.fromCharCode.apply(String,e.slice(0,t))),i.join("")):String.fromCharCode.apply(String,e.slice(0,t))};lo.write=function(n,o,c){for(var l=c,i,e,t=0;t<n.length;++t)i=n.charCodeAt(t),i<128?o[c++]=i:i<2048?(o[c++]=i>>6|192,o[c++]=i&63|128):(i&64512)===55296&&((e=n.charCodeAt(t+1))&64512)===56320?(i=65536+((i&1023)<<10)+(e&1023),++t,o[c++]=i>>18|240,o[c++]=i>>12&63|128,o[c++]=i>>6&63|128,o[c++]=i&63|128):(o[c++]=i>>12|224,o[c++]=i>>6&63|128,o[c++]=i&63|128);return c-l}});var Ku=m((hv,qu)=>{"use strict";qu.exports=gf;function gf(a,n,o){var c=o||8192,l=c>>>1,i=null,e=c;return function(r){if(r<1||r>l)return a(r);e+r>c&&(i=a(c),e=0);var u=n.call(i,e,e+=r);return e&7&&(e=(e|7)+1),u}}});var Yu=m((mv,Xu)=>{"use strict";Xu.exports=H;var Ne=wt();function H(a,n){this.lo=a>>>0,this.hi=n>>>0}var Ht=H.zero=new H(0,0);Ht.toNumber=function(){return 0};Ht.zzEncode=Ht.zzDecode=function(){return this};Ht.length=function(){return 1};var Af=H.zeroHash="\0\0\0\0\0\0\0\0";H.fromNumber=function(n){if(n===0)return Ht;var o=n<0;o&&(n=-n);var c=n>>>0,l=(n-c)/4294967296>>>0;return o&&(l=~l>>>0,c=~c>>>0,++c>4294967295&&(c=0,++l>4294967295&&(l=0))),new H(c,l)};H.from=function(n){if(typeof n=="number")return H.fromNumber(n);if(Ne.isString(n))if(Ne.Long)n=Ne.Long.fromString(n);else return H.fromNumber(parseInt(n,10));return n.low||n.high?new H(n.low>>>0,n.high>>>0):Ht};H.prototype.toNumber=function(n){if(!n&&this.hi>>>31){var o=~this.lo+1>>>0,c=~this.hi>>>0;return o||(c=c+1>>>0),-(o+c*4294967296)}return this.lo+this.hi*4294967296};H.prototype.toLong=function(n){return Ne.Long?new Ne.Long(this.lo|0,this.hi|0,!!n):{low:this.lo|0,high:this.hi|0,unsigned:!!n}};var It=String.prototype.charCodeAt;H.fromHash=function(n){return n===Af?Ht:new H((It.call(n,0)|It.call(n,1)<<8|It.call(n,2)<<16|It.call(n,3)<<24)>>>0,(It.call(n,4)|It.call(n,5)<<8|It.call(n,6)<<16|It.call(n,7)<<24)>>>0)};H.prototype.toHash=function(){return String.fromCharCode(this.lo&255,this.lo>>>8&255,this.lo>>>16&255,this.lo>>>24,this.hi&255,this.hi>>>8&255,this.hi>>>16&255,this.hi>>>24)};H.prototype.zzEncode=function(){var n=this.hi>>31;return this.hi=((this.hi<<1|this.lo>>>31)^n)>>>0,this.lo=(this.lo<<1^n)>>>0,this};H.prototype.zzDecode=function(){var n=-(this.lo&1);return this.lo=((this.lo>>>1|this.hi<<31)^n)>>>0,this.hi=(this.hi>>>1^n)>>>0,this};H.prototype.length=function(){var n=this.lo,o=(this.lo>>>28|this.hi<<4)>>>0,c=this.hi>>>24;return c===0?o===0?n<16384?n<128?1:2:n<2097152?3:4:o<16384?o<128?5:6:o<2097152?7:8:c<128?9:10}});var wt=m(co=>{"use strict";var _=co;_.asPromise=Nu();_.base64=Lu();_.EventEmitter=wu();_.float=Vu();_.inquire=Hu();_.utf8=Fu();_.pool=Ku();_.LongBits=Yu();_.isNode=!!(typeof global<"u"&&global&&global.process&&global.process.versions&&global.process.versions.node);_.global=_.isNode&&global||typeof window<"u"&&window||typeof self<"u"&&self||co;_.emptyArray=Object.freeze?Object.freeze([]):[];_.emptyObject=Object.freeze?Object.freeze({}):{};_.isInteger=Number.isInteger||function(n){return typeof n=="number"&&isFinite(n)&&Math.floor(n)===n};_.isString=function(n){return typeof n=="string"||n instanceof String};_.isObject=function(n){return n&&typeof n=="object"};_.isset=_.isSet=function(n,o){var c=n[o];return c!=null&&n.hasOwnProperty(o)?typeof c!="object"||(Array.isArray(c)?c.length:Object.keys(c).length)>0:!1};_.Buffer=function(){try{var a=_.inquire("buffer").Buffer;return a.prototype.utf8Write?a:null}catch{return null}}();_._Buffer_from=null;_._Buffer_allocUnsafe=null;_.newBuffer=function(n){return typeof n=="number"?_.Buffer?_._Buffer_allocUnsafe(n):new _.Array(n):_.Buffer?_._Buffer_from(n):typeof Uint8Array>"u"?n:new Uint8Array(n)};_.Array=typeof Uint8Array<"u"?Uint8Array:Array;_.Long=_.global.dcodeIO&&_.global.dcodeIO.Long||_.global.Long||_.inquire("long");_.key2Re=/^true|false|0|1$/;_.key32Re=/^-?(?:0|[1-9][0-9]*)$/;_.key64Re=/^(?:[\\x00-\\xff]{8}|-?(?:0|[1-9][0-9]*))$/;_.longToHash=function(n){return n?_.LongBits.from(n).toHash():_.LongBits.zeroHash};_.longFromHash=function(n,o){var c=_.LongBits.fromHash(n);return _.Long?_.Long.fromBits(c.lo,c.hi,o):c.toNumber(!!o)};function Ju(a,n,o){for(var c=Object.keys(n),l=0;l<c.length;++l)(a[c[l]]===void 0||!o)&&(a[c[l]]=n[c[l]]);return a}_.merge=Ju;_.lcFirst=function(n){return n.charAt(0).toLowerCase()+n.substring(1)};function zu(a){function n(o,c){if(!(this instanceof n))return new n(o,c);Object.defineProperty(this,"message",{get:function(){return o}}),Error.captureStackTrace?Error.captureStackTrace(this,n):Object.defineProperty(this,"stack",{value:new Error().stack||""}),c&&Ju(this,c)}return n.prototype=Object.create(Error.prototype,{constructor:{value:n,writable:!0,enumerable:!1,configurable:!0},name:{get:function(){return a},set:void 0,enumerable:!1,configurable:!0},toString:{value:function(){return this.name+": "+this.message},writable:!0,enumerable:!1,configurable:!0}}),n}_.newError=zu;_.ProtocolError=zu("ProtocolError");_.oneOfGetter=function(n){for(var o={},c=0;c<n.length;++c)o[n[c]]=1;return function(){for(var l=Object.keys(this),i=l.length-1;i>-1;--i)if(o[l[i]]===1&&this[l[i]]!==void 0&&this[l[i]]!==null)return l[i]}};_.oneOfSetter=function(n){return function(o){for(var c=0;c<n.length;++c)n[c]!==o&&delete this[n[c]]}};_.toJSONOptions={longs:String,enums:String,bytes:String,json:!0};_._configure=function(){var a=_.Buffer;if(!a){_._Buffer_from=_._Buffer_allocUnsafe=null;return}_._Buffer_from=a.from!==Uint8Array.from&&a.from||function(o,c){return new a(o,c)},_._Buffer_allocUnsafe=a.allocUnsafe||function(o){return new a(o)}}});var vo=m((_v,Zu)=>{"use strict";Zu.exports=A;var Z=wt(),so,Hr=Z.LongBits,Wu=Z.base64,$u=Z.utf8;function Pe(a,n,o){this.fn=a,this.len=n,this.next=void 0,this.val=o}function fo(){}function Nf(a){this.head=a.head,this.tail=a.tail,this.len=a.len,this.next=a.states}function A(){this.len=0,this.head=new Pe(fo,0,0),this.tail=this.head,this.states=null}var Qu=function(){return Z.Buffer?function(){return(A.create=function(){return new so})()}:function(){return new A}};A.create=Qu();A.alloc=function(n){return new Z.Array(n)};Z.Array!==Array&&(A.alloc=Z.pool(A.alloc,Z.Array.prototype.subarray));A.prototype._push=function(n,o,c){return this.tail=this.tail.next=new Pe(n,o,c),this.len+=o,this};function yo(a,n,o){n[o]=a&255}function Pf(a,n,o){for(;a>127;)n[o++]=a&127|128,a>>>=7;n[o]=a}function ho(a,n){this.len=a,this.next=void 0,this.val=n}ho.prototype=Object.create(Pe.prototype);ho.prototype.fn=Pf;A.prototype.uint32=function(n){return this.len+=(this.tail=this.tail.next=new ho((n=n>>>0)<128?1:n<16384?2:n<2097152?3:n<268435456?4:5,n)).len,this};A.prototype.int32=function(n){return n<0?this._push(mo,10,Hr.fromNumber(n)):this.uint32(n)};A.prototype.sint32=function(n){return this.uint32((n<<1^n>>31)>>>0)};function mo(a,n,o){for(;a.hi;)n[o++]=a.lo&127|128,a.lo=(a.lo>>>7|a.hi<<25)>>>0,a.hi>>>=7;for(;a.lo>127;)n[o++]=a.lo&127|128,a.lo=a.lo>>>7;n[o++]=a.lo}A.prototype.uint64=function(n){var o=Hr.from(n);return this._push(mo,o.length(),o)};A.prototype.int64=A.prototype.uint64;A.prototype.sint64=function(n){var o=Hr.from(n).zzEncode();return this._push(mo,o.length(),o)};A.prototype.bool=function(n){return this._push(yo,1,n?1:0)};function po(a,n,o){n[o]=a&255,n[o+1]=a>>>8&255,n[o+2]=a>>>16&255,n[o+3]=a>>>24}A.prototype.fixed32=function(n){return this._push(po,4,n>>>0)};A.prototype.sfixed32=A.prototype.fixed32;A.prototype.fixed64=function(n){var o=Hr.from(n);return this._push(po,4,o.lo)._push(po,4,o.hi)};A.prototype.sfixed64=A.prototype.fixed64;A.prototype.float=function(n){return this._push(Z.float.writeFloatLE,4,n)};A.prototype.double=function(n){return this._push(Z.float.writeDoubleLE,8,n)};var xf=Z.Array.prototype.set?function(n,o,c){o.set(n,c)}:function(n,o,c){for(var l=0;l<n.length;++l)o[c+l]=n[l]};A.prototype.bytes=function(n){var o=n.length>>>0;if(!o)return this._push(yo,1,0);if(Z.isString(n)){var c=A.alloc(o=Wu.length(n));Wu.decode(n,c,0),n=c}return this.uint32(o)._push(xf,o,n)};A.prototype.string=function(n){var o=$u.length(n);return o?this.uint32(o)._push($u.write,o,n):this._push(yo,1,0)};A.prototype.fork=function(){return this.states=new Nf(this),this.head=this.tail=new Pe(fo,0,0),this.len=0,this};A.prototype.reset=function(){return this.states?(this.head=this.states.head,this.tail=this.states.tail,this.len=this.states.len,this.states=this.states.next):(this.head=this.tail=new Pe(fo,0,0),this.len=0),this};A.prototype.ldelim=function(){var n=this.head,o=this.tail,c=this.len;return this.reset().uint32(c),c&&(this.tail.next=n.next,this.tail=o,this.len+=c),this};A.prototype.finish=function(){for(var n=this.head.next,o=this.constructor.alloc(this.len),c=0;n;)n.fn(n.val,o,c),c+=n.len,n=n.next;return o};A._configure=function(a){so=a,A.create=Qu(),so._configure()}});var rl=m((Ev,el)=>{"use strict";el.exports=ct;var tl=vo();(ct.prototype=Object.create(tl.prototype)).constructor=ct;var Ct=wt();function ct(){tl.call(this)}ct._configure=function(){ct.alloc=Ct._Buffer_allocUnsafe,ct.writeBytesBuffer=Ct.Buffer&&Ct.Buffer.prototype instanceof Uint8Array&&Ct.Buffer.prototype.set.name==="set"?function(n,o,c){o.set(n,c)}:function(n,o,c){if(n.copy)n.copy(o,c,0,n.length);else for(var l=0;l<n.length;)o[c++]=n[l++]}};ct.prototype.bytes=function(n){Ct.isString(n)&&(n=Ct._Buffer_from(n,"base64"));var o=n.length>>>0;return this.uint32(o),o&&this._push(ct.writeBytesBuffer,o,n),this};function Rf(a,n,o){a.length<40?Ct.utf8.write(a,n,o):n.utf8Write?n.utf8Write(a,o):n.write(a,o)}ct.prototype.string=function(n){var o=Ct.Buffer.byteLength(n);return this.uint32(o),o&&this._push(Rf,o,n),this};ct._configure()});var bo=m((bv,ul)=>{"use strict";ul.exports=V;var it=wt(),Eo,il=it.LongBits,Lf=it.utf8;function at(a,n){return RangeError("index out of range: "+a.pos+" + "+(n||1)+" > "+a.len)}function V(a){this.buf=a,this.pos=0,this.len=a.length}var nl=typeof Uint8Array<"u"?function(n){if(n instanceof Uint8Array||Array.isArray(n))return new V(n);throw Error("illegal buffer")}:function(n){if(Array.isArray(n))return new V(n);throw Error("illegal buffer")},al=function(){return it.Buffer?function(o){return(V.create=function(l){return it.Buffer.isBuffer(l)?new Eo(l):nl(l)})(o)}:nl};V.create=al();V.prototype._slice=it.Array.prototype.subarray||it.Array.prototype.slice;V.prototype.uint32=function(){var n=4294967295;return function(){if(n=(this.buf[this.pos]&127)>>>0,this.buf[this.pos++]<128||(n=(n|(this.buf[this.pos]&127)<<7)>>>0,this.buf[this.pos++]<128)||(n=(n|(this.buf[this.pos]&127)<<14)>>>0,this.buf[this.pos++]<128)||(n=(n|(this.buf[this.pos]&127)<<21)>>>0,this.buf[this.pos++]<128)||(n=(n|(this.buf[this.pos]&15)<<28)>>>0,this.buf[this.pos++]<128))return n;if((this.pos+=5)>this.len)throw this.pos=this.len,at(this,10);return n}}();V.prototype.int32=function(){return this.uint32()|0};V.prototype.sint32=function(){var n=this.uint32();return n>>>1^-(n&1)|0};function _o(){var a=new il(0,0),n=0;if(this.len-this.pos>4){for(;n<4;++n)if(a.lo=(a.lo|(this.buf[this.pos]&127)<<n*7)>>>0,this.buf[this.pos++]<128)return a;if(a.lo=(a.lo|(this.buf[this.pos]&127)<<28)>>>0,a.hi=(a.hi|(this.buf[this.pos]&127)>>4)>>>0,this.buf[this.pos++]<128)return a;n=0}else{for(;n<3;++n){if(this.pos>=this.len)throw at(this);if(a.lo=(a.lo|(this.buf[this.pos]&127)<<n*7)>>>0,this.buf[this.pos++]<128)return a}return a.lo=(a.lo|(this.buf[this.pos++]&127)<<n*7)>>>0,a}if(this.len-this.pos>4){for(;n<5;++n)if(a.hi=(a.hi|(this.buf[this.pos]&127)<<n*7+3)>>>0,this.buf[this.pos++]<128)return a}else for(;n<5;++n){if(this.pos>=this.len)throw at(this);if(a.hi=(a.hi|(this.buf[this.pos]&127)<<n*7+3)>>>0,this.buf[this.pos++]<128)return a}throw Error("invalid varint encoding")}V.prototype.bool=function(){return this.uint32()!==0};function jr(a,n){return(a[n-4]|a[n-3]<<8|a[n-2]<<16|a[n-1]<<24)>>>0}V.prototype.fixed32=function(){if(this.pos+4>this.len)throw at(this,4);return jr(this.buf,this.pos+=4)};V.prototype.sfixed32=function(){if(this.pos+4>this.len)throw at(this,4);return jr(this.buf,this.pos+=4)|0};function ol(){if(this.pos+8>this.len)throw at(this,8);return new il(jr(this.buf,this.pos+=4),jr(this.buf,this.pos+=4))}V.prototype.float=function(){if(this.pos+4>this.len)throw at(this,4);var n=it.float.readFloatLE(this.buf,this.pos);return this.pos+=4,n};V.prototype.double=function(){if(this.pos+8>this.len)throw at(this,4);var n=it.float.readDoubleLE(this.buf,this.pos);return this.pos+=8,n};V.prototype.bytes=function(){var n=this.uint32(),o=this.pos,c=this.pos+n;if(c>this.len)throw at(this,n);if(this.pos+=n,Array.isArray(this.buf))return this.buf.slice(o,c);if(o===c){var l=it.Buffer;return l?l.alloc(0):new this.buf.constructor(0)}return this._slice.call(this.buf,o,c)};V.prototype.string=function(){var n=this.bytes();return Lf.read(n,0,n.length)};V.prototype.skip=function(n){if(typeof n=="number"){if(this.pos+n>this.len)throw at(this,n);this.pos+=n}else do if(this.pos>=this.len)throw at(this);while(this.buf[this.pos++]&128);return this};V.prototype.skipType=function(a){switch(a){case 0:this.skip();break;case 1:this.skip(8);break;case 2:this.skip(this.uint32());break;case 3:for(;(a=this.uint32()&7)!==4;)this.skipType(a);break;case 5:this.skip(4);break;default:throw Error("invalid wire type "+a+" at offset "+this.pos)}return this};V._configure=function(a){Eo=a,V.create=al(),Eo._configure();var n=it.Long?"toLong":"toNumber";it.merge(V.prototype,{int64:function(){return _o.call(this)[n](!1)},uint64:function(){return _o.call(this)[n](!0)},sint64:function(){return _o.call(this).zzDecode()[n](!1)},fixed64:function(){return ol.call(this)[n](!0)},sfixed64:function(){return ol.call(this)[n](!1)}})}});var pl=m((Sv,sl)=>{"use strict";sl.exports=jt;var cl=bo();(jt.prototype=Object.create(cl.prototype)).constructor=jt;var ll=wt();function jt(a){cl.call(this,a)}jt._configure=function(){ll.Buffer&&(jt.prototype._slice=ll.Buffer.prototype.slice)};jt.prototype.string=function(){var n=this.uint32();return this.buf.utf8Slice?this.buf.utf8Slice(this.pos,this.pos=Math.min(this.pos+n,this.len)):this.buf.toString("utf-8",this.pos,this.pos=Math.min(this.pos+n,this.len))};jt._configure()});var dl=m((Tv,fl)=>{"use strict";fl.exports=xe;var So=wt();(xe.prototype=Object.create(So.EventEmitter.prototype)).constructor=xe;function xe(a,n,o){if(typeof a!="function")throw TypeError("rpcImpl must be a function");So.EventEmitter.call(this),this.rpcImpl=a,this.requestDelimited=!!n,this.responseDelimited=!!o}xe.prototype.rpcCall=function a(n,o,c,l,i){if(!l)throw TypeError("request must be specified");var e=this;if(!i)return So.asPromise(a,e,n,o,c,l);if(!e.rpcImpl){setTimeout(function(){i(Error("already ended"))},0);return}try{return e.rpcImpl(n,o[e.requestDelimited?"encodeDelimited":"encode"](l).finish(),function(r,u){if(r)return e.emit("error",r,n),i(r);if(u===null){e.end(!0);return}if(!(u instanceof c))try{u=c[e.responseDelimited?"decodeDelimited":"decode"](u)}catch(s){return e.emit("error",s,n),i(s)}return e.emit("data",u,n),i(null,u)})}catch(t){e.emit("error",t,n),setTimeout(function(){i(t)},0);return}};xe.prototype.end=function(n){return this.rpcImpl&&(n||this.rpcImpl(null,null,null),this.rpcImpl=null,this.emit("end").off()),this}});var hl=m(yl=>{"use strict";var If=yl;If.Service=dl()});var vl=m((gv,ml)=>{"use strict";ml.exports={}});var bl=m(El=>{"use strict";var J=El;J.build="minimal";J.Writer=vo();J.BufferWriter=rl();J.Reader=bo();J.BufferReader=pl();J.util=wt();J.rpc=hl();J.roots=vl();J.configure=_l;function _l(){J.util._configure(),J.Writer._configure(J.BufferWriter),J.Reader._configure(J.BufferReader)}_l()});var Tl=m((Nv,Sl)=>{"use strict";Sl.exports=bl()});var gl=m((Pv,Ol)=>{"use strict";var E=Tl(),h=E.Reader,S=E.Writer,f=E.util,p=E.roots.default||(E.roots.default={});p.opentelemetry=function(){var a={};return a.proto=function(){var n={};return n.common=function(){var o={};return o.v1=function(){var c={};return c.AnyValue=function(){function l(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.stringValue=null,l.prototype.boolValue=null,l.prototype.intValue=null,l.prototype.doubleValue=null,l.prototype.arrayValue=null,l.prototype.kvlistValue=null,l.prototype.bytesValue=null;var i;return Object.defineProperty(l.prototype,"value",{get:f.oneOfGetter(i=["stringValue","boolValue","intValue","doubleValue","arrayValue","kvlistValue","bytesValue"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){return r||(r=S.create()),t.stringValue!=null&&Object.hasOwnProperty.call(t,"stringValue")&&r.uint32(10).string(t.stringValue),t.boolValue!=null&&Object.hasOwnProperty.call(t,"boolValue")&&r.uint32(16).bool(t.boolValue),t.intValue!=null&&Object.hasOwnProperty.call(t,"intValue")&&r.uint32(24).int64(t.intValue),t.doubleValue!=null&&Object.hasOwnProperty.call(t,"doubleValue")&&r.uint32(33).double(t.doubleValue),t.arrayValue!=null&&Object.hasOwnProperty.call(t,"arrayValue")&&p.opentelemetry.proto.common.v1.ArrayValue.encode(t.arrayValue,r.uint32(42).fork()).ldelim(),t.kvlistValue!=null&&Object.hasOwnProperty.call(t,"kvlistValue")&&p.opentelemetry.proto.common.v1.KeyValueList.encode(t.kvlistValue,r.uint32(50).fork()).ldelim(),t.bytesValue!=null&&Object.hasOwnProperty.call(t,"bytesValue")&&r.uint32(58).bytes(t.bytesValue),r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.common.v1.AnyValue;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.stringValue=t.string();break}case 2:{s.boolValue=t.bool();break}case 3:{s.intValue=t.int64();break}case 4:{s.doubleValue=t.double();break}case 5:{s.arrayValue=p.opentelemetry.proto.common.v1.ArrayValue.decode(t,t.uint32());break}case 6:{s.kvlistValue=p.opentelemetry.proto.common.v1.KeyValueList.decode(t,t.uint32());break}case 7:{s.bytesValue=t.bytes();break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.stringValue!=null&&t.hasOwnProperty("stringValue")&&(r.value=1,!f.isString(t.stringValue)))return"stringValue: string expected";if(t.boolValue!=null&&t.hasOwnProperty("boolValue")){if(r.value===1)return"value: multiple values";if(r.value=1,typeof t.boolValue!="boolean")return"boolValue: boolean expected"}if(t.intValue!=null&&t.hasOwnProperty("intValue")){if(r.value===1)return"value: multiple values";if(r.value=1,!f.isInteger(t.intValue)&&!(t.intValue&&f.isInteger(t.intValue.low)&&f.isInteger(t.intValue.high)))return"intValue: integer|Long expected"}if(t.doubleValue!=null&&t.hasOwnProperty("doubleValue")){if(r.value===1)return"value: multiple values";if(r.value=1,typeof t.doubleValue!="number")return"doubleValue: number expected"}if(t.arrayValue!=null&&t.hasOwnProperty("arrayValue")){if(r.value===1)return"value: multiple values";r.value=1;{var u=p.opentelemetry.proto.common.v1.ArrayValue.verify(t.arrayValue);if(u)return"arrayValue."+u}}if(t.kvlistValue!=null&&t.hasOwnProperty("kvlistValue")){if(r.value===1)return"value: multiple values";r.value=1;{var u=p.opentelemetry.proto.common.v1.KeyValueList.verify(t.kvlistValue);if(u)return"kvlistValue."+u}}if(t.bytesValue!=null&&t.hasOwnProperty("bytesValue")){if(r.value===1)return"value: multiple values";if(r.value=1,!(t.bytesValue&&typeof t.bytesValue.length=="number"||f.isString(t.bytesValue)))return"bytesValue: buffer expected"}return null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.common.v1.AnyValue)return t;var r=new p.opentelemetry.proto.common.v1.AnyValue;if(t.stringValue!=null&&(r.stringValue=String(t.stringValue)),t.boolValue!=null&&(r.boolValue=!!t.boolValue),t.intValue!=null&&(f.Long?(r.intValue=f.Long.fromValue(t.intValue)).unsigned=!1:typeof t.intValue=="string"?r.intValue=parseInt(t.intValue,10):typeof t.intValue=="number"?r.intValue=t.intValue:typeof t.intValue=="object"&&(r.intValue=new f.LongBits(t.intValue.low>>>0,t.intValue.high>>>0).toNumber())),t.doubleValue!=null&&(r.doubleValue=Number(t.doubleValue)),t.arrayValue!=null){if(typeof t.arrayValue!="object")throw TypeError(".opentelemetry.proto.common.v1.AnyValue.arrayValue: object expected");r.arrayValue=p.opentelemetry.proto.common.v1.ArrayValue.fromObject(t.arrayValue)}if(t.kvlistValue!=null){if(typeof t.kvlistValue!="object")throw TypeError(".opentelemetry.proto.common.v1.AnyValue.kvlistValue: object expected");r.kvlistValue=p.opentelemetry.proto.common.v1.KeyValueList.fromObject(t.kvlistValue)}return t.bytesValue!=null&&(typeof t.bytesValue=="string"?f.base64.decode(t.bytesValue,r.bytesValue=f.newBuffer(f.base64.length(t.bytesValue)),0):t.bytesValue.length>=0&&(r.bytesValue=t.bytesValue)),r},l.toObject=function(t,r){r||(r={});var u={};return t.stringValue!=null&&t.hasOwnProperty("stringValue")&&(u.stringValue=t.stringValue,r.oneofs&&(u.value="stringValue")),t.boolValue!=null&&t.hasOwnProperty("boolValue")&&(u.boolValue=t.boolValue,r.oneofs&&(u.value="boolValue")),t.intValue!=null&&t.hasOwnProperty("intValue")&&(typeof t.intValue=="number"?u.intValue=r.longs===String?String(t.intValue):t.intValue:u.intValue=r.longs===String?f.Long.prototype.toString.call(t.intValue):r.longs===Number?new f.LongBits(t.intValue.low>>>0,t.intValue.high>>>0).toNumber():t.intValue,r.oneofs&&(u.value="intValue")),t.doubleValue!=null&&t.hasOwnProperty("doubleValue")&&(u.doubleValue=r.json&&!isFinite(t.doubleValue)?String(t.doubleValue):t.doubleValue,r.oneofs&&(u.value="doubleValue")),t.arrayValue!=null&&t.hasOwnProperty("arrayValue")&&(u.arrayValue=p.opentelemetry.proto.common.v1.ArrayValue.toObject(t.arrayValue,r),r.oneofs&&(u.value="arrayValue")),t.kvlistValue!=null&&t.hasOwnProperty("kvlistValue")&&(u.kvlistValue=p.opentelemetry.proto.common.v1.KeyValueList.toObject(t.kvlistValue,r),r.oneofs&&(u.value="kvlistValue")),t.bytesValue!=null&&t.hasOwnProperty("bytesValue")&&(u.bytesValue=r.bytes===String?f.base64.encode(t.bytesValue,0,t.bytesValue.length):r.bytes===Array?Array.prototype.slice.call(t.bytesValue):t.bytesValue,r.oneofs&&(u.value="bytesValue")),u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.common.v1.AnyValue"},l}(),c.ArrayValue=function(){function l(i){if(this.values=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.values=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.values!=null&&e.values.length)for(var r=0;r<e.values.length;++r)p.opentelemetry.proto.common.v1.AnyValue.encode(e.values[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.common.v1.ArrayValue;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.values&&u.values.length||(u.values=[]),u.values.push(p.opentelemetry.proto.common.v1.AnyValue.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.values!=null&&e.hasOwnProperty("values")){if(!Array.isArray(e.values))return"values: array expected";for(var t=0;t<e.values.length;++t){var r=p.opentelemetry.proto.common.v1.AnyValue.verify(e.values[t]);if(r)return"values."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.common.v1.ArrayValue)return e;var t=new p.opentelemetry.proto.common.v1.ArrayValue;if(e.values){if(!Array.isArray(e.values))throw TypeError(".opentelemetry.proto.common.v1.ArrayValue.values: array expected");t.values=[];for(var r=0;r<e.values.length;++r){if(typeof e.values[r]!="object")throw TypeError(".opentelemetry.proto.common.v1.ArrayValue.values: object expected");t.values[r]=p.opentelemetry.proto.common.v1.AnyValue.fromObject(e.values[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.values=[]),e.values&&e.values.length){r.values=[];for(var u=0;u<e.values.length;++u)r.values[u]=p.opentelemetry.proto.common.v1.AnyValue.toObject(e.values[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.common.v1.ArrayValue"},l}(),c.KeyValueList=function(){function l(i){if(this.values=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.values=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.values!=null&&e.values.length)for(var r=0;r<e.values.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.values[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.common.v1.KeyValueList;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.values&&u.values.length||(u.values=[]),u.values.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.values!=null&&e.hasOwnProperty("values")){if(!Array.isArray(e.values))return"values: array expected";for(var t=0;t<e.values.length;++t){var r=p.opentelemetry.proto.common.v1.KeyValue.verify(e.values[t]);if(r)return"values."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.common.v1.KeyValueList)return e;var t=new p.opentelemetry.proto.common.v1.KeyValueList;if(e.values){if(!Array.isArray(e.values))throw TypeError(".opentelemetry.proto.common.v1.KeyValueList.values: array expected");t.values=[];for(var r=0;r<e.values.length;++r){if(typeof e.values[r]!="object")throw TypeError(".opentelemetry.proto.common.v1.KeyValueList.values: object expected");t.values[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.values[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.values=[]),e.values&&e.values.length){r.values=[];for(var u=0;u<e.values.length;++u)r.values[u]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.values[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.common.v1.KeyValueList"},l}(),c.KeyValue=function(){function l(i){if(i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.key=null,l.prototype.value=null,l.create=function(e){return new l(e)},l.encode=function(e,t){return t||(t=S.create()),e.key!=null&&Object.hasOwnProperty.call(e,"key")&&t.uint32(10).string(e.key),e.value!=null&&Object.hasOwnProperty.call(e,"value")&&p.opentelemetry.proto.common.v1.AnyValue.encode(e.value,t.uint32(18).fork()).ldelim(),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.common.v1.KeyValue;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.key=e.string();break}case 2:{u.value=p.opentelemetry.proto.common.v1.AnyValue.decode(e,e.uint32());break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.key!=null&&e.hasOwnProperty("key")&&!f.isString(e.key))return"key: string expected";if(e.value!=null&&e.hasOwnProperty("value")){var t=p.opentelemetry.proto.common.v1.AnyValue.verify(e.value);if(t)return"value."+t}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.common.v1.KeyValue)return e;var t=new p.opentelemetry.proto.common.v1.KeyValue;if(e.key!=null&&(t.key=String(e.key)),e.value!=null){if(typeof e.value!="object")throw TypeError(".opentelemetry.proto.common.v1.KeyValue.value: object expected");t.value=p.opentelemetry.proto.common.v1.AnyValue.fromObject(e.value)}return t},l.toObject=function(e,t){t||(t={});var r={};return t.defaults&&(r.key="",r.value=null),e.key!=null&&e.hasOwnProperty("key")&&(r.key=e.key),e.value!=null&&e.hasOwnProperty("value")&&(r.value=p.opentelemetry.proto.common.v1.AnyValue.toObject(e.value,t)),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.common.v1.KeyValue"},l}(),c.InstrumentationScope=function(){function l(i){if(this.attributes=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.name=null,l.prototype.version=null,l.prototype.attributes=f.emptyArray,l.prototype.droppedAttributesCount=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.name!=null&&Object.hasOwnProperty.call(e,"name")&&t.uint32(10).string(e.name),e.version!=null&&Object.hasOwnProperty.call(e,"version")&&t.uint32(18).string(e.version),e.attributes!=null&&e.attributes.length)for(var r=0;r<e.attributes.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[r],t.uint32(26).fork()).ldelim();return e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,"droppedAttributesCount")&&t.uint32(32).uint32(e.droppedAttributesCount),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.common.v1.InstrumentationScope;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.name=e.string();break}case 2:{u.version=e.string();break}case 3:{u.attributes&&u.attributes.length||(u.attributes=[]),u.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}case 4:{u.droppedAttributesCount=e.uint32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.name!=null&&e.hasOwnProperty("name")&&!f.isString(e.name))return"name: string expected";if(e.version!=null&&e.hasOwnProperty("version")&&!f.isString(e.version))return"version: string expected";if(e.attributes!=null&&e.hasOwnProperty("attributes")){if(!Array.isArray(e.attributes))return"attributes: array expected";for(var t=0;t<e.attributes.length;++t){var r=p.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(r)return"attributes."+r}}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(e.droppedAttributesCount)?"droppedAttributesCount: integer expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.common.v1.InstrumentationScope)return e;var t=new p.opentelemetry.proto.common.v1.InstrumentationScope;if(e.name!=null&&(t.name=String(e.name)),e.version!=null&&(t.version=String(e.version)),e.attributes){if(!Array.isArray(e.attributes))throw TypeError(".opentelemetry.proto.common.v1.InstrumentationScope.attributes: array expected");t.attributes=[];for(var r=0;r<e.attributes.length;++r){if(typeof e.attributes[r]!="object")throw TypeError(".opentelemetry.proto.common.v1.InstrumentationScope.attributes: object expected");t.attributes[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[r])}}return e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.attributes=[]),t.defaults&&(r.name="",r.version="",r.droppedAttributesCount=0),e.name!=null&&e.hasOwnProperty("name")&&(r.name=e.name),e.version!=null&&e.hasOwnProperty("version")&&(r.version=e.version),e.attributes&&e.attributes.length){r.attributes=[];for(var u=0;u<e.attributes.length;++u)r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[u],t)}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&(r.droppedAttributesCount=e.droppedAttributesCount),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.common.v1.InstrumentationScope"},l}(),c}(),o}(),n.resource=function(){var o={};return o.v1=function(){var c={};return c.Resource=function(){function l(i){if(this.attributes=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.attributes=f.emptyArray,l.prototype.droppedAttributesCount=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.attributes!=null&&e.attributes.length)for(var r=0;r<e.attributes.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[r],t.uint32(10).fork()).ldelim();return e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,"droppedAttributesCount")&&t.uint32(16).uint32(e.droppedAttributesCount),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.resource.v1.Resource;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.attributes&&u.attributes.length||(u.attributes=[]),u.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}case 2:{u.droppedAttributesCount=e.uint32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.attributes!=null&&e.hasOwnProperty("attributes")){if(!Array.isArray(e.attributes))return"attributes: array expected";for(var t=0;t<e.attributes.length;++t){var r=p.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(r)return"attributes."+r}}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(e.droppedAttributesCount)?"droppedAttributesCount: integer expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.resource.v1.Resource)return e;var t=new p.opentelemetry.proto.resource.v1.Resource;if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(".opentelemetry.proto.resource.v1.Resource.attributes: array expected");t.attributes=[];for(var r=0;r<e.attributes.length;++r){if(typeof e.attributes[r]!="object")throw TypeError(".opentelemetry.proto.resource.v1.Resource.attributes: object expected");t.attributes[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[r])}}return e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.attributes=[]),t.defaults&&(r.droppedAttributesCount=0),e.attributes&&e.attributes.length){r.attributes=[];for(var u=0;u<e.attributes.length;++u)r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[u],t)}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&(r.droppedAttributesCount=e.droppedAttributesCount),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.resource.v1.Resource"},l}(),c}(),o}(),n.trace=function(){var o={};return o.v1=function(){var c={};return c.TracesData=function(){function l(i){if(this.resourceSpans=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resourceSpans=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resourceSpans!=null&&e.resourceSpans.length)for(var r=0;r<e.resourceSpans.length;++r)p.opentelemetry.proto.trace.v1.ResourceSpans.encode(e.resourceSpans[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.trace.v1.TracesData;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resourceSpans&&u.resourceSpans.length||(u.resourceSpans=[]),u.resourceSpans.push(p.opentelemetry.proto.trace.v1.ResourceSpans.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resourceSpans!=null&&e.hasOwnProperty("resourceSpans")){if(!Array.isArray(e.resourceSpans))return"resourceSpans: array expected";for(var t=0;t<e.resourceSpans.length;++t){var r=p.opentelemetry.proto.trace.v1.ResourceSpans.verify(e.resourceSpans[t]);if(r)return"resourceSpans."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.trace.v1.TracesData)return e;var t=new p.opentelemetry.proto.trace.v1.TracesData;if(e.resourceSpans){if(!Array.isArray(e.resourceSpans))throw TypeError(".opentelemetry.proto.trace.v1.TracesData.resourceSpans: array expected");t.resourceSpans=[];for(var r=0;r<e.resourceSpans.length;++r){if(typeof e.resourceSpans[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.TracesData.resourceSpans: object expected");t.resourceSpans[r]=p.opentelemetry.proto.trace.v1.ResourceSpans.fromObject(e.resourceSpans[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.resourceSpans=[]),e.resourceSpans&&e.resourceSpans.length){r.resourceSpans=[];for(var u=0;u<e.resourceSpans.length;++u)r.resourceSpans[u]=p.opentelemetry.proto.trace.v1.ResourceSpans.toObject(e.resourceSpans[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.trace.v1.TracesData"},l}(),c.ResourceSpans=function(){function l(i){if(this.scopeSpans=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resource=null,l.prototype.scopeSpans=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resource!=null&&Object.hasOwnProperty.call(e,"resource")&&p.opentelemetry.proto.resource.v1.Resource.encode(e.resource,t.uint32(10).fork()).ldelim(),e.scopeSpans!=null&&e.scopeSpans.length)for(var r=0;r<e.scopeSpans.length;++r)p.opentelemetry.proto.trace.v1.ScopeSpans.encode(e.scopeSpans[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.trace.v1.ResourceSpans;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resource=p.opentelemetry.proto.resource.v1.Resource.decode(e,e.uint32());break}case 2:{u.scopeSpans&&u.scopeSpans.length||(u.scopeSpans=[]),u.scopeSpans.push(p.opentelemetry.proto.trace.v1.ScopeSpans.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resource!=null&&e.hasOwnProperty("resource")){var t=p.opentelemetry.proto.resource.v1.Resource.verify(e.resource);if(t)return"resource."+t}if(e.scopeSpans!=null&&e.hasOwnProperty("scopeSpans")){if(!Array.isArray(e.scopeSpans))return"scopeSpans: array expected";for(var r=0;r<e.scopeSpans.length;++r){var t=p.opentelemetry.proto.trace.v1.ScopeSpans.verify(e.scopeSpans[r]);if(t)return"scopeSpans."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.trace.v1.ResourceSpans)return e;var t=new p.opentelemetry.proto.trace.v1.ResourceSpans;if(e.resource!=null){if(typeof e.resource!="object")throw TypeError(".opentelemetry.proto.trace.v1.ResourceSpans.resource: object expected");t.resource=p.opentelemetry.proto.resource.v1.Resource.fromObject(e.resource)}if(e.scopeSpans){if(!Array.isArray(e.scopeSpans))throw TypeError(".opentelemetry.proto.trace.v1.ResourceSpans.scopeSpans: array expected");t.scopeSpans=[];for(var r=0;r<e.scopeSpans.length;++r){if(typeof e.scopeSpans[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.ResourceSpans.scopeSpans: object expected");t.scopeSpans[r]=p.opentelemetry.proto.trace.v1.ScopeSpans.fromObject(e.scopeSpans[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.scopeSpans=[]),t.defaults&&(r.resource=null,r.schemaUrl=""),e.resource!=null&&e.hasOwnProperty("resource")&&(r.resource=p.opentelemetry.proto.resource.v1.Resource.toObject(e.resource,t)),e.scopeSpans&&e.scopeSpans.length){r.scopeSpans=[];for(var u=0;u<e.scopeSpans.length;++u)r.scopeSpans[u]=p.opentelemetry.proto.trace.v1.ScopeSpans.toObject(e.scopeSpans[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.trace.v1.ResourceSpans"},l}(),c.ScopeSpans=function(){function l(i){if(this.spans=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.scope=null,l.prototype.spans=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.scope!=null&&Object.hasOwnProperty.call(e,"scope")&&p.opentelemetry.proto.common.v1.InstrumentationScope.encode(e.scope,t.uint32(10).fork()).ldelim(),e.spans!=null&&e.spans.length)for(var r=0;r<e.spans.length;++r)p.opentelemetry.proto.trace.v1.Span.encode(e.spans[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.trace.v1.ScopeSpans;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.decode(e,e.uint32());break}case 2:{u.spans&&u.spans.length||(u.spans=[]),u.spans.push(p.opentelemetry.proto.trace.v1.Span.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.scope!=null&&e.hasOwnProperty("scope")){var t=p.opentelemetry.proto.common.v1.InstrumentationScope.verify(e.scope);if(t)return"scope."+t}if(e.spans!=null&&e.hasOwnProperty("spans")){if(!Array.isArray(e.spans))return"spans: array expected";for(var r=0;r<e.spans.length;++r){var t=p.opentelemetry.proto.trace.v1.Span.verify(e.spans[r]);if(t)return"spans."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.trace.v1.ScopeSpans)return e;var t=new p.opentelemetry.proto.trace.v1.ScopeSpans;if(e.scope!=null){if(typeof e.scope!="object")throw TypeError(".opentelemetry.proto.trace.v1.ScopeSpans.scope: object expected");t.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.fromObject(e.scope)}if(e.spans){if(!Array.isArray(e.spans))throw TypeError(".opentelemetry.proto.trace.v1.ScopeSpans.spans: array expected");t.spans=[];for(var r=0;r<e.spans.length;++r){if(typeof e.spans[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.ScopeSpans.spans: object expected");t.spans[r]=p.opentelemetry.proto.trace.v1.Span.fromObject(e.spans[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.spans=[]),t.defaults&&(r.scope=null,r.schemaUrl=""),e.scope!=null&&e.hasOwnProperty("scope")&&(r.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.toObject(e.scope,t)),e.spans&&e.spans.length){r.spans=[];for(var u=0;u<e.spans.length;++u)r.spans[u]=p.opentelemetry.proto.trace.v1.Span.toObject(e.spans[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.trace.v1.ScopeSpans"},l}(),c.Span=function(){function l(i){if(this.attributes=[],this.events=[],this.links=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.traceId=null,l.prototype.spanId=null,l.prototype.traceState=null,l.prototype.parentSpanId=null,l.prototype.name=null,l.prototype.kind=null,l.prototype.startTimeUnixNano=null,l.prototype.endTimeUnixNano=null,l.prototype.attributes=f.emptyArray,l.prototype.droppedAttributesCount=null,l.prototype.events=f.emptyArray,l.prototype.droppedEventsCount=null,l.prototype.links=f.emptyArray,l.prototype.droppedLinksCount=null,l.prototype.status=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.traceId!=null&&Object.hasOwnProperty.call(e,"traceId")&&t.uint32(10).bytes(e.traceId),e.spanId!=null&&Object.hasOwnProperty.call(e,"spanId")&&t.uint32(18).bytes(e.spanId),e.traceState!=null&&Object.hasOwnProperty.call(e,"traceState")&&t.uint32(26).string(e.traceState),e.parentSpanId!=null&&Object.hasOwnProperty.call(e,"parentSpanId")&&t.uint32(34).bytes(e.parentSpanId),e.name!=null&&Object.hasOwnProperty.call(e,"name")&&t.uint32(42).string(e.name),e.kind!=null&&Object.hasOwnProperty.call(e,"kind")&&t.uint32(48).int32(e.kind),e.startTimeUnixNano!=null&&Object.hasOwnProperty.call(e,"startTimeUnixNano")&&t.uint32(57).fixed64(e.startTimeUnixNano),e.endTimeUnixNano!=null&&Object.hasOwnProperty.call(e,"endTimeUnixNano")&&t.uint32(65).fixed64(e.endTimeUnixNano),e.attributes!=null&&e.attributes.length)for(var r=0;r<e.attributes.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[r],t.uint32(74).fork()).ldelim();if(e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,"droppedAttributesCount")&&t.uint32(80).uint32(e.droppedAttributesCount),e.events!=null&&e.events.length)for(var r=0;r<e.events.length;++r)p.opentelemetry.proto.trace.v1.Span.Event.encode(e.events[r],t.uint32(90).fork()).ldelim();if(e.droppedEventsCount!=null&&Object.hasOwnProperty.call(e,"droppedEventsCount")&&t.uint32(96).uint32(e.droppedEventsCount),e.links!=null&&e.links.length)for(var r=0;r<e.links.length;++r)p.opentelemetry.proto.trace.v1.Span.Link.encode(e.links[r],t.uint32(106).fork()).ldelim();return e.droppedLinksCount!=null&&Object.hasOwnProperty.call(e,"droppedLinksCount")&&t.uint32(112).uint32(e.droppedLinksCount),e.status!=null&&Object.hasOwnProperty.call(e,"status")&&p.opentelemetry.proto.trace.v1.Status.encode(e.status,t.uint32(122).fork()).ldelim(),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.trace.v1.Span;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.traceId=e.bytes();break}case 2:{u.spanId=e.bytes();break}case 3:{u.traceState=e.string();break}case 4:{u.parentSpanId=e.bytes();break}case 5:{u.name=e.string();break}case 6:{u.kind=e.int32();break}case 7:{u.startTimeUnixNano=e.fixed64();break}case 8:{u.endTimeUnixNano=e.fixed64();break}case 9:{u.attributes&&u.attributes.length||(u.attributes=[]),u.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}case 10:{u.droppedAttributesCount=e.uint32();break}case 11:{u.events&&u.events.length||(u.events=[]),u.events.push(p.opentelemetry.proto.trace.v1.Span.Event.decode(e,e.uint32()));break}case 12:{u.droppedEventsCount=e.uint32();break}case 13:{u.links&&u.links.length||(u.links=[]),u.links.push(p.opentelemetry.proto.trace.v1.Span.Link.decode(e,e.uint32()));break}case 14:{u.droppedLinksCount=e.uint32();break}case 15:{u.status=p.opentelemetry.proto.trace.v1.Status.decode(e,e.uint32());break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.traceId!=null&&e.hasOwnProperty("traceId")&&!(e.traceId&&typeof e.traceId.length=="number"||f.isString(e.traceId)))return"traceId: buffer expected";if(e.spanId!=null&&e.hasOwnProperty("spanId")&&!(e.spanId&&typeof e.spanId.length=="number"||f.isString(e.spanId)))return"spanId: buffer expected";if(e.traceState!=null&&e.hasOwnProperty("traceState")&&!f.isString(e.traceState))return"traceState: string expected";if(e.parentSpanId!=null&&e.hasOwnProperty("parentSpanId")&&!(e.parentSpanId&&typeof e.parentSpanId.length=="number"||f.isString(e.parentSpanId)))return"parentSpanId: buffer expected";if(e.name!=null&&e.hasOwnProperty("name")&&!f.isString(e.name))return"name: string expected";if(e.kind!=null&&e.hasOwnProperty("kind"))switch(e.kind){default:return"kind: enum value expected";case 0:case 1:case 2:case 3:case 4:case 5:break}if(e.startTimeUnixNano!=null&&e.hasOwnProperty("startTimeUnixNano")&&!f.isInteger(e.startTimeUnixNano)&&!(e.startTimeUnixNano&&f.isInteger(e.startTimeUnixNano.low)&&f.isInteger(e.startTimeUnixNano.high)))return"startTimeUnixNano: integer|Long expected";if(e.endTimeUnixNano!=null&&e.hasOwnProperty("endTimeUnixNano")&&!f.isInteger(e.endTimeUnixNano)&&!(e.endTimeUnixNano&&f.isInteger(e.endTimeUnixNano.low)&&f.isInteger(e.endTimeUnixNano.high)))return"endTimeUnixNano: integer|Long expected";if(e.attributes!=null&&e.hasOwnProperty("attributes")){if(!Array.isArray(e.attributes))return"attributes: array expected";for(var t=0;t<e.attributes.length;++t){var r=p.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(r)return"attributes."+r}}if(e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(e.droppedAttributesCount))return"droppedAttributesCount: integer expected";if(e.events!=null&&e.hasOwnProperty("events")){if(!Array.isArray(e.events))return"events: array expected";for(var t=0;t<e.events.length;++t){var r=p.opentelemetry.proto.trace.v1.Span.Event.verify(e.events[t]);if(r)return"events."+r}}if(e.droppedEventsCount!=null&&e.hasOwnProperty("droppedEventsCount")&&!f.isInteger(e.droppedEventsCount))return"droppedEventsCount: integer expected";if(e.links!=null&&e.hasOwnProperty("links")){if(!Array.isArray(e.links))return"links: array expected";for(var t=0;t<e.links.length;++t){var r=p.opentelemetry.proto.trace.v1.Span.Link.verify(e.links[t]);if(r)return"links."+r}}if(e.droppedLinksCount!=null&&e.hasOwnProperty("droppedLinksCount")&&!f.isInteger(e.droppedLinksCount))return"droppedLinksCount: integer expected";if(e.status!=null&&e.hasOwnProperty("status")){var r=p.opentelemetry.proto.trace.v1.Status.verify(e.status);if(r)return"status."+r}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.trace.v1.Span)return e;var t=new p.opentelemetry.proto.trace.v1.Span;switch(e.traceId!=null&&(typeof e.traceId=="string"?f.base64.decode(e.traceId,t.traceId=f.newBuffer(f.base64.length(e.traceId)),0):e.traceId.length>=0&&(t.traceId=e.traceId)),e.spanId!=null&&(typeof e.spanId=="string"?f.base64.decode(e.spanId,t.spanId=f.newBuffer(f.base64.length(e.spanId)),0):e.spanId.length>=0&&(t.spanId=e.spanId)),e.traceState!=null&&(t.traceState=String(e.traceState)),e.parentSpanId!=null&&(typeof e.parentSpanId=="string"?f.base64.decode(e.parentSpanId,t.parentSpanId=f.newBuffer(f.base64.length(e.parentSpanId)),0):e.parentSpanId.length>=0&&(t.parentSpanId=e.parentSpanId)),e.name!=null&&(t.name=String(e.name)),e.kind){default:if(typeof e.kind=="number"){t.kind=e.kind;break}break;case"SPAN_KIND_UNSPECIFIED":case 0:t.kind=0;break;case"SPAN_KIND_INTERNAL":case 1:t.kind=1;break;case"SPAN_KIND_SERVER":case 2:t.kind=2;break;case"SPAN_KIND_CLIENT":case 3:t.kind=3;break;case"SPAN_KIND_PRODUCER":case 4:t.kind=4;break;case"SPAN_KIND_CONSUMER":case 5:t.kind=5;break}if(e.startTimeUnixNano!=null&&(f.Long?(t.startTimeUnixNano=f.Long.fromValue(e.startTimeUnixNano)).unsigned=!1:typeof e.startTimeUnixNano=="string"?t.startTimeUnixNano=parseInt(e.startTimeUnixNano,10):typeof e.startTimeUnixNano=="number"?t.startTimeUnixNano=e.startTimeUnixNano:typeof e.startTimeUnixNano=="object"&&(t.startTimeUnixNano=new f.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber())),e.endTimeUnixNano!=null&&(f.Long?(t.endTimeUnixNano=f.Long.fromValue(e.endTimeUnixNano)).unsigned=!1:typeof e.endTimeUnixNano=="string"?t.endTimeUnixNano=parseInt(e.endTimeUnixNano,10):typeof e.endTimeUnixNano=="number"?t.endTimeUnixNano=e.endTimeUnixNano:typeof e.endTimeUnixNano=="object"&&(t.endTimeUnixNano=new f.LongBits(e.endTimeUnixNano.low>>>0,e.endTimeUnixNano.high>>>0).toNumber())),e.attributes){if(!Array.isArray(e.attributes))throw TypeError(".opentelemetry.proto.trace.v1.Span.attributes: array expected");t.attributes=[];for(var r=0;r<e.attributes.length;++r){if(typeof e.attributes[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.attributes: object expected");t.attributes[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[r])}}if(e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),e.events){if(!Array.isArray(e.events))throw TypeError(".opentelemetry.proto.trace.v1.Span.events: array expected");t.events=[];for(var r=0;r<e.events.length;++r){if(typeof e.events[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.events: object expected");t.events[r]=p.opentelemetry.proto.trace.v1.Span.Event.fromObject(e.events[r])}}if(e.droppedEventsCount!=null&&(t.droppedEventsCount=e.droppedEventsCount>>>0),e.links){if(!Array.isArray(e.links))throw TypeError(".opentelemetry.proto.trace.v1.Span.links: array expected");t.links=[];for(var r=0;r<e.links.length;++r){if(typeof e.links[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.links: object expected");t.links[r]=p.opentelemetry.proto.trace.v1.Span.Link.fromObject(e.links[r])}}if(e.droppedLinksCount!=null&&(t.droppedLinksCount=e.droppedLinksCount>>>0),e.status!=null){if(typeof e.status!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.status: object expected");t.status=p.opentelemetry.proto.trace.v1.Status.fromObject(e.status)}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.attributes=[],r.events=[],r.links=[]),t.defaults){if(t.bytes===String?r.traceId="":(r.traceId=[],t.bytes!==Array&&(r.traceId=f.newBuffer(r.traceId))),t.bytes===String?r.spanId="":(r.spanId=[],t.bytes!==Array&&(r.spanId=f.newBuffer(r.spanId))),r.traceState="",t.bytes===String?r.parentSpanId="":(r.parentSpanId=[],t.bytes!==Array&&(r.parentSpanId=f.newBuffer(r.parentSpanId))),r.name="",r.kind=t.enums===String?"SPAN_KIND_UNSPECIFIED":0,f.Long){var u=new f.Long(0,0,!1);r.startTimeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.startTimeUnixNano=t.longs===String?"0":0;if(f.Long){var u=new f.Long(0,0,!1);r.endTimeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.endTimeUnixNano=t.longs===String?"0":0;r.droppedAttributesCount=0,r.droppedEventsCount=0,r.droppedLinksCount=0,r.status=null}if(e.traceId!=null&&e.hasOwnProperty("traceId")&&(r.traceId=t.bytes===String?f.base64.encode(e.traceId,0,e.traceId.length):t.bytes===Array?Array.prototype.slice.call(e.traceId):e.traceId),e.spanId!=null&&e.hasOwnProperty("spanId")&&(r.spanId=t.bytes===String?f.base64.encode(e.spanId,0,e.spanId.length):t.bytes===Array?Array.prototype.slice.call(e.spanId):e.spanId),e.traceState!=null&&e.hasOwnProperty("traceState")&&(r.traceState=e.traceState),e.parentSpanId!=null&&e.hasOwnProperty("parentSpanId")&&(r.parentSpanId=t.bytes===String?f.base64.encode(e.parentSpanId,0,e.parentSpanId.length):t.bytes===Array?Array.prototype.slice.call(e.parentSpanId):e.parentSpanId),e.name!=null&&e.hasOwnProperty("name")&&(r.name=e.name),e.kind!=null&&e.hasOwnProperty("kind")&&(r.kind=t.enums===String?p.opentelemetry.proto.trace.v1.Span.SpanKind[e.kind]===void 0?e.kind:p.opentelemetry.proto.trace.v1.Span.SpanKind[e.kind]:e.kind),e.startTimeUnixNano!=null&&e.hasOwnProperty("startTimeUnixNano")&&(typeof e.startTimeUnixNano=="number"?r.startTimeUnixNano=t.longs===String?String(e.startTimeUnixNano):e.startTimeUnixNano:r.startTimeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.startTimeUnixNano):t.longs===Number?new f.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber():e.startTimeUnixNano),e.endTimeUnixNano!=null&&e.hasOwnProperty("endTimeUnixNano")&&(typeof e.endTimeUnixNano=="number"?r.endTimeUnixNano=t.longs===String?String(e.endTimeUnixNano):e.endTimeUnixNano:r.endTimeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.endTimeUnixNano):t.longs===Number?new f.LongBits(e.endTimeUnixNano.low>>>0,e.endTimeUnixNano.high>>>0).toNumber():e.endTimeUnixNano),e.attributes&&e.attributes.length){r.attributes=[];for(var s=0;s<e.attributes.length;++s)r.attributes[s]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[s],t)}if(e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&(r.droppedAttributesCount=e.droppedAttributesCount),e.events&&e.events.length){r.events=[];for(var s=0;s<e.events.length;++s)r.events[s]=p.opentelemetry.proto.trace.v1.Span.Event.toObject(e.events[s],t)}if(e.droppedEventsCount!=null&&e.hasOwnProperty("droppedEventsCount")&&(r.droppedEventsCount=e.droppedEventsCount),e.links&&e.links.length){r.links=[];for(var s=0;s<e.links.length;++s)r.links[s]=p.opentelemetry.proto.trace.v1.Span.Link.toObject(e.links[s],t)}return e.droppedLinksCount!=null&&e.hasOwnProperty("droppedLinksCount")&&(r.droppedLinksCount=e.droppedLinksCount),e.status!=null&&e.hasOwnProperty("status")&&(r.status=p.opentelemetry.proto.trace.v1.Status.toObject(e.status,t)),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.trace.v1.Span"},l.SpanKind=function(){var i={},e=Object.create(i);return e[i[0]="SPAN_KIND_UNSPECIFIED"]=0,e[i[1]="SPAN_KIND_INTERNAL"]=1,e[i[2]="SPAN_KIND_SERVER"]=2,e[i[3]="SPAN_KIND_CLIENT"]=3,e[i[4]="SPAN_KIND_PRODUCER"]=4,e[i[5]="SPAN_KIND_CONSUMER"]=5,e}(),l.Event=function(){function i(e){if(this.attributes=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.timeUnixNano=null,i.prototype.name=null,i.prototype.attributes=f.emptyArray,i.prototype.droppedAttributesCount=null,i.create=function(t){return new i(t)},i.encode=function(t,r){if(r||(r=S.create()),t.timeUnixNano!=null&&Object.hasOwnProperty.call(t,"timeUnixNano")&&r.uint32(9).fixed64(t.timeUnixNano),t.name!=null&&Object.hasOwnProperty.call(t,"name")&&r.uint32(18).string(t.name),t.attributes!=null&&t.attributes.length)for(var u=0;u<t.attributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.attributes[u],r.uint32(26).fork()).ldelim();return t.droppedAttributesCount!=null&&Object.hasOwnProperty.call(t,"droppedAttributesCount")&&r.uint32(32).uint32(t.droppedAttributesCount),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.trace.v1.Span.Event;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.timeUnixNano=t.fixed64();break}case 2:{s.name=t.string();break}case 3:{s.attributes&&s.attributes.length||(s.attributes=[]),s.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 4:{s.droppedAttributesCount=t.uint32();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&!f.isInteger(t.timeUnixNano)&&!(t.timeUnixNano&&f.isInteger(t.timeUnixNano.low)&&f.isInteger(t.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(t.name!=null&&t.hasOwnProperty("name")&&!f.isString(t.name))return"name: string expected";if(t.attributes!=null&&t.hasOwnProperty("attributes")){if(!Array.isArray(t.attributes))return"attributes: array expected";for(var r=0;r<t.attributes.length;++r){var u=p.opentelemetry.proto.common.v1.KeyValue.verify(t.attributes[r]);if(u)return"attributes."+u}}return t.droppedAttributesCount!=null&&t.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(t.droppedAttributesCount)?"droppedAttributesCount: integer expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.trace.v1.Span.Event)return t;var r=new p.opentelemetry.proto.trace.v1.Span.Event;if(t.timeUnixNano!=null&&(f.Long?(r.timeUnixNano=f.Long.fromValue(t.timeUnixNano)).unsigned=!1:typeof t.timeUnixNano=="string"?r.timeUnixNano=parseInt(t.timeUnixNano,10):typeof t.timeUnixNano=="number"?r.timeUnixNano=t.timeUnixNano:typeof t.timeUnixNano=="object"&&(r.timeUnixNano=new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber())),t.name!=null&&(r.name=String(t.name)),t.attributes){if(!Array.isArray(t.attributes))throw TypeError(".opentelemetry.proto.trace.v1.Span.Event.attributes: array expected");r.attributes=[];for(var u=0;u<t.attributes.length;++u){if(typeof t.attributes[u]!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.Event.attributes: object expected");r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.attributes[u])}}return t.droppedAttributesCount!=null&&(r.droppedAttributesCount=t.droppedAttributesCount>>>0),r},i.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.attributes=[]),r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.timeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.timeUnixNano=r.longs===String?"0":0;u.name="",u.droppedAttributesCount=0}if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&(typeof t.timeUnixNano=="number"?u.timeUnixNano=r.longs===String?String(t.timeUnixNano):t.timeUnixNano:u.timeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.timeUnixNano):r.longs===Number?new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber():t.timeUnixNano),t.name!=null&&t.hasOwnProperty("name")&&(u.name=t.name),t.attributes&&t.attributes.length){u.attributes=[];for(var d=0;d<t.attributes.length;++d)u.attributes[d]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.attributes[d],r)}return t.droppedAttributesCount!=null&&t.hasOwnProperty("droppedAttributesCount")&&(u.droppedAttributesCount=t.droppedAttributesCount),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.trace.v1.Span.Event"},i}(),l.Link=function(){function i(e){if(this.attributes=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.traceId=null,i.prototype.spanId=null,i.prototype.traceState=null,i.prototype.attributes=f.emptyArray,i.prototype.droppedAttributesCount=null,i.create=function(t){return new i(t)},i.encode=function(t,r){if(r||(r=S.create()),t.traceId!=null&&Object.hasOwnProperty.call(t,"traceId")&&r.uint32(10).bytes(t.traceId),t.spanId!=null&&Object.hasOwnProperty.call(t,"spanId")&&r.uint32(18).bytes(t.spanId),t.traceState!=null&&Object.hasOwnProperty.call(t,"traceState")&&r.uint32(26).string(t.traceState),t.attributes!=null&&t.attributes.length)for(var u=0;u<t.attributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.attributes[u],r.uint32(34).fork()).ldelim();return t.droppedAttributesCount!=null&&Object.hasOwnProperty.call(t,"droppedAttributesCount")&&r.uint32(40).uint32(t.droppedAttributesCount),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.trace.v1.Span.Link;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.traceId=t.bytes();break}case 2:{s.spanId=t.bytes();break}case 3:{s.traceState=t.string();break}case 4:{s.attributes&&s.attributes.length||(s.attributes=[]),s.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 5:{s.droppedAttributesCount=t.uint32();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.traceId!=null&&t.hasOwnProperty("traceId")&&!(t.traceId&&typeof t.traceId.length=="number"||f.isString(t.traceId)))return"traceId: buffer expected";if(t.spanId!=null&&t.hasOwnProperty("spanId")&&!(t.spanId&&typeof t.spanId.length=="number"||f.isString(t.spanId)))return"spanId: buffer expected";if(t.traceState!=null&&t.hasOwnProperty("traceState")&&!f.isString(t.traceState))return"traceState: string expected";if(t.attributes!=null&&t.hasOwnProperty("attributes")){if(!Array.isArray(t.attributes))return"attributes: array expected";for(var r=0;r<t.attributes.length;++r){var u=p.opentelemetry.proto.common.v1.KeyValue.verify(t.attributes[r]);if(u)return"attributes."+u}}return t.droppedAttributesCount!=null&&t.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(t.droppedAttributesCount)?"droppedAttributesCount: integer expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.trace.v1.Span.Link)return t;var r=new p.opentelemetry.proto.trace.v1.Span.Link;if(t.traceId!=null&&(typeof t.traceId=="string"?f.base64.decode(t.traceId,r.traceId=f.newBuffer(f.base64.length(t.traceId)),0):t.traceId.length>=0&&(r.traceId=t.traceId)),t.spanId!=null&&(typeof t.spanId=="string"?f.base64.decode(t.spanId,r.spanId=f.newBuffer(f.base64.length(t.spanId)),0):t.spanId.length>=0&&(r.spanId=t.spanId)),t.traceState!=null&&(r.traceState=String(t.traceState)),t.attributes){if(!Array.isArray(t.attributes))throw TypeError(".opentelemetry.proto.trace.v1.Span.Link.attributes: array expected");r.attributes=[];for(var u=0;u<t.attributes.length;++u){if(typeof t.attributes[u]!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.Link.attributes: object expected");r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.attributes[u])}}return t.droppedAttributesCount!=null&&(r.droppedAttributesCount=t.droppedAttributesCount>>>0),r},i.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.attributes=[]),r.defaults&&(r.bytes===String?u.traceId="":(u.traceId=[],r.bytes!==Array&&(u.traceId=f.newBuffer(u.traceId))),r.bytes===String?u.spanId="":(u.spanId=[],r.bytes!==Array&&(u.spanId=f.newBuffer(u.spanId))),u.traceState="",u.droppedAttributesCount=0),t.traceId!=null&&t.hasOwnProperty("traceId")&&(u.traceId=r.bytes===String?f.base64.encode(t.traceId,0,t.traceId.length):r.bytes===Array?Array.prototype.slice.call(t.traceId):t.traceId),t.spanId!=null&&t.hasOwnProperty("spanId")&&(u.spanId=r.bytes===String?f.base64.encode(t.spanId,0,t.spanId.length):r.bytes===Array?Array.prototype.slice.call(t.spanId):t.spanId),t.traceState!=null&&t.hasOwnProperty("traceState")&&(u.traceState=t.traceState),t.attributes&&t.attributes.length){u.attributes=[];for(var s=0;s<t.attributes.length;++s)u.attributes[s]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.attributes[s],r)}return t.droppedAttributesCount!=null&&t.hasOwnProperty("droppedAttributesCount")&&(u.droppedAttributesCount=t.droppedAttributesCount),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.trace.v1.Span.Link"},i}(),l}(),c.Status=function(){function l(i){if(i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.message=null,l.prototype.code=null,l.create=function(e){return new l(e)},l.encode=function(e,t){return t||(t=S.create()),e.message!=null&&Object.hasOwnProperty.call(e,"message")&&t.uint32(18).string(e.message),e.code!=null&&Object.hasOwnProperty.call(e,"code")&&t.uint32(24).int32(e.code),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.trace.v1.Status;e.pos<r;){var s=e.uint32();switch(s>>>3){case 2:{u.message=e.string();break}case 3:{u.code=e.int32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.message!=null&&e.hasOwnProperty("message")&&!f.isString(e.message))return"message: string expected";if(e.code!=null&&e.hasOwnProperty("code"))switch(e.code){default:return"code: enum value expected";case 0:case 1:case 2:break}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.trace.v1.Status)return e;var t=new p.opentelemetry.proto.trace.v1.Status;switch(e.message!=null&&(t.message=String(e.message)),e.code){default:if(typeof e.code=="number"){t.code=e.code;break}break;case"STATUS_CODE_UNSET":case 0:t.code=0;break;case"STATUS_CODE_OK":case 1:t.code=1;break;case"STATUS_CODE_ERROR":case 2:t.code=2;break}return t},l.toObject=function(e,t){t||(t={});var r={};return t.defaults&&(r.message="",r.code=t.enums===String?"STATUS_CODE_UNSET":0),e.message!=null&&e.hasOwnProperty("message")&&(r.message=e.message),e.code!=null&&e.hasOwnProperty("code")&&(r.code=t.enums===String?p.opentelemetry.proto.trace.v1.Status.StatusCode[e.code]===void 0?e.code:p.opentelemetry.proto.trace.v1.Status.StatusCode[e.code]:e.code),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.trace.v1.Status"},l.StatusCode=function(){var i={},e=Object.create(i);return e[i[0]="STATUS_CODE_UNSET"]=0,e[i[1]="STATUS_CODE_OK"]=1,e[i[2]="STATUS_CODE_ERROR"]=2,e}(),l}(),c}(),o}(),n.collector=function(){var o={};return o.trace=function(){var c={};return c.v1=function(){var l={};return l.TraceService=function(){function i(e,t,r){E.rpc.Service.call(this,e,t,r)}return(i.prototype=Object.create(E.rpc.Service.prototype)).constructor=i,i.create=function(t,r,u){return new this(t,r,u)},Object.defineProperty(i.prototype.export=function e(t,r){return this.rpcCall(e,p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest,p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse,t,r)},"name",{value:"Export"}),i}(),l.ExportTraceServiceRequest=function(){function i(e){if(this.resourceSpans=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.resourceSpans=f.emptyArray,i.create=function(t){return new i(t)},i.encode=function(t,r){if(r||(r=S.create()),t.resourceSpans!=null&&t.resourceSpans.length)for(var u=0;u<t.resourceSpans.length;++u)p.opentelemetry.proto.trace.v1.ResourceSpans.encode(t.resourceSpans[u],r.uint32(10).fork()).ldelim();return r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.resourceSpans&&s.resourceSpans.length||(s.resourceSpans=[]),s.resourceSpans.push(p.opentelemetry.proto.trace.v1.ResourceSpans.decode(t,t.uint32()));break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.resourceSpans!=null&&t.hasOwnProperty("resourceSpans")){if(!Array.isArray(t.resourceSpans))return"resourceSpans: array expected";for(var r=0;r<t.resourceSpans.length;++r){var u=p.opentelemetry.proto.trace.v1.ResourceSpans.verify(t.resourceSpans[r]);if(u)return"resourceSpans."+u}}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest)return t;var r=new p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest;if(t.resourceSpans){if(!Array.isArray(t.resourceSpans))throw TypeError(".opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest.resourceSpans: array expected");r.resourceSpans=[];for(var u=0;u<t.resourceSpans.length;++u){if(typeof t.resourceSpans[u]!="object")throw TypeError(".opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest.resourceSpans: object expected");r.resourceSpans[u]=p.opentelemetry.proto.trace.v1.ResourceSpans.fromObject(t.resourceSpans[u])}}return r},i.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.resourceSpans=[]),t.resourceSpans&&t.resourceSpans.length){u.resourceSpans=[];for(var s=0;s<t.resourceSpans.length;++s)u.resourceSpans[s]=p.opentelemetry.proto.trace.v1.ResourceSpans.toObject(t.resourceSpans[s],r)}return u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest"},i}(),l.ExportTraceServiceResponse=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.partialSuccess=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.partialSuccess!=null&&Object.hasOwnProperty.call(t,"partialSuccess")&&p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.encode(t.partialSuccess,r.uint32(10).fork()).ldelim(),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.partialSuccess=p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.decode(t,t.uint32());break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")){var r=p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.verify(t.partialSuccess);if(r)return"partialSuccess."+r}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse)return t;var r=new p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse;if(t.partialSuccess!=null){if(typeof t.partialSuccess!="object")throw TypeError(".opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse.partialSuccess: object expected");r.partialSuccess=p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.fromObject(t.partialSuccess)}return r},i.toObject=function(t,r){r||(r={});var u={};return r.defaults&&(u.partialSuccess=null),t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")&&(u.partialSuccess=p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.toObject(t.partialSuccess,r)),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse"},i}(),l.ExportTracePartialSuccess=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.rejectedSpans=null,i.prototype.errorMessage=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.rejectedSpans!=null&&Object.hasOwnProperty.call(t,"rejectedSpans")&&r.uint32(8).int64(t.rejectedSpans),t.errorMessage!=null&&Object.hasOwnProperty.call(t,"errorMessage")&&r.uint32(18).string(t.errorMessage),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.rejectedSpans=t.int64();break}case 2:{s.errorMessage=t.string();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){return typeof t!="object"||t===null?"object expected":t.rejectedSpans!=null&&t.hasOwnProperty("rejectedSpans")&&!f.isInteger(t.rejectedSpans)&&!(t.rejectedSpans&&f.isInteger(t.rejectedSpans.low)&&f.isInteger(t.rejectedSpans.high))?"rejectedSpans: integer|Long expected":t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&!f.isString(t.errorMessage)?"errorMessage: string expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess)return t;var r=new p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess;return t.rejectedSpans!=null&&(f.Long?(r.rejectedSpans=f.Long.fromValue(t.rejectedSpans)).unsigned=!1:typeof t.rejectedSpans=="string"?r.rejectedSpans=parseInt(t.rejectedSpans,10):typeof t.rejectedSpans=="number"?r.rejectedSpans=t.rejectedSpans:typeof t.rejectedSpans=="object"&&(r.rejectedSpans=new f.LongBits(t.rejectedSpans.low>>>0,t.rejectedSpans.high>>>0).toNumber())),t.errorMessage!=null&&(r.errorMessage=String(t.errorMessage)),r},i.toObject=function(t,r){r||(r={});var u={};if(r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.rejectedSpans=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.rejectedSpans=r.longs===String?"0":0;u.errorMessage=""}return t.rejectedSpans!=null&&t.hasOwnProperty("rejectedSpans")&&(typeof t.rejectedSpans=="number"?u.rejectedSpans=r.longs===String?String(t.rejectedSpans):t.rejectedSpans:u.rejectedSpans=r.longs===String?f.Long.prototype.toString.call(t.rejectedSpans):r.longs===Number?new f.LongBits(t.rejectedSpans.low>>>0,t.rejectedSpans.high>>>0).toNumber():t.rejectedSpans),t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&(u.errorMessage=t.errorMessage),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess"},i}(),l}(),c}(),o.metrics=function(){var c={};return c.v1=function(){var l={};return l.MetricsService=function(){function i(e,t,r){E.rpc.Service.call(this,e,t,r)}return(i.prototype=Object.create(E.rpc.Service.prototype)).constructor=i,i.create=function(t,r,u){return new this(t,r,u)},Object.defineProperty(i.prototype.export=function e(t,r){return this.rpcCall(e,p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest,p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse,t,r)},"name",{value:"Export"}),i}(),l.ExportMetricsServiceRequest=function(){function i(e){if(this.resourceMetrics=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.resourceMetrics=f.emptyArray,i.create=function(t){return new i(t)},i.encode=function(t,r){if(r||(r=S.create()),t.resourceMetrics!=null&&t.resourceMetrics.length)for(var u=0;u<t.resourceMetrics.length;++u)p.opentelemetry.proto.metrics.v1.ResourceMetrics.encode(t.resourceMetrics[u],r.uint32(10).fork()).ldelim();return r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.resourceMetrics&&s.resourceMetrics.length||(s.resourceMetrics=[]),s.resourceMetrics.push(p.opentelemetry.proto.metrics.v1.ResourceMetrics.decode(t,t.uint32()));break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.resourceMetrics!=null&&t.hasOwnProperty("resourceMetrics")){if(!Array.isArray(t.resourceMetrics))return"resourceMetrics: array expected";for(var r=0;r<t.resourceMetrics.length;++r){var u=p.opentelemetry.proto.metrics.v1.ResourceMetrics.verify(t.resourceMetrics[r]);if(u)return"resourceMetrics."+u}}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest)return t;var r=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest;if(t.resourceMetrics){if(!Array.isArray(t.resourceMetrics))throw TypeError(".opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest.resourceMetrics: array expected");r.resourceMetrics=[];for(var u=0;u<t.resourceMetrics.length;++u){if(typeof t.resourceMetrics[u]!="object")throw TypeError(".opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest.resourceMetrics: object expected");r.resourceMetrics[u]=p.opentelemetry.proto.metrics.v1.ResourceMetrics.fromObject(t.resourceMetrics[u])}}return r},i.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.resourceMetrics=[]),t.resourceMetrics&&t.resourceMetrics.length){u.resourceMetrics=[];for(var s=0;s<t.resourceMetrics.length;++s)u.resourceMetrics[s]=p.opentelemetry.proto.metrics.v1.ResourceMetrics.toObject(t.resourceMetrics[s],r)}return u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest"},i}(),l.ExportMetricsServiceResponse=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.partialSuccess=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.partialSuccess!=null&&Object.hasOwnProperty.call(t,"partialSuccess")&&p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.encode(t.partialSuccess,r.uint32(10).fork()).ldelim(),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.partialSuccess=p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.decode(t,t.uint32());break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")){var r=p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.verify(t.partialSuccess);if(r)return"partialSuccess."+r}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse)return t;var r=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse;if(t.partialSuccess!=null){if(typeof t.partialSuccess!="object")throw TypeError(".opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse.partialSuccess: object expected");r.partialSuccess=p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.fromObject(t.partialSuccess)}return r},i.toObject=function(t,r){r||(r={});var u={};return r.defaults&&(u.partialSuccess=null),t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")&&(u.partialSuccess=p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.toObject(t.partialSuccess,r)),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse"},i}(),l.ExportMetricsPartialSuccess=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.rejectedDataPoints=null,i.prototype.errorMessage=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.rejectedDataPoints!=null&&Object.hasOwnProperty.call(t,"rejectedDataPoints")&&r.uint32(8).int64(t.rejectedDataPoints),t.errorMessage!=null&&Object.hasOwnProperty.call(t,"errorMessage")&&r.uint32(18).string(t.errorMessage),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.rejectedDataPoints=t.int64();break}case 2:{s.errorMessage=t.string();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){return typeof t!="object"||t===null?"object expected":t.rejectedDataPoints!=null&&t.hasOwnProperty("rejectedDataPoints")&&!f.isInteger(t.rejectedDataPoints)&&!(t.rejectedDataPoints&&f.isInteger(t.rejectedDataPoints.low)&&f.isInteger(t.rejectedDataPoints.high))?"rejectedDataPoints: integer|Long expected":t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&!f.isString(t.errorMessage)?"errorMessage: string expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess)return t;var r=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess;return t.rejectedDataPoints!=null&&(f.Long?(r.rejectedDataPoints=f.Long.fromValue(t.rejectedDataPoints)).unsigned=!1:typeof t.rejectedDataPoints=="string"?r.rejectedDataPoints=parseInt(t.rejectedDataPoints,10):typeof t.rejectedDataPoints=="number"?r.rejectedDataPoints=t.rejectedDataPoints:typeof t.rejectedDataPoints=="object"&&(r.rejectedDataPoints=new f.LongBits(t.rejectedDataPoints.low>>>0,t.rejectedDataPoints.high>>>0).toNumber())),t.errorMessage!=null&&(r.errorMessage=String(t.errorMessage)),r},i.toObject=function(t,r){r||(r={});var u={};if(r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.rejectedDataPoints=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.rejectedDataPoints=r.longs===String?"0":0;u.errorMessage=""}return t.rejectedDataPoints!=null&&t.hasOwnProperty("rejectedDataPoints")&&(typeof t.rejectedDataPoints=="number"?u.rejectedDataPoints=r.longs===String?String(t.rejectedDataPoints):t.rejectedDataPoints:u.rejectedDataPoints=r.longs===String?f.Long.prototype.toString.call(t.rejectedDataPoints):r.longs===Number?new f.LongBits(t.rejectedDataPoints.low>>>0,t.rejectedDataPoints.high>>>0).toNumber():t.rejectedDataPoints),t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&(u.errorMessage=t.errorMessage),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess"},i}(),l}(),c}(),o.logs=function(){var c={};return c.v1=function(){var l={};return l.LogsService=function(){function i(e,t,r){E.rpc.Service.call(this,e,t,r)}return(i.prototype=Object.create(E.rpc.Service.prototype)).constructor=i,i.create=function(t,r,u){return new this(t,r,u)},Object.defineProperty(i.prototype.export=function e(t,r){return this.rpcCall(e,p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest,p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse,t,r)},"name",{value:"Export"}),i}(),l.ExportLogsServiceRequest=function(){function i(e){if(this.resourceLogs=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.resourceLogs=f.emptyArray,i.create=function(t){return new i(t)},i.encode=function(t,r){if(r||(r=S.create()),t.resourceLogs!=null&&t.resourceLogs.length)for(var u=0;u<t.resourceLogs.length;++u)p.opentelemetry.proto.logs.v1.ResourceLogs.encode(t.resourceLogs[u],r.uint32(10).fork()).ldelim();return r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.resourceLogs&&s.resourceLogs.length||(s.resourceLogs=[]),s.resourceLogs.push(p.opentelemetry.proto.logs.v1.ResourceLogs.decode(t,t.uint32()));break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.resourceLogs!=null&&t.hasOwnProperty("resourceLogs")){if(!Array.isArray(t.resourceLogs))return"resourceLogs: array expected";for(var r=0;r<t.resourceLogs.length;++r){var u=p.opentelemetry.proto.logs.v1.ResourceLogs.verify(t.resourceLogs[r]);if(u)return"resourceLogs."+u}}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest)return t;var r=new p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest;if(t.resourceLogs){if(!Array.isArray(t.resourceLogs))throw TypeError(".opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest.resourceLogs: array expected");r.resourceLogs=[];for(var u=0;u<t.resourceLogs.length;++u){if(typeof t.resourceLogs[u]!="object")throw TypeError(".opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest.resourceLogs: object expected");r.resourceLogs[u]=p.opentelemetry.proto.logs.v1.ResourceLogs.fromObject(t.resourceLogs[u])}}return r},i.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.resourceLogs=[]),t.resourceLogs&&t.resourceLogs.length){u.resourceLogs=[];for(var s=0;s<t.resourceLogs.length;++s)u.resourceLogs[s]=p.opentelemetry.proto.logs.v1.ResourceLogs.toObject(t.resourceLogs[s],r)}return u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest"},i}(),l.ExportLogsServiceResponse=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.partialSuccess=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.partialSuccess!=null&&Object.hasOwnProperty.call(t,"partialSuccess")&&p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.encode(t.partialSuccess,r.uint32(10).fork()).ldelim(),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.partialSuccess=p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.decode(t,t.uint32());break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")){var r=p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.verify(t.partialSuccess);if(r)return"partialSuccess."+r}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse)return t;var r=new p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse;if(t.partialSuccess!=null){if(typeof t.partialSuccess!="object")throw TypeError(".opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse.partialSuccess: object expected");r.partialSuccess=p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.fromObject(t.partialSuccess)}return r},i.toObject=function(t,r){r||(r={});var u={};return r.defaults&&(u.partialSuccess=null),t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")&&(u.partialSuccess=p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.toObject(t.partialSuccess,r)),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse"},i}(),l.ExportLogsPartialSuccess=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.rejectedLogRecords=null,i.prototype.errorMessage=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.rejectedLogRecords!=null&&Object.hasOwnProperty.call(t,"rejectedLogRecords")&&r.uint32(8).int64(t.rejectedLogRecords),t.errorMessage!=null&&Object.hasOwnProperty.call(t,"errorMessage")&&r.uint32(18).string(t.errorMessage),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.rejectedLogRecords=t.int64();break}case 2:{s.errorMessage=t.string();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){return typeof t!="object"||t===null?"object expected":t.rejectedLogRecords!=null&&t.hasOwnProperty("rejectedLogRecords")&&!f.isInteger(t.rejectedLogRecords)&&!(t.rejectedLogRecords&&f.isInteger(t.rejectedLogRecords.low)&&f.isInteger(t.rejectedLogRecords.high))?"rejectedLogRecords: integer|Long expected":t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&!f.isString(t.errorMessage)?"errorMessage: string expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess)return t;var r=new p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess;return t.rejectedLogRecords!=null&&(f.Long?(r.rejectedLogRecords=f.Long.fromValue(t.rejectedLogRecords)).unsigned=!1:typeof t.rejectedLogRecords=="string"?r.rejectedLogRecords=parseInt(t.rejectedLogRecords,10):typeof t.rejectedLogRecords=="number"?r.rejectedLogRecords=t.rejectedLogRecords:typeof t.rejectedLogRecords=="object"&&(r.rejectedLogRecords=new f.LongBits(t.rejectedLogRecords.low>>>0,t.rejectedLogRecords.high>>>0).toNumber())),t.errorMessage!=null&&(r.errorMessage=String(t.errorMessage)),r},i.toObject=function(t,r){r||(r={});var u={};if(r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.rejectedLogRecords=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.rejectedLogRecords=r.longs===String?"0":0;u.errorMessage=""}return t.rejectedLogRecords!=null&&t.hasOwnProperty("rejectedLogRecords")&&(typeof t.rejectedLogRecords=="number"?u.rejectedLogRecords=r.longs===String?String(t.rejectedLogRecords):t.rejectedLogRecords:u.rejectedLogRecords=r.longs===String?f.Long.prototype.toString.call(t.rejectedLogRecords):r.longs===Number?new f.LongBits(t.rejectedLogRecords.low>>>0,t.rejectedLogRecords.high>>>0).toNumber():t.rejectedLogRecords),t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&(u.errorMessage=t.errorMessage),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess"},i}(),l}(),c}(),o}(),n.metrics=function(){var o={};return o.v1=function(){var c={};return c.MetricsData=function(){function l(i){if(this.resourceMetrics=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resourceMetrics=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resourceMetrics!=null&&e.resourceMetrics.length)for(var r=0;r<e.resourceMetrics.length;++r)p.opentelemetry.proto.metrics.v1.ResourceMetrics.encode(e.resourceMetrics[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.MetricsData;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resourceMetrics&&u.resourceMetrics.length||(u.resourceMetrics=[]),u.resourceMetrics.push(p.opentelemetry.proto.metrics.v1.ResourceMetrics.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resourceMetrics!=null&&e.hasOwnProperty("resourceMetrics")){if(!Array.isArray(e.resourceMetrics))return"resourceMetrics: array expected";for(var t=0;t<e.resourceMetrics.length;++t){var r=p.opentelemetry.proto.metrics.v1.ResourceMetrics.verify(e.resourceMetrics[t]);if(r)return"resourceMetrics."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.MetricsData)return e;var t=new p.opentelemetry.proto.metrics.v1.MetricsData;if(e.resourceMetrics){if(!Array.isArray(e.resourceMetrics))throw TypeError(".opentelemetry.proto.metrics.v1.MetricsData.resourceMetrics: array expected");t.resourceMetrics=[];for(var r=0;r<e.resourceMetrics.length;++r){if(typeof e.resourceMetrics[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.MetricsData.resourceMetrics: object expected");t.resourceMetrics[r]=p.opentelemetry.proto.metrics.v1.ResourceMetrics.fromObject(e.resourceMetrics[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.resourceMetrics=[]),e.resourceMetrics&&e.resourceMetrics.length){r.resourceMetrics=[];for(var u=0;u<e.resourceMetrics.length;++u)r.resourceMetrics[u]=p.opentelemetry.proto.metrics.v1.ResourceMetrics.toObject(e.resourceMetrics[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.MetricsData"},l}(),c.ResourceMetrics=function(){function l(i){if(this.scopeMetrics=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resource=null,l.prototype.scopeMetrics=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resource!=null&&Object.hasOwnProperty.call(e,"resource")&&p.opentelemetry.proto.resource.v1.Resource.encode(e.resource,t.uint32(10).fork()).ldelim(),e.scopeMetrics!=null&&e.scopeMetrics.length)for(var r=0;r<e.scopeMetrics.length;++r)p.opentelemetry.proto.metrics.v1.ScopeMetrics.encode(e.scopeMetrics[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.ResourceMetrics;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resource=p.opentelemetry.proto.resource.v1.Resource.decode(e,e.uint32());break}case 2:{u.scopeMetrics&&u.scopeMetrics.length||(u.scopeMetrics=[]),u.scopeMetrics.push(p.opentelemetry.proto.metrics.v1.ScopeMetrics.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resource!=null&&e.hasOwnProperty("resource")){var t=p.opentelemetry.proto.resource.v1.Resource.verify(e.resource);if(t)return"resource."+t}if(e.scopeMetrics!=null&&e.hasOwnProperty("scopeMetrics")){if(!Array.isArray(e.scopeMetrics))return"scopeMetrics: array expected";for(var r=0;r<e.scopeMetrics.length;++r){var t=p.opentelemetry.proto.metrics.v1.ScopeMetrics.verify(e.scopeMetrics[r]);if(t)return"scopeMetrics."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.ResourceMetrics)return e;var t=new p.opentelemetry.proto.metrics.v1.ResourceMetrics;if(e.resource!=null){if(typeof e.resource!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ResourceMetrics.resource: object expected");t.resource=p.opentelemetry.proto.resource.v1.Resource.fromObject(e.resource)}if(e.scopeMetrics){if(!Array.isArray(e.scopeMetrics))throw TypeError(".opentelemetry.proto.metrics.v1.ResourceMetrics.scopeMetrics: array expected");t.scopeMetrics=[];for(var r=0;r<e.scopeMetrics.length;++r){if(typeof e.scopeMetrics[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ResourceMetrics.scopeMetrics: object expected");t.scopeMetrics[r]=p.opentelemetry.proto.metrics.v1.ScopeMetrics.fromObject(e.scopeMetrics[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.scopeMetrics=[]),t.defaults&&(r.resource=null,r.schemaUrl=""),e.resource!=null&&e.hasOwnProperty("resource")&&(r.resource=p.opentelemetry.proto.resource.v1.Resource.toObject(e.resource,t)),e.scopeMetrics&&e.scopeMetrics.length){r.scopeMetrics=[];for(var u=0;u<e.scopeMetrics.length;++u)r.scopeMetrics[u]=p.opentelemetry.proto.metrics.v1.ScopeMetrics.toObject(e.scopeMetrics[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.ResourceMetrics"},l}(),c.ScopeMetrics=function(){function l(i){if(this.metrics=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.scope=null,l.prototype.metrics=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.scope!=null&&Object.hasOwnProperty.call(e,"scope")&&p.opentelemetry.proto.common.v1.InstrumentationScope.encode(e.scope,t.uint32(10).fork()).ldelim(),e.metrics!=null&&e.metrics.length)for(var r=0;r<e.metrics.length;++r)p.opentelemetry.proto.metrics.v1.Metric.encode(e.metrics[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.ScopeMetrics;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.decode(e,e.uint32());break}case 2:{u.metrics&&u.metrics.length||(u.metrics=[]),u.metrics.push(p.opentelemetry.proto.metrics.v1.Metric.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.scope!=null&&e.hasOwnProperty("scope")){var t=p.opentelemetry.proto.common.v1.InstrumentationScope.verify(e.scope);if(t)return"scope."+t}if(e.metrics!=null&&e.hasOwnProperty("metrics")){if(!Array.isArray(e.metrics))return"metrics: array expected";for(var r=0;r<e.metrics.length;++r){var t=p.opentelemetry.proto.metrics.v1.Metric.verify(e.metrics[r]);if(t)return"metrics."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.ScopeMetrics)return e;var t=new p.opentelemetry.proto.metrics.v1.ScopeMetrics;if(e.scope!=null){if(typeof e.scope!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ScopeMetrics.scope: object expected");t.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.fromObject(e.scope)}if(e.metrics){if(!Array.isArray(e.metrics))throw TypeError(".opentelemetry.proto.metrics.v1.ScopeMetrics.metrics: array expected");t.metrics=[];for(var r=0;r<e.metrics.length;++r){if(typeof e.metrics[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ScopeMetrics.metrics: object expected");t.metrics[r]=p.opentelemetry.proto.metrics.v1.Metric.fromObject(e.metrics[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.metrics=[]),t.defaults&&(r.scope=null,r.schemaUrl=""),e.scope!=null&&e.hasOwnProperty("scope")&&(r.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.toObject(e.scope,t)),e.metrics&&e.metrics.length){r.metrics=[];for(var u=0;u<e.metrics.length;++u)r.metrics[u]=p.opentelemetry.proto.metrics.v1.Metric.toObject(e.metrics[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.ScopeMetrics"},l}(),c.Metric=function(){function l(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.name=null,l.prototype.description=null,l.prototype.unit=null,l.prototype.gauge=null,l.prototype.sum=null,l.prototype.histogram=null,l.prototype.exponentialHistogram=null,l.prototype.summary=null;var i;return Object.defineProperty(l.prototype,"data",{get:f.oneOfGetter(i=["gauge","sum","histogram","exponentialHistogram","summary"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){return r||(r=S.create()),t.name!=null&&Object.hasOwnProperty.call(t,"name")&&r.uint32(10).string(t.name),t.description!=null&&Object.hasOwnProperty.call(t,"description")&&r.uint32(18).string(t.description),t.unit!=null&&Object.hasOwnProperty.call(t,"unit")&&r.uint32(26).string(t.unit),t.gauge!=null&&Object.hasOwnProperty.call(t,"gauge")&&p.opentelemetry.proto.metrics.v1.Gauge.encode(t.gauge,r.uint32(42).fork()).ldelim(),t.sum!=null&&Object.hasOwnProperty.call(t,"sum")&&p.opentelemetry.proto.metrics.v1.Sum.encode(t.sum,r.uint32(58).fork()).ldelim(),t.histogram!=null&&Object.hasOwnProperty.call(t,"histogram")&&p.opentelemetry.proto.metrics.v1.Histogram.encode(t.histogram,r.uint32(74).fork()).ldelim(),t.exponentialHistogram!=null&&Object.hasOwnProperty.call(t,"exponentialHistogram")&&p.opentelemetry.proto.metrics.v1.ExponentialHistogram.encode(t.exponentialHistogram,r.uint32(82).fork()).ldelim(),t.summary!=null&&Object.hasOwnProperty.call(t,"summary")&&p.opentelemetry.proto.metrics.v1.Summary.encode(t.summary,r.uint32(90).fork()).ldelim(),r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.Metric;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.name=t.string();break}case 2:{s.description=t.string();break}case 3:{s.unit=t.string();break}case 5:{s.gauge=p.opentelemetry.proto.metrics.v1.Gauge.decode(t,t.uint32());break}case 7:{s.sum=p.opentelemetry.proto.metrics.v1.Sum.decode(t,t.uint32());break}case 9:{s.histogram=p.opentelemetry.proto.metrics.v1.Histogram.decode(t,t.uint32());break}case 10:{s.exponentialHistogram=p.opentelemetry.proto.metrics.v1.ExponentialHistogram.decode(t,t.uint32());break}case 11:{s.summary=p.opentelemetry.proto.metrics.v1.Summary.decode(t,t.uint32());break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.name!=null&&t.hasOwnProperty("name")&&!f.isString(t.name))return"name: string expected";if(t.description!=null&&t.hasOwnProperty("description")&&!f.isString(t.description))return"description: string expected";if(t.unit!=null&&t.hasOwnProperty("unit")&&!f.isString(t.unit))return"unit: string expected";if(t.gauge!=null&&t.hasOwnProperty("gauge")){r.data=1;{var u=p.opentelemetry.proto.metrics.v1.Gauge.verify(t.gauge);if(u)return"gauge."+u}}if(t.sum!=null&&t.hasOwnProperty("sum")){if(r.data===1)return"data: multiple values";r.data=1;{var u=p.opentelemetry.proto.metrics.v1.Sum.verify(t.sum);if(u)return"sum."+u}}if(t.histogram!=null&&t.hasOwnProperty("histogram")){if(r.data===1)return"data: multiple values";r.data=1;{var u=p.opentelemetry.proto.metrics.v1.Histogram.verify(t.histogram);if(u)return"histogram."+u}}if(t.exponentialHistogram!=null&&t.hasOwnProperty("exponentialHistogram")){if(r.data===1)return"data: multiple values";r.data=1;{var u=p.opentelemetry.proto.metrics.v1.ExponentialHistogram.verify(t.exponentialHistogram);if(u)return"exponentialHistogram."+u}}if(t.summary!=null&&t.hasOwnProperty("summary")){if(r.data===1)return"data: multiple values";r.data=1;{var u=p.opentelemetry.proto.metrics.v1.Summary.verify(t.summary);if(u)return"summary."+u}}return null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.Metric)return t;var r=new p.opentelemetry.proto.metrics.v1.Metric;if(t.name!=null&&(r.name=String(t.name)),t.description!=null&&(r.description=String(t.description)),t.unit!=null&&(r.unit=String(t.unit)),t.gauge!=null){if(typeof t.gauge!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Metric.gauge: object expected");r.gauge=p.opentelemetry.proto.metrics.v1.Gauge.fromObject(t.gauge)}if(t.sum!=null){if(typeof t.sum!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Metric.sum: object expected");r.sum=p.opentelemetry.proto.metrics.v1.Sum.fromObject(t.sum)}if(t.histogram!=null){if(typeof t.histogram!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Metric.histogram: object expected");r.histogram=p.opentelemetry.proto.metrics.v1.Histogram.fromObject(t.histogram)}if(t.exponentialHistogram!=null){if(typeof t.exponentialHistogram!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Metric.exponentialHistogram: object expected");r.exponentialHistogram=p.opentelemetry.proto.metrics.v1.ExponentialHistogram.fromObject(t.exponentialHistogram)}if(t.summary!=null){if(typeof t.summary!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Metric.summary: object expected");r.summary=p.opentelemetry.proto.metrics.v1.Summary.fromObject(t.summary)}return r},l.toObject=function(t,r){r||(r={});var u={};return r.defaults&&(u.name="",u.description="",u.unit=""),t.name!=null&&t.hasOwnProperty("name")&&(u.name=t.name),t.description!=null&&t.hasOwnProperty("description")&&(u.description=t.description),t.unit!=null&&t.hasOwnProperty("unit")&&(u.unit=t.unit),t.gauge!=null&&t.hasOwnProperty("gauge")&&(u.gauge=p.opentelemetry.proto.metrics.v1.Gauge.toObject(t.gauge,r),r.oneofs&&(u.data="gauge")),t.sum!=null&&t.hasOwnProperty("sum")&&(u.sum=p.opentelemetry.proto.metrics.v1.Sum.toObject(t.sum,r),r.oneofs&&(u.data="sum")),t.histogram!=null&&t.hasOwnProperty("histogram")&&(u.histogram=p.opentelemetry.proto.metrics.v1.Histogram.toObject(t.histogram,r),r.oneofs&&(u.data="histogram")),t.exponentialHistogram!=null&&t.hasOwnProperty("exponentialHistogram")&&(u.exponentialHistogram=p.opentelemetry.proto.metrics.v1.ExponentialHistogram.toObject(t.exponentialHistogram,r),r.oneofs&&(u.data="exponentialHistogram")),t.summary!=null&&t.hasOwnProperty("summary")&&(u.summary=p.opentelemetry.proto.metrics.v1.Summary.toObject(t.summary,r),r.oneofs&&(u.data="summary")),u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.Metric"},l}(),c.Gauge=function(){function l(i){if(this.dataPoints=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.dataPoints=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.dataPoints!=null&&e.dataPoints.length)for(var r=0;r<e.dataPoints.length;++r)p.opentelemetry.proto.metrics.v1.NumberDataPoint.encode(e.dataPoints[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.Gauge;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.dataPoints&&u.dataPoints.length||(u.dataPoints=[]),u.dataPoints.push(p.opentelemetry.proto.metrics.v1.NumberDataPoint.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.dataPoints!=null&&e.hasOwnProperty("dataPoints")){if(!Array.isArray(e.dataPoints))return"dataPoints: array expected";for(var t=0;t<e.dataPoints.length;++t){var r=p.opentelemetry.proto.metrics.v1.NumberDataPoint.verify(e.dataPoints[t]);if(r)return"dataPoints."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.Gauge)return e;var t=new p.opentelemetry.proto.metrics.v1.Gauge;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(".opentelemetry.proto.metrics.v1.Gauge.dataPoints: array expected");t.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r){if(typeof e.dataPoints[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Gauge.dataPoints: object expected");t.dataPoints[r]=p.opentelemetry.proto.metrics.v1.NumberDataPoint.fromObject(e.dataPoints[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.dataPoints=[]),e.dataPoints&&e.dataPoints.length){r.dataPoints=[];for(var u=0;u<e.dataPoints.length;++u)r.dataPoints[u]=p.opentelemetry.proto.metrics.v1.NumberDataPoint.toObject(e.dataPoints[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.Gauge"},l}(),c.Sum=function(){function l(i){if(this.dataPoints=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.dataPoints=f.emptyArray,l.prototype.aggregationTemporality=null,l.prototype.isMonotonic=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.dataPoints!=null&&e.dataPoints.length)for(var r=0;r<e.dataPoints.length;++r)p.opentelemetry.proto.metrics.v1.NumberDataPoint.encode(e.dataPoints[r],t.uint32(10).fork()).ldelim();return e.aggregationTemporality!=null&&Object.hasOwnProperty.call(e,"aggregationTemporality")&&t.uint32(16).int32(e.aggregationTemporality),e.isMonotonic!=null&&Object.hasOwnProperty.call(e,"isMonotonic")&&t.uint32(24).bool(e.isMonotonic),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.Sum;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.dataPoints&&u.dataPoints.length||(u.dataPoints=[]),u.dataPoints.push(p.opentelemetry.proto.metrics.v1.NumberDataPoint.decode(e,e.uint32()));break}case 2:{u.aggregationTemporality=e.int32();break}case 3:{u.isMonotonic=e.bool();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.dataPoints!=null&&e.hasOwnProperty("dataPoints")){if(!Array.isArray(e.dataPoints))return"dataPoints: array expected";for(var t=0;t<e.dataPoints.length;++t){var r=p.opentelemetry.proto.metrics.v1.NumberDataPoint.verify(e.dataPoints[t]);if(r)return"dataPoints."+r}}if(e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality"))switch(e.aggregationTemporality){default:return"aggregationTemporality: enum value expected";case 0:case 1:case 2:break}return e.isMonotonic!=null&&e.hasOwnProperty("isMonotonic")&&typeof e.isMonotonic!="boolean"?"isMonotonic: boolean expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.Sum)return e;var t=new p.opentelemetry.proto.metrics.v1.Sum;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(".opentelemetry.proto.metrics.v1.Sum.dataPoints: array expected");t.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r){if(typeof e.dataPoints[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Sum.dataPoints: object expected");t.dataPoints[r]=p.opentelemetry.proto.metrics.v1.NumberDataPoint.fromObject(e.dataPoints[r])}}switch(e.aggregationTemporality){default:if(typeof e.aggregationTemporality=="number"){t.aggregationTemporality=e.aggregationTemporality;break}break;case"AGGREGATION_TEMPORALITY_UNSPECIFIED":case 0:t.aggregationTemporality=0;break;case"AGGREGATION_TEMPORALITY_DELTA":case 1:t.aggregationTemporality=1;break;case"AGGREGATION_TEMPORALITY_CUMULATIVE":case 2:t.aggregationTemporality=2;break}return e.isMonotonic!=null&&(t.isMonotonic=!!e.isMonotonic),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.dataPoints=[]),t.defaults&&(r.aggregationTemporality=t.enums===String?"AGGREGATION_TEMPORALITY_UNSPECIFIED":0,r.isMonotonic=!1),e.dataPoints&&e.dataPoints.length){r.dataPoints=[];for(var u=0;u<e.dataPoints.length;++u)r.dataPoints[u]=p.opentelemetry.proto.metrics.v1.NumberDataPoint.toObject(e.dataPoints[u],t)}return e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality")&&(r.aggregationTemporality=t.enums===String?p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]===void 0?e.aggregationTemporality:p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]:e.aggregationTemporality),e.isMonotonic!=null&&e.hasOwnProperty("isMonotonic")&&(r.isMonotonic=e.isMonotonic),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.Sum"},l}(),c.Histogram=function(){function l(i){if(this.dataPoints=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.dataPoints=f.emptyArray,l.prototype.aggregationTemporality=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.dataPoints!=null&&e.dataPoints.length)for(var r=0;r<e.dataPoints.length;++r)p.opentelemetry.proto.metrics.v1.HistogramDataPoint.encode(e.dataPoints[r],t.uint32(10).fork()).ldelim();return e.aggregationTemporality!=null&&Object.hasOwnProperty.call(e,"aggregationTemporality")&&t.uint32(16).int32(e.aggregationTemporality),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.Histogram;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.dataPoints&&u.dataPoints.length||(u.dataPoints=[]),u.dataPoints.push(p.opentelemetry.proto.metrics.v1.HistogramDataPoint.decode(e,e.uint32()));break}case 2:{u.aggregationTemporality=e.int32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.dataPoints!=null&&e.hasOwnProperty("dataPoints")){if(!Array.isArray(e.dataPoints))return"dataPoints: array expected";for(var t=0;t<e.dataPoints.length;++t){var r=p.opentelemetry.proto.metrics.v1.HistogramDataPoint.verify(e.dataPoints[t]);if(r)return"dataPoints."+r}}if(e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality"))switch(e.aggregationTemporality){default:return"aggregationTemporality: enum value expected";case 0:case 1:case 2:break}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.Histogram)return e;var t=new p.opentelemetry.proto.metrics.v1.Histogram;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(".opentelemetry.proto.metrics.v1.Histogram.dataPoints: array expected");t.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r){if(typeof e.dataPoints[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Histogram.dataPoints: object expected");t.dataPoints[r]=p.opentelemetry.proto.metrics.v1.HistogramDataPoint.fromObject(e.dataPoints[r])}}switch(e.aggregationTemporality){default:if(typeof e.aggregationTemporality=="number"){t.aggregationTemporality=e.aggregationTemporality;break}break;case"AGGREGATION_TEMPORALITY_UNSPECIFIED":case 0:t.aggregationTemporality=0;break;case"AGGREGATION_TEMPORALITY_DELTA":case 1:t.aggregationTemporality=1;break;case"AGGREGATION_TEMPORALITY_CUMULATIVE":case 2:t.aggregationTemporality=2;break}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.dataPoints=[]),t.defaults&&(r.aggregationTemporality=t.enums===String?"AGGREGATION_TEMPORALITY_UNSPECIFIED":0),e.dataPoints&&e.dataPoints.length){r.dataPoints=[];for(var u=0;u<e.dataPoints.length;++u)r.dataPoints[u]=p.opentelemetry.proto.metrics.v1.HistogramDataPoint.toObject(e.dataPoints[u],t)}return e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality")&&(r.aggregationTemporality=t.enums===String?p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]===void 0?e.aggregationTemporality:p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]:e.aggregationTemporality),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.Histogram"},l}(),c.ExponentialHistogram=function(){function l(i){if(this.dataPoints=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.dataPoints=f.emptyArray,l.prototype.aggregationTemporality=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.dataPoints!=null&&e.dataPoints.length)for(var r=0;r<e.dataPoints.length;++r)p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.encode(e.dataPoints[r],t.uint32(10).fork()).ldelim();return e.aggregationTemporality!=null&&Object.hasOwnProperty.call(e,"aggregationTemporality")&&t.uint32(16).int32(e.aggregationTemporality),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.ExponentialHistogram;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.dataPoints&&u.dataPoints.length||(u.dataPoints=[]),u.dataPoints.push(p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.decode(e,e.uint32()));break}case 2:{u.aggregationTemporality=e.int32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.dataPoints!=null&&e.hasOwnProperty("dataPoints")){if(!Array.isArray(e.dataPoints))return"dataPoints: array expected";for(var t=0;t<e.dataPoints.length;++t){var r=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.verify(e.dataPoints[t]);if(r)return"dataPoints."+r}}if(e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality"))switch(e.aggregationTemporality){default:return"aggregationTemporality: enum value expected";case 0:case 1:case 2:break}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.ExponentialHistogram)return e;var t=new p.opentelemetry.proto.metrics.v1.ExponentialHistogram;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogram.dataPoints: array expected");t.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r){if(typeof e.dataPoints[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogram.dataPoints: object expected");t.dataPoints[r]=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.fromObject(e.dataPoints[r])}}switch(e.aggregationTemporality){default:if(typeof e.aggregationTemporality=="number"){t.aggregationTemporality=e.aggregationTemporality;break}break;case"AGGREGATION_TEMPORALITY_UNSPECIFIED":case 0:t.aggregationTemporality=0;break;case"AGGREGATION_TEMPORALITY_DELTA":case 1:t.aggregationTemporality=1;break;case"AGGREGATION_TEMPORALITY_CUMULATIVE":case 2:t.aggregationTemporality=2;break}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.dataPoints=[]),t.defaults&&(r.aggregationTemporality=t.enums===String?"AGGREGATION_TEMPORALITY_UNSPECIFIED":0),e.dataPoints&&e.dataPoints.length){r.dataPoints=[];for(var u=0;u<e.dataPoints.length;++u)r.dataPoints[u]=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.toObject(e.dataPoints[u],t)}return e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality")&&(r.aggregationTemporality=t.enums===String?p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]===void 0?e.aggregationTemporality:p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]:e.aggregationTemporality),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.ExponentialHistogram"},l}(),c.Summary=function(){function l(i){if(this.dataPoints=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.dataPoints=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.dataPoints!=null&&e.dataPoints.length)for(var r=0;r<e.dataPoints.length;++r)p.opentelemetry.proto.metrics.v1.SummaryDataPoint.encode(e.dataPoints[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.Summary;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.dataPoints&&u.dataPoints.length||(u.dataPoints=[]),u.dataPoints.push(p.opentelemetry.proto.metrics.v1.SummaryDataPoint.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.dataPoints!=null&&e.hasOwnProperty("dataPoints")){if(!Array.isArray(e.dataPoints))return"dataPoints: array expected";for(var t=0;t<e.dataPoints.length;++t){var r=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.verify(e.dataPoints[t]);if(r)return"dataPoints."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.Summary)return e;var t=new p.opentelemetry.proto.metrics.v1.Summary;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(".opentelemetry.proto.metrics.v1.Summary.dataPoints: array expected");t.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r){if(typeof e.dataPoints[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Summary.dataPoints: object expected");t.dataPoints[r]=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.fromObject(e.dataPoints[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.dataPoints=[]),e.dataPoints&&e.dataPoints.length){r.dataPoints=[];for(var u=0;u<e.dataPoints.length;++u)r.dataPoints[u]=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.toObject(e.dataPoints[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.Summary"},l}(),c.AggregationTemporality=function(){var l={},i=Object.create(l);return i[l[0]="AGGREGATION_TEMPORALITY_UNSPECIFIED"]=0,i[l[1]="AGGREGATION_TEMPORALITY_DELTA"]=1,i[l[2]="AGGREGATION_TEMPORALITY_CUMULATIVE"]=2,i}(),c.DataPointFlags=function(){var l={},i=Object.create(l);return i[l[0]="DATA_POINT_FLAGS_DO_NOT_USE"]=0,i[l[1]="DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK"]=1,i}(),c.NumberDataPoint=function(){function l(e){if(this.attributes=[],this.exemplars=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.attributes=f.emptyArray,l.prototype.startTimeUnixNano=null,l.prototype.timeUnixNano=null,l.prototype.asDouble=null,l.prototype.asInt=null,l.prototype.exemplars=f.emptyArray,l.prototype.flags=null;var i;return Object.defineProperty(l.prototype,"value",{get:f.oneOfGetter(i=["asDouble","asInt"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){if(r||(r=S.create()),t.startTimeUnixNano!=null&&Object.hasOwnProperty.call(t,"startTimeUnixNano")&&r.uint32(17).fixed64(t.startTimeUnixNano),t.timeUnixNano!=null&&Object.hasOwnProperty.call(t,"timeUnixNano")&&r.uint32(25).fixed64(t.timeUnixNano),t.asDouble!=null&&Object.hasOwnProperty.call(t,"asDouble")&&r.uint32(33).double(t.asDouble),t.exemplars!=null&&t.exemplars.length)for(var u=0;u<t.exemplars.length;++u)p.opentelemetry.proto.metrics.v1.Exemplar.encode(t.exemplars[u],r.uint32(42).fork()).ldelim();if(t.asInt!=null&&Object.hasOwnProperty.call(t,"asInt")&&r.uint32(49).sfixed64(t.asInt),t.attributes!=null&&t.attributes.length)for(var u=0;u<t.attributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.attributes[u],r.uint32(58).fork()).ldelim();return t.flags!=null&&Object.hasOwnProperty.call(t,"flags")&&r.uint32(64).uint32(t.flags),r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.NumberDataPoint;t.pos<u;){var d=t.uint32();switch(d>>>3){case 7:{s.attributes&&s.attributes.length||(s.attributes=[]),s.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 2:{s.startTimeUnixNano=t.fixed64();break}case 3:{s.timeUnixNano=t.fixed64();break}case 4:{s.asDouble=t.double();break}case 6:{s.asInt=t.sfixed64();break}case 5:{s.exemplars&&s.exemplars.length||(s.exemplars=[]),s.exemplars.push(p.opentelemetry.proto.metrics.v1.Exemplar.decode(t,t.uint32()));break}case 8:{s.flags=t.uint32();break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.attributes!=null&&t.hasOwnProperty("attributes")){if(!Array.isArray(t.attributes))return"attributes: array expected";for(var u=0;u<t.attributes.length;++u){var s=p.opentelemetry.proto.common.v1.KeyValue.verify(t.attributes[u]);if(s)return"attributes."+s}}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&!f.isInteger(t.startTimeUnixNano)&&!(t.startTimeUnixNano&&f.isInteger(t.startTimeUnixNano.low)&&f.isInteger(t.startTimeUnixNano.high)))return"startTimeUnixNano: integer|Long expected";if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&!f.isInteger(t.timeUnixNano)&&!(t.timeUnixNano&&f.isInteger(t.timeUnixNano.low)&&f.isInteger(t.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(t.asDouble!=null&&t.hasOwnProperty("asDouble")&&(r.value=1,typeof t.asDouble!="number"))return"asDouble: number expected";if(t.asInt!=null&&t.hasOwnProperty("asInt")){if(r.value===1)return"value: multiple values";if(r.value=1,!f.isInteger(t.asInt)&&!(t.asInt&&f.isInteger(t.asInt.low)&&f.isInteger(t.asInt.high)))return"asInt: integer|Long expected"}if(t.exemplars!=null&&t.hasOwnProperty("exemplars")){if(!Array.isArray(t.exemplars))return"exemplars: array expected";for(var u=0;u<t.exemplars.length;++u){var s=p.opentelemetry.proto.metrics.v1.Exemplar.verify(t.exemplars[u]);if(s)return"exemplars."+s}}return t.flags!=null&&t.hasOwnProperty("flags")&&!f.isInteger(t.flags)?"flags: integer expected":null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.NumberDataPoint)return t;var r=new p.opentelemetry.proto.metrics.v1.NumberDataPoint;if(t.attributes){if(!Array.isArray(t.attributes))throw TypeError(".opentelemetry.proto.metrics.v1.NumberDataPoint.attributes: array expected");r.attributes=[];for(var u=0;u<t.attributes.length;++u){if(typeof t.attributes[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.NumberDataPoint.attributes: object expected");r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.attributes[u])}}if(t.startTimeUnixNano!=null&&(f.Long?(r.startTimeUnixNano=f.Long.fromValue(t.startTimeUnixNano)).unsigned=!1:typeof t.startTimeUnixNano=="string"?r.startTimeUnixNano=parseInt(t.startTimeUnixNano,10):typeof t.startTimeUnixNano=="number"?r.startTimeUnixNano=t.startTimeUnixNano:typeof t.startTimeUnixNano=="object"&&(r.startTimeUnixNano=new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber())),t.timeUnixNano!=null&&(f.Long?(r.timeUnixNano=f.Long.fromValue(t.timeUnixNano)).unsigned=!1:typeof t.timeUnixNano=="string"?r.timeUnixNano=parseInt(t.timeUnixNano,10):typeof t.timeUnixNano=="number"?r.timeUnixNano=t.timeUnixNano:typeof t.timeUnixNano=="object"&&(r.timeUnixNano=new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber())),t.asDouble!=null&&(r.asDouble=Number(t.asDouble)),t.asInt!=null&&(f.Long?(r.asInt=f.Long.fromValue(t.asInt)).unsigned=!1:typeof t.asInt=="string"?r.asInt=parseInt(t.asInt,10):typeof t.asInt=="number"?r.asInt=t.asInt:typeof t.asInt=="object"&&(r.asInt=new f.LongBits(t.asInt.low>>>0,t.asInt.high>>>0).toNumber())),t.exemplars){if(!Array.isArray(t.exemplars))throw TypeError(".opentelemetry.proto.metrics.v1.NumberDataPoint.exemplars: array expected");r.exemplars=[];for(var u=0;u<t.exemplars.length;++u){if(typeof t.exemplars[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.NumberDataPoint.exemplars: object expected");r.exemplars[u]=p.opentelemetry.proto.metrics.v1.Exemplar.fromObject(t.exemplars[u])}}return t.flags!=null&&(r.flags=t.flags>>>0),r},l.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.exemplars=[],u.attributes=[]),r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.startTimeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.startTimeUnixNano=r.longs===String?"0":0;if(f.Long){var s=new f.Long(0,0,!1);u.timeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.timeUnixNano=r.longs===String?"0":0;u.flags=0}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&(typeof t.startTimeUnixNano=="number"?u.startTimeUnixNano=r.longs===String?String(t.startTimeUnixNano):t.startTimeUnixNano:u.startTimeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.startTimeUnixNano):r.longs===Number?new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber():t.startTimeUnixNano),t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&(typeof t.timeUnixNano=="number"?u.timeUnixNano=r.longs===String?String(t.timeUnixNano):t.timeUnixNano:u.timeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.timeUnixNano):r.longs===Number?new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber():t.timeUnixNano),t.asDouble!=null&&t.hasOwnProperty("asDouble")&&(u.asDouble=r.json&&!isFinite(t.asDouble)?String(t.asDouble):t.asDouble,r.oneofs&&(u.value="asDouble")),t.exemplars&&t.exemplars.length){u.exemplars=[];for(var d=0;d<t.exemplars.length;++d)u.exemplars[d]=p.opentelemetry.proto.metrics.v1.Exemplar.toObject(t.exemplars[d],r)}if(t.asInt!=null&&t.hasOwnProperty("asInt")&&(typeof t.asInt=="number"?u.asInt=r.longs===String?String(t.asInt):t.asInt:u.asInt=r.longs===String?f.Long.prototype.toString.call(t.asInt):r.longs===Number?new f.LongBits(t.asInt.low>>>0,t.asInt.high>>>0).toNumber():t.asInt,r.oneofs&&(u.value="asInt")),t.attributes&&t.attributes.length){u.attributes=[];for(var d=0;d<t.attributes.length;++d)u.attributes[d]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.attributes[d],r)}return t.flags!=null&&t.hasOwnProperty("flags")&&(u.flags=t.flags),u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.NumberDataPoint"},l}(),c.HistogramDataPoint=function(){function l(e){if(this.attributes=[],this.bucketCounts=[],this.explicitBounds=[],this.exemplars=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.attributes=f.emptyArray,l.prototype.startTimeUnixNano=null,l.prototype.timeUnixNano=null,l.prototype.count=null,l.prototype.sum=null,l.prototype.bucketCounts=f.emptyArray,l.prototype.explicitBounds=f.emptyArray,l.prototype.exemplars=f.emptyArray,l.prototype.flags=null,l.prototype.min=null,l.prototype.max=null;var i;return Object.defineProperty(l.prototype,"_sum",{get:f.oneOfGetter(i=["sum"]),set:f.oneOfSetter(i)}),Object.defineProperty(l.prototype,"_min",{get:f.oneOfGetter(i=["min"]),set:f.oneOfSetter(i)}),Object.defineProperty(l.prototype,"_max",{get:f.oneOfGetter(i=["max"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){if(r||(r=S.create()),t.startTimeUnixNano!=null&&Object.hasOwnProperty.call(t,"startTimeUnixNano")&&r.uint32(17).fixed64(t.startTimeUnixNano),t.timeUnixNano!=null&&Object.hasOwnProperty.call(t,"timeUnixNano")&&r.uint32(25).fixed64(t.timeUnixNano),t.count!=null&&Object.hasOwnProperty.call(t,"count")&&r.uint32(33).fixed64(t.count),t.sum!=null&&Object.hasOwnProperty.call(t,"sum")&&r.uint32(41).double(t.sum),t.bucketCounts!=null&&t.bucketCounts.length){r.uint32(50).fork();for(var u=0;u<t.bucketCounts.length;++u)r.fixed64(t.bucketCounts[u]);r.ldelim()}if(t.explicitBounds!=null&&t.explicitBounds.length){r.uint32(58).fork();for(var u=0;u<t.explicitBounds.length;++u)r.double(t.explicitBounds[u]);r.ldelim()}if(t.exemplars!=null&&t.exemplars.length)for(var u=0;u<t.exemplars.length;++u)p.opentelemetry.proto.metrics.v1.Exemplar.encode(t.exemplars[u],r.uint32(66).fork()).ldelim();if(t.attributes!=null&&t.attributes.length)for(var u=0;u<t.attributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.attributes[u],r.uint32(74).fork()).ldelim();return t.flags!=null&&Object.hasOwnProperty.call(t,"flags")&&r.uint32(80).uint32(t.flags),t.min!=null&&Object.hasOwnProperty.call(t,"min")&&r.uint32(89).double(t.min),t.max!=null&&Object.hasOwnProperty.call(t,"max")&&r.uint32(97).double(t.max),r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.HistogramDataPoint;t.pos<u;){var d=t.uint32();switch(d>>>3){case 9:{s.attributes&&s.attributes.length||(s.attributes=[]),s.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 2:{s.startTimeUnixNano=t.fixed64();break}case 3:{s.timeUnixNano=t.fixed64();break}case 4:{s.count=t.fixed64();break}case 5:{s.sum=t.double();break}case 6:{if(s.bucketCounts&&s.bucketCounts.length||(s.bucketCounts=[]),(d&7)===2)for(var v=t.uint32()+t.pos;t.pos<v;)s.bucketCounts.push(t.fixed64());else s.bucketCounts.push(t.fixed64());break}case 7:{if(s.explicitBounds&&s.explicitBounds.length||(s.explicitBounds=[]),(d&7)===2)for(var v=t.uint32()+t.pos;t.pos<v;)s.explicitBounds.push(t.double());else s.explicitBounds.push(t.double());break}case 8:{s.exemplars&&s.exemplars.length||(s.exemplars=[]),s.exemplars.push(p.opentelemetry.proto.metrics.v1.Exemplar.decode(t,t.uint32()));break}case 10:{s.flags=t.uint32();break}case 11:{s.min=t.double();break}case 12:{s.max=t.double();break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.attributes!=null&&t.hasOwnProperty("attributes")){if(!Array.isArray(t.attributes))return"attributes: array expected";for(var u=0;u<t.attributes.length;++u){var s=p.opentelemetry.proto.common.v1.KeyValue.verify(t.attributes[u]);if(s)return"attributes."+s}}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&!f.isInteger(t.startTimeUnixNano)&&!(t.startTimeUnixNano&&f.isInteger(t.startTimeUnixNano.low)&&f.isInteger(t.startTimeUnixNano.high)))return"startTimeUnixNano: integer|Long expected";if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&!f.isInteger(t.timeUnixNano)&&!(t.timeUnixNano&&f.isInteger(t.timeUnixNano.low)&&f.isInteger(t.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(t.count!=null&&t.hasOwnProperty("count")&&!f.isInteger(t.count)&&!(t.count&&f.isInteger(t.count.low)&&f.isInteger(t.count.high)))return"count: integer|Long expected";if(t.sum!=null&&t.hasOwnProperty("sum")&&(r._sum=1,typeof t.sum!="number"))return"sum: number expected";if(t.bucketCounts!=null&&t.hasOwnProperty("bucketCounts")){if(!Array.isArray(t.bucketCounts))return"bucketCounts: array expected";for(var u=0;u<t.bucketCounts.length;++u)if(!f.isInteger(t.bucketCounts[u])&&!(t.bucketCounts[u]&&f.isInteger(t.bucketCounts[u].low)&&f.isInteger(t.bucketCounts[u].high)))return"bucketCounts: integer|Long[] expected"}if(t.explicitBounds!=null&&t.hasOwnProperty("explicitBounds")){if(!Array.isArray(t.explicitBounds))return"explicitBounds: array expected";for(var u=0;u<t.explicitBounds.length;++u)if(typeof t.explicitBounds[u]!="number")return"explicitBounds: number[] expected"}if(t.exemplars!=null&&t.hasOwnProperty("exemplars")){if(!Array.isArray(t.exemplars))return"exemplars: array expected";for(var u=0;u<t.exemplars.length;++u){var s=p.opentelemetry.proto.metrics.v1.Exemplar.verify(t.exemplars[u]);if(s)return"exemplars."+s}}return t.flags!=null&&t.hasOwnProperty("flags")&&!f.isInteger(t.flags)?"flags: integer expected":t.min!=null&&t.hasOwnProperty("min")&&(r._min=1,typeof t.min!="number")?"min: number expected":t.max!=null&&t.hasOwnProperty("max")&&(r._max=1,typeof t.max!="number")?"max: number expected":null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.HistogramDataPoint)return t;var r=new p.opentelemetry.proto.metrics.v1.HistogramDataPoint;if(t.attributes){if(!Array.isArray(t.attributes))throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.attributes: array expected");r.attributes=[];for(var u=0;u<t.attributes.length;++u){if(typeof t.attributes[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.attributes: object expected");r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.attributes[u])}}if(t.startTimeUnixNano!=null&&(f.Long?(r.startTimeUnixNano=f.Long.fromValue(t.startTimeUnixNano)).unsigned=!1:typeof t.startTimeUnixNano=="string"?r.startTimeUnixNano=parseInt(t.startTimeUnixNano,10):typeof t.startTimeUnixNano=="number"?r.startTimeUnixNano=t.startTimeUnixNano:typeof t.startTimeUnixNano=="object"&&(r.startTimeUnixNano=new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber())),t.timeUnixNano!=null&&(f.Long?(r.timeUnixNano=f.Long.fromValue(t.timeUnixNano)).unsigned=!1:typeof t.timeUnixNano=="string"?r.timeUnixNano=parseInt(t.timeUnixNano,10):typeof t.timeUnixNano=="number"?r.timeUnixNano=t.timeUnixNano:typeof t.timeUnixNano=="object"&&(r.timeUnixNano=new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber())),t.count!=null&&(f.Long?(r.count=f.Long.fromValue(t.count)).unsigned=!1:typeof t.count=="string"?r.count=parseInt(t.count,10):typeof t.count=="number"?r.count=t.count:typeof t.count=="object"&&(r.count=new f.LongBits(t.count.low>>>0,t.count.high>>>0).toNumber())),t.sum!=null&&(r.sum=Number(t.sum)),t.bucketCounts){if(!Array.isArray(t.bucketCounts))throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.bucketCounts: array expected");r.bucketCounts=[];for(var u=0;u<t.bucketCounts.length;++u)f.Long?(r.bucketCounts[u]=f.Long.fromValue(t.bucketCounts[u])).unsigned=!1:typeof t.bucketCounts[u]=="string"?r.bucketCounts[u]=parseInt(t.bucketCounts[u],10):typeof t.bucketCounts[u]=="number"?r.bucketCounts[u]=t.bucketCounts[u]:typeof t.bucketCounts[u]=="object"&&(r.bucketCounts[u]=new f.LongBits(t.bucketCounts[u].low>>>0,t.bucketCounts[u].high>>>0).toNumber())}if(t.explicitBounds){if(!Array.isArray(t.explicitBounds))throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.explicitBounds: array expected");r.explicitBounds=[];for(var u=0;u<t.explicitBounds.length;++u)r.explicitBounds[u]=Number(t.explicitBounds[u])}if(t.exemplars){if(!Array.isArray(t.exemplars))throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.exemplars: array expected");r.exemplars=[];for(var u=0;u<t.exemplars.length;++u){if(typeof t.exemplars[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.exemplars: object expected");r.exemplars[u]=p.opentelemetry.proto.metrics.v1.Exemplar.fromObject(t.exemplars[u])}}return t.flags!=null&&(r.flags=t.flags>>>0),t.min!=null&&(r.min=Number(t.min)),t.max!=null&&(r.max=Number(t.max)),r},l.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.bucketCounts=[],u.explicitBounds=[],u.exemplars=[],u.attributes=[]),r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.startTimeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.startTimeUnixNano=r.longs===String?"0":0;if(f.Long){var s=new f.Long(0,0,!1);u.timeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.timeUnixNano=r.longs===String?"0":0;if(f.Long){var s=new f.Long(0,0,!1);u.count=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.count=r.longs===String?"0":0;u.flags=0}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&(typeof t.startTimeUnixNano=="number"?u.startTimeUnixNano=r.longs===String?String(t.startTimeUnixNano):t.startTimeUnixNano:u.startTimeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.startTimeUnixNano):r.longs===Number?new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber():t.startTimeUnixNano),t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&(typeof t.timeUnixNano=="number"?u.timeUnixNano=r.longs===String?String(t.timeUnixNano):t.timeUnixNano:u.timeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.timeUnixNano):r.longs===Number?new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber():t.timeUnixNano),t.count!=null&&t.hasOwnProperty("count")&&(typeof t.count=="number"?u.count=r.longs===String?String(t.count):t.count:u.count=r.longs===String?f.Long.prototype.toString.call(t.count):r.longs===Number?new f.LongBits(t.count.low>>>0,t.count.high>>>0).toNumber():t.count),t.sum!=null&&t.hasOwnProperty("sum")&&(u.sum=r.json&&!isFinite(t.sum)?String(t.sum):t.sum,r.oneofs&&(u._sum="sum")),t.bucketCounts&&t.bucketCounts.length){u.bucketCounts=[];for(var d=0;d<t.bucketCounts.length;++d)typeof t.bucketCounts[d]=="number"?u.bucketCounts[d]=r.longs===String?String(t.bucketCounts[d]):t.bucketCounts[d]:u.bucketCounts[d]=r.longs===String?f.Long.prototype.toString.call(t.bucketCounts[d]):r.longs===Number?new f.LongBits(t.bucketCounts[d].low>>>0,t.bucketCounts[d].high>>>0).toNumber():t.bucketCounts[d]}if(t.explicitBounds&&t.explicitBounds.length){u.explicitBounds=[];for(var d=0;d<t.explicitBounds.length;++d)u.explicitBounds[d]=r.json&&!isFinite(t.explicitBounds[d])?String(t.explicitBounds[d]):t.explicitBounds[d]}if(t.exemplars&&t.exemplars.length){u.exemplars=[];for(var d=0;d<t.exemplars.length;++d)u.exemplars[d]=p.opentelemetry.proto.metrics.v1.Exemplar.toObject(t.exemplars[d],r)}if(t.attributes&&t.attributes.length){u.attributes=[];for(var d=0;d<t.attributes.length;++d)u.attributes[d]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.attributes[d],r)}return t.flags!=null&&t.hasOwnProperty("flags")&&(u.flags=t.flags),t.min!=null&&t.hasOwnProperty("min")&&(u.min=r.json&&!isFinite(t.min)?String(t.min):t.min,r.oneofs&&(u._min="min")),t.max!=null&&t.hasOwnProperty("max")&&(u.max=r.json&&!isFinite(t.max)?String(t.max):t.max,r.oneofs&&(u._max="max")),u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.HistogramDataPoint"},l}(),c.ExponentialHistogramDataPoint=function(){function l(e){if(this.attributes=[],this.exemplars=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.attributes=f.emptyArray,l.prototype.startTimeUnixNano=null,l.prototype.timeUnixNano=null,l.prototype.count=null,l.prototype.sum=null,l.prototype.scale=null,l.prototype.zeroCount=null,l.prototype.positive=null,l.prototype.negative=null,l.prototype.flags=null,l.prototype.exemplars=f.emptyArray,l.prototype.min=null,l.prototype.max=null,l.prototype.zeroThreshold=null;var i;return Object.defineProperty(l.prototype,"_sum",{get:f.oneOfGetter(i=["sum"]),set:f.oneOfSetter(i)}),Object.defineProperty(l.prototype,"_min",{get:f.oneOfGetter(i=["min"]),set:f.oneOfSetter(i)}),Object.defineProperty(l.prototype,"_max",{get:f.oneOfGetter(i=["max"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){if(r||(r=S.create()),t.attributes!=null&&t.attributes.length)for(var u=0;u<t.attributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.attributes[u],r.uint32(10).fork()).ldelim();if(t.startTimeUnixNano!=null&&Object.hasOwnProperty.call(t,"startTimeUnixNano")&&r.uint32(17).fixed64(t.startTimeUnixNano),t.timeUnixNano!=null&&Object.hasOwnProperty.call(t,"timeUnixNano")&&r.uint32(25).fixed64(t.timeUnixNano),t.count!=null&&Object.hasOwnProperty.call(t,"count")&&r.uint32(33).fixed64(t.count),t.sum!=null&&Object.hasOwnProperty.call(t,"sum")&&r.uint32(41).double(t.sum),t.scale!=null&&Object.hasOwnProperty.call(t,"scale")&&r.uint32(48).sint32(t.scale),t.zeroCount!=null&&Object.hasOwnProperty.call(t,"zeroCount")&&r.uint32(57).fixed64(t.zeroCount),t.positive!=null&&Object.hasOwnProperty.call(t,"positive")&&p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.encode(t.positive,r.uint32(66).fork()).ldelim(),t.negative!=null&&Object.hasOwnProperty.call(t,"negative")&&p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.encode(t.negative,r.uint32(74).fork()).ldelim(),t.flags!=null&&Object.hasOwnProperty.call(t,"flags")&&r.uint32(80).uint32(t.flags),t.exemplars!=null&&t.exemplars.length)for(var u=0;u<t.exemplars.length;++u)p.opentelemetry.proto.metrics.v1.Exemplar.encode(t.exemplars[u],r.uint32(90).fork()).ldelim();return t.min!=null&&Object.hasOwnProperty.call(t,"min")&&r.uint32(97).double(t.min),t.max!=null&&Object.hasOwnProperty.call(t,"max")&&r.uint32(105).double(t.max),t.zeroThreshold!=null&&Object.hasOwnProperty.call(t,"zeroThreshold")&&r.uint32(113).double(t.zeroThreshold),r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.attributes&&s.attributes.length||(s.attributes=[]),s.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 2:{s.startTimeUnixNano=t.fixed64();break}case 3:{s.timeUnixNano=t.fixed64();break}case 4:{s.count=t.fixed64();break}case 5:{s.sum=t.double();break}case 6:{s.scale=t.sint32();break}case 7:{s.zeroCount=t.fixed64();break}case 8:{s.positive=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.decode(t,t.uint32());break}case 9:{s.negative=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.decode(t,t.uint32());break}case 10:{s.flags=t.uint32();break}case 11:{s.exemplars&&s.exemplars.length||(s.exemplars=[]),s.exemplars.push(p.opentelemetry.proto.metrics.v1.Exemplar.decode(t,t.uint32()));break}case 12:{s.min=t.double();break}case 13:{s.max=t.double();break}case 14:{s.zeroThreshold=t.double();break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.attributes!=null&&t.hasOwnProperty("attributes")){if(!Array.isArray(t.attributes))return"attributes: array expected";for(var u=0;u<t.attributes.length;++u){var s=p.opentelemetry.proto.common.v1.KeyValue.verify(t.attributes[u]);if(s)return"attributes."+s}}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&!f.isInteger(t.startTimeUnixNano)&&!(t.startTimeUnixNano&&f.isInteger(t.startTimeUnixNano.low)&&f.isInteger(t.startTimeUnixNano.high)))return"startTimeUnixNano: integer|Long expected";if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&!f.isInteger(t.timeUnixNano)&&!(t.timeUnixNano&&f.isInteger(t.timeUnixNano.low)&&f.isInteger(t.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(t.count!=null&&t.hasOwnProperty("count")&&!f.isInteger(t.count)&&!(t.count&&f.isInteger(t.count.low)&&f.isInteger(t.count.high)))return"count: integer|Long expected";if(t.sum!=null&&t.hasOwnProperty("sum")&&(r._sum=1,typeof t.sum!="number"))return"sum: number expected";if(t.scale!=null&&t.hasOwnProperty("scale")&&!f.isInteger(t.scale))return"scale: integer expected";if(t.zeroCount!=null&&t.hasOwnProperty("zeroCount")&&!f.isInteger(t.zeroCount)&&!(t.zeroCount&&f.isInteger(t.zeroCount.low)&&f.isInteger(t.zeroCount.high)))return"zeroCount: integer|Long expected";if(t.positive!=null&&t.hasOwnProperty("positive")){var s=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.verify(t.positive);if(s)return"positive."+s}if(t.negative!=null&&t.hasOwnProperty("negative")){var s=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.verify(t.negative);if(s)return"negative."+s}if(t.flags!=null&&t.hasOwnProperty("flags")&&!f.isInteger(t.flags))return"flags: integer expected";if(t.exemplars!=null&&t.hasOwnProperty("exemplars")){if(!Array.isArray(t.exemplars))return"exemplars: array expected";for(var u=0;u<t.exemplars.length;++u){var s=p.opentelemetry.proto.metrics.v1.Exemplar.verify(t.exemplars[u]);if(s)return"exemplars."+s}}return t.min!=null&&t.hasOwnProperty("min")&&(r._min=1,typeof t.min!="number")?"min: number expected":t.max!=null&&t.hasOwnProperty("max")&&(r._max=1,typeof t.max!="number")?"max: number expected":t.zeroThreshold!=null&&t.hasOwnProperty("zeroThreshold")&&typeof t.zeroThreshold!="number"?"zeroThreshold: number expected":null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint)return t;var r=new p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint;if(t.attributes){if(!Array.isArray(t.attributes))throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.attributes: array expected");r.attributes=[];for(var u=0;u<t.attributes.length;++u){if(typeof t.attributes[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.attributes: object expected");r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.attributes[u])}}if(t.startTimeUnixNano!=null&&(f.Long?(r.startTimeUnixNano=f.Long.fromValue(t.startTimeUnixNano)).unsigned=!1:typeof t.startTimeUnixNano=="string"?r.startTimeUnixNano=parseInt(t.startTimeUnixNano,10):typeof t.startTimeUnixNano=="number"?r.startTimeUnixNano=t.startTimeUnixNano:typeof t.startTimeUnixNano=="object"&&(r.startTimeUnixNano=new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber())),t.timeUnixNano!=null&&(f.Long?(r.timeUnixNano=f.Long.fromValue(t.timeUnixNano)).unsigned=!1:typeof t.timeUnixNano=="string"?r.timeUnixNano=parseInt(t.timeUnixNano,10):typeof t.timeUnixNano=="number"?r.timeUnixNano=t.timeUnixNano:typeof t.timeUnixNano=="object"&&(r.timeUnixNano=new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber())),t.count!=null&&(f.Long?(r.count=f.Long.fromValue(t.count)).unsigned=!1:typeof t.count=="string"?r.count=parseInt(t.count,10):typeof t.count=="number"?r.count=t.count:typeof t.count=="object"&&(r.count=new f.LongBits(t.count.low>>>0,t.count.high>>>0).toNumber())),t.sum!=null&&(r.sum=Number(t.sum)),t.scale!=null&&(r.scale=t.scale|0),t.zeroCount!=null&&(f.Long?(r.zeroCount=f.Long.fromValue(t.zeroCount)).unsigned=!1:typeof t.zeroCount=="string"?r.zeroCount=parseInt(t.zeroCount,10):typeof t.zeroCount=="number"?r.zeroCount=t.zeroCount:typeof t.zeroCount=="object"&&(r.zeroCount=new f.LongBits(t.zeroCount.low>>>0,t.zeroCount.high>>>0).toNumber())),t.positive!=null){if(typeof t.positive!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.positive: object expected");r.positive=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.fromObject(t.positive)}if(t.negative!=null){if(typeof t.negative!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.negative: object expected");r.negative=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.fromObject(t.negative)}if(t.flags!=null&&(r.flags=t.flags>>>0),t.exemplars){if(!Array.isArray(t.exemplars))throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.exemplars: array expected");r.exemplars=[];for(var u=0;u<t.exemplars.length;++u){if(typeof t.exemplars[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.exemplars: object expected");r.exemplars[u]=p.opentelemetry.proto.metrics.v1.Exemplar.fromObject(t.exemplars[u])}}return t.min!=null&&(r.min=Number(t.min)),t.max!=null&&(r.max=Number(t.max)),t.zeroThreshold!=null&&(r.zeroThreshold=Number(t.zeroThreshold)),r},l.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.attributes=[],u.exemplars=[]),r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.startTimeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.startTimeUnixNano=r.longs===String?"0":0;if(f.Long){var s=new f.Long(0,0,!1);u.timeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.timeUnixNano=r.longs===String?"0":0;if(f.Long){var s=new f.Long(0,0,!1);u.count=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.count=r.longs===String?"0":0;if(u.scale=0,f.Long){var s=new f.Long(0,0,!1);u.zeroCount=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.zeroCount=r.longs===String?"0":0;u.positive=null,u.negative=null,u.flags=0,u.zeroThreshold=0}if(t.attributes&&t.attributes.length){u.attributes=[];for(var d=0;d<t.attributes.length;++d)u.attributes[d]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.attributes[d],r)}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&(typeof t.startTimeUnixNano=="number"?u.startTimeUnixNano=r.longs===String?String(t.startTimeUnixNano):t.startTimeUnixNano:u.startTimeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.startTimeUnixNano):r.longs===Number?new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber():t.startTimeUnixNano),t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&(typeof t.timeUnixNano=="number"?u.timeUnixNano=r.longs===String?String(t.timeUnixNano):t.timeUnixNano:u.timeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.timeUnixNano):r.longs===Number?new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber():t.timeUnixNano),t.count!=null&&t.hasOwnProperty("count")&&(typeof t.count=="number"?u.count=r.longs===String?String(t.count):t.count:u.count=r.longs===String?f.Long.prototype.toString.call(t.count):r.longs===Number?new f.LongBits(t.count.low>>>0,t.count.high>>>0).toNumber():t.count),t.sum!=null&&t.hasOwnProperty("sum")&&(u.sum=r.json&&!isFinite(t.sum)?String(t.sum):t.sum,r.oneofs&&(u._sum="sum")),t.scale!=null&&t.hasOwnProperty("scale")&&(u.scale=t.scale),t.zeroCount!=null&&t.hasOwnProperty("zeroCount")&&(typeof t.zeroCount=="number"?u.zeroCount=r.longs===String?String(t.zeroCount):t.zeroCount:u.zeroCount=r.longs===String?f.Long.prototype.toString.call(t.zeroCount):r.longs===Number?new f.LongBits(t.zeroCount.low>>>0,t.zeroCount.high>>>0).toNumber():t.zeroCount),t.positive!=null&&t.hasOwnProperty("positive")&&(u.positive=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.toObject(t.positive,r)),t.negative!=null&&t.hasOwnProperty("negative")&&(u.negative=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.toObject(t.negative,r)),t.flags!=null&&t.hasOwnProperty("flags")&&(u.flags=t.flags),t.exemplars&&t.exemplars.length){u.exemplars=[];for(var d=0;d<t.exemplars.length;++d)u.exemplars[d]=p.opentelemetry.proto.metrics.v1.Exemplar.toObject(t.exemplars[d],r)}return t.min!=null&&t.hasOwnProperty("min")&&(u.min=r.json&&!isFinite(t.min)?String(t.min):t.min,r.oneofs&&(u._min="min")),t.max!=null&&t.hasOwnProperty("max")&&(u.max=r.json&&!isFinite(t.max)?String(t.max):t.max,r.oneofs&&(u._max="max")),t.zeroThreshold!=null&&t.hasOwnProperty("zeroThreshold")&&(u.zeroThreshold=r.json&&!isFinite(t.zeroThreshold)?String(t.zeroThreshold):t.zeroThreshold),u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint"},l.Buckets=function(){function e(t){if(this.bucketCounts=[],t)for(var r=Object.keys(t),u=0;u<r.length;++u)t[r[u]]!=null&&(this[r[u]]=t[r[u]])}return e.prototype.offset=null,e.prototype.bucketCounts=f.emptyArray,e.create=function(r){return new e(r)},e.encode=function(r,u){if(u||(u=S.create()),r.offset!=null&&Object.hasOwnProperty.call(r,"offset")&&u.uint32(8).sint32(r.offset),r.bucketCounts!=null&&r.bucketCounts.length){u.uint32(18).fork();for(var s=0;s<r.bucketCounts.length;++s)u.uint64(r.bucketCounts[s]);u.ldelim()}return u},e.encodeDelimited=function(r,u){return this.encode(r,u).ldelim()},e.decode=function(r,u){r instanceof h||(r=h.create(r));for(var s=u===void 0?r.len:r.pos+u,d=new p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets;r.pos<s;){var v=r.uint32();switch(v>>>3){case 1:{d.offset=r.sint32();break}case 2:{if(d.bucketCounts&&d.bucketCounts.length||(d.bucketCounts=[]),(v&7)===2)for(var g=r.uint32()+r.pos;r.pos<g;)d.bucketCounts.push(r.uint64());else d.bucketCounts.push(r.uint64());break}default:r.skipType(v&7);break}}return d},e.decodeDelimited=function(r){return r instanceof h||(r=new h(r)),this.decode(r,r.uint32())},e.verify=function(r){if(typeof r!="object"||r===null)return"object expected";if(r.offset!=null&&r.hasOwnProperty("offset")&&!f.isInteger(r.offset))return"offset: integer expected";if(r.bucketCounts!=null&&r.hasOwnProperty("bucketCounts")){if(!Array.isArray(r.bucketCounts))return"bucketCounts: array expected";for(var u=0;u<r.bucketCounts.length;++u)if(!f.isInteger(r.bucketCounts[u])&&!(r.bucketCounts[u]&&f.isInteger(r.bucketCounts[u].low)&&f.isInteger(r.bucketCounts[u].high)))return"bucketCounts: integer|Long[] expected"}return null},e.fromObject=function(r){if(r instanceof p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets)return r;var u=new p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets;if(r.offset!=null&&(u.offset=r.offset|0),r.bucketCounts){if(!Array.isArray(r.bucketCounts))throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.bucketCounts: array expected");u.bucketCounts=[];for(var s=0;s<r.bucketCounts.length;++s)f.Long?(u.bucketCounts[s]=f.Long.fromValue(r.bucketCounts[s])).unsigned=!0:typeof r.bucketCounts[s]=="string"?u.bucketCounts[s]=parseInt(r.bucketCounts[s],10):typeof r.bucketCounts[s]=="number"?u.bucketCounts[s]=r.bucketCounts[s]:typeof r.bucketCounts[s]=="object"&&(u.bucketCounts[s]=new f.LongBits(r.bucketCounts[s].low>>>0,r.bucketCounts[s].high>>>0).toNumber(!0))}return u},e.toObject=function(r,u){u||(u={});var s={};if((u.arrays||u.defaults)&&(s.bucketCounts=[]),u.defaults&&(s.offset=0),r.offset!=null&&r.hasOwnProperty("offset")&&(s.offset=r.offset),r.bucketCounts&&r.bucketCounts.length){s.bucketCounts=[];for(var d=0;d<r.bucketCounts.length;++d)typeof r.bucketCounts[d]=="number"?s.bucketCounts[d]=u.longs===String?String(r.bucketCounts[d]):r.bucketCounts[d]:s.bucketCounts[d]=u.longs===String?f.Long.prototype.toString.call(r.bucketCounts[d]):u.longs===Number?new f.LongBits(r.bucketCounts[d].low>>>0,r.bucketCounts[d].high>>>0).toNumber(!0):r.bucketCounts[d]}return s},e.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},e.getTypeUrl=function(r){return r===void 0&&(r="type.googleapis.com"),r+"/opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets"},e}(),l}(),c.SummaryDataPoint=function(){function l(i){if(this.attributes=[],this.quantileValues=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.attributes=f.emptyArray,l.prototype.startTimeUnixNano=null,l.prototype.timeUnixNano=null,l.prototype.count=null,l.prototype.sum=null,l.prototype.quantileValues=f.emptyArray,l.prototype.flags=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.startTimeUnixNano!=null&&Object.hasOwnProperty.call(e,"startTimeUnixNano")&&t.uint32(17).fixed64(e.startTimeUnixNano),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,"timeUnixNano")&&t.uint32(25).fixed64(e.timeUnixNano),e.count!=null&&Object.hasOwnProperty.call(e,"count")&&t.uint32(33).fixed64(e.count),e.sum!=null&&Object.hasOwnProperty.call(e,"sum")&&t.uint32(41).double(e.sum),e.quantileValues!=null&&e.quantileValues.length)for(var r=0;r<e.quantileValues.length;++r)p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.encode(e.quantileValues[r],t.uint32(50).fork()).ldelim();if(e.attributes!=null&&e.attributes.length)for(var r=0;r<e.attributes.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[r],t.uint32(58).fork()).ldelim();return e.flags!=null&&Object.hasOwnProperty.call(e,"flags")&&t.uint32(64).uint32(e.flags),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.SummaryDataPoint;e.pos<r;){var s=e.uint32();switch(s>>>3){case 7:{u.attributes&&u.attributes.length||(u.attributes=[]),u.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}case 2:{u.startTimeUnixNano=e.fixed64();break}case 3:{u.timeUnixNano=e.fixed64();break}case 4:{u.count=e.fixed64();break}case 5:{u.sum=e.double();break}case 6:{u.quantileValues&&u.quantileValues.length||(u.quantileValues=[]),u.quantileValues.push(p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.decode(e,e.uint32()));break}case 8:{u.flags=e.uint32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.attributes!=null&&e.hasOwnProperty("attributes")){if(!Array.isArray(e.attributes))return"attributes: array expected";for(var t=0;t<e.attributes.length;++t){var r=p.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(r)return"attributes."+r}}if(e.startTimeUnixNano!=null&&e.hasOwnProperty("startTimeUnixNano")&&!f.isInteger(e.startTimeUnixNano)&&!(e.startTimeUnixNano&&f.isInteger(e.startTimeUnixNano.low)&&f.isInteger(e.startTimeUnixNano.high)))return"startTimeUnixNano: integer|Long expected";if(e.timeUnixNano!=null&&e.hasOwnProperty("timeUnixNano")&&!f.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&f.isInteger(e.timeUnixNano.low)&&f.isInteger(e.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(e.count!=null&&e.hasOwnProperty("count")&&!f.isInteger(e.count)&&!(e.count&&f.isInteger(e.count.low)&&f.isInteger(e.count.high)))return"count: integer|Long expected";if(e.sum!=null&&e.hasOwnProperty("sum")&&typeof e.sum!="number")return"sum: number expected";if(e.quantileValues!=null&&e.hasOwnProperty("quantileValues")){if(!Array.isArray(e.quantileValues))return"quantileValues: array expected";for(var t=0;t<e.quantileValues.length;++t){var r=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.verify(e.quantileValues[t]);if(r)return"quantileValues."+r}}return e.flags!=null&&e.hasOwnProperty("flags")&&!f.isInteger(e.flags)?"flags: integer expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.SummaryDataPoint)return e;var t=new p.opentelemetry.proto.metrics.v1.SummaryDataPoint;if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(".opentelemetry.proto.metrics.v1.SummaryDataPoint.attributes: array expected");t.attributes=[];for(var r=0;r<e.attributes.length;++r){if(typeof e.attributes[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.SummaryDataPoint.attributes: object expected");t.attributes[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[r])}}if(e.startTimeUnixNano!=null&&(f.Long?(t.startTimeUnixNano=f.Long.fromValue(e.startTimeUnixNano)).unsigned=!1:typeof e.startTimeUnixNano=="string"?t.startTimeUnixNano=parseInt(e.startTimeUnixNano,10):typeof e.startTimeUnixNano=="number"?t.startTimeUnixNano=e.startTimeUnixNano:typeof e.startTimeUnixNano=="object"&&(t.startTimeUnixNano=new f.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber())),e.timeUnixNano!=null&&(f.Long?(t.timeUnixNano=f.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano=="string"?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano=="number"?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano=="object"&&(t.timeUnixNano=new f.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.count!=null&&(f.Long?(t.count=f.Long.fromValue(e.count)).unsigned=!1:typeof e.count=="string"?t.count=parseInt(e.count,10):typeof e.count=="number"?t.count=e.count:typeof e.count=="object"&&(t.count=new f.LongBits(e.count.low>>>0,e.count.high>>>0).toNumber())),e.sum!=null&&(t.sum=Number(e.sum)),e.quantileValues){if(!Array.isArray(e.quantileValues))throw TypeError(".opentelemetry.proto.metrics.v1.SummaryDataPoint.quantileValues: array expected");t.quantileValues=[];for(var r=0;r<e.quantileValues.length;++r){if(typeof e.quantileValues[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.SummaryDataPoint.quantileValues: object expected");t.quantileValues[r]=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.fromObject(e.quantileValues[r])}}return e.flags!=null&&(t.flags=e.flags>>>0),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.quantileValues=[],r.attributes=[]),t.defaults){if(f.Long){var u=new f.Long(0,0,!1);r.startTimeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.startTimeUnixNano=t.longs===String?"0":0;if(f.Long){var u=new f.Long(0,0,!1);r.timeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.timeUnixNano=t.longs===String?"0":0;if(f.Long){var u=new f.Long(0,0,!1);r.count=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.count=t.longs===String?"0":0;r.sum=0,r.flags=0}if(e.startTimeUnixNano!=null&&e.hasOwnProperty("startTimeUnixNano")&&(typeof e.startTimeUnixNano=="number"?r.startTimeUnixNano=t.longs===String?String(e.startTimeUnixNano):e.startTimeUnixNano:r.startTimeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.startTimeUnixNano):t.longs===Number?new f.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber():e.startTimeUnixNano),e.timeUnixNano!=null&&e.hasOwnProperty("timeUnixNano")&&(typeof e.timeUnixNano=="number"?r.timeUnixNano=t.longs===String?String(e.timeUnixNano):e.timeUnixNano:r.timeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new f.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.count!=null&&e.hasOwnProperty("count")&&(typeof e.count=="number"?r.count=t.longs===String?String(e.count):e.count:r.count=t.longs===String?f.Long.prototype.toString.call(e.count):t.longs===Number?new f.LongBits(e.count.low>>>0,e.count.high>>>0).toNumber():e.count),e.sum!=null&&e.hasOwnProperty("sum")&&(r.sum=t.json&&!isFinite(e.sum)?String(e.sum):e.sum),e.quantileValues&&e.quantileValues.length){r.quantileValues=[];for(var s=0;s<e.quantileValues.length;++s)r.quantileValues[s]=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.toObject(e.quantileValues[s],t)}if(e.attributes&&e.attributes.length){r.attributes=[];for(var s=0;s<e.attributes.length;++s)r.attributes[s]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[s],t)}return e.flags!=null&&e.hasOwnProperty("flags")&&(r.flags=e.flags),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.SummaryDataPoint"},l.ValueAtQuantile=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.quantile=null,i.prototype.value=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.quantile!=null&&Object.hasOwnProperty.call(t,"quantile")&&r.uint32(9).double(t.quantile),t.value!=null&&Object.hasOwnProperty.call(t,"value")&&r.uint32(17).double(t.value),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.quantile=t.double();break}case 2:{s.value=t.double();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){return typeof t!="object"||t===null?"object expected":t.quantile!=null&&t.hasOwnProperty("quantile")&&typeof t.quantile!="number"?"quantile: number expected":t.value!=null&&t.hasOwnProperty("value")&&typeof t.value!="number"?"value: number expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile)return t;var r=new p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile;return t.quantile!=null&&(r.quantile=Number(t.quantile)),t.value!=null&&(r.value=Number(t.value)),r},i.toObject=function(t,r){r||(r={});var u={};return r.defaults&&(u.quantile=0,u.value=0),t.quantile!=null&&t.hasOwnProperty("quantile")&&(u.quantile=r.json&&!isFinite(t.quantile)?String(t.quantile):t.quantile),t.value!=null&&t.hasOwnProperty("value")&&(u.value=r.json&&!isFinite(t.value)?String(t.value):t.value),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile"},i}(),l}(),c.Exemplar=function(){function l(e){if(this.filteredAttributes=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.filteredAttributes=f.emptyArray,l.prototype.timeUnixNano=null,l.prototype.asDouble=null,l.prototype.asInt=null,l.prototype.spanId=null,l.prototype.traceId=null;var i;return Object.defineProperty(l.prototype,"value",{get:f.oneOfGetter(i=["asDouble","asInt"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){if(r||(r=S.create()),t.timeUnixNano!=null&&Object.hasOwnProperty.call(t,"timeUnixNano")&&r.uint32(17).fixed64(t.timeUnixNano),t.asDouble!=null&&Object.hasOwnProperty.call(t,"asDouble")&&r.uint32(25).double(t.asDouble),t.spanId!=null&&Object.hasOwnProperty.call(t,"spanId")&&r.uint32(34).bytes(t.spanId),t.traceId!=null&&Object.hasOwnProperty.call(t,"traceId")&&r.uint32(42).bytes(t.traceId),t.asInt!=null&&Object.hasOwnProperty.call(t,"asInt")&&r.uint32(49).sfixed64(t.asInt),t.filteredAttributes!=null&&t.filteredAttributes.length)for(var u=0;u<t.filteredAttributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.filteredAttributes[u],r.uint32(58).fork()).ldelim();return r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.Exemplar;t.pos<u;){var d=t.uint32();switch(d>>>3){case 7:{s.filteredAttributes&&s.filteredAttributes.length||(s.filteredAttributes=[]),s.filteredAttributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 2:{s.timeUnixNano=t.fixed64();break}case 3:{s.asDouble=t.double();break}case 6:{s.asInt=t.sfixed64();break}case 4:{s.spanId=t.bytes();break}case 5:{s.traceId=t.bytes();break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.filteredAttributes!=null&&t.hasOwnProperty("filteredAttributes")){if(!Array.isArray(t.filteredAttributes))return"filteredAttributes: array expected";for(var u=0;u<t.filteredAttributes.length;++u){var s=p.opentelemetry.proto.common.v1.KeyValue.verify(t.filteredAttributes[u]);if(s)return"filteredAttributes."+s}}if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&!f.isInteger(t.timeUnixNano)&&!(t.timeUnixNano&&f.isInteger(t.timeUnixNano.low)&&f.isInteger(t.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(t.asDouble!=null&&t.hasOwnProperty("asDouble")&&(r.value=1,typeof t.asDouble!="number"))return"asDouble: number expected";if(t.asInt!=null&&t.hasOwnProperty("asInt")){if(r.value===1)return"value: multiple values";if(r.value=1,!f.isInteger(t.asInt)&&!(t.asInt&&f.isInteger(t.asInt.low)&&f.isInteger(t.asInt.high)))return"asInt: integer|Long expected"}return t.spanId!=null&&t.hasOwnProperty("spanId")&&!(t.spanId&&typeof t.spanId.length=="number"||f.isString(t.spanId))?"spanId: buffer expected":t.traceId!=null&&t.hasOwnProperty("traceId")&&!(t.traceId&&typeof t.traceId.length=="number"||f.isString(t.traceId))?"traceId: buffer expected":null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.Exemplar)return t;var r=new p.opentelemetry.proto.metrics.v1.Exemplar;if(t.filteredAttributes){if(!Array.isArray(t.filteredAttributes))throw TypeError(".opentelemetry.proto.metrics.v1.Exemplar.filteredAttributes: array expected");r.filteredAttributes=[];for(var u=0;u<t.filteredAttributes.length;++u){if(typeof t.filteredAttributes[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Exemplar.filteredAttributes: object expected");r.filteredAttributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.filteredAttributes[u])}}return t.timeUnixNano!=null&&(f.Long?(r.timeUnixNano=f.Long.fromValue(t.timeUnixNano)).unsigned=!1:typeof t.timeUnixNano=="string"?r.timeUnixNano=parseInt(t.timeUnixNano,10):typeof t.timeUnixNano=="number"?r.timeUnixNano=t.timeUnixNano:typeof t.timeUnixNano=="object"&&(r.timeUnixNano=new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber())),t.asDouble!=null&&(r.asDouble=Number(t.asDouble)),t.asInt!=null&&(f.Long?(r.asInt=f.Long.fromValue(t.asInt)).unsigned=!1:typeof t.asInt=="string"?r.asInt=parseInt(t.asInt,10):typeof t.asInt=="number"?r.asInt=t.asInt:typeof t.asInt=="object"&&(r.asInt=new f.LongBits(t.asInt.low>>>0,t.asInt.high>>>0).toNumber())),t.spanId!=null&&(typeof t.spanId=="string"?f.base64.decode(t.spanId,r.spanId=f.newBuffer(f.base64.length(t.spanId)),0):t.spanId.length>=0&&(r.spanId=t.spanId)),t.traceId!=null&&(typeof t.traceId=="string"?f.base64.decode(t.traceId,r.traceId=f.newBuffer(f.base64.length(t.traceId)),0):t.traceId.length>=0&&(r.traceId=t.traceId)),r},l.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.filteredAttributes=[]),r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.timeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.timeUnixNano=r.longs===String?"0":0;r.bytes===String?u.spanId="":(u.spanId=[],r.bytes!==Array&&(u.spanId=f.newBuffer(u.spanId))),r.bytes===String?u.traceId="":(u.traceId=[],r.bytes!==Array&&(u.traceId=f.newBuffer(u.traceId)))}if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&(typeof t.timeUnixNano=="number"?u.timeUnixNano=r.longs===String?String(t.timeUnixNano):t.timeUnixNano:u.timeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.timeUnixNano):r.longs===Number?new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber():t.timeUnixNano),t.asDouble!=null&&t.hasOwnProperty("asDouble")&&(u.asDouble=r.json&&!isFinite(t.asDouble)?String(t.asDouble):t.asDouble,r.oneofs&&(u.value="asDouble")),t.spanId!=null&&t.hasOwnProperty("spanId")&&(u.spanId=r.bytes===String?f.base64.encode(t.spanId,0,t.spanId.length):r.bytes===Array?Array.prototype.slice.call(t.spanId):t.spanId),t.traceId!=null&&t.hasOwnProperty("traceId")&&(u.traceId=r.bytes===String?f.base64.encode(t.traceId,0,t.traceId.length):r.bytes===Array?Array.prototype.slice.call(t.traceId):t.traceId),t.asInt!=null&&t.hasOwnProperty("asInt")&&(typeof t.asInt=="number"?u.asInt=r.longs===String?String(t.asInt):t.asInt:u.asInt=r.longs===String?f.Long.prototype.toString.call(t.asInt):r.longs===Number?new f.LongBits(t.asInt.low>>>0,t.asInt.high>>>0).toNumber():t.asInt,r.oneofs&&(u.value="asInt")),t.filteredAttributes&&t.filteredAttributes.length){u.filteredAttributes=[];for(var d=0;d<t.filteredAttributes.length;++d)u.filteredAttributes[d]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.filteredAttributes[d],r)}return u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.Exemplar"},l}(),c}(),o}(),n.logs=function(){var o={};return o.v1=function(){var c={};return c.LogsData=function(){function l(i){if(this.resourceLogs=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resourceLogs=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resourceLogs!=null&&e.resourceLogs.length)for(var r=0;r<e.resourceLogs.length;++r)p.opentelemetry.proto.logs.v1.ResourceLogs.encode(e.resourceLogs[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.logs.v1.LogsData;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resourceLogs&&u.resourceLogs.length||(u.resourceLogs=[]),u.resourceLogs.push(p.opentelemetry.proto.logs.v1.ResourceLogs.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resourceLogs!=null&&e.hasOwnProperty("resourceLogs")){if(!Array.isArray(e.resourceLogs))return"resourceLogs: array expected";for(var t=0;t<e.resourceLogs.length;++t){var r=p.opentelemetry.proto.logs.v1.ResourceLogs.verify(e.resourceLogs[t]);if(r)return"resourceLogs."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.logs.v1.LogsData)return e;var t=new p.opentelemetry.proto.logs.v1.LogsData;if(e.resourceLogs){if(!Array.isArray(e.resourceLogs))throw TypeError(".opentelemetry.proto.logs.v1.LogsData.resourceLogs: array expected");t.resourceLogs=[];for(var r=0;r<e.resourceLogs.length;++r){if(typeof e.resourceLogs[r]!="object")throw TypeError(".opentelemetry.proto.logs.v1.LogsData.resourceLogs: object expected");t.resourceLogs[r]=p.opentelemetry.proto.logs.v1.ResourceLogs.fromObject(e.resourceLogs[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.resourceLogs=[]),e.resourceLogs&&e.resourceLogs.length){r.resourceLogs=[];for(var u=0;u<e.resourceLogs.length;++u)r.resourceLogs[u]=p.opentelemetry.proto.logs.v1.ResourceLogs.toObject(e.resourceLogs[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.logs.v1.LogsData"},l}(),c.ResourceLogs=function(){function l(i){if(this.scopeLogs=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resource=null,l.prototype.scopeLogs=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resource!=null&&Object.hasOwnProperty.call(e,"resource")&&p.opentelemetry.proto.resource.v1.Resource.encode(e.resource,t.uint32(10).fork()).ldelim(),e.scopeLogs!=null&&e.scopeLogs.length)for(var r=0;r<e.scopeLogs.length;++r)p.opentelemetry.proto.logs.v1.ScopeLogs.encode(e.scopeLogs[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.logs.v1.ResourceLogs;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resource=p.opentelemetry.proto.resource.v1.Resource.decode(e,e.uint32());break}case 2:{u.scopeLogs&&u.scopeLogs.length||(u.scopeLogs=[]),u.scopeLogs.push(p.opentelemetry.proto.logs.v1.ScopeLogs.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resource!=null&&e.hasOwnProperty("resource")){var t=p.opentelemetry.proto.resource.v1.Resource.verify(e.resource);if(t)return"resource."+t}if(e.scopeLogs!=null&&e.hasOwnProperty("scopeLogs")){if(!Array.isArray(e.scopeLogs))return"scopeLogs: array expected";for(var r=0;r<e.scopeLogs.length;++r){var t=p.opentelemetry.proto.logs.v1.ScopeLogs.verify(e.scopeLogs[r]);if(t)return"scopeLogs."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.logs.v1.ResourceLogs)return e;var t=new p.opentelemetry.proto.logs.v1.ResourceLogs;if(e.resource!=null){if(typeof e.resource!="object")throw TypeError(".opentelemetry.proto.logs.v1.ResourceLogs.resource: object expected");t.resource=p.opentelemetry.proto.resource.v1.Resource.fromObject(e.resource)}if(e.scopeLogs){if(!Array.isArray(e.scopeLogs))throw TypeError(".opentelemetry.proto.logs.v1.ResourceLogs.scopeLogs: array expected");t.scopeLogs=[];for(var r=0;r<e.scopeLogs.length;++r){if(typeof e.scopeLogs[r]!="object")throw TypeError(".opentelemetry.proto.logs.v1.ResourceLogs.scopeLogs: object expected");t.scopeLogs[r]=p.opentelemetry.proto.logs.v1.ScopeLogs.fromObject(e.scopeLogs[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.scopeLogs=[]),t.defaults&&(r.resource=null,r.schemaUrl=""),e.resource!=null&&e.hasOwnProperty("resource")&&(r.resource=p.opentelemetry.proto.resource.v1.Resource.toObject(e.resource,t)),e.scopeLogs&&e.scopeLogs.length){r.scopeLogs=[];for(var u=0;u<e.scopeLogs.length;++u)r.scopeLogs[u]=p.opentelemetry.proto.logs.v1.ScopeLogs.toObject(e.scopeLogs[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.logs.v1.ResourceLogs"},l}(),c.ScopeLogs=function(){function l(i){if(this.logRecords=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.scope=null,l.prototype.logRecords=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.scope!=null&&Object.hasOwnProperty.call(e,"scope")&&p.opentelemetry.proto.common.v1.InstrumentationScope.encode(e.scope,t.uint32(10).fork()).ldelim(),e.logRecords!=null&&e.logRecords.length)for(var r=0;r<e.logRecords.length;++r)p.opentelemetry.proto.logs.v1.LogRecord.encode(e.logRecords[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.logs.v1.ScopeLogs;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.decode(e,e.uint32());break}case 2:{u.logRecords&&u.logRecords.length||(u.logRecords=[]),u.logRecords.push(p.opentelemetry.proto.logs.v1.LogRecord.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.scope!=null&&e.hasOwnProperty("scope")){var t=p.opentelemetry.proto.common.v1.InstrumentationScope.verify(e.scope);if(t)return"scope."+t}if(e.logRecords!=null&&e.hasOwnProperty("logRecords")){if(!Array.isArray(e.logRecords))return"logRecords: array expected";for(var r=0;r<e.logRecords.length;++r){var t=p.opentelemetry.proto.logs.v1.LogRecord.verify(e.logRecords[r]);if(t)return"logRecords."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.logs.v1.ScopeLogs)return e;var t=new p.opentelemetry.proto.logs.v1.ScopeLogs;if(e.scope!=null){if(typeof e.scope!="object")throw TypeError(".opentelemetry.proto.logs.v1.ScopeLogs.scope: object expected");t.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.fromObject(e.scope)}if(e.logRecords){if(!Array.isArray(e.logRecords))throw TypeError(".opentelemetry.proto.logs.v1.ScopeLogs.logRecords: array expected");t.logRecords=[];for(var r=0;r<e.logRecords.length;++r){if(typeof e.logRecords[r]!="object")throw TypeError(".opentelemetry.proto.logs.v1.ScopeLogs.logRecords: object expected");t.logRecords[r]=p.opentelemetry.proto.logs.v1.LogRecord.fromObject(e.logRecords[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.logRecords=[]),t.defaults&&(r.scope=null,r.schemaUrl=""),e.scope!=null&&e.hasOwnProperty("scope")&&(r.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.toObject(e.scope,t)),e.logRecords&&e.logRecords.length){r.logRecords=[];for(var u=0;u<e.logRecords.length;++u)r.logRecords[u]=p.opentelemetry.proto.logs.v1.LogRecord.toObject(e.logRecords[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.logs.v1.ScopeLogs"},l}(),c.SeverityNumber=function(){var l={},i=Object.create(l);return i[l[0]="SEVERITY_NUMBER_UNSPECIFIED"]=0,i[l[1]="SEVERITY_NUMBER_TRACE"]=1,i[l[2]="SEVERITY_NUMBER_TRACE2"]=2,i[l[3]="SEVERITY_NUMBER_TRACE3"]=3,i[l[4]="SEVERITY_NUMBER_TRACE4"]=4,i[l[5]="SEVERITY_NUMBER_DEBUG"]=5,i[l[6]="SEVERITY_NUMBER_DEBUG2"]=6,i[l[7]="SEVERITY_NUMBER_DEBUG3"]=7,i[l[8]="SEVERITY_NUMBER_DEBUG4"]=8,i[l[9]="SEVERITY_NUMBER_INFO"]=9,i[l[10]="SEVERITY_NUMBER_INFO2"]=10,i[l[11]="SEVERITY_NUMBER_INFO3"]=11,i[l[12]="SEVERITY_NUMBER_INFO4"]=12,i[l[13]="SEVERITY_NUMBER_WARN"]=13,i[l[14]="SEVERITY_NUMBER_WARN2"]=14,i[l[15]="SEVERITY_NUMBER_WARN3"]=15,i[l[16]="SEVERITY_NUMBER_WARN4"]=16,i[l[17]="SEVERITY_NUMBER_ERROR"]=17,i[l[18]="SEVERITY_NUMBER_ERROR2"]=18,i[l[19]="SEVERITY_NUMBER_ERROR3"]=19,i[l[20]="SEVERITY_NUMBER_ERROR4"]=20,i[l[21]="SEVERITY_NUMBER_FATAL"]=21,i[l[22]="SEVERITY_NUMBER_FATAL2"]=22,i[l[23]="SEVERITY_NUMBER_FATAL3"]=23,i[l[24]="SEVERITY_NUMBER_FATAL4"]=24,i}(),c.LogRecordFlags=function(){var l={},i=Object.create(l);return i[l[0]="LOG_RECORD_FLAGS_DO_NOT_USE"]=0,i[l[255]="LOG_RECORD_FLAGS_TRACE_FLAGS_MASK"]=255,i}(),c.LogRecord=function(){function l(i){if(this.attributes=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.timeUnixNano=null,l.prototype.observedTimeUnixNano=null,l.prototype.severityNumber=null,l.prototype.severityText=null,l.prototype.body=null,l.prototype.attributes=f.emptyArray,l.prototype.droppedAttributesCount=null,l.prototype.flags=null,l.prototype.traceId=null,l.prototype.spanId=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,"timeUnixNano")&&t.uint32(9).fixed64(e.timeUnixNano),e.severityNumber!=null&&Object.hasOwnProperty.call(e,"severityNumber")&&t.uint32(16).int32(e.severityNumber),e.severityText!=null&&Object.hasOwnProperty.call(e,"severityText")&&t.uint32(26).string(e.severityText),e.body!=null&&Object.hasOwnProperty.call(e,"body")&&p.opentelemetry.proto.common.v1.AnyValue.encode(e.body,t.uint32(42).fork()).ldelim(),e.attributes!=null&&e.attributes.length)for(var r=0;r<e.attributes.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[r],t.uint32(50).fork()).ldelim();return e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,"droppedAttributesCount")&&t.uint32(56).uint32(e.droppedAttributesCount),e.flags!=null&&Object.hasOwnProperty.call(e,"flags")&&t.uint32(69).fixed32(e.flags),e.traceId!=null&&Object.hasOwnProperty.call(e,"traceId")&&t.uint32(74).bytes(e.traceId),e.spanId!=null&&Object.hasOwnProperty.call(e,"spanId")&&t.uint32(82).bytes(e.spanId),e.observedTimeUnixNano!=null&&Object.hasOwnProperty.call(e,"observedTimeUnixNano")&&t.uint32(89).fixed64(e.observedTimeUnixNano),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.logs.v1.LogRecord;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.timeUnixNano=e.fixed64();break}case 11:{u.observedTimeUnixNano=e.fixed64();break}case 2:{u.severityNumber=e.int32();break}case 3:{u.severityText=e.string();break}case 5:{u.body=p.opentelemetry.proto.common.v1.AnyValue.decode(e,e.uint32());break}case 6:{u.attributes&&u.attributes.length||(u.attributes=[]),u.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}case 7:{u.droppedAttributesCount=e.uint32();break}case 8:{u.flags=e.fixed32();break}case 9:{u.traceId=e.bytes();break}case 10:{u.spanId=e.bytes();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.timeUnixNano!=null&&e.hasOwnProperty("timeUnixNano")&&!f.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&f.isInteger(e.timeUnixNano.low)&&f.isInteger(e.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(e.observedTimeUnixNano!=null&&e.hasOwnProperty("observedTimeUnixNano")&&!f.isInteger(e.observedTimeUnixNano)&&!(e.observedTimeUnixNano&&f.isInteger(e.observedTimeUnixNano.low)&&f.isInteger(e.observedTimeUnixNano.high)))return"observedTimeUnixNano: integer|Long expected";if(e.severityNumber!=null&&e.hasOwnProperty("severityNumber"))switch(e.severityNumber){default:return"severityNumber: enum value expected";case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:case 8:case 9:case 10:case 11:case 12:case 13:case 14:case 15:case 16:case 17:case 18:case 19:case 20:case 21:case 22:case 23:case 24:break}if(e.severityText!=null&&e.hasOwnProperty("severityText")&&!f.isString(e.severityText))return"severityText: string expected";if(e.body!=null&&e.hasOwnProperty("body")){var t=p.opentelemetry.proto.common.v1.AnyValue.verify(e.body);if(t)return"body."+t}if(e.attributes!=null&&e.hasOwnProperty("attributes")){if(!Array.isArray(e.attributes))return"attributes: array expected";for(var r=0;r<e.attributes.length;++r){var t=p.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[r]);if(t)return"attributes."+t}}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(e.droppedAttributesCount)?"droppedAttributesCount: integer expected":e.flags!=null&&e.hasOwnProperty("flags")&&!f.isInteger(e.flags)?"flags: integer expected":e.traceId!=null&&e.hasOwnProperty("traceId")&&!(e.traceId&&typeof e.traceId.length=="number"||f.isString(e.traceId))?"traceId: buffer expected":e.spanId!=null&&e.hasOwnProperty("spanId")&&!(e.spanId&&typeof e.spanId.length=="number"||f.isString(e.spanId))?"spanId: buffer expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.logs.v1.LogRecord)return e;var t=new p.opentelemetry.proto.logs.v1.LogRecord;switch(e.timeUnixNano!=null&&(f.Long?(t.timeUnixNano=f.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano=="string"?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano=="number"?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano=="object"&&(t.timeUnixNano=new f.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.observedTimeUnixNano!=null&&(f.Long?(t.observedTimeUnixNano=f.Long.fromValue(e.observedTimeUnixNano)).unsigned=!1:typeof e.observedTimeUnixNano=="string"?t.observedTimeUnixNano=parseInt(e.observedTimeUnixNano,10):typeof e.observedTimeUnixNano=="number"?t.observedTimeUnixNano=e.observedTimeUnixNano:typeof e.observedTimeUnixNano=="object"&&(t.observedTimeUnixNano=new f.LongBits(e.observedTimeUnixNano.low>>>0,e.observedTimeUnixNano.high>>>0).toNumber())),e.severityNumber){default:if(typeof e.severityNumber=="number"){t.severityNumber=e.severityNumber;break}break;case"SEVERITY_NUMBER_UNSPECIFIED":case 0:t.severityNumber=0;break;case"SEVERITY_NUMBER_TRACE":case 1:t.severityNumber=1;break;case"SEVERITY_NUMBER_TRACE2":case 2:t.severityNumber=2;break;case"SEVERITY_NUMBER_TRACE3":case 3:t.severityNumber=3;break;case"SEVERITY_NUMBER_TRACE4":case 4:t.severityNumber=4;break;case"SEVERITY_NUMBER_DEBUG":case 5:t.severityNumber=5;break;case"SEVERITY_NUMBER_DEBUG2":case 6:t.severityNumber=6;break;case"SEVERITY_NUMBER_DEBUG3":case 7:t.severityNumber=7;break;case"SEVERITY_NUMBER_DEBUG4":case 8:t.severityNumber=8;break;case"SEVERITY_NUMBER_INFO":case 9:t.severityNumber=9;break;case"SEVERITY_NUMBER_INFO2":case 10:t.severityNumber=10;break;case"SEVERITY_NUMBER_INFO3":case 11:t.severityNumber=11;break;case"SEVERITY_NUMBER_INFO4":case 12:t.severityNumber=12;break;case"SEVERITY_NUMBER_WARN":case 13:t.severityNumber=13;break;case"SEVERITY_NUMBER_WARN2":case 14:t.severityNumber=14;break;case"SEVERITY_NUMBER_WARN3":case 15:t.severityNumber=15;break;case"SEVERITY_NUMBER_WARN4":case 16:t.severityNumber=16;break;case"SEVERITY_NUMBER_ERROR":case 17:t.severityNumber=17;break;case"SEVERITY_NUMBER_ERROR2":case 18:t.severityNumber=18;break;case"SEVERITY_NUMBER_ERROR3":case 19:t.severityNumber=19;break;case"SEVERITY_NUMBER_ERROR4":case 20:t.severityNumber=20;break;case"SEVERITY_NUMBER_FATAL":case 21:t.severityNumber=21;break;case"SEVERITY_NUMBER_FATAL2":case 22:t.severityNumber=22;break;case"SEVERITY_NUMBER_FATAL3":case 23:t.severityNumber=23;break;case"SEVERITY_NUMBER_FATAL4":case 24:t.severityNumber=24;break}if(e.severityText!=null&&(t.severityText=String(e.severityText)),e.body!=null){if(typeof e.body!="object")throw TypeError(".opentelemetry.proto.logs.v1.LogRecord.body: object expected");t.body=p.opentelemetry.proto.common.v1.AnyValue.fromObject(e.body)}if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(".opentelemetry.proto.logs.v1.LogRecord.attributes: array expected");t.attributes=[];for(var r=0;r<e.attributes.length;++r){if(typeof e.attributes[r]!="object")throw TypeError(".opentelemetry.proto.logs.v1.LogRecord.attributes: object expected");t.attributes[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[r])}}return e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),e.flags!=null&&(t.flags=e.flags>>>0),e.traceId!=null&&(typeof e.traceId=="string"?f.base64.decode(e.traceId,t.traceId=f.newBuffer(f.base64.length(e.traceId)),0):e.traceId.length>=0&&(t.traceId=e.traceId)),e.spanId!=null&&(typeof e.spanId=="string"?f.base64.decode(e.spanId,t.spanId=f.newBuffer(f.base64.length(e.spanId)),0):e.spanId.length>=0&&(t.spanId=e.spanId)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.attributes=[]),t.defaults){if(f.Long){var u=new f.Long(0,0,!1);r.timeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.timeUnixNano=t.longs===String?"0":0;if(r.severityNumber=t.enums===String?"SEVERITY_NUMBER_UNSPECIFIED":0,r.severityText="",r.body=null,r.droppedAttributesCount=0,r.flags=0,t.bytes===String?r.traceId="":(r.traceId=[],t.bytes!==Array&&(r.traceId=f.newBuffer(r.traceId))),t.bytes===String?r.spanId="":(r.spanId=[],t.bytes!==Array&&(r.spanId=f.newBuffer(r.spanId))),f.Long){var u=new f.Long(0,0,!1);r.observedTimeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.observedTimeUnixNano=t.longs===String?"0":0}if(e.timeUnixNano!=null&&e.hasOwnProperty("timeUnixNano")&&(typeof e.timeUnixNano=="number"?r.timeUnixNano=t.longs===String?String(e.timeUnixNano):e.timeUnixNano:r.timeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new f.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.severityNumber!=null&&e.hasOwnProperty("severityNumber")&&(r.severityNumber=t.enums===String?p.opentelemetry.proto.logs.v1.SeverityNumber[e.severityNumber]===void 0?e.severityNumber:p.opentelemetry.proto.logs.v1.SeverityNumber[e.severityNumber]:e.severityNumber),e.severityText!=null&&e.hasOwnProperty("severityText")&&(r.severityText=e.severityText),e.body!=null&&e.hasOwnProperty("body")&&(r.body=p.opentelemetry.proto.common.v1.AnyValue.toObject(e.body,t)),e.attributes&&e.attributes.length){r.attributes=[];for(var s=0;s<e.attributes.length;++s)r.attributes[s]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[s],t)}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&(r.droppedAttributesCount=e.droppedAttributesCount),e.flags!=null&&e.hasOwnProperty("flags")&&(r.flags=e.flags),e.traceId!=null&&e.hasOwnProperty("traceId")&&(r.traceId=t.bytes===String?f.base64.encode(e.traceId,0,e.traceId.length):t.bytes===Array?Array.prototype.slice.call(e.traceId):e.traceId),e.spanId!=null&&e.hasOwnProperty("spanId")&&(r.spanId=t.bytes===String?f.base64.encode(e.spanId,0,e.spanId.length):t.bytes===Array?Array.prototype.slice.call(e.spanId):e.spanId),e.observedTimeUnixNano!=null&&e.hasOwnProperty("observedTimeUnixNano")&&(typeof e.observedTimeUnixNano=="number"?r.observedTimeUnixNano=t.longs===String?String(e.observedTimeUnixNano):e.observedTimeUnixNano:r.observedTimeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.observedTimeUnixNano):t.longs===Number?new f.LongBits(e.observedTimeUnixNano.low>>>0,e.observedTimeUnixNano.high>>>0).toNumber():e.observedTimeUnixNano),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.logs.v1.LogRecord"},l}(),c}(),o}(),n}(),a}();Ol.exports=p});var To=m(Re=>{"use strict";Object.defineProperty(Re,"__esModule",{value:!0});Re.ServiceClientType=void 0;var wf;(function(a){a[a.SPANS=0]="SPANS",a[a.METRICS=1]="METRICS",a[a.LOGS=2]="LOGS"})(wf=Re.ServiceClientType||(Re.ServiceClientType={}))});var go=m(Fr=>{"use strict";Object.defineProperty(Fr,"__esModule",{value:!0});Fr.getExportRequestProto=void 0;var Oo=gl(),Al=To();function Cf(a){return a===Al.ServiceClientType.SPANS?Oo.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest:a===Al.ServiceClientType.LOGS?Oo.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest:Oo.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest}Fr.getExportRequestProto=Cf});var Nl=m(qr=>{"use strict";Object.defineProperty(qr,"__esModule",{value:!0});qr.OTLPProtoExporterBrowserBase=void 0;var Uf=(b(),D(y)),Ao=gu(),Mf=go(),No=class extends Ao.OTLPExporterBrowserBase{constructor(n={}){super(n)}send(n,o,c){if(this._shutdownOnce.isCalled){Uf.diag.debug("Shutdown already started. Cannot send objects");return}let l=this.convert(n),i=(0,Mf.getExportRequestProto)(this.getServiceClientType()),e=i.create(l);if(e){let t=i.encode(e).finish();t&&(0,Ao.sendWithXhr)(new Blob([t],{type:"application/x-protobuf"}),this.url,Object.assign(Object.assign({},this._headers),{"Content-Type":"application/x-protobuf",Accept:"application/x-protobuf"}),this.timeoutMillis,o,c)}else c(new Ao.OTLPExporterError("No proto"))}};qr.OTLPProtoExporterBrowserBase=No});var Pl=m(ue=>{"use strict";Object.defineProperty(ue,"__esModule",{value:!0});ue.ServiceClientType=ue.OTLPProtoExporterBrowserBase=void 0;var Df=Nl();Object.defineProperty(ue,"OTLPProtoExporterBrowserBase",{enumerable:!0,get:function(){return Df.OTLPProtoExporterBrowserBase}});var kf=To();Object.defineProperty(ue,"ServiceClientType",{enumerable:!0,get:function(){return kf.ServiceClientType}})});b();var $t=N(k());b();var C=N(k()),gt=N(Ot());var ki="exception";var Hs=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},js=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Bi=function(){function a(n,o,c,l,i,e,t,r,u,s){t===void 0&&(t=[]),this.attributes={},this.links=[],this.events=[],this._droppedAttributesCount=0,this._droppedEventsCount=0,this._droppedLinksCount=0,this.status={code:y.SpanStatusCode.UNSET},this.endTime=[0,0],this._ended=!1,this._duration=[-1,-1],this.name=c,this._spanContext=l,this.parentSpanId=e,this.kind=i,this.links=t;var d=Date.now();this._performanceStartTime=C.otperformance.now(),this._performanceOffset=d-(this._performanceStartTime+(0,C.getTimeOrigin)()),this._startTimeProvided=r!=null,this.startTime=this._getTime(r??d),this.resource=n.resource,this.instrumentationLibrary=n.instrumentationLibrary,this._spanLimits=n.getSpanLimits(),s!=null&&this.setAttributes(s),this._spanProcessor=n.getActiveSpanProcessor(),this._spanProcessor.onStart(this,o),this._attributeValueLengthLimit=this._spanLimits.attributeValueLengthLimit||0}return a.prototype.spanContext=function(){return this._spanContext},a.prototype.setAttribute=function(n,o){return o==null||this._isSpanEnded()?this:n.length===0?(y.diag.warn("Invalid attribute key: "+n),this):(0,C.isAttributeValue)(o)?Object.keys(this.attributes).length>=this._spanLimits.attributeCountLimit&&!Object.prototype.hasOwnProperty.call(this.attributes,n)?(this._droppedAttributesCount++,this):(this.attributes[n]=this._truncateToSize(o),this):(y.diag.warn("Invalid attribute value set for key: "+n),this)},a.prototype.setAttributes=function(n){var o,c;try{for(var l=Hs(Object.entries(n)),i=l.next();!i.done;i=l.next()){var e=js(i.value,2),t=e[0],r=e[1];this.setAttribute(t,r)}}catch(u){o={error:u}}finally{try{i&&!i.done&&(c=l.return)&&c.call(l)}finally{if(o)throw o.error}}return this},a.prototype.addEvent=function(n,o,c){if(this._isSpanEnded())return this;if(this._spanLimits.eventCountLimit===0)return y.diag.warn("No events allowed."),this._droppedEventsCount++,this;this.events.length>=this._spanLimits.eventCountLimit&&(y.diag.warn("Dropping extra events."),this.events.shift(),this._droppedEventsCount++),(0,C.isTimeInput)(o)&&((0,C.isTimeInput)(c)||(c=o),o=void 0);var l=(0,C.sanitizeAttributes)(o);return this.events.push({name:n,attributes:l,time:this._getTime(c),droppedAttributesCount:0}),this},a.prototype.setStatus=function(n){return this._isSpanEnded()?this:(this.status=n,this)},a.prototype.updateName=function(n){return this._isSpanEnded()?this:(this.name=n,this)},a.prototype.end=function(n){if(this._isSpanEnded()){y.diag.error(this.name+" "+this._spanContext.traceId+"-"+this._spanContext.spanId+" - You can only call end() on a span once.");return}this._ended=!0,this.endTime=this._getTime(n),this._duration=(0,C.hrTimeDuration)(this.startTime,this.endTime),this._duration[0]<0&&(y.diag.warn("Inconsistent start and end time, startTime > endTime. Setting span duration to 0ms.",this.startTime,this.endTime),this.endTime=this.startTime.slice(),this._duration=[0,0]),this._spanProcessor.onEnd(this)},a.prototype._getTime=function(n){if(typeof n=="number"&&n<C.otperformance.now())return(0,C.hrTime)(n+this._performanceOffset);if(typeof n=="number")return(0,C.millisToHrTime)(n);if(n instanceof Date)return(0,C.millisToHrTime)(n.getTime());if((0,C.isTimeInputHrTime)(n))return n;if(this._startTimeProvided)return(0,C.millisToHrTime)(Date.now());var o=C.otperformance.now()-this._performanceStartTime;return(0,C.addHrTimes)(this.startTime,(0,C.millisToHrTime)(o))},a.prototype.isRecording=function(){return this._ended===!1},a.prototype.recordException=function(n,o){var c={};typeof n=="string"?c[gt.SemanticAttributes.EXCEPTION_MESSAGE]=n:n&&(n.code?c[gt.SemanticAttributes.EXCEPTION_TYPE]=n.code.toString():n.name&&(c[gt.SemanticAttributes.EXCEPTION_TYPE]=n.name),n.message&&(c[gt.SemanticAttributes.EXCEPTION_MESSAGE]=n.message),n.stack&&(c[gt.SemanticAttributes.EXCEPTION_STACKTRACE]=n.stack)),c[gt.SemanticAttributes.EXCEPTION_TYPE]||c[gt.SemanticAttributes.EXCEPTION_MESSAGE]?this.addEvent(ki,c,o):y.diag.warn("Failed to record an exception "+n)},Object.defineProperty(a.prototype,"duration",{get:function(){return this._duration},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"ended",{get:function(){return this._ended},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"droppedAttributesCount",{get:function(){return this._droppedAttributesCount},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"droppedEventsCount",{get:function(){return this._droppedEventsCount},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"droppedLinksCount",{get:function(){return this._droppedLinksCount},enumerable:!1,configurable:!0}),a.prototype._isSpanEnded=function(){return this._ended&&y.diag.warn("Can not execute the operation on ended Span {traceId: "+this._spanContext.traceId+", spanId: "+this._spanContext.spanId+"}"),this._ended},a.prototype._truncateToLimitUtil=function(n,o){return n.length<=o?n:n.substr(0,o)},a.prototype._truncateToSize=function(n){var o=this,c=this._attributeValueLengthLimit;return c<=0?(y.diag.warn("Attribute value limit must be positive, got "+c),n):typeof n=="string"?this._truncateToLimitUtil(n,c):Array.isArray(n)?n.map(function(l){return typeof l=="string"?o._truncateToLimitUtil(l,c):l}):n},a}();b();var G=N(k());var pt;(function(a){a[a.NOT_RECORD=0]="NOT_RECORD",a[a.RECORD=1]="RECORD",a[a.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED"})(pt||(pt={}));var ft=function(){function a(){}return a.prototype.shouldSample=function(){return{decision:pt.NOT_RECORD}},a.prototype.toString=function(){return"AlwaysOffSampler"},a}();var $=function(){function a(){}return a.prototype.shouldSample=function(){return{decision:pt.RECORD_AND_SAMPLED}},a.prototype.toString=function(){return"AlwaysOnSampler"},a}();b();var Vi=N(k());var At=function(){function a(n){var o,c,l,i;this._root=n.root,this._root||((0,Vi.globalErrorHandler)(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new $),this._remoteParentSampled=(o=n.remoteParentSampled)!==null&&o!==void 0?o:new $,this._remoteParentNotSampled=(c=n.remoteParentNotSampled)!==null&&c!==void 0?c:new ft,this._localParentSampled=(l=n.localParentSampled)!==null&&l!==void 0?l:new $,this._localParentNotSampled=(i=n.localParentNotSampled)!==null&&i!==void 0?i:new ft}return a.prototype.shouldSample=function(n,o,c,l,i,e){var t=y.trace.getSpanContext(n);return!t||!(0,y.isSpanContextValid)(t)?this._root.shouldSample(n,o,c,l,i,e):t.isRemote?t.traceFlags&y.TraceFlags.SAMPLED?this._remoteParentSampled.shouldSample(n,o,c,l,i,e):this._remoteParentNotSampled.shouldSample(n,o,c,l,i,e):t.traceFlags&y.TraceFlags.SAMPLED?this._localParentSampled.shouldSample(n,o,c,l,i,e):this._localParentNotSampled.shouldSample(n,o,c,l,i,e)},a.prototype.toString=function(){return"ParentBased{root="+this._root.toString()+", remoteParentSampled="+this._remoteParentSampled.toString()+", remoteParentNotSampled="+this._remoteParentNotSampled.toString()+", localParentSampled="+this._localParentSampled.toString()+", localParentNotSampled="+this._localParentNotSampled.toString()+"}"},a}();b();var Jt=function(){function a(n){n===void 0&&(n=0),this._ratio=n,this._ratio=this._normalize(n),this._upperBound=Math.floor(this._ratio*4294967295)}return a.prototype.shouldSample=function(n,o){return{decision:(0,y.isValidTraceId)(o)&&this._accumulate(o)<this._upperBound?pt.RECORD_AND_SAMPLED:pt.NOT_RECORD}},a.prototype.toString=function(){return"TraceIdRatioBased{"+this._ratio+"}"},a.prototype._normalize=function(n){return typeof n!="number"||isNaN(n)?0:n>=1?1:n<=0?0:n},a.prototype._accumulate=function(n){for(var o=0,c=0;c<n.length/8;c++){var l=c*8,i=parseInt(n.slice(l,l+8),16);o=(o^i)>>>0}return o},a}();var Fs=(0,G.getEnv)(),qs=G.TracesSamplerValues.AlwaysOn,zt=1;function fr(){return{sampler:In(Fs),forceFlushTimeoutMillis:3e4,generalLimits:{attributeValueLengthLimit:(0,G.getEnv)().OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:(0,G.getEnv)().OTEL_ATTRIBUTE_COUNT_LIMIT},spanLimits:{attributeValueLengthLimit:(0,G.getEnv)().OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:(0,G.getEnv)().OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT,linkCountLimit:(0,G.getEnv)().OTEL_SPAN_LINK_COUNT_LIMIT,eventCountLimit:(0,G.getEnv)().OTEL_SPAN_EVENT_COUNT_LIMIT,attributePerEventCountLimit:(0,G.getEnv)().OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT,attributePerLinkCountLimit:(0,G.getEnv)().OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT}}}function In(a){switch(a===void 0&&(a=(0,G.getEnv)()),a.OTEL_TRACES_SAMPLER){case G.TracesSamplerValues.AlwaysOn:return new $;case G.TracesSamplerValues.AlwaysOff:return new ft;case G.TracesSamplerValues.ParentBasedAlwaysOn:return new At({root:new $});case G.TracesSamplerValues.ParentBasedAlwaysOff:return new At({root:new ft});case G.TracesSamplerValues.TraceIdRatio:return new Jt(Gi(a));case G.TracesSamplerValues.ParentBasedTraceIdRatio:return new At({root:new Jt(Gi(a))});default:return y.diag.error('OTEL_TRACES_SAMPLER value "'+a.OTEL_TRACES_SAMPLER+" invalid, defaulting to "+qs+'".'),new $}}function Gi(a){if(a.OTEL_TRACES_SAMPLER_ARG===void 0||a.OTEL_TRACES_SAMPLER_ARG==="")return y.diag.error("OTEL_TRACES_SAMPLER_ARG is blank, defaulting to "+zt+"."),zt;var n=Number(a.OTEL_TRACES_SAMPLER_ARG);return isNaN(n)?(y.diag.error("OTEL_TRACES_SAMPLER_ARG="+a.OTEL_TRACES_SAMPLER_ARG+" was given, but it is invalid, defaulting to "+zt+"."),zt):n<0||n>1?(y.diag.error("OTEL_TRACES_SAMPLER_ARG="+a.OTEL_TRACES_SAMPLER_ARG+" was given, but it is out of range ([0..1]), defaulting to "+zt+"."),zt):n}var Wt=N(k());function Hi(a){var n={sampler:In()},o=fr(),c=Object.assign({},o,n,a);return c.generalLimits=Object.assign({},o.generalLimits,a.generalLimits||{}),c.spanLimits=Object.assign({},o.spanLimits,a.spanLimits||{}),c}function ji(a){var n,o,c,l,i,e,t,r,u,s,d,v,g=Object.assign({},a.spanLimits),x=(0,Wt.getEnvWithoutDefaults)();return g.attributeCountLimit=(e=(i=(l=(o=(n=a.spanLimits)===null||n===void 0?void 0:n.attributeCountLimit)!==null&&o!==void 0?o:(c=a.generalLimits)===null||c===void 0?void 0:c.attributeCountLimit)!==null&&l!==void 0?l:x.OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT)!==null&&i!==void 0?i:x.OTEL_ATTRIBUTE_COUNT_LIMIT)!==null&&e!==void 0?e:Wt.DEFAULT_ATTRIBUTE_COUNT_LIMIT,g.attributeValueLengthLimit=(v=(d=(s=(r=(t=a.spanLimits)===null||t===void 0?void 0:t.attributeValueLengthLimit)!==null&&r!==void 0?r:(u=a.generalLimits)===null||u===void 0?void 0:u.attributeValueLengthLimit)!==null&&s!==void 0?s:x.OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT)!==null&&d!==void 0?d:x.OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT)!==null&&v!==void 0?v:Wt.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT,Object.assign({},a,{spanLimits:g})}b();var W=N(k()),Fi=function(){function a(n,o){this._exporter=n,this._isExporting=!1,this._finishedSpans=[],this._droppedSpansCount=0;var c=(0,W.getEnv)();this._maxExportBatchSize=typeof o?.maxExportBatchSize=="number"?o.maxExportBatchSize:c.OTEL_BSP_MAX_EXPORT_BATCH_SIZE,this._maxQueueSize=typeof o?.maxQueueSize=="number"?o.maxQueueSize:c.OTEL_BSP_MAX_QUEUE_SIZE,this._scheduledDelayMillis=typeof o?.scheduledDelayMillis=="number"?o.scheduledDelayMillis:c.OTEL_BSP_SCHEDULE_DELAY,this._exportTimeoutMillis=typeof o?.exportTimeoutMillis=="number"?o.exportTimeoutMillis:c.OTEL_BSP_EXPORT_TIMEOUT,this._shutdownOnce=new W.BindOnceFuture(this._shutdown,this),this._maxExportBatchSize>this._maxQueueSize&&(y.diag.warn("BatchSpanProcessor: maxExportBatchSize must be smaller or equal to maxQueueSize, setting maxExportBatchSize to match maxQueueSize"),this._maxExportBatchSize=this._maxQueueSize)}return a.prototype.forceFlush=function(){return this._shutdownOnce.isCalled?this._shutdownOnce.promise:this._flushAll()},a.prototype.onStart=function(n,o){},a.prototype.onEnd=function(n){this._shutdownOnce.isCalled||n.spanContext().traceFlags&y.TraceFlags.SAMPLED&&this._addToBuffer(n)},a.prototype.shutdown=function(){return this._shutdownOnce.call()},a.prototype._shutdown=function(){var n=this;return Promise.resolve().then(function(){return n.onShutdown()}).then(function(){return n._flushAll()}).then(function(){return n._exporter.shutdown()})},a.prototype._addToBuffer=function(n){if(this._finishedSpans.length>=this._maxQueueSize){this._droppedSpansCount===0&&y.diag.debug("maxQueueSize reached, dropping spans"),this._droppedSpansCount++;return}this._droppedSpansCount>0&&(y.diag.warn("Dropped "+this._droppedSpansCount+" spans because maxQueueSize reached"),this._droppedSpansCount=0),this._finishedSpans.push(n),this._maybeStartTimer()},a.prototype._flushAll=function(){var n=this;return new Promise(function(o,c){for(var l=[],i=Math.ceil(n._finishedSpans.length/n._maxExportBatchSize),e=0,t=i;e<t;e++)l.push(n._flushOneBatch());Promise.all(l).then(function(){o()}).catch(c)})},a.prototype._flushOneBatch=function(){var n=this;return this._clearTimer(),this._finishedSpans.length===0?Promise.resolve():new Promise(function(o,c){var l=setTimeout(function(){c(new Error("Timeout"))},n._exportTimeoutMillis);y.context.with((0,W.suppressTracing)(y.context.active()),function(){var i=n._finishedSpans.splice(0,n._maxExportBatchSize),e=function(){return n._exporter.export(i,function(r){var u;clearTimeout(l),r.code===W.ExportResultCode.SUCCESS?o():c((u=r.error)!==null&&u!==void 0?u:new Error("BatchSpanProcessor: span export failed"))})},t=i.map(function(r){return r.resource}).filter(function(r){return r.asyncAttributesPending});t.length===0?e():Promise.all(t.map(function(r){var u;return(u=r.waitForAsyncAttributes)===null||u===void 0?void 0:u.call(r)})).then(e,function(r){(0,W.globalErrorHandler)(r),c(r)})})})},a.prototype._maybeStartTimer=function(){var n=this;if(!this._isExporting){var o=function(){n._isExporting=!0,n._flushOneBatch().then(function(){n._isExporting=!1,n._finishedSpans.length>0&&(n._clearTimer(),n._maybeStartTimer())}).catch(function(c){n._isExporting=!1,(0,W.globalErrorHandler)(c)})};if(this._finishedSpans.length>=this._maxExportBatchSize)return o();this._timer===void 0&&(this._timer=setTimeout(function(){return o()},this._scheduledDelayMillis),(0,W.unrefTimer)(this._timer))}},a.prototype._clearTimer=function(){this._timer!==void 0&&(clearTimeout(this._timer),this._timer=void 0)},a}();var Ks=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),ve=function(a){Ks(n,a);function n(o,c){var l=a.call(this,o,c)||this;return l.onInit(c),l}return n.prototype.onInit=function(o){var c=this;o?.disableAutoFlushOnDocumentHide!==!0&&typeof document<"u"&&(this._visibilityChangeListener=function(){document.visibilityState==="hidden"&&c.forceFlush()},this._pageHideListener=function(){c.forceFlush()},document.addEventListener("visibilitychange",this._visibilityChangeListener),document.addEventListener("pagehide",this._pageHideListener))},n.prototype.onShutdown=function(){typeof document<"u"&&(this._visibilityChangeListener&&document.removeEventListener("visibilitychange",this._visibilityChangeListener),this._pageHideListener&&document.removeEventListener("pagehide",this._pageHideListener))},n}(Fi);var Xs=8,Ys=16,yr=function(){function a(){this.generateTraceId=qi(Ys),this.generateSpanId=qi(Xs)}return a}();var dr=Array(32);function qi(a){return function(){for(var o=0;o<a*2;o++)dr[o]=Math.floor(Math.random()*16)+48,dr[o]>=58&&(dr[o]+=39);return String.fromCharCode.apply(null,dr.slice(0,a*2))}}var Ki=function(){function a(n,o,c){this._tracerProvider=c;var l=Hi(o);this._sampler=l.sampler,this._generalLimits=l.generalLimits,this._spanLimits=l.spanLimits,this._idGenerator=o.idGenerator||new yr,this.resource=c.resource,this.instrumentationLibrary=n}return a.prototype.startSpan=function(n,o,c){var l,i,e;o===void 0&&(o={}),c===void 0&&(c=y.context.active()),o.root&&(c=y.trace.deleteSpan(c));var t=y.trace.getSpan(c);if((0,$t.isTracingSuppressed)(c)){y.diag.debug("Instrumentation suppressed, returning Noop Span");var r=y.trace.wrapSpanContext(y.INVALID_SPAN_CONTEXT);return r}var u=t?.spanContext(),s=this._idGenerator.generateSpanId(),d,v,g;!u||!y.trace.isSpanContextValid(u)?d=this._idGenerator.generateTraceId():(d=u.traceId,v=u.traceState,g=u.spanId);var x=(l=o.kind)!==null&&l!==void 0?l:y.SpanKind.INTERNAL,I=((i=o.links)!==null&&i!==void 0?i:[]).map(function(Ie){return{context:Ie.context,attributes:(0,$t.sanitizeAttributes)(Ie.attributes)}}),F=(0,$t.sanitizeAttributes)(o.attributes),R=this._sampler.shouldSample(c,d,n,x,F,I);v=(e=R.traceState)!==null&&e!==void 0?e:v;var T=R.decision===y.SamplingDecision.RECORD_AND_SAMPLED?y.TraceFlags.SAMPLED:y.TraceFlags.NONE,st={traceId:d,spanId:s,traceFlags:T,traceState:v};if(R.decision===y.SamplingDecision.NOT_RECORD){y.diag.debug("Recording is off, propagating context in a non-recording span");var r=y.trace.wrapSpanContext(st);return r}var Le=(0,$t.sanitizeAttributes)(Object.assign(F,R.attributes)),Xr=new Bi(this,c,n,st,x,g,I,o.startTime,void 0,Le);return Xr},a.prototype.startActiveSpan=function(n,o,c,l){var i,e,t;if(!(arguments.length<2)){arguments.length===2?t=o:arguments.length===3?(i=o,t=c):(i=o,e=c,t=l);var r=e??y.context.active(),u=this.startSpan(n,i,r),s=y.trace.setSpan(r,u);return y.context.with(s,t,void 0,u)}},a.prototype.getGeneralLimits=function(){return this._generalLimits},a.prototype.getSpanLimits=function(){return this._spanLimits},a.prototype.getActiveSpanProcessor=function(){return this._tracerProvider.getActiveSpanProcessor()},a}();b();var rt=N(k());b();var Nt=N(Ot()),hr=N(k());function Xi(){return"unknown_service"}var Pt=function(){return Pt=Object.assign||function(a){for(var n,o=1,c=arguments.length;o<c;o++){n=arguments[o];for(var l in n)Object.prototype.hasOwnProperty.call(n,l)&&(a[l]=n[l])}return a},Pt.apply(this,arguments)},Js=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},zs=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Ws=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Y=function(){function a(n,o){var c=this,l;this._attributes=n,this.asyncAttributesPending=o!=null,this._syncAttributes=(l=this._attributes)!==null&&l!==void 0?l:{},this._asyncAttributesPromise=o?.then(function(i){return c._attributes=Object.assign({},c._attributes,i),c.asyncAttributesPending=!1,i},function(i){return y.diag.debug("a resource's async attributes promise rejected: %s",i),c.asyncAttributesPending=!1,{}})}return a.empty=function(){return a.EMPTY},a.default=function(){var n;return new a((n={},n[Nt.SemanticResourceAttributes.SERVICE_NAME]=Xi(),n[Nt.SemanticResourceAttributes.TELEMETRY_SDK_LANGUAGE]=hr.SDK_INFO[Nt.SemanticResourceAttributes.TELEMETRY_SDK_LANGUAGE],n[Nt.SemanticResourceAttributes.TELEMETRY_SDK_NAME]=hr.SDK_INFO[Nt.SemanticResourceAttributes.TELEMETRY_SDK_NAME],n[Nt.SemanticResourceAttributes.TELEMETRY_SDK_VERSION]=hr.SDK_INFO[Nt.SemanticResourceAttributes.TELEMETRY_SDK_VERSION],n))},Object.defineProperty(a.prototype,"attributes",{get:function(){var n;return this.asyncAttributesPending&&y.diag.error("Accessing resource attributes before async attributes settled"),(n=this._attributes)!==null&&n!==void 0?n:{}},enumerable:!1,configurable:!0}),a.prototype.waitForAsyncAttributes=function(){return Js(this,void 0,void 0,function(){return zs(this,function(n){switch(n.label){case 0:return this.asyncAttributesPending?[4,this._asyncAttributesPromise]:[3,2];case 1:n.sent(),n.label=2;case 2:return[2]}})})},a.prototype.merge=function(n){var o=this,c;if(!n)return this;var l=Pt(Pt({},this._syncAttributes),(c=n._syncAttributes)!==null&&c!==void 0?c:n.attributes);if(!this._asyncAttributesPromise&&!n._asyncAttributesPromise)return new a(l);var i=Promise.all([this._asyncAttributesPromise,n._asyncAttributesPromise]).then(function(e){var t,r=Ws(e,2),u=r[0],s=r[1];return Pt(Pt(Pt(Pt({},o._syncAttributes),u),(t=n._syncAttributes)!==null&&t!==void 0?t:n.attributes),s)});return new a(l,i)},a.EMPTY=new a({}),a}();b();var Yi=N(k()),Ji=N(Ot());var $s=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},Qs=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Zs=function(){function a(){this._MAX_LENGTH=255,this._COMMA_SEPARATOR=",",this._LABEL_KEY_VALUE_SPLITTER="=",this._ERROR_MESSAGE_INVALID_CHARS="should be a ASCII string with a length greater than 0 and not exceed "+this._MAX_LENGTH+" characters.",this._ERROR_MESSAGE_INVALID_VALUE="should be a ASCII string with a length not exceed "+this._MAX_LENGTH+" characters."}return a.prototype.detect=function(n){var o={},c=(0,Yi.getEnv)(),l=c.OTEL_RESOURCE_ATTRIBUTES,i=c.OTEL_SERVICE_NAME;if(l)try{var e=this._parseResourceAttributes(l);Object.assign(o,e)}catch(t){y.diag.debug("EnvDetector failed: "+t.message)}return i&&(o[Ji.SemanticResourceAttributes.SERVICE_NAME]=i),new Y(o)},a.prototype._parseResourceAttributes=function(n){var o,c;if(!n)return{};var l={},i=n.split(this._COMMA_SEPARATOR,-1);try{for(var e=$s(i),t=e.next();!t.done;t=e.next()){var r=t.value,u=r.split(this._LABEL_KEY_VALUE_SPLITTER,-1);if(u.length===2){var s=Qs(u,2),d=s[0],v=s[1];if(d=d.trim(),v=v.trim().split(/^"|"$/).join(""),!this._isValidAndNotEmpty(d))throw new Error("Attribute key "+this._ERROR_MESSAGE_INVALID_CHARS);if(!this._isValid(v))throw new Error("Attribute value "+this._ERROR_MESSAGE_INVALID_VALUE);l[d]=decodeURIComponent(v)}}}catch(g){o={error:g}}finally{try{t&&!t.done&&(c=e.return)&&c.call(e)}finally{if(o)throw o.error}}return l},a.prototype._isValid=function(n){return n.length<=this._MAX_LENGTH&&this._isBaggageOctetString(n)},a.prototype._isBaggageOctetString=function(n){for(var o=0;o<n.length;o++){var c=n.charCodeAt(o);if(c<33||c===44||c===59||c===92||c>126)return!1}return!0},a.prototype._isValidAndNotEmpty=function(n){return n.length>0&&this._isValid(n)},a}(),zi=new Zs;b();var Wi=function(a){return a!==null&&typeof a=="object"&&typeof a.then=="function"};var tp=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},ep=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}};var $i=function(a){var n;a===void 0&&(a={});var o=((n=a.detectors)!==null&&n!==void 0?n:[]).map(function(l){try{var i=l.detect(a),e;if(Wi(i)){var t=function(){return tp(void 0,void 0,void 0,function(){var r;return ep(this,function(u){switch(u.label){case 0:return[4,i];case 1:return r=u.sent(),[2,r.attributes]}})})};e=new Y({},t())}else e=i;return e.waitForAsyncAttributes?e.waitForAsyncAttributes().then(function(){return y.diag.debug(l.constructor.name+" found resource.",e)}):y.diag.debug(l.constructor.name+" found resource.",e),e}catch(r){return y.diag.error(l.constructor.name+" failed: "+r.message),Y.empty()}}),c=o.reduce(function(l,i){return l.merge(i)},Y.empty());return c.waitForAsyncAttributes&&c.waitForAsyncAttributes().then(function(){rp(o)}),c},rp=function(a){a.forEach(function(n){if(Object.keys(n.attributes).length>0){var o=JSON.stringify(n.attributes,null,4);y.diag.verbose(o)}})};var Qi=N(k()),mr=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},Zi=function(){function a(n){this._spanProcessors=n}return a.prototype.forceFlush=function(){var n,o,c=[];try{for(var l=mr(this._spanProcessors),i=l.next();!i.done;i=l.next()){var e=i.value;c.push(e.forceFlush())}}catch(t){n={error:t}}finally{try{i&&!i.done&&(o=l.return)&&o.call(l)}finally{if(n)throw n.error}}return new Promise(function(t){Promise.all(c).then(function(){t()}).catch(function(r){(0,Qi.globalErrorHandler)(r||new Error("MultiSpanProcessor: forceFlush failed")),t()})})},a.prototype.onStart=function(n,o){var c,l;try{for(var i=mr(this._spanProcessors),e=i.next();!e.done;e=i.next()){var t=e.value;t.onStart(n,o)}}catch(r){c={error:r}}finally{try{e&&!e.done&&(l=i.return)&&l.call(i)}finally{if(c)throw c.error}}},a.prototype.onEnd=function(n){var o,c;try{for(var l=mr(this._spanProcessors),i=l.next();!i.done;i=l.next()){var e=i.value;e.onEnd(n)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(c=l.return)&&c.call(l)}finally{if(o)throw o.error}}},a.prototype.shutdown=function(){var n,o,c=[];try{for(var l=mr(this._spanProcessors),i=l.next();!i.done;i=l.next()){var e=i.value;c.push(e.shutdown())}}catch(t){n={error:t}}finally{try{i&&!i.done&&(o=l.return)&&o.call(l)}finally{if(n)throw n.error}}return new Promise(function(t,r){Promise.all(c).then(function(){t()},r)})},a}();var ta=function(){function a(){}return a.prototype.onStart=function(n,o){},a.prototype.onEnd=function(n){},a.prototype.shutdown=function(){return Promise.resolve()},a.prototype.forceFlush=function(){return Promise.resolve()},a}();var Gt;(function(a){a[a.resolved=0]="resolved",a[a.timeout=1]="timeout",a[a.error=2]="error",a[a.unresolved=3]="unresolved"})(Gt||(Gt={}));var ea=function(){function a(n){n===void 0&&(n={});var o;this._registeredSpanProcessors=[],this._tracers=new Map;var c=(0,rt.merge)({},fr(),ji(n));this.resource=(o=c.resource)!==null&&o!==void 0?o:Y.empty(),this.resource=Y.default().merge(this.resource),this._config=Object.assign({},c,{resource:this.resource});var l=this._buildExporterFromEnv();if(l!==void 0){var i=new ve(l);this.activeSpanProcessor=i}else this.activeSpanProcessor=new ta}return a.prototype.getTracer=function(n,o,c){var l=n+"@"+(o||"")+":"+(c?.schemaUrl||"");return this._tracers.has(l)||this._tracers.set(l,new Ki({name:n,version:o,schemaUrl:c?.schemaUrl},this._config,this)),this._tracers.get(l)},a.prototype.addSpanProcessor=function(n){this._registeredSpanProcessors.length===0&&this.activeSpanProcessor.shutdown().catch(function(o){return y.diag.error("Error while trying to shutdown current span processor",o)}),this._registeredSpanProcessors.push(n),this.activeSpanProcessor=new Zi(this._registeredSpanProcessors)},a.prototype.getActiveSpanProcessor=function(){return this.activeSpanProcessor},a.prototype.register=function(n){n===void 0&&(n={}),y.trace.setGlobalTracerProvider(this),n.propagator===void 0&&(n.propagator=this._buildPropagatorFromEnv()),n.contextManager&&y.context.setGlobalContextManager(n.contextManager),n.propagator&&y.propagation.setGlobalPropagator(n.propagator)},a.prototype.forceFlush=function(){var n=this._config.forceFlushTimeoutMillis,o=this._registeredSpanProcessors.map(function(c){return new Promise(function(l){var i,e=setTimeout(function(){l(new Error("Span processor did not completed within timeout period of "+n+" ms")),i=Gt.timeout},n);c.forceFlush().then(function(){clearTimeout(e),i!==Gt.timeout&&(i=Gt.resolved,l(i))}).catch(function(t){clearTimeout(e),i=Gt.error,l(t)})})});return new Promise(function(c,l){Promise.all(o).then(function(i){var e=i.filter(function(t){return t!==Gt.resolved});e.length>0?l(e):c()}).catch(function(i){return l([i])})})},a.prototype.shutdown=function(){return this.activeSpanProcessor.shutdown()},a.prototype._getPropagator=function(n){var o;return(o=this.constructor._registeredPropagators.get(n))===null||o===void 0?void 0:o()},a.prototype._getSpanExporter=function(n){var o;return(o=this.constructor._registeredExporters.get(n))===null||o===void 0?void 0:o()},a.prototype._buildPropagatorFromEnv=function(){var n=this,o=Array.from(new Set((0,rt.getEnv)().OTEL_PROPAGATORS)),c=o.map(function(i){var e=n._getPropagator(i);return e||y.diag.warn('Propagator "'+i+'" requested through environment variable is unavailable.'),e}),l=c.reduce(function(i,e){return e&&i.push(e),i},[]);if(l.length!==0)return o.length===1?l[0]:new rt.CompositePropagator({propagators:l})},a.prototype._buildExporterFromEnv=function(){var n=(0,rt.getEnv)().OTEL_TRACES_EXPORTER;if(!(n==="none"||n==="")){var o=this._getSpanExporter(n);return o||y.diag.error('Exporter "'+n+'" requested through environment variable is unavailable.'),o}},a._registeredPropagators=new Map([["tracecontext",function(){return new rt.W3CTraceContextPropagator}],["baggage",function(){return new rt.W3CBaggagePropagator}]]),a._registeredExporters=new Map,a}();b();var dt={};tt(dt,Xy);import*as Xy from"@opentelemetry/api-logs";var Ml=N(ia(),1);b();var _r=N(k());b();b();b();var Qt=N(k()),ap=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},up=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},aa=function(){function a(n,o,c){this.attributes={},this.totalAttributesCount=0,this._isReadonly=!1;var l=c.timestamp,i=c.observedTimestamp,e=c.severityNumber,t=c.severityText,r=c.body,u=c.attributes,s=u===void 0?{}:u,d=c.context,v=Date.now();if(this.hrTime=(0,Qt.timeInputToHrTime)(l??v),this.hrTimeObserved=(0,Qt.timeInputToHrTime)(i??v),d){var g=y.trace.getSpanContext(d);g&&y.isSpanContextValid(g)&&(this.spanContext=g)}this.severityNumber=e,this.severityText=t,this.body=r,this.resource=n.resource,this.instrumentationScope=o,this._logRecordLimits=n.logRecordLimits,this.setAttributes(s)}return Object.defineProperty(a.prototype,"severityText",{get:function(){return this._severityText},set:function(n){this._isLogRecordReadonly()||(this._severityText=n)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"severityNumber",{get:function(){return this._severityNumber},set:function(n){this._isLogRecordReadonly()||(this._severityNumber=n)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"body",{get:function(){return this._body},set:function(n){this._isLogRecordReadonly()||(this._body=n)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"droppedAttributesCount",{get:function(){return this.totalAttributesCount-Object.keys(this.attributes).length},enumerable:!1,configurable:!0}),a.prototype.setAttribute=function(n,o){return this._isLogRecordReadonly()?this:o===null?this:n.length===0?(y.diag.warn("Invalid attribute key: "+n),this):!(0,Qt.isAttributeValue)(o)&&!(typeof o=="object"&&!Array.isArray(o)&&Object.keys(o).length>0)?(y.diag.warn("Invalid attribute value set for key: "+n),this):(this.totalAttributesCount+=1,Object.keys(this.attributes).length>=this._logRecordLimits.attributeCountLimit&&!Object.prototype.hasOwnProperty.call(this.attributes,n)?this:((0,Qt.isAttributeValue)(o)?this.attributes[n]=this._truncateToSize(o):this.attributes[n]=o,this))},a.prototype.setAttributes=function(n){var o,c;try{for(var l=ap(Object.entries(n)),i=l.next();!i.done;i=l.next()){var e=up(i.value,2),t=e[0],r=e[1];this.setAttribute(t,r)}}catch(u){o={error:u}}finally{try{i&&!i.done&&(c=l.return)&&c.call(l)}finally{if(o)throw o.error}}return this},a.prototype.setBody=function(n){return this.body=n,this},a.prototype.setSeverityNumber=function(n){return this.severityNumber=n,this},a.prototype.setSeverityText=function(n){return this.severityText=n,this},a.prototype._makeReadonly=function(){this._isReadonly=!0},a.prototype._truncateToSize=function(n){var o=this,c=this._logRecordLimits.attributeValueLengthLimit;return c<=0?(y.diag.warn("Attribute value limit must be positive, got "+c),n):typeof n=="string"?this._truncateToLimitUtil(n,c):Array.isArray(n)?n.map(function(l){return typeof l=="string"?o._truncateToLimitUtil(l,c):l}):n},a.prototype._truncateToLimitUtil=function(n,o){return n.length<=o?n:n.substring(0,o)},a.prototype._isLogRecordReadonly=function(){return this._isReadonly&&y.diag.warn("Can not execute the operation on emitted log record"),this._isReadonly},a}();var Cn=function(){return Cn=Object.assign||function(a){for(var n,o=1,c=arguments.length;o<c;o++){n=arguments[o];for(var l in n)Object.prototype.hasOwnProperty.call(n,l)&&(a[l]=n[l])}return a},Cn.apply(this,arguments)},ua=function(){function a(n,o){this.instrumentationScope=n,this._sharedState=o}return a.prototype.emit=function(n){var o=n.context||y.context.active(),c=new aa(this._sharedState,this.instrumentationScope,Cn({context:o},n));this._sharedState.activeProcessor.onEmit(c,o),c._makeReadonly()},a}();var yt=N(k());function la(){return{forceFlushTimeoutMillis:3e4,logRecordLimits:{attributeValueLengthLimit:(0,yt.getEnv)().OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:(0,yt.getEnv)().OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT},includeTraceContext:!0}}function ca(a){var n,o,c,l,i,e,t=(0,yt.getEnvWithoutDefaults)();return{attributeCountLimit:(c=(o=(n=a.attributeCountLimit)!==null&&n!==void 0?n:t.OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT)!==null&&o!==void 0?o:t.OTEL_ATTRIBUTE_COUNT_LIMIT)!==null&&c!==void 0?c:yt.DEFAULT_ATTRIBUTE_COUNT_LIMIT,attributeValueLengthLimit:(e=(i=(l=a.attributeValueLengthLimit)!==null&&l!==void 0?l:t.OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT)!==null&&i!==void 0?i:t.OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT)!==null&&e!==void 0?e:yt.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT}}var fa=N(k()),sa=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},pa=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},da=function(){function a(n,o){this.processors=n,this.forceFlushTimeoutMillis=o}return a.prototype.forceFlush=function(){return sa(this,void 0,void 0,function(){var n;return pa(this,function(o){switch(o.label){case 0:return n=this.forceFlushTimeoutMillis,[4,Promise.all(this.processors.map(function(c){return(0,fa.callWithTimeout)(c.forceFlush(),n)}))];case 1:return o.sent(),[2]}})})},a.prototype.onEmit=function(n,o){this.processors.forEach(function(c){return c.onEmit(n,o)})},a.prototype.shutdown=function(){return sa(this,void 0,void 0,function(){return pa(this,function(n){switch(n.label){case 0:return[4,Promise.all(this.processors.map(function(o){return o.shutdown()}))];case 1:return n.sent(),[2]}})})},a}();var ya=function(){function a(){}return a.prototype.forceFlush=function(){return Promise.resolve()},a.prototype.onEmit=function(n,o){},a.prototype.shutdown=function(){return Promise.resolve()},a}();var ha=function(){function a(n,o,c){this.resource=n,this.forceFlushTimeoutMillis=o,this.logRecordLimits=c,this.loggers=new Map,this.registeredLogRecordProcessors=[],this.activeProcessor=new ya}return a}();var lp="unknown",Un=function(){function a(n){n===void 0&&(n={});var o=(0,_r.merge)({},la(),n),c=o.resource,l=c===void 0?Y.default():c,i=o.logRecordLimits,e=o.forceFlushTimeoutMillis;this._sharedState=new ha(l,e,ca(i)),this._shutdownOnce=new _r.BindOnceFuture(this._shutdown,this)}return a.prototype.getLogger=function(n,o,c){if(this._shutdownOnce.isCalled)return y.diag.warn("A shutdown LoggerProvider cannot provide a Logger"),dt.NOOP_LOGGER;n||y.diag.warn("Logger requested without instrumentation scope name.");var l=n||lp,i=l+"@"+(o||"")+":"+(c?.schemaUrl||"");return this._sharedState.loggers.has(i)||this._sharedState.loggers.set(i,new ua({name:l,version:o,schemaUrl:c?.schemaUrl},this._sharedState)),this._sharedState.loggers.get(i)},a.prototype.addLogRecordProcessor=function(n){this._sharedState.registeredLogRecordProcessors.length===0&&this._sharedState.activeProcessor.shutdown().catch(function(o){return y.diag.error("Error while trying to shutdown current log record processor",o)}),this._sharedState.registeredLogRecordProcessors.push(n),this._sharedState.activeProcessor=new da(this._sharedState.registeredLogRecordProcessors,this._sharedState.forceFlushTimeoutMillis)},a.prototype.forceFlush=function(){return this._shutdownOnce.isCalled?(y.diag.warn("invalid attempt to force flush after LoggerProvider shutdown"),this._shutdownOnce.promise):this._sharedState.activeProcessor.forceFlush()},a.prototype.shutdown=function(){return this._shutdownOnce.isCalled?(y.diag.warn("shutdown may only be called once per LoggerProvider"),this._shutdownOnce.promise):this._shutdownOnce.call()},a.prototype._shutdown=function(){return this._sharedState.activeProcessor.shutdown()},a}();var Er;(function(a){a[a.DELTA=0]="DELTA",a[a.CUMULATIVE=1]="CUMULATIVE"})(Er||(Er={}));var cp=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),ma=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},va=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}};var sp=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")};function _a(a){return a!=null}function Ea(a){var n=Object.keys(a);return n.length===0?"":(n=n.sort(),JSON.stringify(n.map(function(o){return[o,a[o]]})))}function ba(a){var n,o;return a.name+":"+((n=a.version)!==null&&n!==void 0?n:"")+":"+((o=a.schemaUrl)!==null&&o!==void 0?o:"")}var pp=function(a){cp(n,a);function n(o){var c=a.call(this,o)||this;return Object.setPrototypeOf(c,n.prototype),c}return n}(Error);function Mn(a,n){var o,c=new Promise(function(i,e){o=setTimeout(function(){e(new pp("Operation timed out."))},n)});return Promise.race([a,c]).then(function(l){return clearTimeout(o),l},function(l){throw clearTimeout(o),l})}function Sa(a){return ma(this,void 0,void 0,function(){var n=this;return va(this,function(o){return[2,Promise.all(a.map(function(c){return ma(n,void 0,void 0,function(){var l,i;return va(this,function(e){switch(e.label){case 0:return e.trys.push([0,2,,3]),[4,c];case 1:return l=e.sent(),[2,{status:"fulfilled",value:l}];case 2:return i=e.sent(),[2,{status:"rejected",reason:i}];case 3:return[2]}})})}))]})})}function Ta(a){return a.status==="rejected"}function Oa(a,n){var o,c;if(a.size!==n.size)return!1;try{for(var l=sp(a),i=l.next();!i.done;i=l.next()){var e=i.value;if(!n.has(e))return!1}}catch(t){o={error:t}}finally{try{i&&!i.done&&(c=l.return)&&c.call(l)}finally{if(o)throw o.error}}return!0}function ga(a,n){return a.toLowerCase()===n.toLowerCase()}b();var ht;(function(a){a.COUNTER="COUNTER",a.HISTOGRAM="HISTOGRAM",a.UP_DOWN_COUNTER="UP_DOWN_COUNTER",a.OBSERVABLE_COUNTER="OBSERVABLE_COUNTER",a.OBSERVABLE_GAUGE="OBSERVABLE_GAUGE",a.OBSERVABLE_UP_DOWN_COUNTER="OBSERVABLE_UP_DOWN_COUNTER"})(ht||(ht={}));function mt(a,n,o){var c,l,i,e;return dp(a)||y.diag.warn('Invalid metric name: "'+a+'". The metric name should be a ASCII string with a length no greater than 255 characters.'),{name:a,type:n,description:(c=o?.description)!==null&&c!==void 0?c:"",unit:(l=o?.unit)!==null&&l!==void 0?l:"",valueType:(i=o?.valueType)!==null&&i!==void 0?i:y.ValueType.DOUBLE,advice:(e=o?.advice)!==null&&e!==void 0?e:{}}}function Aa(a,n){var o,c;return{name:(o=a.name)!==null&&o!==void 0?o:n.name,description:(c=a.description)!==null&&c!==void 0?c:n.description,type:n.type,unit:n.unit,valueType:n.valueType,advice:n.advice}}function Na(a,n){return ga(a.name,n.name)&&a.unit===n.unit&&a.type===n.type&&a.valueType===n.valueType}var fp=/^[a-z][a-z0-9_.\-/]{0,254}$/i;function dp(a){return a.match(fp)!=null}b();var Pa=function(){function a(){this._registeredViews=[]}return a.prototype.addView=function(n){this._registeredViews.push(n)},a.prototype.findViews=function(n,o){var c=this,l=this._registeredViews.filter(function(i){return c._matchInstrument(i.instrumentSelector,n)&&c._matchMeter(i.meterSelector,o)});return l},a.prototype._matchInstrument=function(n,o){return(n.getType()===void 0||o.type===n.getType())&&n.getNameFilter().match(o.name)&&n.getUnitFilter().match(o.unit)},a.prototype._matchMeter=function(n,o){return n.getNameFilter().match(o.name)&&(o.version===void 0||n.getVersionFilter().match(o.version))&&(o.schemaUrl===void 0||n.getSchemaUrlFilter().match(o.schemaUrl))},a}();b();var xa=N(k()),Zt=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),Dn=function(){function a(n,o){this._writableMetricStorage=n,this._descriptor=o}return a.prototype._record=function(n,o,c){if(o===void 0&&(o={}),c===void 0&&(c=y.context.active()),typeof n!="number"){y.diag.warn("non-number value provided to metric "+this._descriptor.name+": "+n);return}this._descriptor.valueType===y.ValueType.INT&&!Number.isInteger(n)&&(y.diag.warn("INT value type cannot accept a floating-point value for "+this._descriptor.name+", ignoring the fractional digits."),n=Math.trunc(n),!Number.isInteger(n))||this._writableMetricStorage.record(n,o,c,(0,xa.millisToHrTime)(Date.now()))},a}();var Ra=function(a){Zt(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n.prototype.add=function(o,c,l){this._record(o,c,l)},n}(Dn);var La=function(a){Zt(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n.prototype.add=function(o,c,l){if(o<0){y.diag.warn("negative value provided to counter "+this._descriptor.name+": "+o);return}this._record(o,c,l)},n}(Dn);var Ia=function(a){Zt(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n.prototype.record=function(o,c,l){if(o<0){y.diag.warn("negative value provided to histogram "+this._descriptor.name+": "+o);return}this._record(o,c,l)},n}(Dn);var br=function(){function a(n,o,c){this._observableRegistry=c,this._descriptor=n,this._metricStorages=o}return a.prototype.addCallback=function(n){this._observableRegistry.addCallback(n,this)},a.prototype.removeCallback=function(n){this._observableRegistry.removeCallback(n,this)},a}();var wa=function(a){Zt(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n}(br);var Ca=function(a){Zt(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n}(br);var Ua=function(a){Zt(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n}(br);function _e(a){return a instanceof br}var Ma=function(){function a(n){this._meterSharedState=n}return a.prototype.createHistogram=function(n,o){var c=mt(n,ht.HISTOGRAM,o),l=this._meterSharedState.registerMetricStorage(c);return new Ia(l,c)},a.prototype.createCounter=function(n,o){var c=mt(n,ht.COUNTER,o),l=this._meterSharedState.registerMetricStorage(c);return new La(l,c)},a.prototype.createUpDownCounter=function(n,o){var c=mt(n,ht.UP_DOWN_COUNTER,o),l=this._meterSharedState.registerMetricStorage(c);return new Ra(l,c)},a.prototype.createObservableGauge=function(n,o){var c=mt(n,ht.OBSERVABLE_GAUGE,o),l=this._meterSharedState.registerAsyncMetricStorage(c);return new Ca(c,l,this._meterSharedState.observableRegistry)},a.prototype.createObservableCounter=function(n,o){var c=mt(n,ht.OBSERVABLE_COUNTER,o),l=this._meterSharedState.registerAsyncMetricStorage(c);return new wa(c,l,this._meterSharedState.observableRegistry)},a.prototype.createObservableUpDownCounter=function(n,o){var c=mt(n,ht.OBSERVABLE_UP_DOWN_COUNTER,o),l=this._meterSharedState.registerAsyncMetricStorage(c);return new Ua(c,l,this._meterSharedState.observableRegistry)},a.prototype.addBatchObservableCallback=function(n,o){this._meterSharedState.observableRegistry.addBatchCallback(n,o)},a.prototype.removeBatchObservableCallback=function(n,o){this._meterSharedState.observableRegistry.removeBatchCallback(n,o)},a}();var Sr=function(){function a(n){this._instrumentDescriptor=n}return a.prototype.getInstrumentDescriptor=function(){return this._instrumentDescriptor},a.prototype.updateDescription=function(n){this._instrumentDescriptor=mt(this._instrumentDescriptor.name,this._instrumentDescriptor.type,{description:n,valueType:this._instrumentDescriptor.valueType,unit:this._instrumentDescriptor.unit,advice:this._instrumentDescriptor.advice})},a}();var yp=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),Da=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},hp=function(){function a(n){this._hash=n,this._valueMap=new Map,this._keyMap=new Map}return a.prototype.get=function(n,o){return o??(o=this._hash(n)),this._valueMap.get(o)},a.prototype.getOrDefault=function(n,o){var c=this._hash(n);if(this._valueMap.has(c))return this._valueMap.get(c);var l=o();return this._keyMap.has(c)||this._keyMap.set(c,n),this._valueMap.set(c,l),l},a.prototype.set=function(n,o,c){c??(c=this._hash(n)),this._keyMap.has(c)||this._keyMap.set(c,n),this._valueMap.set(c,o)},a.prototype.has=function(n,o){return o??(o=this._hash(n)),this._valueMap.has(o)},a.prototype.keys=function(){var n,o;return Da(this,function(c){switch(c.label){case 0:n=this._keyMap.entries(),o=n.next(),c.label=1;case 1:return o.done===!0?[3,3]:[4,[o.value[1],o.value[0]]];case 2:return c.sent(),o=n.next(),[3,1];case 3:return[2]}})},a.prototype.entries=function(){var n,o;return Da(this,function(c){switch(c.label){case 0:n=this._valueMap.entries(),o=n.next(),c.label=1;case 1:return o.done===!0?[3,3]:[4,[this._keyMap.get(o.value[0]),o.value[1],o.value[0]]];case 2:return c.sent(),o=n.next(),[3,1];case 3:return[2]}})},Object.defineProperty(a.prototype,"size",{get:function(){return this._valueMap.size},enumerable:!1,configurable:!0}),a}();var nt=function(a){yp(n,a);function n(){return a.call(this,Ea)||this}return n}(hp);var mp=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Tr=function(){function a(n){this._aggregator=n,this._activeCollectionStorage=new nt,this._cumulativeMemoStorage=new nt}return a.prototype.record=function(n,o,c,l){var i=this,e=this._activeCollectionStorage.getOrDefault(o,function(){return i._aggregator.createAccumulation(l)});e?.record(n)},a.prototype.batchCumulate=function(n,o){var c=this;Array.from(n.entries()).forEach(function(l){var i=mp(l,3),e=i[0],t=i[1],r=i[2],u=c._aggregator.createAccumulation(o);u?.record(t);var s=u;if(c._cumulativeMemoStorage.has(e,r)){var d=c._cumulativeMemoStorage.get(e,r);s=c._aggregator.diff(d,u)}if(c._activeCollectionStorage.has(e,r)){var v=c._activeCollectionStorage.get(e,r);s=c._aggregator.merge(v,s)}c._cumulativeMemoStorage.set(e,u,r),c._activeCollectionStorage.set(e,s,r)})},a.prototype.collect=function(){var n=this._activeCollectionStorage;return this._activeCollectionStorage=new nt,n},a}();var kn=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},ka=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Or=function(){function a(n,o){var c=this;this._aggregator=n,this._unreportedAccumulations=new Map,this._reportHistory=new Map,o.forEach(function(l){c._unreportedAccumulations.set(l,[])})}return a.prototype.buildMetrics=function(n,o,c,l){this._stashAccumulations(c);var i=this._getMergedUnreportedAccumulations(n),e=i,t;if(this._reportHistory.has(n)){var r=this._reportHistory.get(n),u=r.collectionTime;t=r.aggregationTemporality,t===Er.CUMULATIVE?e=a.merge(r.accumulations,i,this._aggregator):e=a.calibrateStartTime(r.accumulations,i,u)}else t=n.selectAggregationTemporality(o.type);this._reportHistory.set(n,{accumulations:e,collectionTime:l,aggregationTemporality:t});var s=vp(e);if(s.length!==0)return this._aggregator.toMetricData(o,t,s,l)},a.prototype._stashAccumulations=function(n){var o,c,l=this._unreportedAccumulations.keys();try{for(var i=kn(l),e=i.next();!e.done;e=i.next()){var t=e.value,r=this._unreportedAccumulations.get(t);r===void 0&&(r=[],this._unreportedAccumulations.set(t,r)),r.push(n)}}catch(u){o={error:u}}finally{try{e&&!e.done&&(c=i.return)&&c.call(i)}finally{if(o)throw o.error}}},a.prototype._getMergedUnreportedAccumulations=function(n){var o,c,l=new nt,i=this._unreportedAccumulations.get(n);if(this._unreportedAccumulations.set(n,[]),i===void 0)return l;try{for(var e=kn(i),t=e.next();!t.done;t=e.next()){var r=t.value;l=a.merge(l,r,this._aggregator)}}catch(u){o={error:u}}finally{try{t&&!t.done&&(c=e.return)&&c.call(e)}finally{if(o)throw o.error}}return l},a.merge=function(n,o,c){for(var l=n,i=o.entries(),e=i.next();e.done!==!0;){var t=ka(e.value,3),r=t[0],u=t[1],s=t[2];if(n.has(r,s)){var d=n.get(r,s),v=c.merge(d,u);l.set(r,v,s)}else l.set(r,u,s);e=i.next()}return l},a.calibrateStartTime=function(n,o,c){var l,i;try{for(var e=kn(n.keys()),t=e.next();!t.done;t=e.next()){var r=ka(t.value,2),u=r[0],s=r[1],d=o.get(u,s);d?.setStartTime(c)}}catch(v){l={error:v}}finally{try{t&&!t.done&&(i=e.return)&&i.call(e)}finally{if(l)throw l.error}}return o},a}();function vp(a){return Array.from(a.entries())}var _p=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),Ep=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Ba=function(a){_p(n,a);function n(o,c,l,i){var e=a.call(this,o)||this;return e._attributesProcessor=l,e._deltaMetricStorage=new Tr(c),e._temporalMetricStorage=new Or(c,i),e}return n.prototype.record=function(o,c){var l=this,i=new nt;Array.from(o.entries()).forEach(function(e){var t=Ep(e,2),r=t[0],u=t[1];i.set(l._attributesProcessor.process(r),u)}),this._deltaMetricStorage.batchCumulate(i,c)},n.prototype.collect=function(o,c){var l=this._deltaMetricStorage.collect();return this._temporalMetricStorage.buildMetrics(o,this._instrumentDescriptor,l,c)},n}(Sr);b();function Bn(a,n){var o="";return a.unit!==n.unit&&(o+=" - Unit '"+a.unit+"' does not match '"+n.unit+`'
|
|
4
|
+
var Gl=Object.create;var Jr=Object.defineProperty;var Hl=Object.getOwnPropertyDescriptor;var jl=Object.getOwnPropertyNames;var Fl=Object.getPrototypeOf,ql=Object.prototype.hasOwnProperty;var zr=(a,n)=>()=>(a&&(n=a(a=0)),n);var m=(a,n)=>()=>(n||a((n={exports:{}}).exports,n),n.exports);var Ce=(a,n,o,c)=>{if(n&&typeof n=="object"||typeof n=="function")for(let l of jl(n))!ql.call(a,l)&&l!==o&&Jr(a,l,{get:()=>n[l],enumerable:!(c=Hl(n,l))||c.enumerable});return a},tt=(a,n,o)=>(Ce(a,n,"default"),o&&Ce(o,n,"default")),N=(a,n,o)=>(o=a!=null?Gl(Fl(a)):{},Ce(n||!a||!a.__esModule?Jr(o,"default",{value:a,enumerable:!0}):o,a)),D=a=>Ce(Jr({},"__esModule",{value:!0}),a);var y={};import*as Zf from"@opentelemetry/api";var b=zr(()=>{tt(y,Zf)});var fe=m(Et=>{"use strict";Object.defineProperty(Et,"__esModule",{value:!0});Et.isTracingSuppressed=Et.unsuppressTracing=Et.suppressTracing=void 0;var Kl=(b(),D(y)),Wr=(0,Kl.createContextKey)("OpenTelemetry SDK Context Key SUPPRESS_TRACING");function Xl(a){return a.setValue(Wr,!0)}Et.suppressTracing=Xl;function Yl(a){return a.deleteValue(Wr)}Et.unsuppressTracing=Yl;function Jl(a){return a.getValue(Wr)===!0}Et.isTracingSuppressed=Jl});var $r=m(q=>{"use strict";Object.defineProperty(q,"__esModule",{value:!0});q.BAGGAGE_MAX_TOTAL_LENGTH=q.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS=q.BAGGAGE_MAX_NAME_VALUE_PAIRS=q.BAGGAGE_HEADER=q.BAGGAGE_ITEMS_SEPARATOR=q.BAGGAGE_PROPERTIES_SEPARATOR=q.BAGGAGE_KEY_PAIR_SEPARATOR=void 0;q.BAGGAGE_KEY_PAIR_SEPARATOR="=";q.BAGGAGE_PROPERTIES_SEPARATOR=";";q.BAGGAGE_ITEMS_SEPARATOR=",";q.BAGGAGE_HEADER="baggage";q.BAGGAGE_MAX_NAME_VALUE_PAIRS=180;q.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS=4096;q.BAGGAGE_MAX_TOTAL_LENGTH=8192});var Qr=m(lt=>{"use strict";Object.defineProperty(lt,"__esModule",{value:!0});lt.parseKeyPairsIntoRecord=lt.parsePairKeyValue=lt.getKeyPairs=lt.serializeKeyPairs=void 0;var zl=(b(),D(y)),Ut=$r();function Wl(a){return a.reduce((n,o)=>{let c=`${n}${n!==""?Ut.BAGGAGE_ITEMS_SEPARATOR:""}${o}`;return c.length>Ut.BAGGAGE_MAX_TOTAL_LENGTH?n:c},"")}lt.serializeKeyPairs=Wl;function $l(a){return a.getAllEntries().map(([n,o])=>{let c=`${encodeURIComponent(n)}=${encodeURIComponent(o.value)}`;return o.metadata!==void 0&&(c+=Ut.BAGGAGE_PROPERTIES_SEPARATOR+o.metadata.toString()),c})}lt.getKeyPairs=$l;function Ro(a){let n=a.split(Ut.BAGGAGE_PROPERTIES_SEPARATOR);if(n.length<=0)return;let o=n.shift();if(!o)return;let c=o.indexOf(Ut.BAGGAGE_KEY_PAIR_SEPARATOR);if(c<=0)return;let l=decodeURIComponent(o.substring(0,c).trim()),i=decodeURIComponent(o.substring(c+1).trim()),e;return n.length>0&&(e=(0,zl.baggageEntryMetadataFromString)(n.join(Ut.BAGGAGE_PROPERTIES_SEPARATOR))),{key:l,value:i,metadata:e}}lt.parsePairKeyValue=Ro;function Ql(a){return typeof a!="string"||a.length===0?{}:a.split(Ut.BAGGAGE_ITEMS_SEPARATOR).map(n=>Ro(n)).filter(n=>n!==void 0&&n.value.length>0).reduce((n,o)=>(n[o.key]=o.value,n),{})}lt.parseKeyPairsIntoRecord=Ql});var Lo=m(Ue=>{"use strict";Object.defineProperty(Ue,"__esModule",{value:!0});Ue.W3CBaggagePropagator=void 0;var Zr=(b(),D(y)),Zl=fe(),Mt=$r(),tn=Qr(),en=class{inject(n,o,c){let l=Zr.propagation.getBaggage(n);if(!l||(0,Zl.isTracingSuppressed)(n))return;let i=(0,tn.getKeyPairs)(l).filter(t=>t.length<=Mt.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS).slice(0,Mt.BAGGAGE_MAX_NAME_VALUE_PAIRS),e=(0,tn.serializeKeyPairs)(i);e.length>0&&c.set(o,Mt.BAGGAGE_HEADER,e)}extract(n,o,c){let l=c.get(o,Mt.BAGGAGE_HEADER),i=Array.isArray(l)?l.join(Mt.BAGGAGE_ITEMS_SEPARATOR):l;if(!i)return n;let e={};return i.length===0||(i.split(Mt.BAGGAGE_ITEMS_SEPARATOR).forEach(r=>{let u=(0,tn.parsePairKeyValue)(r);if(u){let s={value:u.value};u.metadata&&(s.metadata=u.metadata),e[u.key]=s}}),Object.entries(e).length===0)?n:Zr.propagation.setBaggage(n,Zr.propagation.createBaggage(e))}fields(){return[Mt.BAGGAGE_HEADER]}};Ue.W3CBaggagePropagator=en});var Io=m(Me=>{"use strict";Object.defineProperty(Me,"__esModule",{value:!0});Me.AnchoredClock=void 0;var rn=class{constructor(n,o){this._monotonicClock=o,this._epochMillis=n.now(),this._performanceMillis=o.now()}now(){let n=this._monotonicClock.now()-this._performanceMillis;return this._epochMillis+n}};Me.AnchoredClock=rn});var Do=m(bt=>{"use strict";Object.defineProperty(bt,"__esModule",{value:!0});bt.isAttributeValue=bt.isAttributeKey=bt.sanitizeAttributes=void 0;var wo=(b(),D(y));function tc(a){let n={};if(typeof a!="object"||a==null)return n;for(let[o,c]of Object.entries(a)){if(!Co(o)){wo.diag.warn(`Invalid attribute key: ${o}`);continue}if(!Uo(c)){wo.diag.warn(`Invalid attribute value set for key: ${o}`);continue}Array.isArray(c)?n[o]=c.slice():n[o]=c}return n}bt.sanitizeAttributes=tc;function Co(a){return typeof a=="string"&&a.length>0}bt.isAttributeKey=Co;function Uo(a){return a==null?!0:Array.isArray(a)?ec(a):Mo(a)}bt.isAttributeValue=Uo;function ec(a){let n;for(let o of a)if(o!=null){if(!n){if(Mo(o)){n=typeof o;continue}return!1}if(typeof o!==n)return!1}return!0}function Mo(a){switch(typeof a){case"number":case"boolean":case"string":return!0}return!1}});var nn=m(De=>{"use strict";Object.defineProperty(De,"__esModule",{value:!0});De.loggingErrorHandler=void 0;var rc=(b(),D(y));function nc(){return a=>{rc.diag.error(oc(a))}}De.loggingErrorHandler=nc;function oc(a){return typeof a=="string"?a:JSON.stringify(ic(a))}function ic(a){let n={},o=a;for(;o!==null;)Object.getOwnPropertyNames(o).forEach(c=>{if(n[c])return;let l=o[c];l&&(n[c]=String(l))}),o=Object.getPrototypeOf(o);return n}});var on=m(qt=>{"use strict";Object.defineProperty(qt,"__esModule",{value:!0});qt.globalErrorHandler=qt.setGlobalErrorHandler=void 0;var ac=nn(),Vo=(0,ac.loggingErrorHandler)();function uc(a){Vo=a}qt.setGlobalErrorHandler=uc;function lc(a){try{Vo(a)}catch{}}qt.globalErrorHandler=lc});var an=m(de=>{"use strict";Object.defineProperty(de,"__esModule",{value:!0});de.TracesSamplerValues=void 0;var cc;(function(a){a.AlwaysOff="always_off",a.AlwaysOn="always_on",a.ParentBasedAlwaysOff="parentbased_always_off",a.ParentBasedAlwaysOn="parentbased_always_on",a.ParentBasedTraceIdRatio="parentbased_traceidratio",a.TraceIdRatio="traceidratio"})(cc=de.TracesSamplerValues||(de.TracesSamplerValues={}))});var ke=m(Ve=>{"use strict";Object.defineProperty(Ve,"__esModule",{value:!0});Ve._globalThis=void 0;Ve._globalThis=typeof globalThis=="object"?globalThis:typeof self=="object"?self:typeof window=="object"?window:typeof global=="object"?global:{}});var Be=m(U=>{"use strict";Object.defineProperty(U,"__esModule",{value:!0});U.getEnvWithoutDefaults=U.parseEnvironment=U.DEFAULT_ENVIRONMENT=U.DEFAULT_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT=U.DEFAULT_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT=U.DEFAULT_ATTRIBUTE_COUNT_LIMIT=U.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT=void 0;var St=(b(),D(y)),sc=an(),pc=ke(),fc=",",dc=["OTEL_SDK_DISABLED"];function yc(a){return dc.indexOf(a)>-1}var hc=["OTEL_BSP_EXPORT_TIMEOUT","OTEL_BSP_MAX_EXPORT_BATCH_SIZE","OTEL_BSP_MAX_QUEUE_SIZE","OTEL_BSP_SCHEDULE_DELAY","OTEL_BLRP_EXPORT_TIMEOUT","OTEL_BLRP_MAX_EXPORT_BATCH_SIZE","OTEL_BLRP_MAX_QUEUE_SIZE","OTEL_BLRP_SCHEDULE_DELAY","OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_EVENT_COUNT_LIMIT","OTEL_SPAN_LINK_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT","OTEL_EXPORTER_OTLP_TIMEOUT","OTEL_EXPORTER_OTLP_TRACES_TIMEOUT","OTEL_EXPORTER_OTLP_METRICS_TIMEOUT","OTEL_EXPORTER_OTLP_LOGS_TIMEOUT","OTEL_EXPORTER_JAEGER_AGENT_PORT"];function mc(a){return hc.indexOf(a)>-1}var vc=["OTEL_NO_PATCH_MODULES","OTEL_PROPAGATORS"];function _c(a){return vc.indexOf(a)>-1}U.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT=1/0;U.DEFAULT_ATTRIBUTE_COUNT_LIMIT=128;U.DEFAULT_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT=128;U.DEFAULT_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT=128;U.DEFAULT_ENVIRONMENT={OTEL_SDK_DISABLED:!1,CONTAINER_NAME:"",ECS_CONTAINER_METADATA_URI_V4:"",ECS_CONTAINER_METADATA_URI:"",HOSTNAME:"",KUBERNETES_SERVICE_HOST:"",NAMESPACE:"",OTEL_BSP_EXPORT_TIMEOUT:3e4,OTEL_BSP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BSP_MAX_QUEUE_SIZE:2048,OTEL_BSP_SCHEDULE_DELAY:5e3,OTEL_BLRP_EXPORT_TIMEOUT:3e4,OTEL_BLRP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BLRP_MAX_QUEUE_SIZE:2048,OTEL_BLRP_SCHEDULE_DELAY:5e3,OTEL_EXPORTER_JAEGER_AGENT_HOST:"",OTEL_EXPORTER_JAEGER_AGENT_PORT:6832,OTEL_EXPORTER_JAEGER_ENDPOINT:"",OTEL_EXPORTER_JAEGER_PASSWORD:"",OTEL_EXPORTER_JAEGER_USER:"",OTEL_EXPORTER_OTLP_ENDPOINT:"",OTEL_EXPORTER_OTLP_TRACES_ENDPOINT:"",OTEL_EXPORTER_OTLP_METRICS_ENDPOINT:"",OTEL_EXPORTER_OTLP_LOGS_ENDPOINT:"",OTEL_EXPORTER_OTLP_HEADERS:"",OTEL_EXPORTER_OTLP_TRACES_HEADERS:"",OTEL_EXPORTER_OTLP_METRICS_HEADERS:"",OTEL_EXPORTER_OTLP_LOGS_HEADERS:"",OTEL_EXPORTER_OTLP_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_TRACES_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_METRICS_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_LOGS_TIMEOUT:1e4,OTEL_EXPORTER_ZIPKIN_ENDPOINT:"http://localhost:9411/api/v2/spans",OTEL_LOG_LEVEL:St.DiagLogLevel.INFO,OTEL_NO_PATCH_MODULES:[],OTEL_PROPAGATORS:["tracecontext","baggage"],OTEL_RESOURCE_ATTRIBUTES:"",OTEL_SERVICE_NAME:"",OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT:U.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT,OTEL_ATTRIBUTE_COUNT_LIMIT:U.DEFAULT_ATTRIBUTE_COUNT_LIMIT,OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT:U.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT,OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT:U.DEFAULT_ATTRIBUTE_COUNT_LIMIT,OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT:U.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT,OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT:U.DEFAULT_ATTRIBUTE_COUNT_LIMIT,OTEL_SPAN_EVENT_COUNT_LIMIT:128,OTEL_SPAN_LINK_COUNT_LIMIT:128,OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT:U.DEFAULT_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT,OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT:U.DEFAULT_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT,OTEL_TRACES_EXPORTER:"",OTEL_TRACES_SAMPLER:sc.TracesSamplerValues.ParentBasedAlwaysOn,OTEL_TRACES_SAMPLER_ARG:"",OTEL_LOGS_EXPORTER:"",OTEL_EXPORTER_OTLP_INSECURE:"",OTEL_EXPORTER_OTLP_TRACES_INSECURE:"",OTEL_EXPORTER_OTLP_METRICS_INSECURE:"",OTEL_EXPORTER_OTLP_LOGS_INSECURE:"",OTEL_EXPORTER_OTLP_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_COMPRESSION:"",OTEL_EXPORTER_OTLP_TRACES_COMPRESSION:"",OTEL_EXPORTER_OTLP_METRICS_COMPRESSION:"",OTEL_EXPORTER_OTLP_LOGS_COMPRESSION:"",OTEL_EXPORTER_OTLP_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_TRACES_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_LOGS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE:"cumulative"};function Ec(a,n,o){if(typeof o[a]>"u")return;let c=String(o[a]);n[a]=c.toLowerCase()==="true"}function bc(a,n,o,c=-1/0,l=1/0){if(typeof o[a]<"u"){let i=Number(o[a]);isNaN(i)||(i<c?n[a]=c:i>l?n[a]=l:n[a]=i)}}function Sc(a,n,o,c=fc){let l=o[a];typeof l=="string"&&(n[a]=l.split(c).map(i=>i.trim()))}var Tc={ALL:St.DiagLogLevel.ALL,VERBOSE:St.DiagLogLevel.VERBOSE,DEBUG:St.DiagLogLevel.DEBUG,INFO:St.DiagLogLevel.INFO,WARN:St.DiagLogLevel.WARN,ERROR:St.DiagLogLevel.ERROR,NONE:St.DiagLogLevel.NONE};function Oc(a,n,o){let c=o[a];if(typeof c=="string"){let l=Tc[c.toUpperCase()];l!=null&&(n[a]=l)}}function un(a){let n={};for(let o in U.DEFAULT_ENVIRONMENT){let c=o;switch(c){case"OTEL_LOG_LEVEL":Oc(c,n,a);break;default:if(yc(c))Ec(c,n,a);else if(mc(c))bc(c,n,a);else if(_c(c))Sc(c,n,a);else{let l=a[c];typeof l<"u"&&l!==null&&(n[c]=String(l))}}}return n}U.parseEnvironment=un;function gc(){return typeof process<"u"&&process&&process.env?un(process.env):un(pc._globalThis)}U.getEnvWithoutDefaults=gc});var Bo=m(Ge=>{"use strict";Object.defineProperty(Ge,"__esModule",{value:!0});Ge.getEnv=void 0;var ko=Be(),Ac=ke();function Nc(){let a=(0,ko.parseEnvironment)(Ac._globalThis);return Object.assign({},ko.DEFAULT_ENVIRONMENT,a)}Ge.getEnv=Nc});var Go=m(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.hexToBase64=void 0;function Pc(a){let n=a.length,o="";for(let c=0;c<n;c+=2){let l=a.substring(c,c+2),i=parseInt(l,16);o+=String.fromCharCode(i)}return btoa(o)}He.hexToBase64=Pc});var jo=m(Fe=>{"use strict";Object.defineProperty(Fe,"__esModule",{value:!0});Fe.RandomIdGenerator=void 0;var xc=8,Rc=16,ln=class{constructor(){this.generateTraceId=Ho(Rc),this.generateSpanId=Ho(xc)}};Fe.RandomIdGenerator=ln;var je=Array(32);function Ho(a){return function(){for(let o=0;o<a*2;o++)je[o]=Math.floor(Math.random()*16)+48,je[o]>=58&&(je[o]+=39);return String.fromCharCode.apply(null,je.slice(0,a*2))}}});var Fo=m(qe=>{"use strict";Object.defineProperty(qe,"__esModule",{value:!0});qe.otperformance=void 0;qe.otperformance=performance});var cn=m(Ke=>{"use strict";Object.defineProperty(Ke,"__esModule",{value:!0});Ke.VERSION=void 0;Ke.VERSION="1.19.0"});var qo=m(P=>{"use strict";Object.defineProperty(P,"__esModule",{value:!0});P.MessageTypeValues=P.RpcGrpcStatusCodeValues=P.MessagingOperationValues=P.MessagingDestinationKindValues=P.HttpFlavorValues=P.NetHostConnectionSubtypeValues=P.NetHostConnectionTypeValues=P.NetTransportValues=P.FaasInvokedProviderValues=P.FaasDocumentOperationValues=P.FaasTriggerValues=P.DbCassandraConsistencyLevelValues=P.DbSystemValues=P.SemanticAttributes=void 0;P.SemanticAttributes={AWS_LAMBDA_INVOKED_ARN:"aws.lambda.invoked_arn",DB_SYSTEM:"db.system",DB_CONNECTION_STRING:"db.connection_string",DB_USER:"db.user",DB_JDBC_DRIVER_CLASSNAME:"db.jdbc.driver_classname",DB_NAME:"db.name",DB_STATEMENT:"db.statement",DB_OPERATION:"db.operation",DB_MSSQL_INSTANCE_NAME:"db.mssql.instance_name",DB_CASSANDRA_KEYSPACE:"db.cassandra.keyspace",DB_CASSANDRA_PAGE_SIZE:"db.cassandra.page_size",DB_CASSANDRA_CONSISTENCY_LEVEL:"db.cassandra.consistency_level",DB_CASSANDRA_TABLE:"db.cassandra.table",DB_CASSANDRA_IDEMPOTENCE:"db.cassandra.idempotence",DB_CASSANDRA_SPECULATIVE_EXECUTION_COUNT:"db.cassandra.speculative_execution_count",DB_CASSANDRA_COORDINATOR_ID:"db.cassandra.coordinator.id",DB_CASSANDRA_COORDINATOR_DC:"db.cassandra.coordinator.dc",DB_HBASE_NAMESPACE:"db.hbase.namespace",DB_REDIS_DATABASE_INDEX:"db.redis.database_index",DB_MONGODB_COLLECTION:"db.mongodb.collection",DB_SQL_TABLE:"db.sql.table",EXCEPTION_TYPE:"exception.type",EXCEPTION_MESSAGE:"exception.message",EXCEPTION_STACKTRACE:"exception.stacktrace",EXCEPTION_ESCAPED:"exception.escaped",FAAS_TRIGGER:"faas.trigger",FAAS_EXECUTION:"faas.execution",FAAS_DOCUMENT_COLLECTION:"faas.document.collection",FAAS_DOCUMENT_OPERATION:"faas.document.operation",FAAS_DOCUMENT_TIME:"faas.document.time",FAAS_DOCUMENT_NAME:"faas.document.name",FAAS_TIME:"faas.time",FAAS_CRON:"faas.cron",FAAS_COLDSTART:"faas.coldstart",FAAS_INVOKED_NAME:"faas.invoked_name",FAAS_INVOKED_PROVIDER:"faas.invoked_provider",FAAS_INVOKED_REGION:"faas.invoked_region",NET_TRANSPORT:"net.transport",NET_PEER_IP:"net.peer.ip",NET_PEER_PORT:"net.peer.port",NET_PEER_NAME:"net.peer.name",NET_HOST_IP:"net.host.ip",NET_HOST_PORT:"net.host.port",NET_HOST_NAME:"net.host.name",NET_HOST_CONNECTION_TYPE:"net.host.connection.type",NET_HOST_CONNECTION_SUBTYPE:"net.host.connection.subtype",NET_HOST_CARRIER_NAME:"net.host.carrier.name",NET_HOST_CARRIER_MCC:"net.host.carrier.mcc",NET_HOST_CARRIER_MNC:"net.host.carrier.mnc",NET_HOST_CARRIER_ICC:"net.host.carrier.icc",PEER_SERVICE:"peer.service",ENDUSER_ID:"enduser.id",ENDUSER_ROLE:"enduser.role",ENDUSER_SCOPE:"enduser.scope",THREAD_ID:"thread.id",THREAD_NAME:"thread.name",CODE_FUNCTION:"code.function",CODE_NAMESPACE:"code.namespace",CODE_FILEPATH:"code.filepath",CODE_LINENO:"code.lineno",HTTP_METHOD:"http.method",HTTP_URL:"http.url",HTTP_TARGET:"http.target",HTTP_HOST:"http.host",HTTP_SCHEME:"http.scheme",HTTP_STATUS_CODE:"http.status_code",HTTP_FLAVOR:"http.flavor",HTTP_USER_AGENT:"http.user_agent",HTTP_REQUEST_CONTENT_LENGTH:"http.request_content_length",HTTP_REQUEST_CONTENT_LENGTH_UNCOMPRESSED:"http.request_content_length_uncompressed",HTTP_RESPONSE_CONTENT_LENGTH:"http.response_content_length",HTTP_RESPONSE_CONTENT_LENGTH_UNCOMPRESSED:"http.response_content_length_uncompressed",HTTP_SERVER_NAME:"http.server_name",HTTP_ROUTE:"http.route",HTTP_CLIENT_IP:"http.client_ip",AWS_DYNAMODB_TABLE_NAMES:"aws.dynamodb.table_names",AWS_DYNAMODB_CONSUMED_CAPACITY:"aws.dynamodb.consumed_capacity",AWS_DYNAMODB_ITEM_COLLECTION_METRICS:"aws.dynamodb.item_collection_metrics",AWS_DYNAMODB_PROVISIONED_READ_CAPACITY:"aws.dynamodb.provisioned_read_capacity",AWS_DYNAMODB_PROVISIONED_WRITE_CAPACITY:"aws.dynamodb.provisioned_write_capacity",AWS_DYNAMODB_CONSISTENT_READ:"aws.dynamodb.consistent_read",AWS_DYNAMODB_PROJECTION:"aws.dynamodb.projection",AWS_DYNAMODB_LIMIT:"aws.dynamodb.limit",AWS_DYNAMODB_ATTRIBUTES_TO_GET:"aws.dynamodb.attributes_to_get",AWS_DYNAMODB_INDEX_NAME:"aws.dynamodb.index_name",AWS_DYNAMODB_SELECT:"aws.dynamodb.select",AWS_DYNAMODB_GLOBAL_SECONDARY_INDEXES:"aws.dynamodb.global_secondary_indexes",AWS_DYNAMODB_LOCAL_SECONDARY_INDEXES:"aws.dynamodb.local_secondary_indexes",AWS_DYNAMODB_EXCLUSIVE_START_TABLE:"aws.dynamodb.exclusive_start_table",AWS_DYNAMODB_TABLE_COUNT:"aws.dynamodb.table_count",AWS_DYNAMODB_SCAN_FORWARD:"aws.dynamodb.scan_forward",AWS_DYNAMODB_SEGMENT:"aws.dynamodb.segment",AWS_DYNAMODB_TOTAL_SEGMENTS:"aws.dynamodb.total_segments",AWS_DYNAMODB_COUNT:"aws.dynamodb.count",AWS_DYNAMODB_SCANNED_COUNT:"aws.dynamodb.scanned_count",AWS_DYNAMODB_ATTRIBUTE_DEFINITIONS:"aws.dynamodb.attribute_definitions",AWS_DYNAMODB_GLOBAL_SECONDARY_INDEX_UPDATES:"aws.dynamodb.global_secondary_index_updates",MESSAGING_SYSTEM:"messaging.system",MESSAGING_DESTINATION:"messaging.destination",MESSAGING_DESTINATION_KIND:"messaging.destination_kind",MESSAGING_TEMP_DESTINATION:"messaging.temp_destination",MESSAGING_PROTOCOL:"messaging.protocol",MESSAGING_PROTOCOL_VERSION:"messaging.protocol_version",MESSAGING_URL:"messaging.url",MESSAGING_MESSAGE_ID:"messaging.message_id",MESSAGING_CONVERSATION_ID:"messaging.conversation_id",MESSAGING_MESSAGE_PAYLOAD_SIZE_BYTES:"messaging.message_payload_size_bytes",MESSAGING_MESSAGE_PAYLOAD_COMPRESSED_SIZE_BYTES:"messaging.message_payload_compressed_size_bytes",MESSAGING_OPERATION:"messaging.operation",MESSAGING_CONSUMER_ID:"messaging.consumer_id",MESSAGING_RABBITMQ_ROUTING_KEY:"messaging.rabbitmq.routing_key",MESSAGING_KAFKA_MESSAGE_KEY:"messaging.kafka.message_key",MESSAGING_KAFKA_CONSUMER_GROUP:"messaging.kafka.consumer_group",MESSAGING_KAFKA_CLIENT_ID:"messaging.kafka.client_id",MESSAGING_KAFKA_PARTITION:"messaging.kafka.partition",MESSAGING_KAFKA_TOMBSTONE:"messaging.kafka.tombstone",RPC_SYSTEM:"rpc.system",RPC_SERVICE:"rpc.service",RPC_METHOD:"rpc.method",RPC_GRPC_STATUS_CODE:"rpc.grpc.status_code",RPC_JSONRPC_VERSION:"rpc.jsonrpc.version",RPC_JSONRPC_REQUEST_ID:"rpc.jsonrpc.request_id",RPC_JSONRPC_ERROR_CODE:"rpc.jsonrpc.error_code",RPC_JSONRPC_ERROR_MESSAGE:"rpc.jsonrpc.error_message",MESSAGE_TYPE:"message.type",MESSAGE_ID:"message.id",MESSAGE_COMPRESSED_SIZE:"message.compressed_size",MESSAGE_UNCOMPRESSED_SIZE:"message.uncompressed_size"};P.DbSystemValues={OTHER_SQL:"other_sql",MSSQL:"mssql",MYSQL:"mysql",ORACLE:"oracle",DB2:"db2",POSTGRESQL:"postgresql",REDSHIFT:"redshift",HIVE:"hive",CLOUDSCAPE:"cloudscape",HSQLDB:"hsqldb",PROGRESS:"progress",MAXDB:"maxdb",HANADB:"hanadb",INGRES:"ingres",FIRSTSQL:"firstsql",EDB:"edb",CACHE:"cache",ADABAS:"adabas",FIREBIRD:"firebird",DERBY:"derby",FILEMAKER:"filemaker",INFORMIX:"informix",INSTANTDB:"instantdb",INTERBASE:"interbase",MARIADB:"mariadb",NETEZZA:"netezza",PERVASIVE:"pervasive",POINTBASE:"pointbase",SQLITE:"sqlite",SYBASE:"sybase",TERADATA:"teradata",VERTICA:"vertica",H2:"h2",COLDFUSION:"coldfusion",CASSANDRA:"cassandra",HBASE:"hbase",MONGODB:"mongodb",REDIS:"redis",COUCHBASE:"couchbase",COUCHDB:"couchdb",COSMOSDB:"cosmosdb",DYNAMODB:"dynamodb",NEO4J:"neo4j",GEODE:"geode",ELASTICSEARCH:"elasticsearch",MEMCACHED:"memcached",COCKROACHDB:"cockroachdb"};P.DbCassandraConsistencyLevelValues={ALL:"all",EACH_QUORUM:"each_quorum",QUORUM:"quorum",LOCAL_QUORUM:"local_quorum",ONE:"one",TWO:"two",THREE:"three",LOCAL_ONE:"local_one",ANY:"any",SERIAL:"serial",LOCAL_SERIAL:"local_serial"};P.FaasTriggerValues={DATASOURCE:"datasource",HTTP:"http",PUBSUB:"pubsub",TIMER:"timer",OTHER:"other"};P.FaasDocumentOperationValues={INSERT:"insert",EDIT:"edit",DELETE:"delete"};P.FaasInvokedProviderValues={ALIBABA_CLOUD:"alibaba_cloud",AWS:"aws",AZURE:"azure",GCP:"gcp"};P.NetTransportValues={IP_TCP:"ip_tcp",IP_UDP:"ip_udp",IP:"ip",UNIX:"unix",PIPE:"pipe",INPROC:"inproc",OTHER:"other"};P.NetHostConnectionTypeValues={WIFI:"wifi",WIRED:"wired",CELL:"cell",UNAVAILABLE:"unavailable",UNKNOWN:"unknown"};P.NetHostConnectionSubtypeValues={GPRS:"gprs",EDGE:"edge",UMTS:"umts",CDMA:"cdma",EVDO_0:"evdo_0",EVDO_A:"evdo_a",CDMA2000_1XRTT:"cdma2000_1xrtt",HSDPA:"hsdpa",HSUPA:"hsupa",HSPA:"hspa",IDEN:"iden",EVDO_B:"evdo_b",LTE:"lte",EHRPD:"ehrpd",HSPAP:"hspap",GSM:"gsm",TD_SCDMA:"td_scdma",IWLAN:"iwlan",NR:"nr",NRNSA:"nrnsa",LTE_CA:"lte_ca"};P.HttpFlavorValues={HTTP_1_0:"1.0",HTTP_1_1:"1.1",HTTP_2_0:"2.0",SPDY:"SPDY",QUIC:"QUIC"};P.MessagingDestinationKindValues={QUEUE:"queue",TOPIC:"topic"};P.MessagingOperationValues={RECEIVE:"receive",PROCESS:"process"};P.RpcGrpcStatusCodeValues={OK:0,CANCELLED:1,UNKNOWN:2,INVALID_ARGUMENT:3,DEADLINE_EXCEEDED:4,NOT_FOUND:5,ALREADY_EXISTS:6,PERMISSION_DENIED:7,RESOURCE_EXHAUSTED:8,FAILED_PRECONDITION:9,ABORTED:10,OUT_OF_RANGE:11,UNIMPLEMENTED:12,INTERNAL:13,UNAVAILABLE:14,DATA_LOSS:15,UNAUTHENTICATED:16};P.MessageTypeValues={SENT:"SENT",RECEIVED:"RECEIVED"}});var Ko=m(Dt=>{"use strict";var Lc=Dt&&Dt.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),Ic=Dt&&Dt.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&Lc(n,a,o)};Object.defineProperty(Dt,"__esModule",{value:!0});Ic(qo(),Dt)});var Xo=m(K=>{"use strict";Object.defineProperty(K,"__esModule",{value:!0});K.TelemetrySdkLanguageValues=K.OsTypeValues=K.HostArchValues=K.AwsEcsLaunchtypeValues=K.CloudPlatformValues=K.CloudProviderValues=K.SemanticResourceAttributes=void 0;K.SemanticResourceAttributes={CLOUD_PROVIDER:"cloud.provider",CLOUD_ACCOUNT_ID:"cloud.account.id",CLOUD_REGION:"cloud.region",CLOUD_AVAILABILITY_ZONE:"cloud.availability_zone",CLOUD_PLATFORM:"cloud.platform",AWS_ECS_CONTAINER_ARN:"aws.ecs.container.arn",AWS_ECS_CLUSTER_ARN:"aws.ecs.cluster.arn",AWS_ECS_LAUNCHTYPE:"aws.ecs.launchtype",AWS_ECS_TASK_ARN:"aws.ecs.task.arn",AWS_ECS_TASK_FAMILY:"aws.ecs.task.family",AWS_ECS_TASK_REVISION:"aws.ecs.task.revision",AWS_EKS_CLUSTER_ARN:"aws.eks.cluster.arn",AWS_LOG_GROUP_NAMES:"aws.log.group.names",AWS_LOG_GROUP_ARNS:"aws.log.group.arns",AWS_LOG_STREAM_NAMES:"aws.log.stream.names",AWS_LOG_STREAM_ARNS:"aws.log.stream.arns",CONTAINER_NAME:"container.name",CONTAINER_ID:"container.id",CONTAINER_RUNTIME:"container.runtime",CONTAINER_IMAGE_NAME:"container.image.name",CONTAINER_IMAGE_TAG:"container.image.tag",DEPLOYMENT_ENVIRONMENT:"deployment.environment",DEVICE_ID:"device.id",DEVICE_MODEL_IDENTIFIER:"device.model.identifier",DEVICE_MODEL_NAME:"device.model.name",FAAS_NAME:"faas.name",FAAS_ID:"faas.id",FAAS_VERSION:"faas.version",FAAS_INSTANCE:"faas.instance",FAAS_MAX_MEMORY:"faas.max_memory",HOST_ID:"host.id",HOST_NAME:"host.name",HOST_TYPE:"host.type",HOST_ARCH:"host.arch",HOST_IMAGE_NAME:"host.image.name",HOST_IMAGE_ID:"host.image.id",HOST_IMAGE_VERSION:"host.image.version",K8S_CLUSTER_NAME:"k8s.cluster.name",K8S_NODE_NAME:"k8s.node.name",K8S_NODE_UID:"k8s.node.uid",K8S_NAMESPACE_NAME:"k8s.namespace.name",K8S_POD_UID:"k8s.pod.uid",K8S_POD_NAME:"k8s.pod.name",K8S_CONTAINER_NAME:"k8s.container.name",K8S_REPLICASET_UID:"k8s.replicaset.uid",K8S_REPLICASET_NAME:"k8s.replicaset.name",K8S_DEPLOYMENT_UID:"k8s.deployment.uid",K8S_DEPLOYMENT_NAME:"k8s.deployment.name",K8S_STATEFULSET_UID:"k8s.statefulset.uid",K8S_STATEFULSET_NAME:"k8s.statefulset.name",K8S_DAEMONSET_UID:"k8s.daemonset.uid",K8S_DAEMONSET_NAME:"k8s.daemonset.name",K8S_JOB_UID:"k8s.job.uid",K8S_JOB_NAME:"k8s.job.name",K8S_CRONJOB_UID:"k8s.cronjob.uid",K8S_CRONJOB_NAME:"k8s.cronjob.name",OS_TYPE:"os.type",OS_DESCRIPTION:"os.description",OS_NAME:"os.name",OS_VERSION:"os.version",PROCESS_PID:"process.pid",PROCESS_EXECUTABLE_NAME:"process.executable.name",PROCESS_EXECUTABLE_PATH:"process.executable.path",PROCESS_COMMAND:"process.command",PROCESS_COMMAND_LINE:"process.command_line",PROCESS_COMMAND_ARGS:"process.command_args",PROCESS_OWNER:"process.owner",PROCESS_RUNTIME_NAME:"process.runtime.name",PROCESS_RUNTIME_VERSION:"process.runtime.version",PROCESS_RUNTIME_DESCRIPTION:"process.runtime.description",SERVICE_NAME:"service.name",SERVICE_NAMESPACE:"service.namespace",SERVICE_INSTANCE_ID:"service.instance.id",SERVICE_VERSION:"service.version",TELEMETRY_SDK_NAME:"telemetry.sdk.name",TELEMETRY_SDK_LANGUAGE:"telemetry.sdk.language",TELEMETRY_SDK_VERSION:"telemetry.sdk.version",TELEMETRY_AUTO_VERSION:"telemetry.auto.version",WEBENGINE_NAME:"webengine.name",WEBENGINE_VERSION:"webengine.version",WEBENGINE_DESCRIPTION:"webengine.description"};K.CloudProviderValues={ALIBABA_CLOUD:"alibaba_cloud",AWS:"aws",AZURE:"azure",GCP:"gcp"};K.CloudPlatformValues={ALIBABA_CLOUD_ECS:"alibaba_cloud_ecs",ALIBABA_CLOUD_FC:"alibaba_cloud_fc",AWS_EC2:"aws_ec2",AWS_ECS:"aws_ecs",AWS_EKS:"aws_eks",AWS_LAMBDA:"aws_lambda",AWS_ELASTIC_BEANSTALK:"aws_elastic_beanstalk",AZURE_VM:"azure_vm",AZURE_CONTAINER_INSTANCES:"azure_container_instances",AZURE_AKS:"azure_aks",AZURE_FUNCTIONS:"azure_functions",AZURE_APP_SERVICE:"azure_app_service",GCP_COMPUTE_ENGINE:"gcp_compute_engine",GCP_CLOUD_RUN:"gcp_cloud_run",GCP_KUBERNETES_ENGINE:"gcp_kubernetes_engine",GCP_CLOUD_FUNCTIONS:"gcp_cloud_functions",GCP_APP_ENGINE:"gcp_app_engine"};K.AwsEcsLaunchtypeValues={EC2:"ec2",FARGATE:"fargate"};K.HostArchValues={AMD64:"amd64",ARM32:"arm32",ARM64:"arm64",IA64:"ia64",PPC32:"ppc32",PPC64:"ppc64",X86:"x86"};K.OsTypeValues={WINDOWS:"windows",LINUX:"linux",DARWIN:"darwin",FREEBSD:"freebsd",NETBSD:"netbsd",OPENBSD:"openbsd",DRAGONFLYBSD:"dragonflybsd",HPUX:"hpux",AIX:"aix",SOLARIS:"solaris",Z_OS:"z_os"};K.TelemetrySdkLanguageValues={CPP:"cpp",DOTNET:"dotnet",ERLANG:"erlang",GO:"go",JAVA:"java",NODEJS:"nodejs",PHP:"php",PYTHON:"python",RUBY:"ruby",WEBJS:"webjs"}});var Yo=m(Vt=>{"use strict";var wc=Vt&&Vt.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),Cc=Vt&&Vt.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&wc(n,a,o)};Object.defineProperty(Vt,"__esModule",{value:!0});Cc(Xo(),Vt)});var Ot=m(Tt=>{"use strict";var Uc=Tt&&Tt.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),Jo=Tt&&Tt.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&Uc(n,a,o)};Object.defineProperty(Tt,"__esModule",{value:!0});Jo(Ko(),Tt);Jo(Yo(),Tt)});var zo=m(Xe=>{"use strict";Object.defineProperty(Xe,"__esModule",{value:!0});Xe.SDK_INFO=void 0;var Mc=cn(),ye=Ot();Xe.SDK_INFO={[ye.SemanticResourceAttributes.TELEMETRY_SDK_NAME]:"opentelemetry",[ye.SemanticResourceAttributes.PROCESS_RUNTIME_NAME]:"browser",[ye.SemanticResourceAttributes.TELEMETRY_SDK_LANGUAGE]:ye.TelemetrySdkLanguageValues.WEBJS,[ye.SemanticResourceAttributes.TELEMETRY_SDK_VERSION]:Mc.VERSION}});var Wo=m(Ye=>{"use strict";Object.defineProperty(Ye,"__esModule",{value:!0});Ye.unrefTimer=void 0;function Dc(a){}Ye.unrefTimer=Dc});var sn=m(z=>{"use strict";var Vc=z&&z.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),kt=z&&z.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&Vc(n,a,o)};Object.defineProperty(z,"__esModule",{value:!0});kt(Bo(),z);kt(ke(),z);kt(Go(),z);kt(jo(),z);kt(Fo(),z);kt(zo(),z);kt(Wo(),z)});var ti=m(w=>{"use strict";Object.defineProperty(w,"__esModule",{value:!0});w.addHrTimes=w.isTimeInput=w.isTimeInputHrTime=w.hrTimeToMicroseconds=w.hrTimeToMilliseconds=w.hrTimeToNanoseconds=w.hrTimeToTimeStamp=w.hrTimeDuration=w.timeInputToHrTime=w.hrTime=w.getTimeOrigin=w.millisToHrTime=void 0;var pn=sn(),$o=9,kc=6,Bc=Math.pow(10,kc),Je=Math.pow(10,$o);function he(a){let n=a/1e3,o=Math.trunc(n),c=Math.round(a%1e3*Bc);return[o,c]}w.millisToHrTime=he;function fn(){let a=pn.otperformance.timeOrigin;if(typeof a!="number"){let n=pn.otperformance;a=n.timing&&n.timing.fetchStart}return a}w.getTimeOrigin=fn;function Qo(a){let n=he(fn()),o=he(typeof a=="number"?a:pn.otperformance.now());return Zo(n,o)}w.hrTime=Qo;function Gc(a){if(dn(a))return a;if(typeof a=="number")return a<fn()?Qo(a):he(a);if(a instanceof Date)return he(a.getTime());throw TypeError("Invalid input type")}w.timeInputToHrTime=Gc;function Hc(a,n){let o=n[0]-a[0],c=n[1]-a[1];return c<0&&(o-=1,c+=Je),[o,c]}w.hrTimeDuration=Hc;function jc(a){let n=$o,o=`${"0".repeat(n)}${a[1]}Z`,c=o.substr(o.length-n-1);return new Date(a[0]*1e3).toISOString().replace("000Z",c)}w.hrTimeToTimeStamp=jc;function Fc(a){return a[0]*Je+a[1]}w.hrTimeToNanoseconds=Fc;function qc(a){return a[0]*1e3+a[1]/1e6}w.hrTimeToMilliseconds=qc;function Kc(a){return a[0]*1e6+a[1]/1e3}w.hrTimeToMicroseconds=Kc;function dn(a){return Array.isArray(a)&&a.length===2&&typeof a[0]=="number"&&typeof a[1]=="number"}w.isTimeInputHrTime=dn;function Xc(a){return dn(a)||typeof a=="number"||a instanceof Date}w.isTimeInput=Xc;function Zo(a,n){let o=[a[0]+n[0],a[1]+n[1]];return o[1]>=Je&&(o[1]-=Je,o[0]+=1),o}w.addHrTimes=Zo});var ri=m(ei=>{"use strict";Object.defineProperty(ei,"__esModule",{value:!0})});var ni=m(me=>{"use strict";Object.defineProperty(me,"__esModule",{value:!0});me.ExportResultCode=void 0;var Yc;(function(a){a[a.SUCCESS=0]="SUCCESS",a[a.FAILED=1]="FAILED"})(Yc=me.ExportResultCode||(me.ExportResultCode={}))});var ii=m(ze=>{"use strict";Object.defineProperty(ze,"__esModule",{value:!0});ze.CompositePropagator=void 0;var oi=(b(),D(y)),yn=class{constructor(n={}){var o;this._propagators=(o=n.propagators)!==null&&o!==void 0?o:[],this._fields=Array.from(new Set(this._propagators.map(c=>typeof c.fields=="function"?c.fields():[]).reduce((c,l)=>c.concat(l),[])))}inject(n,o,c){for(let l of this._propagators)try{l.inject(n,o,c)}catch(i){oi.diag.warn(`Failed to inject with ${l.constructor.name}. Err: ${i.message}`)}}extract(n,o,c){return this._propagators.reduce((l,i)=>{try{return i.extract(l,o,c)}catch(e){oi.diag.warn(`Failed to inject with ${i.constructor.name}. Err: ${e.message}`)}return l},n)}fields(){return this._fields.slice()}};ze.CompositePropagator=yn});var ai=m(Kt=>{"use strict";Object.defineProperty(Kt,"__esModule",{value:!0});Kt.validateValue=Kt.validateKey=void 0;var hn="[_0-9a-z-*/]",Jc=`[a-z]${hn}{0,255}`,zc=`[a-z0-9]${hn}{0,240}@[a-z]${hn}{0,13}`,Wc=new RegExp(`^(?:${Jc}|${zc})$`),$c=/^[ -~]{0,255}[!-~]$/,Qc=/,|=/;function Zc(a){return Wc.test(a)}Kt.validateKey=Zc;function ts(a){return $c.test(a)&&!Qc.test(a)}Kt.validateValue=ts});var vn=m(We=>{"use strict";Object.defineProperty(We,"__esModule",{value:!0});We.TraceState=void 0;var ui=ai(),li=32,es=512,ci=",",si="=",mn=class a{constructor(n){this._internalState=new Map,n&&this._parse(n)}set(n,o){let c=this._clone();return c._internalState.has(n)&&c._internalState.delete(n),c._internalState.set(n,o),c}unset(n){let o=this._clone();return o._internalState.delete(n),o}get(n){return this._internalState.get(n)}serialize(){return this._keys().reduce((n,o)=>(n.push(o+si+this.get(o)),n),[]).join(ci)}_parse(n){n.length>es||(this._internalState=n.split(ci).reverse().reduce((o,c)=>{let l=c.trim(),i=l.indexOf(si);if(i!==-1){let e=l.slice(0,i),t=l.slice(i+1,c.length);(0,ui.validateKey)(e)&&(0,ui.validateValue)(t)&&o.set(e,t)}return o},new Map),this._internalState.size>li&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,li))))}_keys(){return Array.from(this._internalState.keys()).reverse()}_clone(){let n=new a;return n._internalState=new Map(this._internalState),n}};We.TraceState=mn});var fi=m(X=>{"use strict";Object.defineProperty(X,"__esModule",{value:!0});X.W3CTraceContextPropagator=X.parseTraceParent=X.TRACE_STATE_HEADER=X.TRACE_PARENT_HEADER=void 0;var $e=(b(),D(y)),rs=fe(),ns=vn();X.TRACE_PARENT_HEADER="traceparent";X.TRACE_STATE_HEADER="tracestate";var os="00",is="(?!ff)[\\da-f]{2}",as="(?![0]{32})[\\da-f]{32}",us="(?![0]{16})[\\da-f]{16}",ls="[\\da-f]{2}",cs=new RegExp(`^\\s?(${is})-(${as})-(${us})-(${ls})(-.*)?\\s?$`);function pi(a){let n=cs.exec(a);return!n||n[1]==="00"&&n[5]?null:{traceId:n[2],spanId:n[3],traceFlags:parseInt(n[4],16)}}X.parseTraceParent=pi;var _n=class{inject(n,o,c){let l=$e.trace.getSpanContext(n);if(!l||(0,rs.isTracingSuppressed)(n)||!(0,$e.isSpanContextValid)(l))return;let i=`${os}-${l.traceId}-${l.spanId}-0${Number(l.traceFlags||$e.TraceFlags.NONE).toString(16)}`;c.set(o,X.TRACE_PARENT_HEADER,i),l.traceState&&c.set(o,X.TRACE_STATE_HEADER,l.traceState.serialize())}extract(n,o,c){let l=c.get(o,X.TRACE_PARENT_HEADER);if(!l)return n;let i=Array.isArray(l)?l[0]:l;if(typeof i!="string")return n;let e=pi(i);if(!e)return n;e.isRemote=!0;let t=c.get(o,X.TRACE_STATE_HEADER);if(t){let r=Array.isArray(t)?t.join(","):t;e.traceState=new ns.TraceState(typeof r=="string"?r:void 0)}return $e.trace.setSpanContext(n,e)}fields(){return[X.TRACE_PARENT_HEADER,X.TRACE_STATE_HEADER]}};X.W3CTraceContextPropagator=_n});var yi=m(di=>{"use strict";Object.defineProperty(di,"__esModule",{value:!0})});var hi=m(et=>{"use strict";Object.defineProperty(et,"__esModule",{value:!0});et.getRPCMetadata=et.deleteRPCMetadata=et.setRPCMetadata=et.RPCType=void 0;var ss=(b(),D(y)),En=(0,ss.createContextKey)("OpenTelemetry SDK Context Key RPC_METADATA"),ps;(function(a){a.HTTP="http"})(ps=et.RPCType||(et.RPCType={}));function fs(a,n){return a.setValue(En,n)}et.setRPCMetadata=fs;function ds(a){return a.deleteValue(En)}et.deleteRPCMetadata=ds;function ys(a){return a.getValue(En)}et.getRPCMetadata=ys});var Sn=m(Qe=>{"use strict";Object.defineProperty(Qe,"__esModule",{value:!0});Qe.AlwaysOffSampler=void 0;var hs=(b(),D(y)),bn=class{shouldSample(){return{decision:hs.SamplingDecision.NOT_RECORD}}toString(){return"AlwaysOffSampler"}};Qe.AlwaysOffSampler=bn});var On=m(Ze=>{"use strict";Object.defineProperty(Ze,"__esModule",{value:!0});Ze.AlwaysOnSampler=void 0;var ms=(b(),D(y)),Tn=class{shouldSample(){return{decision:ms.SamplingDecision.RECORD_AND_SAMPLED}}toString(){return"AlwaysOnSampler"}};Ze.AlwaysOnSampler=Tn});var vi=m(er=>{"use strict";Object.defineProperty(er,"__esModule",{value:!0});er.ParentBasedSampler=void 0;var tr=(b(),D(y)),vs=on(),mi=Sn(),gn=On(),An=class{constructor(n){var o,c,l,i;this._root=n.root,this._root||((0,vs.globalErrorHandler)(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new gn.AlwaysOnSampler),this._remoteParentSampled=(o=n.remoteParentSampled)!==null&&o!==void 0?o:new gn.AlwaysOnSampler,this._remoteParentNotSampled=(c=n.remoteParentNotSampled)!==null&&c!==void 0?c:new mi.AlwaysOffSampler,this._localParentSampled=(l=n.localParentSampled)!==null&&l!==void 0?l:new gn.AlwaysOnSampler,this._localParentNotSampled=(i=n.localParentNotSampled)!==null&&i!==void 0?i:new mi.AlwaysOffSampler}shouldSample(n,o,c,l,i,e){let t=tr.trace.getSpanContext(n);return!t||!(0,tr.isSpanContextValid)(t)?this._root.shouldSample(n,o,c,l,i,e):t.isRemote?t.traceFlags&tr.TraceFlags.SAMPLED?this._remoteParentSampled.shouldSample(n,o,c,l,i,e):this._remoteParentNotSampled.shouldSample(n,o,c,l,i,e):t.traceFlags&tr.TraceFlags.SAMPLED?this._localParentSampled.shouldSample(n,o,c,l,i,e):this._localParentNotSampled.shouldSample(n,o,c,l,i,e)}toString(){return`ParentBased{root=${this._root.toString()}, remoteParentSampled=${this._remoteParentSampled.toString()}, remoteParentNotSampled=${this._remoteParentNotSampled.toString()}, localParentSampled=${this._localParentSampled.toString()}, localParentNotSampled=${this._localParentNotSampled.toString()}}`}};er.ParentBasedSampler=An});var _i=m(rr=>{"use strict";Object.defineProperty(rr,"__esModule",{value:!0});rr.TraceIdRatioBasedSampler=void 0;var Nn=(b(),D(y)),Pn=class{constructor(n=0){this._ratio=n,this._ratio=this._normalize(n),this._upperBound=Math.floor(this._ratio*4294967295)}shouldSample(n,o){return{decision:(0,Nn.isValidTraceId)(o)&&this._accumulate(o)<this._upperBound?Nn.SamplingDecision.RECORD_AND_SAMPLED:Nn.SamplingDecision.NOT_RECORD}}toString(){return`TraceIdRatioBased{${this._ratio}}`}_normalize(n){return typeof n!="number"||isNaN(n)?0:n>=1?1:n<=0?0:n}_accumulate(n){let o=0;for(let c=0;c<n.length/8;c++){let l=c*8,i=parseInt(n.slice(l,l+8),16);o=(o^i)>>>0}return o}};rr.TraceIdRatioBasedSampler=Pn});var Oi=m(nr=>{"use strict";Object.defineProperty(nr,"__esModule",{value:!0});nr.isPlainObject=void 0;var _s="[object Object]",Es="[object Null]",bs="[object Undefined]",Ss=Function.prototype,Ei=Ss.toString,Ts=Ei.call(Object),Os=gs(Object.getPrototypeOf,Object),bi=Object.prototype,Si=bi.hasOwnProperty,Bt=Symbol?Symbol.toStringTag:void 0,Ti=bi.toString;function gs(a,n){return function(o){return a(n(o))}}function As(a){if(!Ns(a)||Ps(a)!==_s)return!1;let n=Os(a);if(n===null)return!0;let o=Si.call(n,"constructor")&&n.constructor;return typeof o=="function"&&o instanceof o&&Ei.call(o)===Ts}nr.isPlainObject=As;function Ns(a){return a!=null&&typeof a=="object"}function Ps(a){return a==null?a===void 0?bs:Es:Bt&&Bt in Object(a)?xs(a):Rs(a)}function xs(a){let n=Si.call(a,Bt),o=a[Bt],c=!1;try{a[Bt]=void 0,c=!0}catch{}let l=Ti.call(a);return c&&(n?a[Bt]=o:delete a[Bt]),l}function Rs(a){return Ti.call(a)}});var xi=m(ar=>{"use strict";Object.defineProperty(ar,"__esModule",{value:!0});ar.merge=void 0;var gi=Oi(),Ls=20;function Is(...a){let n=a.shift(),o=new WeakMap;for(;a.length>0;)n=Ni(n,a.shift(),0,o);return n}ar.merge=Is;function xn(a){return ir(a)?a.slice():a}function Ni(a,n,o=0,c){let l;if(!(o>Ls)){if(o++,or(a)||or(n)||Pi(n))l=xn(n);else if(ir(a)){if(l=a.slice(),ir(n))for(let i=0,e=n.length;i<e;i++)l.push(xn(n[i]));else if(ve(n)){let i=Object.keys(n);for(let e=0,t=i.length;e<t;e++){let r=i[e];l[r]=xn(n[r])}}}else if(ve(a))if(ve(n)){if(!ws(a,n))return n;l=Object.assign({},a);let i=Object.keys(n);for(let e=0,t=i.length;e<t;e++){let r=i[e],u=n[r];if(or(u))typeof u>"u"?delete l[r]:l[r]=u;else{let s=l[r],d=u;if(Ai(a,r,c)||Ai(n,r,c))delete l[r];else{if(ve(s)&&ve(d)){let v=c.get(s)||[],g=c.get(d)||[];v.push({obj:a,key:r}),g.push({obj:n,key:r}),c.set(s,v),c.set(d,g)}l[r]=Ni(l[r],u,o,c)}}}}else l=n;return l}}function Ai(a,n,o){let c=o.get(a[n])||[];for(let l=0,i=c.length;l<i;l++){let e=c[l];if(e.key===n&&e.obj===a)return!0}return!1}function ir(a){return Array.isArray(a)}function Pi(a){return typeof a=="function"}function ve(a){return!or(a)&&!ir(a)&&!Pi(a)&&typeof a=="object"}function or(a){return typeof a=="string"||typeof a=="number"||typeof a=="boolean"||typeof a>"u"||a instanceof Date||a instanceof RegExp||a===null}function ws(a,n){return!(!(0,gi.isPlainObject)(a)||!(0,gi.isPlainObject)(n))}});var Ri=m(Xt=>{"use strict";Object.defineProperty(Xt,"__esModule",{value:!0});Xt.callWithTimeout=Xt.TimeoutError=void 0;var ur=class a extends Error{constructor(n){super(n),Object.setPrototypeOf(this,a.prototype)}};Xt.TimeoutError=ur;function Cs(a,n){let o,c=new Promise(function(i,e){o=setTimeout(function(){e(new ur("Operation timed out."))},n)});return Promise.race([a,c]).then(l=>(clearTimeout(o),l),l=>{throw clearTimeout(o),l})}Xt.callWithTimeout=Cs});var Ii=m(Yt=>{"use strict";Object.defineProperty(Yt,"__esModule",{value:!0});Yt.isUrlIgnored=Yt.urlMatches=void 0;function Li(a,n){return typeof n=="string"?a===n:!!a.match(n)}Yt.urlMatches=Li;function Us(a,n){if(!n)return!1;for(let o of n)if(Li(a,o))return!0;return!1}Yt.isUrlIgnored=Us});var wi=m(lr=>{"use strict";Object.defineProperty(lr,"__esModule",{value:!0});lr.isWrapped=void 0;function Ms(a){return typeof a=="function"&&typeof a.__original=="function"&&typeof a.__unwrap=="function"&&a.__wrapped===!0}lr.isWrapped=Ms});var Ci=m(cr=>{"use strict";Object.defineProperty(cr,"__esModule",{value:!0});cr.Deferred=void 0;var Rn=class{constructor(){this._promise=new Promise((n,o)=>{this._resolve=n,this._reject=o})}get promise(){return this._promise}resolve(n){this._resolve(n)}reject(n){this._reject(n)}};cr.Deferred=Rn});var Ui=m(sr=>{"use strict";Object.defineProperty(sr,"__esModule",{value:!0});sr.BindOnceFuture=void 0;var Ds=Ci(),Ln=class{constructor(n,o){this._callback=n,this._that=o,this._isCalled=!1,this._deferred=new Ds.Deferred}get isCalled(){return this._isCalled}get promise(){return this._deferred.promise}call(...n){if(!this._isCalled){this._isCalled=!0;try{Promise.resolve(this._callback.call(this._that,...n)).then(o=>this._deferred.resolve(o),o=>this._deferred.reject(o))}catch(o){this._deferred.reject(o)}}return this._deferred.promise}};sr.BindOnceFuture=Ln});var Di=m(pr=>{"use strict";Object.defineProperty(pr,"__esModule",{value:!0});pr._export=void 0;var Mi=(b(),D(y)),Vs=fe();function ks(a,n){return new Promise(o=>{Mi.context.with((0,Vs.suppressTracing)(Mi.context.active()),()=>{a.export(n,c=>{o(c)})})})}pr._export=ks});var V=m(O=>{"use strict";var Bs=O&&O.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),L=O&&O.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&Bs(n,a,o)};Object.defineProperty(O,"__esModule",{value:!0});O.internal=O.baggageUtils=void 0;L(Lo(),O);L(Io(),O);L(Do(),O);L(on(),O);L(nn(),O);L(ti(),O);L(ri(),O);L(ni(),O);O.baggageUtils=Qr();L(sn(),O);L(ii(),O);L(fi(),O);L(yi(),O);L(hi(),O);L(Sn(),O);L(On(),O);L(vi(),O);L(_i(),O);L(fe(),O);L(vn(),O);L(Be(),O);L(xi(),O);L(an(),O);L(Ri(),O);L(Ii(),O);L(wi(),O);L(Ui(),O);L(cn(),O);var Gs=Di();O.internal={_export:Gs._export}});var na=m(xt=>{"use strict";Object.defineProperty(xt,"__esModule",{value:!0});xt.disableInstrumentations=xt.enableInstrumentations=xt.parseInstrumentationOptions=void 0;function ra(a=[]){let n=[];for(let o=0,c=a.length;o<c;o++){let l=a[o];if(Array.isArray(l)){let i=ra(l);n=n.concat(i.instrumentations)}else typeof l=="function"?n.push(new l):l.instrumentationName&&n.push(l)}return{instrumentations:n}}xt.parseInstrumentationOptions=ra;function np(a,n,o){for(let c=0,l=a.length;c<l;c++){let i=a[c];n&&i.setTracerProvider(n),o&&i.setMeterProvider(o),i.getConfig().enabled||i.enable()}}xt.enableInstrumentations=np;function op(a){a.forEach(n=>n.disable())}xt.disableInstrumentations=op});var ia=m(vr=>{"use strict";Object.defineProperty(vr,"__esModule",{value:!0});vr.registerInstrumentations=void 0;var oa=(b(),D(y)),wn=na();function ip(a){let{instrumentations:n}=(0,wn.parseInstrumentationOptions)(a.instrumentations),o=a.tracerProvider||oa.trace.getTracerProvider(),c=a.meterProvider||oa.metrics.getMeterProvider();return(0,wn.enableInstrumentations)(n,o,c),()=>{(0,wn.disableInstrumentations)(n)}}vr.registerInstrumentations=ip});var Ee={};import*as Lm from"async_hooks";var tu=zr(()=>{tt(Ee,Lm)});var be={};import*as Im from"events";var eu=zr(()=>{tt(be,Im)});var ru=m(Pr=>{"use strict";Object.defineProperty(Pr,"__esModule",{value:!0});Pr.AbstractAsyncHooksContextManager=void 0;var Up=(eu(),D(be)),Mp=["addListener","on","once","prependListener","prependOnceListener"],qn=class{constructor(){this._kOtListeners=Symbol("OtListeners"),this._wrapped=!1}bind(n,o){return o instanceof Up.EventEmitter?this._bindEventEmitter(n,o):typeof o=="function"?this._bindFunction(n,o):o}_bindFunction(n,o){let c=this,l=function(...i){return c.with(n,()=>o.apply(this,i))};return Object.defineProperty(l,"length",{enumerable:!1,configurable:!0,writable:!1,value:o.length}),l}_bindEventEmitter(n,o){return this._getPatchMap(o)!==void 0||(this._createPatchMap(o),Mp.forEach(l=>{o[l]!==void 0&&(o[l]=this._patchAddListener(o,o[l],n))}),typeof o.removeListener=="function"&&(o.removeListener=this._patchRemoveListener(o,o.removeListener)),typeof o.off=="function"&&(o.off=this._patchRemoveListener(o,o.off)),typeof o.removeAllListeners=="function"&&(o.removeAllListeners=this._patchRemoveAllListeners(o,o.removeAllListeners))),o}_patchRemoveListener(n,o){let c=this;return function(l,i){var e;let t=(e=c._getPatchMap(n))===null||e===void 0?void 0:e[l];if(t===void 0)return o.call(this,l,i);let r=t.get(i);return o.call(this,l,r||i)}}_patchRemoveAllListeners(n,o){let c=this;return function(l){let i=c._getPatchMap(n);return i!==void 0&&(arguments.length===0?c._createPatchMap(n):i[l]!==void 0&&delete i[l]),o.apply(this,arguments)}}_patchAddListener(n,o,c){let l=this;return function(i,e){if(l._wrapped)return o.call(this,i,e);let t=l._getPatchMap(n);t===void 0&&(t=l._createPatchMap(n));let r=t[i];r===void 0&&(r=new WeakMap,t[i]=r);let u=l.bind(c,e);r.set(e,u),l._wrapped=!0;try{return o.call(this,i,u)}finally{l._wrapped=!1}}}_createPatchMap(n){let o=Object.create(null);return n[this._kOtListeners]=o,o}_getPatchMap(n){return n[this._kOtListeners]}};Pr.AbstractAsyncHooksContextManager=qn});var nu=m(xr=>{"use strict";Object.defineProperty(xr,"__esModule",{value:!0});xr.AsyncLocalStorageContextManager=void 0;var Dp=(b(),D(y)),Vp=(tu(),D(Ee)),kp=ru(),Kn=class extends kp.AbstractAsyncHooksContextManager{constructor(){super(),this._asyncLocalStorage=new Vp.AsyncLocalStorage}active(){var n;return(n=this._asyncLocalStorage.getStore())!==null&&n!==void 0?n:Dp.ROOT_CONTEXT}with(n,o,c,...l){let i=c==null?o:o.bind(c);return this._asyncLocalStorage.run(n,i,...l)}enable(){return this}disable(){return this._asyncLocalStorage.disable(),this}};xr.AsyncLocalStorageContextManager=Kn});var zn=m(Rt=>{"use strict";Object.defineProperty(Rt,"__esModule",{value:!0});Rt.toAnyValue=Rt.toKeyValue=Rt.toAttributes=void 0;function qp(a){return Object.keys(a).map(n=>Yn(n,a[n]))}Rt.toAttributes=qp;function Yn(a,n){return{key:a,value:Jn(n)}}Rt.toKeyValue=Yn;function Jn(a){let n=typeof a;return n==="string"?{stringValue:a}:n==="number"?Number.isInteger(a)?{intValue:a}:{doubleValue:a}:n==="boolean"?{boolValue:a}:a instanceof Uint8Array?{bytesValue:a}:Array.isArray(a)?{arrayValue:{values:a.map(Jn)}}:n==="object"&&a!=null?{kvlistValue:{values:Object.entries(a).map(([o,c])=>Yn(o,c))}}:{}}Rt.toAnyValue=Jn});var cu=m(Lt=>{"use strict";Object.defineProperty(Lt,"__esModule",{value:!0});Lt.toOtlpSpanEvent=Lt.toOtlpLink=Lt.sdkSpanToOtlpSpan=void 0;var Wn=zn();function Kp(a,n){var o;let c=a.spanContext(),l=a.status;return{traceId:n.encodeSpanContext(c.traceId),spanId:n.encodeSpanContext(c.spanId),parentSpanId:n.encodeOptionalSpanContext(a.parentSpanId),traceState:(o=c.traceState)===null||o===void 0?void 0:o.serialize(),name:a.name,kind:a.kind==null?0:a.kind+1,startTimeUnixNano:n.encodeHrTime(a.startTime),endTimeUnixNano:n.encodeHrTime(a.endTime),attributes:(0,Wn.toAttributes)(a.attributes),droppedAttributesCount:a.droppedAttributesCount,events:a.events.map(i=>lu(i,n)),droppedEventsCount:a.droppedEventsCount,status:{code:l.code,message:l.message},links:a.links.map(i=>uu(i,n)),droppedLinksCount:a.droppedLinksCount}}Lt.sdkSpanToOtlpSpan=Kp;function uu(a,n){var o;return{attributes:a.attributes?(0,Wn.toAttributes)(a.attributes):[],spanId:n.encodeSpanContext(a.context.spanId),traceId:n.encodeSpanContext(a.context.traceId),traceState:(o=a.context.traceState)===null||o===void 0?void 0:o.serialize(),droppedAttributesCount:a.droppedAttributesCount||0}}Lt.toOtlpLink=uu;function lu(a,n){return{attributes:a.attributes?(0,Wn.toAttributes)(a.attributes):[],name:a.name,timeUnixNano:n.encodeHrTime(a.time),droppedAttributesCount:a.droppedAttributesCount||0}}Lt.toOtlpSpanEvent=lu});var yu=m(Q=>{"use strict";Object.defineProperty(Q,"__esModule",{value:!0});Q.getOtlpEncoder=Q.encodeAsString=Q.encodeAsLongBits=Q.toLongBits=Q.hrTimeToNanos=void 0;var Ir=V(),Xp=BigInt(1e9);function $n(a){return BigInt(a[0])*Xp+BigInt(a[1])}Q.hrTimeToNanos=$n;function pu(a){let n=Number(BigInt.asUintN(32,a)),o=Number(BigInt.asUintN(32,a>>BigInt(32)));return{low:n,high:o}}Q.toLongBits=pu;function Qn(a){let n=$n(a);return pu(n)}Q.encodeAsLongBits=Qn;function fu(a){return $n(a).toString()}Q.encodeAsString=fu;var Yp=typeof BigInt<"u"?fu:Ir.hrTimeToNanoseconds;function su(a){return a}function du(a){if(a!==void 0)return(0,Ir.hexToBase64)(a)}var Jp={encodeHrTime:Qn,encodeSpanContext:Ir.hexToBase64,encodeOptionalSpanContext:du};function zp(a){var n,o;if(a===void 0)return Jp;let c=(n=a.useLongBits)!==null&&n!==void 0?n:!0,l=(o=a.useHex)!==null&&o!==void 0?o:!1;return{encodeHrTime:c?Qn:Yp,encodeSpanContext:l?su:Ir.hexToBase64,encodeOptionalSpanContext:l?su:du}}Q.getOtlpEncoder=zp});var Zn=m(wr=>{"use strict";Object.defineProperty(wr,"__esModule",{value:!0});wr.createExportTraceServiceRequest=void 0;var Wp=zn(),$p=cu(),Qp=yu();function Zp(a,n){let o=(0,Qp.getOtlpEncoder)(n);return{resourceSpans:ef(a,o)}}wr.createExportTraceServiceRequest=Zp;function tf(a){let n=new Map;for(let o of a){let c=n.get(o.resource);c||(c=new Map,n.set(o.resource,c));let l=`${o.instrumentationLibrary.name}@${o.instrumentationLibrary.version||""}:${o.instrumentationLibrary.schemaUrl||""}`,i=c.get(l);i||(i=[],c.set(l,i)),i.push(o)}return n}function ef(a,n){let o=tf(a),c=[],l=o.entries(),i=l.next();for(;!i.done;){let[e,t]=i.value,r=[],u=t.values(),s=u.next();for(;!s.done;){let v=s.value;if(v.length>0){let{name:g,version:x,schemaUrl:I}=v[0].instrumentationLibrary,F=v.map(R=>(0,$p.sdkSpanToOtlpSpan)(R,n));r.push({scope:{name:g,version:x},spans:F,schemaUrl:I})}s=u.next()}let d={resource:{attributes:(0,Wp.toAttributes)(e.attributes),droppedAttributesCount:0},scopeSpans:r,schemaUrl:void 0};c.push(d),i=l.next()}return c}});var Te=m(M=>{"use strict";Object.defineProperty(M,"__esModule",{value:!0});M.parseRetryAfterToMills=M.isExportRetryable=M.invalidTimeout=M.configureExporterTimeout=M.appendRootPathToUrlIfNeeded=M.appendResourcePathToUrl=M.parseHeaders=M.DEFAULT_EXPORT_BACKOFF_MULTIPLIER=M.DEFAULT_EXPORT_MAX_BACKOFF=M.DEFAULT_EXPORT_INITIAL_BACKOFF=M.DEFAULT_EXPORT_MAX_ATTEMPTS=void 0;var to=(b(),D(y)),hu=V(),mu=1e4;M.DEFAULT_EXPORT_MAX_ATTEMPTS=5;M.DEFAULT_EXPORT_INITIAL_BACKOFF=1e3;M.DEFAULT_EXPORT_MAX_BACKOFF=5e3;M.DEFAULT_EXPORT_BACKOFF_MULTIPLIER=1.5;function rf(a={}){let n={};return Object.entries(a).forEach(([o,c])=>{typeof c<"u"?n[o]=String(c):to.diag.warn(`Header "${o}" has wrong value and will be ignored`)}),n}M.parseHeaders=rf;function nf(a,n){return a.endsWith("/")||(a=a+"/"),a+n}M.appendResourcePathToUrl=nf;function of(a){try{let n=new URL(a);return n.pathname===""&&(n.pathname=n.pathname+"/"),n.toString()}catch{return to.diag.warn(`Could not parse export URL: '${a}'`),a}}M.appendRootPathToUrlIfNeeded=of;function af(a){return typeof a=="number"?a<=0?eo(a,mu):a:uf()}M.configureExporterTimeout=af;function uf(){var a;let n=Number((a=(0,hu.getEnv)().OTEL_EXPORTER_OTLP_TRACES_TIMEOUT)!==null&&a!==void 0?a:(0,hu.getEnv)().OTEL_EXPORTER_OTLP_TIMEOUT);return n<=0?eo(n,mu):n}function eo(a,n){return to.diag.warn("Timeout must be greater than 0",a),n}M.invalidTimeout=eo;function lf(a){return[429,502,503,504].includes(a)}M.isExportRetryable=lf;function cf(a){if(a==null)return-1;let n=Number.parseInt(a,10);if(Number.isInteger(n))return n>0?n*1e3:-1;let o=new Date(a).getTime()-Date.now();return o>=0?o:0}M.parseRetryAfterToMills=cf});var Ur=m(Cr=>{"use strict";Object.defineProperty(Cr,"__esModule",{value:!0});Cr.OTLPExporterBase=void 0;var vu=(b(),D(y)),Oe=V(),sf=Te(),ro=class{constructor(n={}){this._sendingPromises=[],this.url=this.getDefaultUrl(n),typeof n.hostname=="string"&&(this.hostname=n.hostname),this.shutdown=this.shutdown.bind(this),this._shutdownOnce=new Oe.BindOnceFuture(this._shutdown,this),this._concurrencyLimit=typeof n.concurrencyLimit=="number"?n.concurrencyLimit:30,this.timeoutMillis=(0,sf.configureExporterTimeout)(n.timeoutMillis),this.onInit(n)}export(n,o){if(this._shutdownOnce.isCalled){o({code:Oe.ExportResultCode.FAILED,error:new Error("Exporter has been shutdown")});return}if(this._sendingPromises.length>=this._concurrencyLimit){o({code:Oe.ExportResultCode.FAILED,error:new Error("Concurrent export limit reached")});return}this._export(n).then(()=>{o({code:Oe.ExportResultCode.SUCCESS})}).catch(c=>{o({code:Oe.ExportResultCode.FAILED,error:c})})}_export(n){return new Promise((o,c)=>{try{vu.diag.debug("items to be sent",n),this.send(n,o,c)}catch(l){c(l)}})}shutdown(){return this._shutdownOnce.call()}forceFlush(){return Promise.all(this._sendingPromises).then(()=>{})}_shutdown(){return vu.diag.debug("shutdown started"),this.onShutdown(),this.forceFlush()}};Cr.OTLPExporterBase=ro});var io=m(Dr=>{"use strict";Object.defineProperty(Dr,"__esModule",{value:!0});Dr.OTLPExporterError=void 0;var oo=class extends Error{constructor(n,o,c){super(n),this.name="OTLPExporterError",this.data=c,this.code=o}};Dr.OTLPExporterError=oo});var ao=m(ie=>{"use strict";Object.defineProperty(ie,"__esModule",{value:!0});ie.sendWithXhr=ie.sendWithBeacon=void 0;var bu=(b(),D(y)),ge=io(),oe=Te();function df(a,n,o,c,l){if(navigator.sendBeacon(n,new Blob([a],o)))bu.diag.debug("sendBeacon - can send",a),c();else{let i=new ge.OTLPExporterError(`sendBeacon - cannot send ${a}`);l(i)}}ie.sendWithBeacon=df;function yf(a,n,o,c,l,i){let e,t,r=!1,u=setTimeout(()=>{if(clearTimeout(e),r=!0,t.readyState===XMLHttpRequest.DONE){let d=new ge.OTLPExporterError("Request Timeout");i(d)}else t.abort()},c),s=(d=oe.DEFAULT_EXPORT_MAX_ATTEMPTS,v=oe.DEFAULT_EXPORT_INITIAL_BACKOFF)=>{t=new XMLHttpRequest,t.open("POST",n),Object.entries(Object.assign(Object.assign({},{Accept:"application/json","Content-Type":"application/json"}),o)).forEach(([x,I])=>{t.setRequestHeader(x,I)}),t.send(a),t.onreadystatechange=()=>{if(t.readyState===XMLHttpRequest.DONE&&r===!1)if(t.status>=200&&t.status<=299)bu.diag.debug("xhr success",a),l(),clearTimeout(u),clearTimeout(e);else if(t.status&&(0,oe.isExportRetryable)(t.status)&&d>0){let x;v=oe.DEFAULT_EXPORT_BACKOFF_MULTIPLIER*v,t.getResponseHeader("Retry-After")?x=(0,oe.parseRetryAfterToMills)(t.getResponseHeader("Retry-After")):x=Math.round(Math.random()*(oe.DEFAULT_EXPORT_MAX_BACKOFF-v)+v),e=setTimeout(()=>{s(d-1,v)},x)}else{let x=new ge.OTLPExporterError(`Failed to export with XHR (status: ${t.status})`,t.status);i(x),clearTimeout(u),clearTimeout(e)}},t.onabort=()=>{if(r){let x=new ge.OTLPExporterError("Request Timeout");i(x)}clearTimeout(u),clearTimeout(e)},t.onerror=()=>{if(r){let x=new ge.OTLPExporterError("Request Timeout");i(x)}clearTimeout(u),clearTimeout(e)}};s()}ie.sendWithXhr=yf});var Tu=m(kr=>{"use strict";Object.defineProperty(kr,"__esModule",{value:!0});kr.OTLPExporterBrowserBase=void 0;var hf=Ur(),mf=Te(),Su=ao(),vf=(b(),D(y)),Vr=V(),uo=class extends hf.OTLPExporterBase{constructor(n={}){super(n),this._useXHR=!1,this._useXHR=!!n.headers||typeof navigator.sendBeacon!="function",this._useXHR?this._headers=Object.assign({},(0,mf.parseHeaders)(n.headers),Vr.baggageUtils.parseKeyPairsIntoRecord((0,Vr.getEnv)().OTEL_EXPORTER_OTLP_HEADERS)):this._headers={}}onInit(){Vr._globalThis.addEventListener("unload",this.shutdown)}onShutdown(){Vr._globalThis.removeEventListener("unload",this.shutdown)}send(n,o,c){if(this._shutdownOnce.isCalled){vf.diag.debug("Shutdown already started. Cannot send objects");return}let l=this.convert(n),i=JSON.stringify(l),e=new Promise((r,u)=>{this._useXHR?(0,Su.sendWithXhr)(i,this.url,this._headers,this.timeoutMillis,r,u):(0,Su.sendWithBeacon)(i,this.url,{type:"application/json"},r,u)}).then(o,c);this._sendingPromises.push(e);let t=()=>{let r=this._sendingPromises.indexOf(e);this._sendingPromises.splice(r,1)};e.then(t,t)}};kr.OTLPExporterBrowserBase=uo});var Ou=m(ae=>{"use strict";Object.defineProperty(ae,"__esModule",{value:!0});ae.sendWithXhr=ae.OTLPExporterBrowserBase=void 0;var _f=Tu();Object.defineProperty(ae,"OTLPExporterBrowserBase",{enumerable:!0,get:function(){return _f.OTLPExporterBrowserBase}});var Ef=ao();Object.defineProperty(ae,"sendWithXhr",{enumerable:!0,get:function(){return Ef.sendWithXhr}})});var gu=m(k=>{"use strict";var bf=k&&k.__createBinding||(Object.create?function(a,n,o,c){c===void 0&&(c=o),Object.defineProperty(a,c,{enumerable:!0,get:function(){return n[o]}})}:function(a,n,o,c){c===void 0&&(c=o),a[c]=n[o]}),Sf=k&&k.__exportStar||function(a,n){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(n,o)&&bf(n,a,o)};Object.defineProperty(k,"__esModule",{value:!0});k.invalidTimeout=k.configureExporterTimeout=k.appendRootPathToUrlIfNeeded=k.appendResourcePathToUrl=k.parseHeaders=k.OTLPExporterError=k.OTLPExporterBase=void 0;Sf(Ou(),k);var Tf=Ur();Object.defineProperty(k,"OTLPExporterBase",{enumerable:!0,get:function(){return Tf.OTLPExporterBase}});var Of=io();Object.defineProperty(k,"OTLPExporterError",{enumerable:!0,get:function(){return Of.OTLPExporterError}});var Ae=Te();Object.defineProperty(k,"parseHeaders",{enumerable:!0,get:function(){return Ae.parseHeaders}});Object.defineProperty(k,"appendResourcePathToUrl",{enumerable:!0,get:function(){return Ae.appendResourcePathToUrl}});Object.defineProperty(k,"appendRootPathToUrlIfNeeded",{enumerable:!0,get:function(){return Ae.appendRootPathToUrlIfNeeded}});Object.defineProperty(k,"configureExporterTimeout",{enumerable:!0,get:function(){return Ae.configureExporterTimeout}});Object.defineProperty(k,"invalidTimeout",{enumerable:!0,get:function(){return Ae.invalidTimeout}})});var Nu=m((pv,Au)=>{"use strict";Au.exports=gf;function gf(a,n){for(var o=new Array(arguments.length-1),c=0,l=2,i=!0;l<arguments.length;)o[c++]=arguments[l++];return new Promise(function(t,r){o[c]=function(s){if(i)if(i=!1,s)r(s);else{for(var d=new Array(arguments.length-1),v=0;v<d.length;)d[v++]=arguments[v];t.apply(null,d)}};try{a.apply(n||null,o)}catch(u){i&&(i=!1,r(u))}})}});var Lu=m(Ru=>{"use strict";var Br=Ru;Br.length=function(n){var o=n.length;if(!o)return 0;for(var c=0;--o%4>1&&n.charAt(o)==="=";)++c;return Math.ceil(n.length*3)/4-c};var ue=new Array(64),xu=new Array(123);for(ot=0;ot<64;)xu[ue[ot]=ot<26?ot+65:ot<52?ot+71:ot<62?ot-4:ot-59|43]=ot++;var ot;Br.encode=function(n,o,c){for(var l=null,i=[],e=0,t=0,r;o<c;){var u=n[o++];switch(t){case 0:i[e++]=ue[u>>2],r=(u&3)<<4,t=1;break;case 1:i[e++]=ue[r|u>>4],r=(u&15)<<2,t=2;break;case 2:i[e++]=ue[r|u>>6],i[e++]=ue[u&63],t=0;break}e>8191&&((l||(l=[])).push(String.fromCharCode.apply(String,i)),e=0)}return t&&(i[e++]=ue[r],i[e++]=61,t===1&&(i[e++]=61)),l?(e&&l.push(String.fromCharCode.apply(String,i.slice(0,e))),l.join("")):String.fromCharCode.apply(String,i.slice(0,e))};var Pu="invalid encoding";Br.decode=function(n,o,c){for(var l=c,i=0,e,t=0;t<n.length;){var r=n.charCodeAt(t++);if(r===61&&i>1)break;if((r=xu[r])===void 0)throw Error(Pu);switch(i){case 0:e=r,i=1;break;case 1:o[c++]=e<<2|(r&48)>>4,e=r,i=2;break;case 2:o[c++]=(e&15)<<4|(r&60)>>2,e=r,i=3;break;case 3:o[c++]=(e&3)<<6|r,i=0;break}}if(i===1)throw Error(Pu);return c-l};Br.test=function(n){return/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(n)}});var wu=m((dv,Iu)=>{"use strict";Iu.exports=Gr;function Gr(){this._listeners={}}Gr.prototype.on=function(n,o,c){return(this._listeners[n]||(this._listeners[n]=[])).push({fn:o,ctx:c||this}),this};Gr.prototype.off=function(n,o){if(n===void 0)this._listeners={};else if(o===void 0)this._listeners[n]=[];else for(var c=this._listeners[n],l=0;l<c.length;)c[l].fn===o?c.splice(l,1):++l;return this};Gr.prototype.emit=function(n){var o=this._listeners[n];if(o){for(var c=[],l=1;l<arguments.length;)c.push(arguments[l++]);for(l=0;l<o.length;)o[l].fn.apply(o[l++].ctx,c)}return this}});var Bu=m((yv,ku)=>{"use strict";ku.exports=Cu(Cu);function Cu(a){return typeof Float32Array<"u"?function(){var n=new Float32Array([-0]),o=new Uint8Array(n.buffer),c=o[3]===128;function l(r,u,s){n[0]=r,u[s]=o[0],u[s+1]=o[1],u[s+2]=o[2],u[s+3]=o[3]}function i(r,u,s){n[0]=r,u[s]=o[3],u[s+1]=o[2],u[s+2]=o[1],u[s+3]=o[0]}a.writeFloatLE=c?l:i,a.writeFloatBE=c?i:l;function e(r,u){return o[0]=r[u],o[1]=r[u+1],o[2]=r[u+2],o[3]=r[u+3],n[0]}function t(r,u){return o[3]=r[u],o[2]=r[u+1],o[1]=r[u+2],o[0]=r[u+3],n[0]}a.readFloatLE=c?e:t,a.readFloatBE=c?t:e}():function(){function n(c,l,i,e){var t=l<0?1:0;if(t&&(l=-l),l===0)c(1/l>0?0:2147483648,i,e);else if(isNaN(l))c(2143289344,i,e);else if(l>34028234663852886e22)c((t<<31|2139095040)>>>0,i,e);else if(l<11754943508222875e-54)c((t<<31|Math.round(l/1401298464324817e-60))>>>0,i,e);else{var r=Math.floor(Math.log(l)/Math.LN2),u=Math.round(l*Math.pow(2,-r)*8388608)&8388607;c((t<<31|r+127<<23|u)>>>0,i,e)}}a.writeFloatLE=n.bind(null,Uu),a.writeFloatBE=n.bind(null,Mu);function o(c,l,i){var e=c(l,i),t=(e>>31)*2+1,r=e>>>23&255,u=e&8388607;return r===255?u?NaN:t*(1/0):r===0?t*1401298464324817e-60*u:t*Math.pow(2,r-150)*(u+8388608)}a.readFloatLE=o.bind(null,Du),a.readFloatBE=o.bind(null,Vu)}(),typeof Float64Array<"u"?function(){var n=new Float64Array([-0]),o=new Uint8Array(n.buffer),c=o[7]===128;function l(r,u,s){n[0]=r,u[s]=o[0],u[s+1]=o[1],u[s+2]=o[2],u[s+3]=o[3],u[s+4]=o[4],u[s+5]=o[5],u[s+6]=o[6],u[s+7]=o[7]}function i(r,u,s){n[0]=r,u[s]=o[7],u[s+1]=o[6],u[s+2]=o[5],u[s+3]=o[4],u[s+4]=o[3],u[s+5]=o[2],u[s+6]=o[1],u[s+7]=o[0]}a.writeDoubleLE=c?l:i,a.writeDoubleBE=c?i:l;function e(r,u){return o[0]=r[u],o[1]=r[u+1],o[2]=r[u+2],o[3]=r[u+3],o[4]=r[u+4],o[5]=r[u+5],o[6]=r[u+6],o[7]=r[u+7],n[0]}function t(r,u){return o[7]=r[u],o[6]=r[u+1],o[5]=r[u+2],o[4]=r[u+3],o[3]=r[u+4],o[2]=r[u+5],o[1]=r[u+6],o[0]=r[u+7],n[0]}a.readDoubleLE=c?e:t,a.readDoubleBE=c?t:e}():function(){function n(c,l,i,e,t,r){var u=e<0?1:0;if(u&&(e=-e),e===0)c(0,t,r+l),c(1/e>0?0:2147483648,t,r+i);else if(isNaN(e))c(0,t,r+l),c(2146959360,t,r+i);else if(e>17976931348623157e292)c(0,t,r+l),c((u<<31|2146435072)>>>0,t,r+i);else{var s;if(e<22250738585072014e-324)s=e/5e-324,c(s>>>0,t,r+l),c((u<<31|s/4294967296)>>>0,t,r+i);else{var d=Math.floor(Math.log(e)/Math.LN2);d===1024&&(d=1023),s=e*Math.pow(2,-d),c(s*4503599627370496>>>0,t,r+l),c((u<<31|d+1023<<20|s*1048576&1048575)>>>0,t,r+i)}}}a.writeDoubleLE=n.bind(null,Uu,0,4),a.writeDoubleBE=n.bind(null,Mu,4,0);function o(c,l,i,e,t){var r=c(e,t+l),u=c(e,t+i),s=(u>>31)*2+1,d=u>>>20&2047,v=4294967296*(u&1048575)+r;return d===2047?v?NaN:s*(1/0):d===0?s*5e-324*v:s*Math.pow(2,d-1075)*(v+4503599627370496)}a.readDoubleLE=o.bind(null,Du,0,4),a.readDoubleBE=o.bind(null,Vu,4,0)}(),a}function Uu(a,n,o){n[o]=a&255,n[o+1]=a>>>8&255,n[o+2]=a>>>16&255,n[o+3]=a>>>24}function Mu(a,n,o){n[o]=a>>>24,n[o+1]=a>>>16&255,n[o+2]=a>>>8&255,n[o+3]=a&255}function Du(a,n){return(a[n]|a[n+1]<<8|a[n+2]<<16|a[n+3]<<24)>>>0}function Vu(a,n){return(a[n]<<24|a[n+1]<<16|a[n+2]<<8|a[n+3])>>>0}});var Hu=m((hv,Gu)=>{"use strict";Gu.exports=Af;function Af(a){return null}});var Fu=m(ju=>{"use strict";var lo=ju;lo.length=function(n){for(var o=0,c=0,l=0;l<n.length;++l)c=n.charCodeAt(l),c<128?o+=1:c<2048?o+=2:(c&64512)===55296&&(n.charCodeAt(l+1)&64512)===56320?(++l,o+=4):o+=3;return o};lo.read=function(n,o,c){var l=c-o;if(l<1)return"";for(var i=null,e=[],t=0,r;o<c;)r=n[o++],r<128?e[t++]=r:r>191&&r<224?e[t++]=(r&31)<<6|n[o++]&63:r>239&&r<365?(r=((r&7)<<18|(n[o++]&63)<<12|(n[o++]&63)<<6|n[o++]&63)-65536,e[t++]=55296+(r>>10),e[t++]=56320+(r&1023)):e[t++]=(r&15)<<12|(n[o++]&63)<<6|n[o++]&63,t>8191&&((i||(i=[])).push(String.fromCharCode.apply(String,e)),t=0);return i?(t&&i.push(String.fromCharCode.apply(String,e.slice(0,t))),i.join("")):String.fromCharCode.apply(String,e.slice(0,t))};lo.write=function(n,o,c){for(var l=c,i,e,t=0;t<n.length;++t)i=n.charCodeAt(t),i<128?o[c++]=i:i<2048?(o[c++]=i>>6|192,o[c++]=i&63|128):(i&64512)===55296&&((e=n.charCodeAt(t+1))&64512)===56320?(i=65536+((i&1023)<<10)+(e&1023),++t,o[c++]=i>>18|240,o[c++]=i>>12&63|128,o[c++]=i>>6&63|128,o[c++]=i&63|128):(o[c++]=i>>12|224,o[c++]=i>>6&63|128,o[c++]=i&63|128);return c-l}});var Ku=m((vv,qu)=>{"use strict";qu.exports=Nf;function Nf(a,n,o){var c=o||8192,l=c>>>1,i=null,e=c;return function(r){if(r<1||r>l)return a(r);e+r>c&&(i=a(c),e=0);var u=n.call(i,e,e+=r);return e&7&&(e=(e|7)+1),u}}});var Yu=m((_v,Xu)=>{"use strict";Xu.exports=H;var Ne=wt();function H(a,n){this.lo=a>>>0,this.hi=n>>>0}var Ht=H.zero=new H(0,0);Ht.toNumber=function(){return 0};Ht.zzEncode=Ht.zzDecode=function(){return this};Ht.length=function(){return 1};var Pf=H.zeroHash="\0\0\0\0\0\0\0\0";H.fromNumber=function(n){if(n===0)return Ht;var o=n<0;o&&(n=-n);var c=n>>>0,l=(n-c)/4294967296>>>0;return o&&(l=~l>>>0,c=~c>>>0,++c>4294967295&&(c=0,++l>4294967295&&(l=0))),new H(c,l)};H.from=function(n){if(typeof n=="number")return H.fromNumber(n);if(Ne.isString(n))if(Ne.Long)n=Ne.Long.fromString(n);else return H.fromNumber(parseInt(n,10));return n.low||n.high?new H(n.low>>>0,n.high>>>0):Ht};H.prototype.toNumber=function(n){if(!n&&this.hi>>>31){var o=~this.lo+1>>>0,c=~this.hi>>>0;return o||(c=c+1>>>0),-(o+c*4294967296)}return this.lo+this.hi*4294967296};H.prototype.toLong=function(n){return Ne.Long?new Ne.Long(this.lo|0,this.hi|0,!!n):{low:this.lo|0,high:this.hi|0,unsigned:!!n}};var It=String.prototype.charCodeAt;H.fromHash=function(n){return n===Pf?Ht:new H((It.call(n,0)|It.call(n,1)<<8|It.call(n,2)<<16|It.call(n,3)<<24)>>>0,(It.call(n,4)|It.call(n,5)<<8|It.call(n,6)<<16|It.call(n,7)<<24)>>>0)};H.prototype.toHash=function(){return String.fromCharCode(this.lo&255,this.lo>>>8&255,this.lo>>>16&255,this.lo>>>24,this.hi&255,this.hi>>>8&255,this.hi>>>16&255,this.hi>>>24)};H.prototype.zzEncode=function(){var n=this.hi>>31;return this.hi=((this.hi<<1|this.lo>>>31)^n)>>>0,this.lo=(this.lo<<1^n)>>>0,this};H.prototype.zzDecode=function(){var n=-(this.lo&1);return this.lo=((this.lo>>>1|this.hi<<31)^n)>>>0,this.hi=(this.hi>>>1^n)>>>0,this};H.prototype.length=function(){var n=this.lo,o=(this.lo>>>28|this.hi<<4)>>>0,c=this.hi>>>24;return c===0?o===0?n<16384?n<128?1:2:n<2097152?3:4:o<16384?o<128?5:6:o<2097152?7:8:c<128?9:10}});var wt=m(co=>{"use strict";var _=co;_.asPromise=Nu();_.base64=Lu();_.EventEmitter=wu();_.float=Bu();_.inquire=Hu();_.utf8=Fu();_.pool=Ku();_.LongBits=Yu();_.isNode=!!(typeof global<"u"&&global&&global.process&&global.process.versions&&global.process.versions.node);_.global=_.isNode&&global||typeof window<"u"&&window||typeof self<"u"&&self||co;_.emptyArray=Object.freeze?Object.freeze([]):[];_.emptyObject=Object.freeze?Object.freeze({}):{};_.isInteger=Number.isInteger||function(n){return typeof n=="number"&&isFinite(n)&&Math.floor(n)===n};_.isString=function(n){return typeof n=="string"||n instanceof String};_.isObject=function(n){return n&&typeof n=="object"};_.isset=_.isSet=function(n,o){var c=n[o];return c!=null&&n.hasOwnProperty(o)?typeof c!="object"||(Array.isArray(c)?c.length:Object.keys(c).length)>0:!1};_.Buffer=function(){try{var a=_.inquire("buffer").Buffer;return a.prototype.utf8Write?a:null}catch{return null}}();_._Buffer_from=null;_._Buffer_allocUnsafe=null;_.newBuffer=function(n){return typeof n=="number"?_.Buffer?_._Buffer_allocUnsafe(n):new _.Array(n):_.Buffer?_._Buffer_from(n):typeof Uint8Array>"u"?n:new Uint8Array(n)};_.Array=typeof Uint8Array<"u"?Uint8Array:Array;_.Long=_.global.dcodeIO&&_.global.dcodeIO.Long||_.global.Long||_.inquire("long");_.key2Re=/^true|false|0|1$/;_.key32Re=/^-?(?:0|[1-9][0-9]*)$/;_.key64Re=/^(?:[\\x00-\\xff]{8}|-?(?:0|[1-9][0-9]*))$/;_.longToHash=function(n){return n?_.LongBits.from(n).toHash():_.LongBits.zeroHash};_.longFromHash=function(n,o){var c=_.LongBits.fromHash(n);return _.Long?_.Long.fromBits(c.lo,c.hi,o):c.toNumber(!!o)};function Ju(a,n,o){for(var c=Object.keys(n),l=0;l<c.length;++l)(a[c[l]]===void 0||!o)&&(a[c[l]]=n[c[l]]);return a}_.merge=Ju;_.lcFirst=function(n){return n.charAt(0).toLowerCase()+n.substring(1)};function zu(a){function n(o,c){if(!(this instanceof n))return new n(o,c);Object.defineProperty(this,"message",{get:function(){return o}}),Error.captureStackTrace?Error.captureStackTrace(this,n):Object.defineProperty(this,"stack",{value:new Error().stack||""}),c&&Ju(this,c)}return n.prototype=Object.create(Error.prototype,{constructor:{value:n,writable:!0,enumerable:!1,configurable:!0},name:{get:function(){return a},set:void 0,enumerable:!1,configurable:!0},toString:{value:function(){return this.name+": "+this.message},writable:!0,enumerable:!1,configurable:!0}}),n}_.newError=zu;_.ProtocolError=zu("ProtocolError");_.oneOfGetter=function(n){for(var o={},c=0;c<n.length;++c)o[n[c]]=1;return function(){for(var l=Object.keys(this),i=l.length-1;i>-1;--i)if(o[l[i]]===1&&this[l[i]]!==void 0&&this[l[i]]!==null)return l[i]}};_.oneOfSetter=function(n){return function(o){for(var c=0;c<n.length;++c)n[c]!==o&&delete this[n[c]]}};_.toJSONOptions={longs:String,enums:String,bytes:String,json:!0};_._configure=function(){var a=_.Buffer;if(!a){_._Buffer_from=_._Buffer_allocUnsafe=null;return}_._Buffer_from=a.from!==Uint8Array.from&&a.from||function(o,c){return new a(o,c)},_._Buffer_allocUnsafe=a.allocUnsafe||function(o){return new a(o)}}});var vo=m((bv,Zu)=>{"use strict";Zu.exports=A;var Z=wt(),so,Hr=Z.LongBits,Wu=Z.base64,$u=Z.utf8;function Pe(a,n,o){this.fn=a,this.len=n,this.next=void 0,this.val=o}function fo(){}function xf(a){this.head=a.head,this.tail=a.tail,this.len=a.len,this.next=a.states}function A(){this.len=0,this.head=new Pe(fo,0,0),this.tail=this.head,this.states=null}var Qu=function(){return Z.Buffer?function(){return(A.create=function(){return new so})()}:function(){return new A}};A.create=Qu();A.alloc=function(n){return new Z.Array(n)};Z.Array!==Array&&(A.alloc=Z.pool(A.alloc,Z.Array.prototype.subarray));A.prototype._push=function(n,o,c){return this.tail=this.tail.next=new Pe(n,o,c),this.len+=o,this};function yo(a,n,o){n[o]=a&255}function Rf(a,n,o){for(;a>127;)n[o++]=a&127|128,a>>>=7;n[o]=a}function ho(a,n){this.len=a,this.next=void 0,this.val=n}ho.prototype=Object.create(Pe.prototype);ho.prototype.fn=Rf;A.prototype.uint32=function(n){return this.len+=(this.tail=this.tail.next=new ho((n=n>>>0)<128?1:n<16384?2:n<2097152?3:n<268435456?4:5,n)).len,this};A.prototype.int32=function(n){return n<0?this._push(mo,10,Hr.fromNumber(n)):this.uint32(n)};A.prototype.sint32=function(n){return this.uint32((n<<1^n>>31)>>>0)};function mo(a,n,o){for(;a.hi;)n[o++]=a.lo&127|128,a.lo=(a.lo>>>7|a.hi<<25)>>>0,a.hi>>>=7;for(;a.lo>127;)n[o++]=a.lo&127|128,a.lo=a.lo>>>7;n[o++]=a.lo}A.prototype.uint64=function(n){var o=Hr.from(n);return this._push(mo,o.length(),o)};A.prototype.int64=A.prototype.uint64;A.prototype.sint64=function(n){var o=Hr.from(n).zzEncode();return this._push(mo,o.length(),o)};A.prototype.bool=function(n){return this._push(yo,1,n?1:0)};function po(a,n,o){n[o]=a&255,n[o+1]=a>>>8&255,n[o+2]=a>>>16&255,n[o+3]=a>>>24}A.prototype.fixed32=function(n){return this._push(po,4,n>>>0)};A.prototype.sfixed32=A.prototype.fixed32;A.prototype.fixed64=function(n){var o=Hr.from(n);return this._push(po,4,o.lo)._push(po,4,o.hi)};A.prototype.sfixed64=A.prototype.fixed64;A.prototype.float=function(n){return this._push(Z.float.writeFloatLE,4,n)};A.prototype.double=function(n){return this._push(Z.float.writeDoubleLE,8,n)};var Lf=Z.Array.prototype.set?function(n,o,c){o.set(n,c)}:function(n,o,c){for(var l=0;l<n.length;++l)o[c+l]=n[l]};A.prototype.bytes=function(n){var o=n.length>>>0;if(!o)return this._push(yo,1,0);if(Z.isString(n)){var c=A.alloc(o=Wu.length(n));Wu.decode(n,c,0),n=c}return this.uint32(o)._push(Lf,o,n)};A.prototype.string=function(n){var o=$u.length(n);return o?this.uint32(o)._push($u.write,o,n):this._push(yo,1,0)};A.prototype.fork=function(){return this.states=new xf(this),this.head=this.tail=new Pe(fo,0,0),this.len=0,this};A.prototype.reset=function(){return this.states?(this.head=this.states.head,this.tail=this.states.tail,this.len=this.states.len,this.states=this.states.next):(this.head=this.tail=new Pe(fo,0,0),this.len=0),this};A.prototype.ldelim=function(){var n=this.head,o=this.tail,c=this.len;return this.reset().uint32(c),c&&(this.tail.next=n.next,this.tail=o,this.len+=c),this};A.prototype.finish=function(){for(var n=this.head.next,o=this.constructor.alloc(this.len),c=0;n;)n.fn(n.val,o,c),c+=n.len,n=n.next;return o};A._configure=function(a){so=a,A.create=Qu(),so._configure()}});var rl=m((Sv,el)=>{"use strict";el.exports=ct;var tl=vo();(ct.prototype=Object.create(tl.prototype)).constructor=ct;var Ct=wt();function ct(){tl.call(this)}ct._configure=function(){ct.alloc=Ct._Buffer_allocUnsafe,ct.writeBytesBuffer=Ct.Buffer&&Ct.Buffer.prototype instanceof Uint8Array&&Ct.Buffer.prototype.set.name==="set"?function(n,o,c){o.set(n,c)}:function(n,o,c){if(n.copy)n.copy(o,c,0,n.length);else for(var l=0;l<n.length;)o[c++]=n[l++]}};ct.prototype.bytes=function(n){Ct.isString(n)&&(n=Ct._Buffer_from(n,"base64"));var o=n.length>>>0;return this.uint32(o),o&&this._push(ct.writeBytesBuffer,o,n),this};function If(a,n,o){a.length<40?Ct.utf8.write(a,n,o):n.utf8Write?n.utf8Write(a,o):n.write(a,o)}ct.prototype.string=function(n){var o=Ct.Buffer.byteLength(n);return this.uint32(o),o&&this._push(If,o,n),this};ct._configure()});var bo=m((Tv,ul)=>{"use strict";ul.exports=B;var it=wt(),Eo,il=it.LongBits,wf=it.utf8;function at(a,n){return RangeError("index out of range: "+a.pos+" + "+(n||1)+" > "+a.len)}function B(a){this.buf=a,this.pos=0,this.len=a.length}var nl=typeof Uint8Array<"u"?function(n){if(n instanceof Uint8Array||Array.isArray(n))return new B(n);throw Error("illegal buffer")}:function(n){if(Array.isArray(n))return new B(n);throw Error("illegal buffer")},al=function(){return it.Buffer?function(o){return(B.create=function(l){return it.Buffer.isBuffer(l)?new Eo(l):nl(l)})(o)}:nl};B.create=al();B.prototype._slice=it.Array.prototype.subarray||it.Array.prototype.slice;B.prototype.uint32=function(){var n=4294967295;return function(){if(n=(this.buf[this.pos]&127)>>>0,this.buf[this.pos++]<128||(n=(n|(this.buf[this.pos]&127)<<7)>>>0,this.buf[this.pos++]<128)||(n=(n|(this.buf[this.pos]&127)<<14)>>>0,this.buf[this.pos++]<128)||(n=(n|(this.buf[this.pos]&127)<<21)>>>0,this.buf[this.pos++]<128)||(n=(n|(this.buf[this.pos]&15)<<28)>>>0,this.buf[this.pos++]<128))return n;if((this.pos+=5)>this.len)throw this.pos=this.len,at(this,10);return n}}();B.prototype.int32=function(){return this.uint32()|0};B.prototype.sint32=function(){var n=this.uint32();return n>>>1^-(n&1)|0};function _o(){var a=new il(0,0),n=0;if(this.len-this.pos>4){for(;n<4;++n)if(a.lo=(a.lo|(this.buf[this.pos]&127)<<n*7)>>>0,this.buf[this.pos++]<128)return a;if(a.lo=(a.lo|(this.buf[this.pos]&127)<<28)>>>0,a.hi=(a.hi|(this.buf[this.pos]&127)>>4)>>>0,this.buf[this.pos++]<128)return a;n=0}else{for(;n<3;++n){if(this.pos>=this.len)throw at(this);if(a.lo=(a.lo|(this.buf[this.pos]&127)<<n*7)>>>0,this.buf[this.pos++]<128)return a}return a.lo=(a.lo|(this.buf[this.pos++]&127)<<n*7)>>>0,a}if(this.len-this.pos>4){for(;n<5;++n)if(a.hi=(a.hi|(this.buf[this.pos]&127)<<n*7+3)>>>0,this.buf[this.pos++]<128)return a}else for(;n<5;++n){if(this.pos>=this.len)throw at(this);if(a.hi=(a.hi|(this.buf[this.pos]&127)<<n*7+3)>>>0,this.buf[this.pos++]<128)return a}throw Error("invalid varint encoding")}B.prototype.bool=function(){return this.uint32()!==0};function jr(a,n){return(a[n-4]|a[n-3]<<8|a[n-2]<<16|a[n-1]<<24)>>>0}B.prototype.fixed32=function(){if(this.pos+4>this.len)throw at(this,4);return jr(this.buf,this.pos+=4)};B.prototype.sfixed32=function(){if(this.pos+4>this.len)throw at(this,4);return jr(this.buf,this.pos+=4)|0};function ol(){if(this.pos+8>this.len)throw at(this,8);return new il(jr(this.buf,this.pos+=4),jr(this.buf,this.pos+=4))}B.prototype.float=function(){if(this.pos+4>this.len)throw at(this,4);var n=it.float.readFloatLE(this.buf,this.pos);return this.pos+=4,n};B.prototype.double=function(){if(this.pos+8>this.len)throw at(this,4);var n=it.float.readDoubleLE(this.buf,this.pos);return this.pos+=8,n};B.prototype.bytes=function(){var n=this.uint32(),o=this.pos,c=this.pos+n;if(c>this.len)throw at(this,n);if(this.pos+=n,Array.isArray(this.buf))return this.buf.slice(o,c);if(o===c){var l=it.Buffer;return l?l.alloc(0):new this.buf.constructor(0)}return this._slice.call(this.buf,o,c)};B.prototype.string=function(){var n=this.bytes();return wf.read(n,0,n.length)};B.prototype.skip=function(n){if(typeof n=="number"){if(this.pos+n>this.len)throw at(this,n);this.pos+=n}else do if(this.pos>=this.len)throw at(this);while(this.buf[this.pos++]&128);return this};B.prototype.skipType=function(a){switch(a){case 0:this.skip();break;case 1:this.skip(8);break;case 2:this.skip(this.uint32());break;case 3:for(;(a=this.uint32()&7)!==4;)this.skipType(a);break;case 5:this.skip(4);break;default:throw Error("invalid wire type "+a+" at offset "+this.pos)}return this};B._configure=function(a){Eo=a,B.create=al(),Eo._configure();var n=it.Long?"toLong":"toNumber";it.merge(B.prototype,{int64:function(){return _o.call(this)[n](!1)},uint64:function(){return _o.call(this)[n](!0)},sint64:function(){return _o.call(this).zzDecode()[n](!1)},fixed64:function(){return ol.call(this)[n](!0)},sfixed64:function(){return ol.call(this)[n](!1)}})}});var pl=m((Ov,sl)=>{"use strict";sl.exports=jt;var cl=bo();(jt.prototype=Object.create(cl.prototype)).constructor=jt;var ll=wt();function jt(a){cl.call(this,a)}jt._configure=function(){ll.Buffer&&(jt.prototype._slice=ll.Buffer.prototype.slice)};jt.prototype.string=function(){var n=this.uint32();return this.buf.utf8Slice?this.buf.utf8Slice(this.pos,this.pos=Math.min(this.pos+n,this.len)):this.buf.toString("utf-8",this.pos,this.pos=Math.min(this.pos+n,this.len))};jt._configure()});var dl=m((gv,fl)=>{"use strict";fl.exports=xe;var So=wt();(xe.prototype=Object.create(So.EventEmitter.prototype)).constructor=xe;function xe(a,n,o){if(typeof a!="function")throw TypeError("rpcImpl must be a function");So.EventEmitter.call(this),this.rpcImpl=a,this.requestDelimited=!!n,this.responseDelimited=!!o}xe.prototype.rpcCall=function a(n,o,c,l,i){if(!l)throw TypeError("request must be specified");var e=this;if(!i)return So.asPromise(a,e,n,o,c,l);if(!e.rpcImpl){setTimeout(function(){i(Error("already ended"))},0);return}try{return e.rpcImpl(n,o[e.requestDelimited?"encodeDelimited":"encode"](l).finish(),function(r,u){if(r)return e.emit("error",r,n),i(r);if(u===null){e.end(!0);return}if(!(u instanceof c))try{u=c[e.responseDelimited?"decodeDelimited":"decode"](u)}catch(s){return e.emit("error",s,n),i(s)}return e.emit("data",u,n),i(null,u)})}catch(t){e.emit("error",t,n),setTimeout(function(){i(t)},0);return}};xe.prototype.end=function(n){return this.rpcImpl&&(n||this.rpcImpl(null,null,null),this.rpcImpl=null,this.emit("end").off()),this}});var hl=m(yl=>{"use strict";var Cf=yl;Cf.Service=dl()});var vl=m((Nv,ml)=>{"use strict";ml.exports={}});var bl=m(El=>{"use strict";var J=El;J.build="minimal";J.Writer=vo();J.BufferWriter=rl();J.Reader=bo();J.BufferReader=pl();J.util=wt();J.rpc=hl();J.roots=vl();J.configure=_l;function _l(){J.util._configure(),J.Writer._configure(J.BufferWriter),J.Reader._configure(J.BufferReader)}_l()});var Tl=m((xv,Sl)=>{"use strict";Sl.exports=bl()});var gl=m((Rv,Ol)=>{"use strict";var E=Tl(),h=E.Reader,S=E.Writer,f=E.util,p=E.roots.default||(E.roots.default={});p.opentelemetry=function(){var a={};return a.proto=function(){var n={};return n.common=function(){var o={};return o.v1=function(){var c={};return c.AnyValue=function(){function l(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.stringValue=null,l.prototype.boolValue=null,l.prototype.intValue=null,l.prototype.doubleValue=null,l.prototype.arrayValue=null,l.prototype.kvlistValue=null,l.prototype.bytesValue=null;var i;return Object.defineProperty(l.prototype,"value",{get:f.oneOfGetter(i=["stringValue","boolValue","intValue","doubleValue","arrayValue","kvlistValue","bytesValue"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){return r||(r=S.create()),t.stringValue!=null&&Object.hasOwnProperty.call(t,"stringValue")&&r.uint32(10).string(t.stringValue),t.boolValue!=null&&Object.hasOwnProperty.call(t,"boolValue")&&r.uint32(16).bool(t.boolValue),t.intValue!=null&&Object.hasOwnProperty.call(t,"intValue")&&r.uint32(24).int64(t.intValue),t.doubleValue!=null&&Object.hasOwnProperty.call(t,"doubleValue")&&r.uint32(33).double(t.doubleValue),t.arrayValue!=null&&Object.hasOwnProperty.call(t,"arrayValue")&&p.opentelemetry.proto.common.v1.ArrayValue.encode(t.arrayValue,r.uint32(42).fork()).ldelim(),t.kvlistValue!=null&&Object.hasOwnProperty.call(t,"kvlistValue")&&p.opentelemetry.proto.common.v1.KeyValueList.encode(t.kvlistValue,r.uint32(50).fork()).ldelim(),t.bytesValue!=null&&Object.hasOwnProperty.call(t,"bytesValue")&&r.uint32(58).bytes(t.bytesValue),r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.common.v1.AnyValue;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.stringValue=t.string();break}case 2:{s.boolValue=t.bool();break}case 3:{s.intValue=t.int64();break}case 4:{s.doubleValue=t.double();break}case 5:{s.arrayValue=p.opentelemetry.proto.common.v1.ArrayValue.decode(t,t.uint32());break}case 6:{s.kvlistValue=p.opentelemetry.proto.common.v1.KeyValueList.decode(t,t.uint32());break}case 7:{s.bytesValue=t.bytes();break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.stringValue!=null&&t.hasOwnProperty("stringValue")&&(r.value=1,!f.isString(t.stringValue)))return"stringValue: string expected";if(t.boolValue!=null&&t.hasOwnProperty("boolValue")){if(r.value===1)return"value: multiple values";if(r.value=1,typeof t.boolValue!="boolean")return"boolValue: boolean expected"}if(t.intValue!=null&&t.hasOwnProperty("intValue")){if(r.value===1)return"value: multiple values";if(r.value=1,!f.isInteger(t.intValue)&&!(t.intValue&&f.isInteger(t.intValue.low)&&f.isInteger(t.intValue.high)))return"intValue: integer|Long expected"}if(t.doubleValue!=null&&t.hasOwnProperty("doubleValue")){if(r.value===1)return"value: multiple values";if(r.value=1,typeof t.doubleValue!="number")return"doubleValue: number expected"}if(t.arrayValue!=null&&t.hasOwnProperty("arrayValue")){if(r.value===1)return"value: multiple values";r.value=1;{var u=p.opentelemetry.proto.common.v1.ArrayValue.verify(t.arrayValue);if(u)return"arrayValue."+u}}if(t.kvlistValue!=null&&t.hasOwnProperty("kvlistValue")){if(r.value===1)return"value: multiple values";r.value=1;{var u=p.opentelemetry.proto.common.v1.KeyValueList.verify(t.kvlistValue);if(u)return"kvlistValue."+u}}if(t.bytesValue!=null&&t.hasOwnProperty("bytesValue")){if(r.value===1)return"value: multiple values";if(r.value=1,!(t.bytesValue&&typeof t.bytesValue.length=="number"||f.isString(t.bytesValue)))return"bytesValue: buffer expected"}return null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.common.v1.AnyValue)return t;var r=new p.opentelemetry.proto.common.v1.AnyValue;if(t.stringValue!=null&&(r.stringValue=String(t.stringValue)),t.boolValue!=null&&(r.boolValue=!!t.boolValue),t.intValue!=null&&(f.Long?(r.intValue=f.Long.fromValue(t.intValue)).unsigned=!1:typeof t.intValue=="string"?r.intValue=parseInt(t.intValue,10):typeof t.intValue=="number"?r.intValue=t.intValue:typeof t.intValue=="object"&&(r.intValue=new f.LongBits(t.intValue.low>>>0,t.intValue.high>>>0).toNumber())),t.doubleValue!=null&&(r.doubleValue=Number(t.doubleValue)),t.arrayValue!=null){if(typeof t.arrayValue!="object")throw TypeError(".opentelemetry.proto.common.v1.AnyValue.arrayValue: object expected");r.arrayValue=p.opentelemetry.proto.common.v1.ArrayValue.fromObject(t.arrayValue)}if(t.kvlistValue!=null){if(typeof t.kvlistValue!="object")throw TypeError(".opentelemetry.proto.common.v1.AnyValue.kvlistValue: object expected");r.kvlistValue=p.opentelemetry.proto.common.v1.KeyValueList.fromObject(t.kvlistValue)}return t.bytesValue!=null&&(typeof t.bytesValue=="string"?f.base64.decode(t.bytesValue,r.bytesValue=f.newBuffer(f.base64.length(t.bytesValue)),0):t.bytesValue.length>=0&&(r.bytesValue=t.bytesValue)),r},l.toObject=function(t,r){r||(r={});var u={};return t.stringValue!=null&&t.hasOwnProperty("stringValue")&&(u.stringValue=t.stringValue,r.oneofs&&(u.value="stringValue")),t.boolValue!=null&&t.hasOwnProperty("boolValue")&&(u.boolValue=t.boolValue,r.oneofs&&(u.value="boolValue")),t.intValue!=null&&t.hasOwnProperty("intValue")&&(typeof t.intValue=="number"?u.intValue=r.longs===String?String(t.intValue):t.intValue:u.intValue=r.longs===String?f.Long.prototype.toString.call(t.intValue):r.longs===Number?new f.LongBits(t.intValue.low>>>0,t.intValue.high>>>0).toNumber():t.intValue,r.oneofs&&(u.value="intValue")),t.doubleValue!=null&&t.hasOwnProperty("doubleValue")&&(u.doubleValue=r.json&&!isFinite(t.doubleValue)?String(t.doubleValue):t.doubleValue,r.oneofs&&(u.value="doubleValue")),t.arrayValue!=null&&t.hasOwnProperty("arrayValue")&&(u.arrayValue=p.opentelemetry.proto.common.v1.ArrayValue.toObject(t.arrayValue,r),r.oneofs&&(u.value="arrayValue")),t.kvlistValue!=null&&t.hasOwnProperty("kvlistValue")&&(u.kvlistValue=p.opentelemetry.proto.common.v1.KeyValueList.toObject(t.kvlistValue,r),r.oneofs&&(u.value="kvlistValue")),t.bytesValue!=null&&t.hasOwnProperty("bytesValue")&&(u.bytesValue=r.bytes===String?f.base64.encode(t.bytesValue,0,t.bytesValue.length):r.bytes===Array?Array.prototype.slice.call(t.bytesValue):t.bytesValue,r.oneofs&&(u.value="bytesValue")),u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.common.v1.AnyValue"},l}(),c.ArrayValue=function(){function l(i){if(this.values=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.values=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.values!=null&&e.values.length)for(var r=0;r<e.values.length;++r)p.opentelemetry.proto.common.v1.AnyValue.encode(e.values[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.common.v1.ArrayValue;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.values&&u.values.length||(u.values=[]),u.values.push(p.opentelemetry.proto.common.v1.AnyValue.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.values!=null&&e.hasOwnProperty("values")){if(!Array.isArray(e.values))return"values: array expected";for(var t=0;t<e.values.length;++t){var r=p.opentelemetry.proto.common.v1.AnyValue.verify(e.values[t]);if(r)return"values."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.common.v1.ArrayValue)return e;var t=new p.opentelemetry.proto.common.v1.ArrayValue;if(e.values){if(!Array.isArray(e.values))throw TypeError(".opentelemetry.proto.common.v1.ArrayValue.values: array expected");t.values=[];for(var r=0;r<e.values.length;++r){if(typeof e.values[r]!="object")throw TypeError(".opentelemetry.proto.common.v1.ArrayValue.values: object expected");t.values[r]=p.opentelemetry.proto.common.v1.AnyValue.fromObject(e.values[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.values=[]),e.values&&e.values.length){r.values=[];for(var u=0;u<e.values.length;++u)r.values[u]=p.opentelemetry.proto.common.v1.AnyValue.toObject(e.values[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.common.v1.ArrayValue"},l}(),c.KeyValueList=function(){function l(i){if(this.values=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.values=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.values!=null&&e.values.length)for(var r=0;r<e.values.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.values[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.common.v1.KeyValueList;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.values&&u.values.length||(u.values=[]),u.values.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.values!=null&&e.hasOwnProperty("values")){if(!Array.isArray(e.values))return"values: array expected";for(var t=0;t<e.values.length;++t){var r=p.opentelemetry.proto.common.v1.KeyValue.verify(e.values[t]);if(r)return"values."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.common.v1.KeyValueList)return e;var t=new p.opentelemetry.proto.common.v1.KeyValueList;if(e.values){if(!Array.isArray(e.values))throw TypeError(".opentelemetry.proto.common.v1.KeyValueList.values: array expected");t.values=[];for(var r=0;r<e.values.length;++r){if(typeof e.values[r]!="object")throw TypeError(".opentelemetry.proto.common.v1.KeyValueList.values: object expected");t.values[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.values[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.values=[]),e.values&&e.values.length){r.values=[];for(var u=0;u<e.values.length;++u)r.values[u]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.values[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.common.v1.KeyValueList"},l}(),c.KeyValue=function(){function l(i){if(i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.key=null,l.prototype.value=null,l.create=function(e){return new l(e)},l.encode=function(e,t){return t||(t=S.create()),e.key!=null&&Object.hasOwnProperty.call(e,"key")&&t.uint32(10).string(e.key),e.value!=null&&Object.hasOwnProperty.call(e,"value")&&p.opentelemetry.proto.common.v1.AnyValue.encode(e.value,t.uint32(18).fork()).ldelim(),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.common.v1.KeyValue;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.key=e.string();break}case 2:{u.value=p.opentelemetry.proto.common.v1.AnyValue.decode(e,e.uint32());break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.key!=null&&e.hasOwnProperty("key")&&!f.isString(e.key))return"key: string expected";if(e.value!=null&&e.hasOwnProperty("value")){var t=p.opentelemetry.proto.common.v1.AnyValue.verify(e.value);if(t)return"value."+t}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.common.v1.KeyValue)return e;var t=new p.opentelemetry.proto.common.v1.KeyValue;if(e.key!=null&&(t.key=String(e.key)),e.value!=null){if(typeof e.value!="object")throw TypeError(".opentelemetry.proto.common.v1.KeyValue.value: object expected");t.value=p.opentelemetry.proto.common.v1.AnyValue.fromObject(e.value)}return t},l.toObject=function(e,t){t||(t={});var r={};return t.defaults&&(r.key="",r.value=null),e.key!=null&&e.hasOwnProperty("key")&&(r.key=e.key),e.value!=null&&e.hasOwnProperty("value")&&(r.value=p.opentelemetry.proto.common.v1.AnyValue.toObject(e.value,t)),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.common.v1.KeyValue"},l}(),c.InstrumentationScope=function(){function l(i){if(this.attributes=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.name=null,l.prototype.version=null,l.prototype.attributes=f.emptyArray,l.prototype.droppedAttributesCount=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.name!=null&&Object.hasOwnProperty.call(e,"name")&&t.uint32(10).string(e.name),e.version!=null&&Object.hasOwnProperty.call(e,"version")&&t.uint32(18).string(e.version),e.attributes!=null&&e.attributes.length)for(var r=0;r<e.attributes.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[r],t.uint32(26).fork()).ldelim();return e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,"droppedAttributesCount")&&t.uint32(32).uint32(e.droppedAttributesCount),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.common.v1.InstrumentationScope;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.name=e.string();break}case 2:{u.version=e.string();break}case 3:{u.attributes&&u.attributes.length||(u.attributes=[]),u.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}case 4:{u.droppedAttributesCount=e.uint32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.name!=null&&e.hasOwnProperty("name")&&!f.isString(e.name))return"name: string expected";if(e.version!=null&&e.hasOwnProperty("version")&&!f.isString(e.version))return"version: string expected";if(e.attributes!=null&&e.hasOwnProperty("attributes")){if(!Array.isArray(e.attributes))return"attributes: array expected";for(var t=0;t<e.attributes.length;++t){var r=p.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(r)return"attributes."+r}}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(e.droppedAttributesCount)?"droppedAttributesCount: integer expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.common.v1.InstrumentationScope)return e;var t=new p.opentelemetry.proto.common.v1.InstrumentationScope;if(e.name!=null&&(t.name=String(e.name)),e.version!=null&&(t.version=String(e.version)),e.attributes){if(!Array.isArray(e.attributes))throw TypeError(".opentelemetry.proto.common.v1.InstrumentationScope.attributes: array expected");t.attributes=[];for(var r=0;r<e.attributes.length;++r){if(typeof e.attributes[r]!="object")throw TypeError(".opentelemetry.proto.common.v1.InstrumentationScope.attributes: object expected");t.attributes[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[r])}}return e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.attributes=[]),t.defaults&&(r.name="",r.version="",r.droppedAttributesCount=0),e.name!=null&&e.hasOwnProperty("name")&&(r.name=e.name),e.version!=null&&e.hasOwnProperty("version")&&(r.version=e.version),e.attributes&&e.attributes.length){r.attributes=[];for(var u=0;u<e.attributes.length;++u)r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[u],t)}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&(r.droppedAttributesCount=e.droppedAttributesCount),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.common.v1.InstrumentationScope"},l}(),c}(),o}(),n.resource=function(){var o={};return o.v1=function(){var c={};return c.Resource=function(){function l(i){if(this.attributes=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.attributes=f.emptyArray,l.prototype.droppedAttributesCount=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.attributes!=null&&e.attributes.length)for(var r=0;r<e.attributes.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[r],t.uint32(10).fork()).ldelim();return e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,"droppedAttributesCount")&&t.uint32(16).uint32(e.droppedAttributesCount),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.resource.v1.Resource;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.attributes&&u.attributes.length||(u.attributes=[]),u.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}case 2:{u.droppedAttributesCount=e.uint32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.attributes!=null&&e.hasOwnProperty("attributes")){if(!Array.isArray(e.attributes))return"attributes: array expected";for(var t=0;t<e.attributes.length;++t){var r=p.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(r)return"attributes."+r}}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(e.droppedAttributesCount)?"droppedAttributesCount: integer expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.resource.v1.Resource)return e;var t=new p.opentelemetry.proto.resource.v1.Resource;if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(".opentelemetry.proto.resource.v1.Resource.attributes: array expected");t.attributes=[];for(var r=0;r<e.attributes.length;++r){if(typeof e.attributes[r]!="object")throw TypeError(".opentelemetry.proto.resource.v1.Resource.attributes: object expected");t.attributes[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[r])}}return e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.attributes=[]),t.defaults&&(r.droppedAttributesCount=0),e.attributes&&e.attributes.length){r.attributes=[];for(var u=0;u<e.attributes.length;++u)r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[u],t)}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&(r.droppedAttributesCount=e.droppedAttributesCount),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.resource.v1.Resource"},l}(),c}(),o}(),n.trace=function(){var o={};return o.v1=function(){var c={};return c.TracesData=function(){function l(i){if(this.resourceSpans=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resourceSpans=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resourceSpans!=null&&e.resourceSpans.length)for(var r=0;r<e.resourceSpans.length;++r)p.opentelemetry.proto.trace.v1.ResourceSpans.encode(e.resourceSpans[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.trace.v1.TracesData;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resourceSpans&&u.resourceSpans.length||(u.resourceSpans=[]),u.resourceSpans.push(p.opentelemetry.proto.trace.v1.ResourceSpans.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resourceSpans!=null&&e.hasOwnProperty("resourceSpans")){if(!Array.isArray(e.resourceSpans))return"resourceSpans: array expected";for(var t=0;t<e.resourceSpans.length;++t){var r=p.opentelemetry.proto.trace.v1.ResourceSpans.verify(e.resourceSpans[t]);if(r)return"resourceSpans."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.trace.v1.TracesData)return e;var t=new p.opentelemetry.proto.trace.v1.TracesData;if(e.resourceSpans){if(!Array.isArray(e.resourceSpans))throw TypeError(".opentelemetry.proto.trace.v1.TracesData.resourceSpans: array expected");t.resourceSpans=[];for(var r=0;r<e.resourceSpans.length;++r){if(typeof e.resourceSpans[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.TracesData.resourceSpans: object expected");t.resourceSpans[r]=p.opentelemetry.proto.trace.v1.ResourceSpans.fromObject(e.resourceSpans[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.resourceSpans=[]),e.resourceSpans&&e.resourceSpans.length){r.resourceSpans=[];for(var u=0;u<e.resourceSpans.length;++u)r.resourceSpans[u]=p.opentelemetry.proto.trace.v1.ResourceSpans.toObject(e.resourceSpans[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.trace.v1.TracesData"},l}(),c.ResourceSpans=function(){function l(i){if(this.scopeSpans=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resource=null,l.prototype.scopeSpans=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resource!=null&&Object.hasOwnProperty.call(e,"resource")&&p.opentelemetry.proto.resource.v1.Resource.encode(e.resource,t.uint32(10).fork()).ldelim(),e.scopeSpans!=null&&e.scopeSpans.length)for(var r=0;r<e.scopeSpans.length;++r)p.opentelemetry.proto.trace.v1.ScopeSpans.encode(e.scopeSpans[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.trace.v1.ResourceSpans;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resource=p.opentelemetry.proto.resource.v1.Resource.decode(e,e.uint32());break}case 2:{u.scopeSpans&&u.scopeSpans.length||(u.scopeSpans=[]),u.scopeSpans.push(p.opentelemetry.proto.trace.v1.ScopeSpans.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resource!=null&&e.hasOwnProperty("resource")){var t=p.opentelemetry.proto.resource.v1.Resource.verify(e.resource);if(t)return"resource."+t}if(e.scopeSpans!=null&&e.hasOwnProperty("scopeSpans")){if(!Array.isArray(e.scopeSpans))return"scopeSpans: array expected";for(var r=0;r<e.scopeSpans.length;++r){var t=p.opentelemetry.proto.trace.v1.ScopeSpans.verify(e.scopeSpans[r]);if(t)return"scopeSpans."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.trace.v1.ResourceSpans)return e;var t=new p.opentelemetry.proto.trace.v1.ResourceSpans;if(e.resource!=null){if(typeof e.resource!="object")throw TypeError(".opentelemetry.proto.trace.v1.ResourceSpans.resource: object expected");t.resource=p.opentelemetry.proto.resource.v1.Resource.fromObject(e.resource)}if(e.scopeSpans){if(!Array.isArray(e.scopeSpans))throw TypeError(".opentelemetry.proto.trace.v1.ResourceSpans.scopeSpans: array expected");t.scopeSpans=[];for(var r=0;r<e.scopeSpans.length;++r){if(typeof e.scopeSpans[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.ResourceSpans.scopeSpans: object expected");t.scopeSpans[r]=p.opentelemetry.proto.trace.v1.ScopeSpans.fromObject(e.scopeSpans[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.scopeSpans=[]),t.defaults&&(r.resource=null,r.schemaUrl=""),e.resource!=null&&e.hasOwnProperty("resource")&&(r.resource=p.opentelemetry.proto.resource.v1.Resource.toObject(e.resource,t)),e.scopeSpans&&e.scopeSpans.length){r.scopeSpans=[];for(var u=0;u<e.scopeSpans.length;++u)r.scopeSpans[u]=p.opentelemetry.proto.trace.v1.ScopeSpans.toObject(e.scopeSpans[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.trace.v1.ResourceSpans"},l}(),c.ScopeSpans=function(){function l(i){if(this.spans=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.scope=null,l.prototype.spans=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.scope!=null&&Object.hasOwnProperty.call(e,"scope")&&p.opentelemetry.proto.common.v1.InstrumentationScope.encode(e.scope,t.uint32(10).fork()).ldelim(),e.spans!=null&&e.spans.length)for(var r=0;r<e.spans.length;++r)p.opentelemetry.proto.trace.v1.Span.encode(e.spans[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.trace.v1.ScopeSpans;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.decode(e,e.uint32());break}case 2:{u.spans&&u.spans.length||(u.spans=[]),u.spans.push(p.opentelemetry.proto.trace.v1.Span.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.scope!=null&&e.hasOwnProperty("scope")){var t=p.opentelemetry.proto.common.v1.InstrumentationScope.verify(e.scope);if(t)return"scope."+t}if(e.spans!=null&&e.hasOwnProperty("spans")){if(!Array.isArray(e.spans))return"spans: array expected";for(var r=0;r<e.spans.length;++r){var t=p.opentelemetry.proto.trace.v1.Span.verify(e.spans[r]);if(t)return"spans."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.trace.v1.ScopeSpans)return e;var t=new p.opentelemetry.proto.trace.v1.ScopeSpans;if(e.scope!=null){if(typeof e.scope!="object")throw TypeError(".opentelemetry.proto.trace.v1.ScopeSpans.scope: object expected");t.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.fromObject(e.scope)}if(e.spans){if(!Array.isArray(e.spans))throw TypeError(".opentelemetry.proto.trace.v1.ScopeSpans.spans: array expected");t.spans=[];for(var r=0;r<e.spans.length;++r){if(typeof e.spans[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.ScopeSpans.spans: object expected");t.spans[r]=p.opentelemetry.proto.trace.v1.Span.fromObject(e.spans[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.spans=[]),t.defaults&&(r.scope=null,r.schemaUrl=""),e.scope!=null&&e.hasOwnProperty("scope")&&(r.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.toObject(e.scope,t)),e.spans&&e.spans.length){r.spans=[];for(var u=0;u<e.spans.length;++u)r.spans[u]=p.opentelemetry.proto.trace.v1.Span.toObject(e.spans[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.trace.v1.ScopeSpans"},l}(),c.Span=function(){function l(i){if(this.attributes=[],this.events=[],this.links=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.traceId=null,l.prototype.spanId=null,l.prototype.traceState=null,l.prototype.parentSpanId=null,l.prototype.name=null,l.prototype.kind=null,l.prototype.startTimeUnixNano=null,l.prototype.endTimeUnixNano=null,l.prototype.attributes=f.emptyArray,l.prototype.droppedAttributesCount=null,l.prototype.events=f.emptyArray,l.prototype.droppedEventsCount=null,l.prototype.links=f.emptyArray,l.prototype.droppedLinksCount=null,l.prototype.status=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.traceId!=null&&Object.hasOwnProperty.call(e,"traceId")&&t.uint32(10).bytes(e.traceId),e.spanId!=null&&Object.hasOwnProperty.call(e,"spanId")&&t.uint32(18).bytes(e.spanId),e.traceState!=null&&Object.hasOwnProperty.call(e,"traceState")&&t.uint32(26).string(e.traceState),e.parentSpanId!=null&&Object.hasOwnProperty.call(e,"parentSpanId")&&t.uint32(34).bytes(e.parentSpanId),e.name!=null&&Object.hasOwnProperty.call(e,"name")&&t.uint32(42).string(e.name),e.kind!=null&&Object.hasOwnProperty.call(e,"kind")&&t.uint32(48).int32(e.kind),e.startTimeUnixNano!=null&&Object.hasOwnProperty.call(e,"startTimeUnixNano")&&t.uint32(57).fixed64(e.startTimeUnixNano),e.endTimeUnixNano!=null&&Object.hasOwnProperty.call(e,"endTimeUnixNano")&&t.uint32(65).fixed64(e.endTimeUnixNano),e.attributes!=null&&e.attributes.length)for(var r=0;r<e.attributes.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[r],t.uint32(74).fork()).ldelim();if(e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,"droppedAttributesCount")&&t.uint32(80).uint32(e.droppedAttributesCount),e.events!=null&&e.events.length)for(var r=0;r<e.events.length;++r)p.opentelemetry.proto.trace.v1.Span.Event.encode(e.events[r],t.uint32(90).fork()).ldelim();if(e.droppedEventsCount!=null&&Object.hasOwnProperty.call(e,"droppedEventsCount")&&t.uint32(96).uint32(e.droppedEventsCount),e.links!=null&&e.links.length)for(var r=0;r<e.links.length;++r)p.opentelemetry.proto.trace.v1.Span.Link.encode(e.links[r],t.uint32(106).fork()).ldelim();return e.droppedLinksCount!=null&&Object.hasOwnProperty.call(e,"droppedLinksCount")&&t.uint32(112).uint32(e.droppedLinksCount),e.status!=null&&Object.hasOwnProperty.call(e,"status")&&p.opentelemetry.proto.trace.v1.Status.encode(e.status,t.uint32(122).fork()).ldelim(),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.trace.v1.Span;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.traceId=e.bytes();break}case 2:{u.spanId=e.bytes();break}case 3:{u.traceState=e.string();break}case 4:{u.parentSpanId=e.bytes();break}case 5:{u.name=e.string();break}case 6:{u.kind=e.int32();break}case 7:{u.startTimeUnixNano=e.fixed64();break}case 8:{u.endTimeUnixNano=e.fixed64();break}case 9:{u.attributes&&u.attributes.length||(u.attributes=[]),u.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}case 10:{u.droppedAttributesCount=e.uint32();break}case 11:{u.events&&u.events.length||(u.events=[]),u.events.push(p.opentelemetry.proto.trace.v1.Span.Event.decode(e,e.uint32()));break}case 12:{u.droppedEventsCount=e.uint32();break}case 13:{u.links&&u.links.length||(u.links=[]),u.links.push(p.opentelemetry.proto.trace.v1.Span.Link.decode(e,e.uint32()));break}case 14:{u.droppedLinksCount=e.uint32();break}case 15:{u.status=p.opentelemetry.proto.trace.v1.Status.decode(e,e.uint32());break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.traceId!=null&&e.hasOwnProperty("traceId")&&!(e.traceId&&typeof e.traceId.length=="number"||f.isString(e.traceId)))return"traceId: buffer expected";if(e.spanId!=null&&e.hasOwnProperty("spanId")&&!(e.spanId&&typeof e.spanId.length=="number"||f.isString(e.spanId)))return"spanId: buffer expected";if(e.traceState!=null&&e.hasOwnProperty("traceState")&&!f.isString(e.traceState))return"traceState: string expected";if(e.parentSpanId!=null&&e.hasOwnProperty("parentSpanId")&&!(e.parentSpanId&&typeof e.parentSpanId.length=="number"||f.isString(e.parentSpanId)))return"parentSpanId: buffer expected";if(e.name!=null&&e.hasOwnProperty("name")&&!f.isString(e.name))return"name: string expected";if(e.kind!=null&&e.hasOwnProperty("kind"))switch(e.kind){default:return"kind: enum value expected";case 0:case 1:case 2:case 3:case 4:case 5:break}if(e.startTimeUnixNano!=null&&e.hasOwnProperty("startTimeUnixNano")&&!f.isInteger(e.startTimeUnixNano)&&!(e.startTimeUnixNano&&f.isInteger(e.startTimeUnixNano.low)&&f.isInteger(e.startTimeUnixNano.high)))return"startTimeUnixNano: integer|Long expected";if(e.endTimeUnixNano!=null&&e.hasOwnProperty("endTimeUnixNano")&&!f.isInteger(e.endTimeUnixNano)&&!(e.endTimeUnixNano&&f.isInteger(e.endTimeUnixNano.low)&&f.isInteger(e.endTimeUnixNano.high)))return"endTimeUnixNano: integer|Long expected";if(e.attributes!=null&&e.hasOwnProperty("attributes")){if(!Array.isArray(e.attributes))return"attributes: array expected";for(var t=0;t<e.attributes.length;++t){var r=p.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(r)return"attributes."+r}}if(e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(e.droppedAttributesCount))return"droppedAttributesCount: integer expected";if(e.events!=null&&e.hasOwnProperty("events")){if(!Array.isArray(e.events))return"events: array expected";for(var t=0;t<e.events.length;++t){var r=p.opentelemetry.proto.trace.v1.Span.Event.verify(e.events[t]);if(r)return"events."+r}}if(e.droppedEventsCount!=null&&e.hasOwnProperty("droppedEventsCount")&&!f.isInteger(e.droppedEventsCount))return"droppedEventsCount: integer expected";if(e.links!=null&&e.hasOwnProperty("links")){if(!Array.isArray(e.links))return"links: array expected";for(var t=0;t<e.links.length;++t){var r=p.opentelemetry.proto.trace.v1.Span.Link.verify(e.links[t]);if(r)return"links."+r}}if(e.droppedLinksCount!=null&&e.hasOwnProperty("droppedLinksCount")&&!f.isInteger(e.droppedLinksCount))return"droppedLinksCount: integer expected";if(e.status!=null&&e.hasOwnProperty("status")){var r=p.opentelemetry.proto.trace.v1.Status.verify(e.status);if(r)return"status."+r}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.trace.v1.Span)return e;var t=new p.opentelemetry.proto.trace.v1.Span;switch(e.traceId!=null&&(typeof e.traceId=="string"?f.base64.decode(e.traceId,t.traceId=f.newBuffer(f.base64.length(e.traceId)),0):e.traceId.length>=0&&(t.traceId=e.traceId)),e.spanId!=null&&(typeof e.spanId=="string"?f.base64.decode(e.spanId,t.spanId=f.newBuffer(f.base64.length(e.spanId)),0):e.spanId.length>=0&&(t.spanId=e.spanId)),e.traceState!=null&&(t.traceState=String(e.traceState)),e.parentSpanId!=null&&(typeof e.parentSpanId=="string"?f.base64.decode(e.parentSpanId,t.parentSpanId=f.newBuffer(f.base64.length(e.parentSpanId)),0):e.parentSpanId.length>=0&&(t.parentSpanId=e.parentSpanId)),e.name!=null&&(t.name=String(e.name)),e.kind){default:if(typeof e.kind=="number"){t.kind=e.kind;break}break;case"SPAN_KIND_UNSPECIFIED":case 0:t.kind=0;break;case"SPAN_KIND_INTERNAL":case 1:t.kind=1;break;case"SPAN_KIND_SERVER":case 2:t.kind=2;break;case"SPAN_KIND_CLIENT":case 3:t.kind=3;break;case"SPAN_KIND_PRODUCER":case 4:t.kind=4;break;case"SPAN_KIND_CONSUMER":case 5:t.kind=5;break}if(e.startTimeUnixNano!=null&&(f.Long?(t.startTimeUnixNano=f.Long.fromValue(e.startTimeUnixNano)).unsigned=!1:typeof e.startTimeUnixNano=="string"?t.startTimeUnixNano=parseInt(e.startTimeUnixNano,10):typeof e.startTimeUnixNano=="number"?t.startTimeUnixNano=e.startTimeUnixNano:typeof e.startTimeUnixNano=="object"&&(t.startTimeUnixNano=new f.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber())),e.endTimeUnixNano!=null&&(f.Long?(t.endTimeUnixNano=f.Long.fromValue(e.endTimeUnixNano)).unsigned=!1:typeof e.endTimeUnixNano=="string"?t.endTimeUnixNano=parseInt(e.endTimeUnixNano,10):typeof e.endTimeUnixNano=="number"?t.endTimeUnixNano=e.endTimeUnixNano:typeof e.endTimeUnixNano=="object"&&(t.endTimeUnixNano=new f.LongBits(e.endTimeUnixNano.low>>>0,e.endTimeUnixNano.high>>>0).toNumber())),e.attributes){if(!Array.isArray(e.attributes))throw TypeError(".opentelemetry.proto.trace.v1.Span.attributes: array expected");t.attributes=[];for(var r=0;r<e.attributes.length;++r){if(typeof e.attributes[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.attributes: object expected");t.attributes[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[r])}}if(e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),e.events){if(!Array.isArray(e.events))throw TypeError(".opentelemetry.proto.trace.v1.Span.events: array expected");t.events=[];for(var r=0;r<e.events.length;++r){if(typeof e.events[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.events: object expected");t.events[r]=p.opentelemetry.proto.trace.v1.Span.Event.fromObject(e.events[r])}}if(e.droppedEventsCount!=null&&(t.droppedEventsCount=e.droppedEventsCount>>>0),e.links){if(!Array.isArray(e.links))throw TypeError(".opentelemetry.proto.trace.v1.Span.links: array expected");t.links=[];for(var r=0;r<e.links.length;++r){if(typeof e.links[r]!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.links: object expected");t.links[r]=p.opentelemetry.proto.trace.v1.Span.Link.fromObject(e.links[r])}}if(e.droppedLinksCount!=null&&(t.droppedLinksCount=e.droppedLinksCount>>>0),e.status!=null){if(typeof e.status!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.status: object expected");t.status=p.opentelemetry.proto.trace.v1.Status.fromObject(e.status)}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.attributes=[],r.events=[],r.links=[]),t.defaults){if(t.bytes===String?r.traceId="":(r.traceId=[],t.bytes!==Array&&(r.traceId=f.newBuffer(r.traceId))),t.bytes===String?r.spanId="":(r.spanId=[],t.bytes!==Array&&(r.spanId=f.newBuffer(r.spanId))),r.traceState="",t.bytes===String?r.parentSpanId="":(r.parentSpanId=[],t.bytes!==Array&&(r.parentSpanId=f.newBuffer(r.parentSpanId))),r.name="",r.kind=t.enums===String?"SPAN_KIND_UNSPECIFIED":0,f.Long){var u=new f.Long(0,0,!1);r.startTimeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.startTimeUnixNano=t.longs===String?"0":0;if(f.Long){var u=new f.Long(0,0,!1);r.endTimeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.endTimeUnixNano=t.longs===String?"0":0;r.droppedAttributesCount=0,r.droppedEventsCount=0,r.droppedLinksCount=0,r.status=null}if(e.traceId!=null&&e.hasOwnProperty("traceId")&&(r.traceId=t.bytes===String?f.base64.encode(e.traceId,0,e.traceId.length):t.bytes===Array?Array.prototype.slice.call(e.traceId):e.traceId),e.spanId!=null&&e.hasOwnProperty("spanId")&&(r.spanId=t.bytes===String?f.base64.encode(e.spanId,0,e.spanId.length):t.bytes===Array?Array.prototype.slice.call(e.spanId):e.spanId),e.traceState!=null&&e.hasOwnProperty("traceState")&&(r.traceState=e.traceState),e.parentSpanId!=null&&e.hasOwnProperty("parentSpanId")&&(r.parentSpanId=t.bytes===String?f.base64.encode(e.parentSpanId,0,e.parentSpanId.length):t.bytes===Array?Array.prototype.slice.call(e.parentSpanId):e.parentSpanId),e.name!=null&&e.hasOwnProperty("name")&&(r.name=e.name),e.kind!=null&&e.hasOwnProperty("kind")&&(r.kind=t.enums===String?p.opentelemetry.proto.trace.v1.Span.SpanKind[e.kind]===void 0?e.kind:p.opentelemetry.proto.trace.v1.Span.SpanKind[e.kind]:e.kind),e.startTimeUnixNano!=null&&e.hasOwnProperty("startTimeUnixNano")&&(typeof e.startTimeUnixNano=="number"?r.startTimeUnixNano=t.longs===String?String(e.startTimeUnixNano):e.startTimeUnixNano:r.startTimeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.startTimeUnixNano):t.longs===Number?new f.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber():e.startTimeUnixNano),e.endTimeUnixNano!=null&&e.hasOwnProperty("endTimeUnixNano")&&(typeof e.endTimeUnixNano=="number"?r.endTimeUnixNano=t.longs===String?String(e.endTimeUnixNano):e.endTimeUnixNano:r.endTimeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.endTimeUnixNano):t.longs===Number?new f.LongBits(e.endTimeUnixNano.low>>>0,e.endTimeUnixNano.high>>>0).toNumber():e.endTimeUnixNano),e.attributes&&e.attributes.length){r.attributes=[];for(var s=0;s<e.attributes.length;++s)r.attributes[s]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[s],t)}if(e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&(r.droppedAttributesCount=e.droppedAttributesCount),e.events&&e.events.length){r.events=[];for(var s=0;s<e.events.length;++s)r.events[s]=p.opentelemetry.proto.trace.v1.Span.Event.toObject(e.events[s],t)}if(e.droppedEventsCount!=null&&e.hasOwnProperty("droppedEventsCount")&&(r.droppedEventsCount=e.droppedEventsCount),e.links&&e.links.length){r.links=[];for(var s=0;s<e.links.length;++s)r.links[s]=p.opentelemetry.proto.trace.v1.Span.Link.toObject(e.links[s],t)}return e.droppedLinksCount!=null&&e.hasOwnProperty("droppedLinksCount")&&(r.droppedLinksCount=e.droppedLinksCount),e.status!=null&&e.hasOwnProperty("status")&&(r.status=p.opentelemetry.proto.trace.v1.Status.toObject(e.status,t)),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.trace.v1.Span"},l.SpanKind=function(){var i={},e=Object.create(i);return e[i[0]="SPAN_KIND_UNSPECIFIED"]=0,e[i[1]="SPAN_KIND_INTERNAL"]=1,e[i[2]="SPAN_KIND_SERVER"]=2,e[i[3]="SPAN_KIND_CLIENT"]=3,e[i[4]="SPAN_KIND_PRODUCER"]=4,e[i[5]="SPAN_KIND_CONSUMER"]=5,e}(),l.Event=function(){function i(e){if(this.attributes=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.timeUnixNano=null,i.prototype.name=null,i.prototype.attributes=f.emptyArray,i.prototype.droppedAttributesCount=null,i.create=function(t){return new i(t)},i.encode=function(t,r){if(r||(r=S.create()),t.timeUnixNano!=null&&Object.hasOwnProperty.call(t,"timeUnixNano")&&r.uint32(9).fixed64(t.timeUnixNano),t.name!=null&&Object.hasOwnProperty.call(t,"name")&&r.uint32(18).string(t.name),t.attributes!=null&&t.attributes.length)for(var u=0;u<t.attributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.attributes[u],r.uint32(26).fork()).ldelim();return t.droppedAttributesCount!=null&&Object.hasOwnProperty.call(t,"droppedAttributesCount")&&r.uint32(32).uint32(t.droppedAttributesCount),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.trace.v1.Span.Event;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.timeUnixNano=t.fixed64();break}case 2:{s.name=t.string();break}case 3:{s.attributes&&s.attributes.length||(s.attributes=[]),s.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 4:{s.droppedAttributesCount=t.uint32();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&!f.isInteger(t.timeUnixNano)&&!(t.timeUnixNano&&f.isInteger(t.timeUnixNano.low)&&f.isInteger(t.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(t.name!=null&&t.hasOwnProperty("name")&&!f.isString(t.name))return"name: string expected";if(t.attributes!=null&&t.hasOwnProperty("attributes")){if(!Array.isArray(t.attributes))return"attributes: array expected";for(var r=0;r<t.attributes.length;++r){var u=p.opentelemetry.proto.common.v1.KeyValue.verify(t.attributes[r]);if(u)return"attributes."+u}}return t.droppedAttributesCount!=null&&t.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(t.droppedAttributesCount)?"droppedAttributesCount: integer expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.trace.v1.Span.Event)return t;var r=new p.opentelemetry.proto.trace.v1.Span.Event;if(t.timeUnixNano!=null&&(f.Long?(r.timeUnixNano=f.Long.fromValue(t.timeUnixNano)).unsigned=!1:typeof t.timeUnixNano=="string"?r.timeUnixNano=parseInt(t.timeUnixNano,10):typeof t.timeUnixNano=="number"?r.timeUnixNano=t.timeUnixNano:typeof t.timeUnixNano=="object"&&(r.timeUnixNano=new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber())),t.name!=null&&(r.name=String(t.name)),t.attributes){if(!Array.isArray(t.attributes))throw TypeError(".opentelemetry.proto.trace.v1.Span.Event.attributes: array expected");r.attributes=[];for(var u=0;u<t.attributes.length;++u){if(typeof t.attributes[u]!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.Event.attributes: object expected");r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.attributes[u])}}return t.droppedAttributesCount!=null&&(r.droppedAttributesCount=t.droppedAttributesCount>>>0),r},i.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.attributes=[]),r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.timeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.timeUnixNano=r.longs===String?"0":0;u.name="",u.droppedAttributesCount=0}if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&(typeof t.timeUnixNano=="number"?u.timeUnixNano=r.longs===String?String(t.timeUnixNano):t.timeUnixNano:u.timeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.timeUnixNano):r.longs===Number?new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber():t.timeUnixNano),t.name!=null&&t.hasOwnProperty("name")&&(u.name=t.name),t.attributes&&t.attributes.length){u.attributes=[];for(var d=0;d<t.attributes.length;++d)u.attributes[d]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.attributes[d],r)}return t.droppedAttributesCount!=null&&t.hasOwnProperty("droppedAttributesCount")&&(u.droppedAttributesCount=t.droppedAttributesCount),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.trace.v1.Span.Event"},i}(),l.Link=function(){function i(e){if(this.attributes=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.traceId=null,i.prototype.spanId=null,i.prototype.traceState=null,i.prototype.attributes=f.emptyArray,i.prototype.droppedAttributesCount=null,i.create=function(t){return new i(t)},i.encode=function(t,r){if(r||(r=S.create()),t.traceId!=null&&Object.hasOwnProperty.call(t,"traceId")&&r.uint32(10).bytes(t.traceId),t.spanId!=null&&Object.hasOwnProperty.call(t,"spanId")&&r.uint32(18).bytes(t.spanId),t.traceState!=null&&Object.hasOwnProperty.call(t,"traceState")&&r.uint32(26).string(t.traceState),t.attributes!=null&&t.attributes.length)for(var u=0;u<t.attributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.attributes[u],r.uint32(34).fork()).ldelim();return t.droppedAttributesCount!=null&&Object.hasOwnProperty.call(t,"droppedAttributesCount")&&r.uint32(40).uint32(t.droppedAttributesCount),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.trace.v1.Span.Link;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.traceId=t.bytes();break}case 2:{s.spanId=t.bytes();break}case 3:{s.traceState=t.string();break}case 4:{s.attributes&&s.attributes.length||(s.attributes=[]),s.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 5:{s.droppedAttributesCount=t.uint32();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.traceId!=null&&t.hasOwnProperty("traceId")&&!(t.traceId&&typeof t.traceId.length=="number"||f.isString(t.traceId)))return"traceId: buffer expected";if(t.spanId!=null&&t.hasOwnProperty("spanId")&&!(t.spanId&&typeof t.spanId.length=="number"||f.isString(t.spanId)))return"spanId: buffer expected";if(t.traceState!=null&&t.hasOwnProperty("traceState")&&!f.isString(t.traceState))return"traceState: string expected";if(t.attributes!=null&&t.hasOwnProperty("attributes")){if(!Array.isArray(t.attributes))return"attributes: array expected";for(var r=0;r<t.attributes.length;++r){var u=p.opentelemetry.proto.common.v1.KeyValue.verify(t.attributes[r]);if(u)return"attributes."+u}}return t.droppedAttributesCount!=null&&t.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(t.droppedAttributesCount)?"droppedAttributesCount: integer expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.trace.v1.Span.Link)return t;var r=new p.opentelemetry.proto.trace.v1.Span.Link;if(t.traceId!=null&&(typeof t.traceId=="string"?f.base64.decode(t.traceId,r.traceId=f.newBuffer(f.base64.length(t.traceId)),0):t.traceId.length>=0&&(r.traceId=t.traceId)),t.spanId!=null&&(typeof t.spanId=="string"?f.base64.decode(t.spanId,r.spanId=f.newBuffer(f.base64.length(t.spanId)),0):t.spanId.length>=0&&(r.spanId=t.spanId)),t.traceState!=null&&(r.traceState=String(t.traceState)),t.attributes){if(!Array.isArray(t.attributes))throw TypeError(".opentelemetry.proto.trace.v1.Span.Link.attributes: array expected");r.attributes=[];for(var u=0;u<t.attributes.length;++u){if(typeof t.attributes[u]!="object")throw TypeError(".opentelemetry.proto.trace.v1.Span.Link.attributes: object expected");r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.attributes[u])}}return t.droppedAttributesCount!=null&&(r.droppedAttributesCount=t.droppedAttributesCount>>>0),r},i.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.attributes=[]),r.defaults&&(r.bytes===String?u.traceId="":(u.traceId=[],r.bytes!==Array&&(u.traceId=f.newBuffer(u.traceId))),r.bytes===String?u.spanId="":(u.spanId=[],r.bytes!==Array&&(u.spanId=f.newBuffer(u.spanId))),u.traceState="",u.droppedAttributesCount=0),t.traceId!=null&&t.hasOwnProperty("traceId")&&(u.traceId=r.bytes===String?f.base64.encode(t.traceId,0,t.traceId.length):r.bytes===Array?Array.prototype.slice.call(t.traceId):t.traceId),t.spanId!=null&&t.hasOwnProperty("spanId")&&(u.spanId=r.bytes===String?f.base64.encode(t.spanId,0,t.spanId.length):r.bytes===Array?Array.prototype.slice.call(t.spanId):t.spanId),t.traceState!=null&&t.hasOwnProperty("traceState")&&(u.traceState=t.traceState),t.attributes&&t.attributes.length){u.attributes=[];for(var s=0;s<t.attributes.length;++s)u.attributes[s]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.attributes[s],r)}return t.droppedAttributesCount!=null&&t.hasOwnProperty("droppedAttributesCount")&&(u.droppedAttributesCount=t.droppedAttributesCount),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.trace.v1.Span.Link"},i}(),l}(),c.Status=function(){function l(i){if(i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.message=null,l.prototype.code=null,l.create=function(e){return new l(e)},l.encode=function(e,t){return t||(t=S.create()),e.message!=null&&Object.hasOwnProperty.call(e,"message")&&t.uint32(18).string(e.message),e.code!=null&&Object.hasOwnProperty.call(e,"code")&&t.uint32(24).int32(e.code),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.trace.v1.Status;e.pos<r;){var s=e.uint32();switch(s>>>3){case 2:{u.message=e.string();break}case 3:{u.code=e.int32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.message!=null&&e.hasOwnProperty("message")&&!f.isString(e.message))return"message: string expected";if(e.code!=null&&e.hasOwnProperty("code"))switch(e.code){default:return"code: enum value expected";case 0:case 1:case 2:break}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.trace.v1.Status)return e;var t=new p.opentelemetry.proto.trace.v1.Status;switch(e.message!=null&&(t.message=String(e.message)),e.code){default:if(typeof e.code=="number"){t.code=e.code;break}break;case"STATUS_CODE_UNSET":case 0:t.code=0;break;case"STATUS_CODE_OK":case 1:t.code=1;break;case"STATUS_CODE_ERROR":case 2:t.code=2;break}return t},l.toObject=function(e,t){t||(t={});var r={};return t.defaults&&(r.message="",r.code=t.enums===String?"STATUS_CODE_UNSET":0),e.message!=null&&e.hasOwnProperty("message")&&(r.message=e.message),e.code!=null&&e.hasOwnProperty("code")&&(r.code=t.enums===String?p.opentelemetry.proto.trace.v1.Status.StatusCode[e.code]===void 0?e.code:p.opentelemetry.proto.trace.v1.Status.StatusCode[e.code]:e.code),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.trace.v1.Status"},l.StatusCode=function(){var i={},e=Object.create(i);return e[i[0]="STATUS_CODE_UNSET"]=0,e[i[1]="STATUS_CODE_OK"]=1,e[i[2]="STATUS_CODE_ERROR"]=2,e}(),l}(),c}(),o}(),n.collector=function(){var o={};return o.trace=function(){var c={};return c.v1=function(){var l={};return l.TraceService=function(){function i(e,t,r){E.rpc.Service.call(this,e,t,r)}return(i.prototype=Object.create(E.rpc.Service.prototype)).constructor=i,i.create=function(t,r,u){return new this(t,r,u)},Object.defineProperty(i.prototype.export=function e(t,r){return this.rpcCall(e,p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest,p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse,t,r)},"name",{value:"Export"}),i}(),l.ExportTraceServiceRequest=function(){function i(e){if(this.resourceSpans=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.resourceSpans=f.emptyArray,i.create=function(t){return new i(t)},i.encode=function(t,r){if(r||(r=S.create()),t.resourceSpans!=null&&t.resourceSpans.length)for(var u=0;u<t.resourceSpans.length;++u)p.opentelemetry.proto.trace.v1.ResourceSpans.encode(t.resourceSpans[u],r.uint32(10).fork()).ldelim();return r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.resourceSpans&&s.resourceSpans.length||(s.resourceSpans=[]),s.resourceSpans.push(p.opentelemetry.proto.trace.v1.ResourceSpans.decode(t,t.uint32()));break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.resourceSpans!=null&&t.hasOwnProperty("resourceSpans")){if(!Array.isArray(t.resourceSpans))return"resourceSpans: array expected";for(var r=0;r<t.resourceSpans.length;++r){var u=p.opentelemetry.proto.trace.v1.ResourceSpans.verify(t.resourceSpans[r]);if(u)return"resourceSpans."+u}}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest)return t;var r=new p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest;if(t.resourceSpans){if(!Array.isArray(t.resourceSpans))throw TypeError(".opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest.resourceSpans: array expected");r.resourceSpans=[];for(var u=0;u<t.resourceSpans.length;++u){if(typeof t.resourceSpans[u]!="object")throw TypeError(".opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest.resourceSpans: object expected");r.resourceSpans[u]=p.opentelemetry.proto.trace.v1.ResourceSpans.fromObject(t.resourceSpans[u])}}return r},i.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.resourceSpans=[]),t.resourceSpans&&t.resourceSpans.length){u.resourceSpans=[];for(var s=0;s<t.resourceSpans.length;++s)u.resourceSpans[s]=p.opentelemetry.proto.trace.v1.ResourceSpans.toObject(t.resourceSpans[s],r)}return u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest"},i}(),l.ExportTraceServiceResponse=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.partialSuccess=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.partialSuccess!=null&&Object.hasOwnProperty.call(t,"partialSuccess")&&p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.encode(t.partialSuccess,r.uint32(10).fork()).ldelim(),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.partialSuccess=p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.decode(t,t.uint32());break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")){var r=p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.verify(t.partialSuccess);if(r)return"partialSuccess."+r}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse)return t;var r=new p.opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse;if(t.partialSuccess!=null){if(typeof t.partialSuccess!="object")throw TypeError(".opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse.partialSuccess: object expected");r.partialSuccess=p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.fromObject(t.partialSuccess)}return r},i.toObject=function(t,r){r||(r={});var u={};return r.defaults&&(u.partialSuccess=null),t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")&&(u.partialSuccess=p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess.toObject(t.partialSuccess,r)),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.trace.v1.ExportTraceServiceResponse"},i}(),l.ExportTracePartialSuccess=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.rejectedSpans=null,i.prototype.errorMessage=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.rejectedSpans!=null&&Object.hasOwnProperty.call(t,"rejectedSpans")&&r.uint32(8).int64(t.rejectedSpans),t.errorMessage!=null&&Object.hasOwnProperty.call(t,"errorMessage")&&r.uint32(18).string(t.errorMessage),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.rejectedSpans=t.int64();break}case 2:{s.errorMessage=t.string();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){return typeof t!="object"||t===null?"object expected":t.rejectedSpans!=null&&t.hasOwnProperty("rejectedSpans")&&!f.isInteger(t.rejectedSpans)&&!(t.rejectedSpans&&f.isInteger(t.rejectedSpans.low)&&f.isInteger(t.rejectedSpans.high))?"rejectedSpans: integer|Long expected":t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&!f.isString(t.errorMessage)?"errorMessage: string expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess)return t;var r=new p.opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess;return t.rejectedSpans!=null&&(f.Long?(r.rejectedSpans=f.Long.fromValue(t.rejectedSpans)).unsigned=!1:typeof t.rejectedSpans=="string"?r.rejectedSpans=parseInt(t.rejectedSpans,10):typeof t.rejectedSpans=="number"?r.rejectedSpans=t.rejectedSpans:typeof t.rejectedSpans=="object"&&(r.rejectedSpans=new f.LongBits(t.rejectedSpans.low>>>0,t.rejectedSpans.high>>>0).toNumber())),t.errorMessage!=null&&(r.errorMessage=String(t.errorMessage)),r},i.toObject=function(t,r){r||(r={});var u={};if(r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.rejectedSpans=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.rejectedSpans=r.longs===String?"0":0;u.errorMessage=""}return t.rejectedSpans!=null&&t.hasOwnProperty("rejectedSpans")&&(typeof t.rejectedSpans=="number"?u.rejectedSpans=r.longs===String?String(t.rejectedSpans):t.rejectedSpans:u.rejectedSpans=r.longs===String?f.Long.prototype.toString.call(t.rejectedSpans):r.longs===Number?new f.LongBits(t.rejectedSpans.low>>>0,t.rejectedSpans.high>>>0).toNumber():t.rejectedSpans),t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&(u.errorMessage=t.errorMessage),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.trace.v1.ExportTracePartialSuccess"},i}(),l}(),c}(),o.metrics=function(){var c={};return c.v1=function(){var l={};return l.MetricsService=function(){function i(e,t,r){E.rpc.Service.call(this,e,t,r)}return(i.prototype=Object.create(E.rpc.Service.prototype)).constructor=i,i.create=function(t,r,u){return new this(t,r,u)},Object.defineProperty(i.prototype.export=function e(t,r){return this.rpcCall(e,p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest,p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse,t,r)},"name",{value:"Export"}),i}(),l.ExportMetricsServiceRequest=function(){function i(e){if(this.resourceMetrics=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.resourceMetrics=f.emptyArray,i.create=function(t){return new i(t)},i.encode=function(t,r){if(r||(r=S.create()),t.resourceMetrics!=null&&t.resourceMetrics.length)for(var u=0;u<t.resourceMetrics.length;++u)p.opentelemetry.proto.metrics.v1.ResourceMetrics.encode(t.resourceMetrics[u],r.uint32(10).fork()).ldelim();return r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.resourceMetrics&&s.resourceMetrics.length||(s.resourceMetrics=[]),s.resourceMetrics.push(p.opentelemetry.proto.metrics.v1.ResourceMetrics.decode(t,t.uint32()));break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.resourceMetrics!=null&&t.hasOwnProperty("resourceMetrics")){if(!Array.isArray(t.resourceMetrics))return"resourceMetrics: array expected";for(var r=0;r<t.resourceMetrics.length;++r){var u=p.opentelemetry.proto.metrics.v1.ResourceMetrics.verify(t.resourceMetrics[r]);if(u)return"resourceMetrics."+u}}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest)return t;var r=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest;if(t.resourceMetrics){if(!Array.isArray(t.resourceMetrics))throw TypeError(".opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest.resourceMetrics: array expected");r.resourceMetrics=[];for(var u=0;u<t.resourceMetrics.length;++u){if(typeof t.resourceMetrics[u]!="object")throw TypeError(".opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest.resourceMetrics: object expected");r.resourceMetrics[u]=p.opentelemetry.proto.metrics.v1.ResourceMetrics.fromObject(t.resourceMetrics[u])}}return r},i.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.resourceMetrics=[]),t.resourceMetrics&&t.resourceMetrics.length){u.resourceMetrics=[];for(var s=0;s<t.resourceMetrics.length;++s)u.resourceMetrics[s]=p.opentelemetry.proto.metrics.v1.ResourceMetrics.toObject(t.resourceMetrics[s],r)}return u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest"},i}(),l.ExportMetricsServiceResponse=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.partialSuccess=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.partialSuccess!=null&&Object.hasOwnProperty.call(t,"partialSuccess")&&p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.encode(t.partialSuccess,r.uint32(10).fork()).ldelim(),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.partialSuccess=p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.decode(t,t.uint32());break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")){var r=p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.verify(t.partialSuccess);if(r)return"partialSuccess."+r}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse)return t;var r=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse;if(t.partialSuccess!=null){if(typeof t.partialSuccess!="object")throw TypeError(".opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse.partialSuccess: object expected");r.partialSuccess=p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.fromObject(t.partialSuccess)}return r},i.toObject=function(t,r){r||(r={});var u={};return r.defaults&&(u.partialSuccess=null),t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")&&(u.partialSuccess=p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess.toObject(t.partialSuccess,r)),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceResponse"},i}(),l.ExportMetricsPartialSuccess=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.rejectedDataPoints=null,i.prototype.errorMessage=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.rejectedDataPoints!=null&&Object.hasOwnProperty.call(t,"rejectedDataPoints")&&r.uint32(8).int64(t.rejectedDataPoints),t.errorMessage!=null&&Object.hasOwnProperty.call(t,"errorMessage")&&r.uint32(18).string(t.errorMessage),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.rejectedDataPoints=t.int64();break}case 2:{s.errorMessage=t.string();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){return typeof t!="object"||t===null?"object expected":t.rejectedDataPoints!=null&&t.hasOwnProperty("rejectedDataPoints")&&!f.isInteger(t.rejectedDataPoints)&&!(t.rejectedDataPoints&&f.isInteger(t.rejectedDataPoints.low)&&f.isInteger(t.rejectedDataPoints.high))?"rejectedDataPoints: integer|Long expected":t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&!f.isString(t.errorMessage)?"errorMessage: string expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess)return t;var r=new p.opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess;return t.rejectedDataPoints!=null&&(f.Long?(r.rejectedDataPoints=f.Long.fromValue(t.rejectedDataPoints)).unsigned=!1:typeof t.rejectedDataPoints=="string"?r.rejectedDataPoints=parseInt(t.rejectedDataPoints,10):typeof t.rejectedDataPoints=="number"?r.rejectedDataPoints=t.rejectedDataPoints:typeof t.rejectedDataPoints=="object"&&(r.rejectedDataPoints=new f.LongBits(t.rejectedDataPoints.low>>>0,t.rejectedDataPoints.high>>>0).toNumber())),t.errorMessage!=null&&(r.errorMessage=String(t.errorMessage)),r},i.toObject=function(t,r){r||(r={});var u={};if(r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.rejectedDataPoints=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.rejectedDataPoints=r.longs===String?"0":0;u.errorMessage=""}return t.rejectedDataPoints!=null&&t.hasOwnProperty("rejectedDataPoints")&&(typeof t.rejectedDataPoints=="number"?u.rejectedDataPoints=r.longs===String?String(t.rejectedDataPoints):t.rejectedDataPoints:u.rejectedDataPoints=r.longs===String?f.Long.prototype.toString.call(t.rejectedDataPoints):r.longs===Number?new f.LongBits(t.rejectedDataPoints.low>>>0,t.rejectedDataPoints.high>>>0).toNumber():t.rejectedDataPoints),t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&(u.errorMessage=t.errorMessage),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.metrics.v1.ExportMetricsPartialSuccess"},i}(),l}(),c}(),o.logs=function(){var c={};return c.v1=function(){var l={};return l.LogsService=function(){function i(e,t,r){E.rpc.Service.call(this,e,t,r)}return(i.prototype=Object.create(E.rpc.Service.prototype)).constructor=i,i.create=function(t,r,u){return new this(t,r,u)},Object.defineProperty(i.prototype.export=function e(t,r){return this.rpcCall(e,p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest,p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse,t,r)},"name",{value:"Export"}),i}(),l.ExportLogsServiceRequest=function(){function i(e){if(this.resourceLogs=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.resourceLogs=f.emptyArray,i.create=function(t){return new i(t)},i.encode=function(t,r){if(r||(r=S.create()),t.resourceLogs!=null&&t.resourceLogs.length)for(var u=0;u<t.resourceLogs.length;++u)p.opentelemetry.proto.logs.v1.ResourceLogs.encode(t.resourceLogs[u],r.uint32(10).fork()).ldelim();return r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.resourceLogs&&s.resourceLogs.length||(s.resourceLogs=[]),s.resourceLogs.push(p.opentelemetry.proto.logs.v1.ResourceLogs.decode(t,t.uint32()));break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.resourceLogs!=null&&t.hasOwnProperty("resourceLogs")){if(!Array.isArray(t.resourceLogs))return"resourceLogs: array expected";for(var r=0;r<t.resourceLogs.length;++r){var u=p.opentelemetry.proto.logs.v1.ResourceLogs.verify(t.resourceLogs[r]);if(u)return"resourceLogs."+u}}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest)return t;var r=new p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest;if(t.resourceLogs){if(!Array.isArray(t.resourceLogs))throw TypeError(".opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest.resourceLogs: array expected");r.resourceLogs=[];for(var u=0;u<t.resourceLogs.length;++u){if(typeof t.resourceLogs[u]!="object")throw TypeError(".opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest.resourceLogs: object expected");r.resourceLogs[u]=p.opentelemetry.proto.logs.v1.ResourceLogs.fromObject(t.resourceLogs[u])}}return r},i.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.resourceLogs=[]),t.resourceLogs&&t.resourceLogs.length){u.resourceLogs=[];for(var s=0;s<t.resourceLogs.length;++s)u.resourceLogs[s]=p.opentelemetry.proto.logs.v1.ResourceLogs.toObject(t.resourceLogs[s],r)}return u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest"},i}(),l.ExportLogsServiceResponse=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.partialSuccess=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.partialSuccess!=null&&Object.hasOwnProperty.call(t,"partialSuccess")&&p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.encode(t.partialSuccess,r.uint32(10).fork()).ldelim(),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.partialSuccess=p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.decode(t,t.uint32());break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){if(typeof t!="object"||t===null)return"object expected";if(t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")){var r=p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.verify(t.partialSuccess);if(r)return"partialSuccess."+r}return null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse)return t;var r=new p.opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse;if(t.partialSuccess!=null){if(typeof t.partialSuccess!="object")throw TypeError(".opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse.partialSuccess: object expected");r.partialSuccess=p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.fromObject(t.partialSuccess)}return r},i.toObject=function(t,r){r||(r={});var u={};return r.defaults&&(u.partialSuccess=null),t.partialSuccess!=null&&t.hasOwnProperty("partialSuccess")&&(u.partialSuccess=p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess.toObject(t.partialSuccess,r)),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.logs.v1.ExportLogsServiceResponse"},i}(),l.ExportLogsPartialSuccess=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.rejectedLogRecords=null,i.prototype.errorMessage=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.rejectedLogRecords!=null&&Object.hasOwnProperty.call(t,"rejectedLogRecords")&&r.uint32(8).int64(t.rejectedLogRecords),t.errorMessage!=null&&Object.hasOwnProperty.call(t,"errorMessage")&&r.uint32(18).string(t.errorMessage),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.rejectedLogRecords=t.int64();break}case 2:{s.errorMessage=t.string();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){return typeof t!="object"||t===null?"object expected":t.rejectedLogRecords!=null&&t.hasOwnProperty("rejectedLogRecords")&&!f.isInteger(t.rejectedLogRecords)&&!(t.rejectedLogRecords&&f.isInteger(t.rejectedLogRecords.low)&&f.isInteger(t.rejectedLogRecords.high))?"rejectedLogRecords: integer|Long expected":t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&!f.isString(t.errorMessage)?"errorMessage: string expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess)return t;var r=new p.opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess;return t.rejectedLogRecords!=null&&(f.Long?(r.rejectedLogRecords=f.Long.fromValue(t.rejectedLogRecords)).unsigned=!1:typeof t.rejectedLogRecords=="string"?r.rejectedLogRecords=parseInt(t.rejectedLogRecords,10):typeof t.rejectedLogRecords=="number"?r.rejectedLogRecords=t.rejectedLogRecords:typeof t.rejectedLogRecords=="object"&&(r.rejectedLogRecords=new f.LongBits(t.rejectedLogRecords.low>>>0,t.rejectedLogRecords.high>>>0).toNumber())),t.errorMessage!=null&&(r.errorMessage=String(t.errorMessage)),r},i.toObject=function(t,r){r||(r={});var u={};if(r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.rejectedLogRecords=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.rejectedLogRecords=r.longs===String?"0":0;u.errorMessage=""}return t.rejectedLogRecords!=null&&t.hasOwnProperty("rejectedLogRecords")&&(typeof t.rejectedLogRecords=="number"?u.rejectedLogRecords=r.longs===String?String(t.rejectedLogRecords):t.rejectedLogRecords:u.rejectedLogRecords=r.longs===String?f.Long.prototype.toString.call(t.rejectedLogRecords):r.longs===Number?new f.LongBits(t.rejectedLogRecords.low>>>0,t.rejectedLogRecords.high>>>0).toNumber():t.rejectedLogRecords),t.errorMessage!=null&&t.hasOwnProperty("errorMessage")&&(u.errorMessage=t.errorMessage),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.collector.logs.v1.ExportLogsPartialSuccess"},i}(),l}(),c}(),o}(),n.metrics=function(){var o={};return o.v1=function(){var c={};return c.MetricsData=function(){function l(i){if(this.resourceMetrics=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resourceMetrics=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resourceMetrics!=null&&e.resourceMetrics.length)for(var r=0;r<e.resourceMetrics.length;++r)p.opentelemetry.proto.metrics.v1.ResourceMetrics.encode(e.resourceMetrics[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.MetricsData;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resourceMetrics&&u.resourceMetrics.length||(u.resourceMetrics=[]),u.resourceMetrics.push(p.opentelemetry.proto.metrics.v1.ResourceMetrics.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resourceMetrics!=null&&e.hasOwnProperty("resourceMetrics")){if(!Array.isArray(e.resourceMetrics))return"resourceMetrics: array expected";for(var t=0;t<e.resourceMetrics.length;++t){var r=p.opentelemetry.proto.metrics.v1.ResourceMetrics.verify(e.resourceMetrics[t]);if(r)return"resourceMetrics."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.MetricsData)return e;var t=new p.opentelemetry.proto.metrics.v1.MetricsData;if(e.resourceMetrics){if(!Array.isArray(e.resourceMetrics))throw TypeError(".opentelemetry.proto.metrics.v1.MetricsData.resourceMetrics: array expected");t.resourceMetrics=[];for(var r=0;r<e.resourceMetrics.length;++r){if(typeof e.resourceMetrics[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.MetricsData.resourceMetrics: object expected");t.resourceMetrics[r]=p.opentelemetry.proto.metrics.v1.ResourceMetrics.fromObject(e.resourceMetrics[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.resourceMetrics=[]),e.resourceMetrics&&e.resourceMetrics.length){r.resourceMetrics=[];for(var u=0;u<e.resourceMetrics.length;++u)r.resourceMetrics[u]=p.opentelemetry.proto.metrics.v1.ResourceMetrics.toObject(e.resourceMetrics[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.MetricsData"},l}(),c.ResourceMetrics=function(){function l(i){if(this.scopeMetrics=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resource=null,l.prototype.scopeMetrics=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resource!=null&&Object.hasOwnProperty.call(e,"resource")&&p.opentelemetry.proto.resource.v1.Resource.encode(e.resource,t.uint32(10).fork()).ldelim(),e.scopeMetrics!=null&&e.scopeMetrics.length)for(var r=0;r<e.scopeMetrics.length;++r)p.opentelemetry.proto.metrics.v1.ScopeMetrics.encode(e.scopeMetrics[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.ResourceMetrics;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resource=p.opentelemetry.proto.resource.v1.Resource.decode(e,e.uint32());break}case 2:{u.scopeMetrics&&u.scopeMetrics.length||(u.scopeMetrics=[]),u.scopeMetrics.push(p.opentelemetry.proto.metrics.v1.ScopeMetrics.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resource!=null&&e.hasOwnProperty("resource")){var t=p.opentelemetry.proto.resource.v1.Resource.verify(e.resource);if(t)return"resource."+t}if(e.scopeMetrics!=null&&e.hasOwnProperty("scopeMetrics")){if(!Array.isArray(e.scopeMetrics))return"scopeMetrics: array expected";for(var r=0;r<e.scopeMetrics.length;++r){var t=p.opentelemetry.proto.metrics.v1.ScopeMetrics.verify(e.scopeMetrics[r]);if(t)return"scopeMetrics."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.ResourceMetrics)return e;var t=new p.opentelemetry.proto.metrics.v1.ResourceMetrics;if(e.resource!=null){if(typeof e.resource!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ResourceMetrics.resource: object expected");t.resource=p.opentelemetry.proto.resource.v1.Resource.fromObject(e.resource)}if(e.scopeMetrics){if(!Array.isArray(e.scopeMetrics))throw TypeError(".opentelemetry.proto.metrics.v1.ResourceMetrics.scopeMetrics: array expected");t.scopeMetrics=[];for(var r=0;r<e.scopeMetrics.length;++r){if(typeof e.scopeMetrics[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ResourceMetrics.scopeMetrics: object expected");t.scopeMetrics[r]=p.opentelemetry.proto.metrics.v1.ScopeMetrics.fromObject(e.scopeMetrics[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.scopeMetrics=[]),t.defaults&&(r.resource=null,r.schemaUrl=""),e.resource!=null&&e.hasOwnProperty("resource")&&(r.resource=p.opentelemetry.proto.resource.v1.Resource.toObject(e.resource,t)),e.scopeMetrics&&e.scopeMetrics.length){r.scopeMetrics=[];for(var u=0;u<e.scopeMetrics.length;++u)r.scopeMetrics[u]=p.opentelemetry.proto.metrics.v1.ScopeMetrics.toObject(e.scopeMetrics[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.ResourceMetrics"},l}(),c.ScopeMetrics=function(){function l(i){if(this.metrics=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.scope=null,l.prototype.metrics=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.scope!=null&&Object.hasOwnProperty.call(e,"scope")&&p.opentelemetry.proto.common.v1.InstrumentationScope.encode(e.scope,t.uint32(10).fork()).ldelim(),e.metrics!=null&&e.metrics.length)for(var r=0;r<e.metrics.length;++r)p.opentelemetry.proto.metrics.v1.Metric.encode(e.metrics[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.ScopeMetrics;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.decode(e,e.uint32());break}case 2:{u.metrics&&u.metrics.length||(u.metrics=[]),u.metrics.push(p.opentelemetry.proto.metrics.v1.Metric.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.scope!=null&&e.hasOwnProperty("scope")){var t=p.opentelemetry.proto.common.v1.InstrumentationScope.verify(e.scope);if(t)return"scope."+t}if(e.metrics!=null&&e.hasOwnProperty("metrics")){if(!Array.isArray(e.metrics))return"metrics: array expected";for(var r=0;r<e.metrics.length;++r){var t=p.opentelemetry.proto.metrics.v1.Metric.verify(e.metrics[r]);if(t)return"metrics."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.ScopeMetrics)return e;var t=new p.opentelemetry.proto.metrics.v1.ScopeMetrics;if(e.scope!=null){if(typeof e.scope!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ScopeMetrics.scope: object expected");t.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.fromObject(e.scope)}if(e.metrics){if(!Array.isArray(e.metrics))throw TypeError(".opentelemetry.proto.metrics.v1.ScopeMetrics.metrics: array expected");t.metrics=[];for(var r=0;r<e.metrics.length;++r){if(typeof e.metrics[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ScopeMetrics.metrics: object expected");t.metrics[r]=p.opentelemetry.proto.metrics.v1.Metric.fromObject(e.metrics[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.metrics=[]),t.defaults&&(r.scope=null,r.schemaUrl=""),e.scope!=null&&e.hasOwnProperty("scope")&&(r.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.toObject(e.scope,t)),e.metrics&&e.metrics.length){r.metrics=[];for(var u=0;u<e.metrics.length;++u)r.metrics[u]=p.opentelemetry.proto.metrics.v1.Metric.toObject(e.metrics[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.ScopeMetrics"},l}(),c.Metric=function(){function l(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.name=null,l.prototype.description=null,l.prototype.unit=null,l.prototype.gauge=null,l.prototype.sum=null,l.prototype.histogram=null,l.prototype.exponentialHistogram=null,l.prototype.summary=null;var i;return Object.defineProperty(l.prototype,"data",{get:f.oneOfGetter(i=["gauge","sum","histogram","exponentialHistogram","summary"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){return r||(r=S.create()),t.name!=null&&Object.hasOwnProperty.call(t,"name")&&r.uint32(10).string(t.name),t.description!=null&&Object.hasOwnProperty.call(t,"description")&&r.uint32(18).string(t.description),t.unit!=null&&Object.hasOwnProperty.call(t,"unit")&&r.uint32(26).string(t.unit),t.gauge!=null&&Object.hasOwnProperty.call(t,"gauge")&&p.opentelemetry.proto.metrics.v1.Gauge.encode(t.gauge,r.uint32(42).fork()).ldelim(),t.sum!=null&&Object.hasOwnProperty.call(t,"sum")&&p.opentelemetry.proto.metrics.v1.Sum.encode(t.sum,r.uint32(58).fork()).ldelim(),t.histogram!=null&&Object.hasOwnProperty.call(t,"histogram")&&p.opentelemetry.proto.metrics.v1.Histogram.encode(t.histogram,r.uint32(74).fork()).ldelim(),t.exponentialHistogram!=null&&Object.hasOwnProperty.call(t,"exponentialHistogram")&&p.opentelemetry.proto.metrics.v1.ExponentialHistogram.encode(t.exponentialHistogram,r.uint32(82).fork()).ldelim(),t.summary!=null&&Object.hasOwnProperty.call(t,"summary")&&p.opentelemetry.proto.metrics.v1.Summary.encode(t.summary,r.uint32(90).fork()).ldelim(),r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.Metric;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.name=t.string();break}case 2:{s.description=t.string();break}case 3:{s.unit=t.string();break}case 5:{s.gauge=p.opentelemetry.proto.metrics.v1.Gauge.decode(t,t.uint32());break}case 7:{s.sum=p.opentelemetry.proto.metrics.v1.Sum.decode(t,t.uint32());break}case 9:{s.histogram=p.opentelemetry.proto.metrics.v1.Histogram.decode(t,t.uint32());break}case 10:{s.exponentialHistogram=p.opentelemetry.proto.metrics.v1.ExponentialHistogram.decode(t,t.uint32());break}case 11:{s.summary=p.opentelemetry.proto.metrics.v1.Summary.decode(t,t.uint32());break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.name!=null&&t.hasOwnProperty("name")&&!f.isString(t.name))return"name: string expected";if(t.description!=null&&t.hasOwnProperty("description")&&!f.isString(t.description))return"description: string expected";if(t.unit!=null&&t.hasOwnProperty("unit")&&!f.isString(t.unit))return"unit: string expected";if(t.gauge!=null&&t.hasOwnProperty("gauge")){r.data=1;{var u=p.opentelemetry.proto.metrics.v1.Gauge.verify(t.gauge);if(u)return"gauge."+u}}if(t.sum!=null&&t.hasOwnProperty("sum")){if(r.data===1)return"data: multiple values";r.data=1;{var u=p.opentelemetry.proto.metrics.v1.Sum.verify(t.sum);if(u)return"sum."+u}}if(t.histogram!=null&&t.hasOwnProperty("histogram")){if(r.data===1)return"data: multiple values";r.data=1;{var u=p.opentelemetry.proto.metrics.v1.Histogram.verify(t.histogram);if(u)return"histogram."+u}}if(t.exponentialHistogram!=null&&t.hasOwnProperty("exponentialHistogram")){if(r.data===1)return"data: multiple values";r.data=1;{var u=p.opentelemetry.proto.metrics.v1.ExponentialHistogram.verify(t.exponentialHistogram);if(u)return"exponentialHistogram."+u}}if(t.summary!=null&&t.hasOwnProperty("summary")){if(r.data===1)return"data: multiple values";r.data=1;{var u=p.opentelemetry.proto.metrics.v1.Summary.verify(t.summary);if(u)return"summary."+u}}return null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.Metric)return t;var r=new p.opentelemetry.proto.metrics.v1.Metric;if(t.name!=null&&(r.name=String(t.name)),t.description!=null&&(r.description=String(t.description)),t.unit!=null&&(r.unit=String(t.unit)),t.gauge!=null){if(typeof t.gauge!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Metric.gauge: object expected");r.gauge=p.opentelemetry.proto.metrics.v1.Gauge.fromObject(t.gauge)}if(t.sum!=null){if(typeof t.sum!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Metric.sum: object expected");r.sum=p.opentelemetry.proto.metrics.v1.Sum.fromObject(t.sum)}if(t.histogram!=null){if(typeof t.histogram!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Metric.histogram: object expected");r.histogram=p.opentelemetry.proto.metrics.v1.Histogram.fromObject(t.histogram)}if(t.exponentialHistogram!=null){if(typeof t.exponentialHistogram!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Metric.exponentialHistogram: object expected");r.exponentialHistogram=p.opentelemetry.proto.metrics.v1.ExponentialHistogram.fromObject(t.exponentialHistogram)}if(t.summary!=null){if(typeof t.summary!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Metric.summary: object expected");r.summary=p.opentelemetry.proto.metrics.v1.Summary.fromObject(t.summary)}return r},l.toObject=function(t,r){r||(r={});var u={};return r.defaults&&(u.name="",u.description="",u.unit=""),t.name!=null&&t.hasOwnProperty("name")&&(u.name=t.name),t.description!=null&&t.hasOwnProperty("description")&&(u.description=t.description),t.unit!=null&&t.hasOwnProperty("unit")&&(u.unit=t.unit),t.gauge!=null&&t.hasOwnProperty("gauge")&&(u.gauge=p.opentelemetry.proto.metrics.v1.Gauge.toObject(t.gauge,r),r.oneofs&&(u.data="gauge")),t.sum!=null&&t.hasOwnProperty("sum")&&(u.sum=p.opentelemetry.proto.metrics.v1.Sum.toObject(t.sum,r),r.oneofs&&(u.data="sum")),t.histogram!=null&&t.hasOwnProperty("histogram")&&(u.histogram=p.opentelemetry.proto.metrics.v1.Histogram.toObject(t.histogram,r),r.oneofs&&(u.data="histogram")),t.exponentialHistogram!=null&&t.hasOwnProperty("exponentialHistogram")&&(u.exponentialHistogram=p.opentelemetry.proto.metrics.v1.ExponentialHistogram.toObject(t.exponentialHistogram,r),r.oneofs&&(u.data="exponentialHistogram")),t.summary!=null&&t.hasOwnProperty("summary")&&(u.summary=p.opentelemetry.proto.metrics.v1.Summary.toObject(t.summary,r),r.oneofs&&(u.data="summary")),u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.Metric"},l}(),c.Gauge=function(){function l(i){if(this.dataPoints=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.dataPoints=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.dataPoints!=null&&e.dataPoints.length)for(var r=0;r<e.dataPoints.length;++r)p.opentelemetry.proto.metrics.v1.NumberDataPoint.encode(e.dataPoints[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.Gauge;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.dataPoints&&u.dataPoints.length||(u.dataPoints=[]),u.dataPoints.push(p.opentelemetry.proto.metrics.v1.NumberDataPoint.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.dataPoints!=null&&e.hasOwnProperty("dataPoints")){if(!Array.isArray(e.dataPoints))return"dataPoints: array expected";for(var t=0;t<e.dataPoints.length;++t){var r=p.opentelemetry.proto.metrics.v1.NumberDataPoint.verify(e.dataPoints[t]);if(r)return"dataPoints."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.Gauge)return e;var t=new p.opentelemetry.proto.metrics.v1.Gauge;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(".opentelemetry.proto.metrics.v1.Gauge.dataPoints: array expected");t.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r){if(typeof e.dataPoints[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Gauge.dataPoints: object expected");t.dataPoints[r]=p.opentelemetry.proto.metrics.v1.NumberDataPoint.fromObject(e.dataPoints[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.dataPoints=[]),e.dataPoints&&e.dataPoints.length){r.dataPoints=[];for(var u=0;u<e.dataPoints.length;++u)r.dataPoints[u]=p.opentelemetry.proto.metrics.v1.NumberDataPoint.toObject(e.dataPoints[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.Gauge"},l}(),c.Sum=function(){function l(i){if(this.dataPoints=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.dataPoints=f.emptyArray,l.prototype.aggregationTemporality=null,l.prototype.isMonotonic=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.dataPoints!=null&&e.dataPoints.length)for(var r=0;r<e.dataPoints.length;++r)p.opentelemetry.proto.metrics.v1.NumberDataPoint.encode(e.dataPoints[r],t.uint32(10).fork()).ldelim();return e.aggregationTemporality!=null&&Object.hasOwnProperty.call(e,"aggregationTemporality")&&t.uint32(16).int32(e.aggregationTemporality),e.isMonotonic!=null&&Object.hasOwnProperty.call(e,"isMonotonic")&&t.uint32(24).bool(e.isMonotonic),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.Sum;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.dataPoints&&u.dataPoints.length||(u.dataPoints=[]),u.dataPoints.push(p.opentelemetry.proto.metrics.v1.NumberDataPoint.decode(e,e.uint32()));break}case 2:{u.aggregationTemporality=e.int32();break}case 3:{u.isMonotonic=e.bool();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.dataPoints!=null&&e.hasOwnProperty("dataPoints")){if(!Array.isArray(e.dataPoints))return"dataPoints: array expected";for(var t=0;t<e.dataPoints.length;++t){var r=p.opentelemetry.proto.metrics.v1.NumberDataPoint.verify(e.dataPoints[t]);if(r)return"dataPoints."+r}}if(e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality"))switch(e.aggregationTemporality){default:return"aggregationTemporality: enum value expected";case 0:case 1:case 2:break}return e.isMonotonic!=null&&e.hasOwnProperty("isMonotonic")&&typeof e.isMonotonic!="boolean"?"isMonotonic: boolean expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.Sum)return e;var t=new p.opentelemetry.proto.metrics.v1.Sum;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(".opentelemetry.proto.metrics.v1.Sum.dataPoints: array expected");t.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r){if(typeof e.dataPoints[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Sum.dataPoints: object expected");t.dataPoints[r]=p.opentelemetry.proto.metrics.v1.NumberDataPoint.fromObject(e.dataPoints[r])}}switch(e.aggregationTemporality){default:if(typeof e.aggregationTemporality=="number"){t.aggregationTemporality=e.aggregationTemporality;break}break;case"AGGREGATION_TEMPORALITY_UNSPECIFIED":case 0:t.aggregationTemporality=0;break;case"AGGREGATION_TEMPORALITY_DELTA":case 1:t.aggregationTemporality=1;break;case"AGGREGATION_TEMPORALITY_CUMULATIVE":case 2:t.aggregationTemporality=2;break}return e.isMonotonic!=null&&(t.isMonotonic=!!e.isMonotonic),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.dataPoints=[]),t.defaults&&(r.aggregationTemporality=t.enums===String?"AGGREGATION_TEMPORALITY_UNSPECIFIED":0,r.isMonotonic=!1),e.dataPoints&&e.dataPoints.length){r.dataPoints=[];for(var u=0;u<e.dataPoints.length;++u)r.dataPoints[u]=p.opentelemetry.proto.metrics.v1.NumberDataPoint.toObject(e.dataPoints[u],t)}return e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality")&&(r.aggregationTemporality=t.enums===String?p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]===void 0?e.aggregationTemporality:p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]:e.aggregationTemporality),e.isMonotonic!=null&&e.hasOwnProperty("isMonotonic")&&(r.isMonotonic=e.isMonotonic),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.Sum"},l}(),c.Histogram=function(){function l(i){if(this.dataPoints=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.dataPoints=f.emptyArray,l.prototype.aggregationTemporality=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.dataPoints!=null&&e.dataPoints.length)for(var r=0;r<e.dataPoints.length;++r)p.opentelemetry.proto.metrics.v1.HistogramDataPoint.encode(e.dataPoints[r],t.uint32(10).fork()).ldelim();return e.aggregationTemporality!=null&&Object.hasOwnProperty.call(e,"aggregationTemporality")&&t.uint32(16).int32(e.aggregationTemporality),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.Histogram;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.dataPoints&&u.dataPoints.length||(u.dataPoints=[]),u.dataPoints.push(p.opentelemetry.proto.metrics.v1.HistogramDataPoint.decode(e,e.uint32()));break}case 2:{u.aggregationTemporality=e.int32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.dataPoints!=null&&e.hasOwnProperty("dataPoints")){if(!Array.isArray(e.dataPoints))return"dataPoints: array expected";for(var t=0;t<e.dataPoints.length;++t){var r=p.opentelemetry.proto.metrics.v1.HistogramDataPoint.verify(e.dataPoints[t]);if(r)return"dataPoints."+r}}if(e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality"))switch(e.aggregationTemporality){default:return"aggregationTemporality: enum value expected";case 0:case 1:case 2:break}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.Histogram)return e;var t=new p.opentelemetry.proto.metrics.v1.Histogram;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(".opentelemetry.proto.metrics.v1.Histogram.dataPoints: array expected");t.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r){if(typeof e.dataPoints[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Histogram.dataPoints: object expected");t.dataPoints[r]=p.opentelemetry.proto.metrics.v1.HistogramDataPoint.fromObject(e.dataPoints[r])}}switch(e.aggregationTemporality){default:if(typeof e.aggregationTemporality=="number"){t.aggregationTemporality=e.aggregationTemporality;break}break;case"AGGREGATION_TEMPORALITY_UNSPECIFIED":case 0:t.aggregationTemporality=0;break;case"AGGREGATION_TEMPORALITY_DELTA":case 1:t.aggregationTemporality=1;break;case"AGGREGATION_TEMPORALITY_CUMULATIVE":case 2:t.aggregationTemporality=2;break}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.dataPoints=[]),t.defaults&&(r.aggregationTemporality=t.enums===String?"AGGREGATION_TEMPORALITY_UNSPECIFIED":0),e.dataPoints&&e.dataPoints.length){r.dataPoints=[];for(var u=0;u<e.dataPoints.length;++u)r.dataPoints[u]=p.opentelemetry.proto.metrics.v1.HistogramDataPoint.toObject(e.dataPoints[u],t)}return e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality")&&(r.aggregationTemporality=t.enums===String?p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]===void 0?e.aggregationTemporality:p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]:e.aggregationTemporality),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.Histogram"},l}(),c.ExponentialHistogram=function(){function l(i){if(this.dataPoints=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.dataPoints=f.emptyArray,l.prototype.aggregationTemporality=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.dataPoints!=null&&e.dataPoints.length)for(var r=0;r<e.dataPoints.length;++r)p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.encode(e.dataPoints[r],t.uint32(10).fork()).ldelim();return e.aggregationTemporality!=null&&Object.hasOwnProperty.call(e,"aggregationTemporality")&&t.uint32(16).int32(e.aggregationTemporality),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.ExponentialHistogram;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.dataPoints&&u.dataPoints.length||(u.dataPoints=[]),u.dataPoints.push(p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.decode(e,e.uint32()));break}case 2:{u.aggregationTemporality=e.int32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.dataPoints!=null&&e.hasOwnProperty("dataPoints")){if(!Array.isArray(e.dataPoints))return"dataPoints: array expected";for(var t=0;t<e.dataPoints.length;++t){var r=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.verify(e.dataPoints[t]);if(r)return"dataPoints."+r}}if(e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality"))switch(e.aggregationTemporality){default:return"aggregationTemporality: enum value expected";case 0:case 1:case 2:break}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.ExponentialHistogram)return e;var t=new p.opentelemetry.proto.metrics.v1.ExponentialHistogram;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogram.dataPoints: array expected");t.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r){if(typeof e.dataPoints[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogram.dataPoints: object expected");t.dataPoints[r]=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.fromObject(e.dataPoints[r])}}switch(e.aggregationTemporality){default:if(typeof e.aggregationTemporality=="number"){t.aggregationTemporality=e.aggregationTemporality;break}break;case"AGGREGATION_TEMPORALITY_UNSPECIFIED":case 0:t.aggregationTemporality=0;break;case"AGGREGATION_TEMPORALITY_DELTA":case 1:t.aggregationTemporality=1;break;case"AGGREGATION_TEMPORALITY_CUMULATIVE":case 2:t.aggregationTemporality=2;break}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.dataPoints=[]),t.defaults&&(r.aggregationTemporality=t.enums===String?"AGGREGATION_TEMPORALITY_UNSPECIFIED":0),e.dataPoints&&e.dataPoints.length){r.dataPoints=[];for(var u=0;u<e.dataPoints.length;++u)r.dataPoints[u]=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.toObject(e.dataPoints[u],t)}return e.aggregationTemporality!=null&&e.hasOwnProperty("aggregationTemporality")&&(r.aggregationTemporality=t.enums===String?p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]===void 0?e.aggregationTemporality:p.opentelemetry.proto.metrics.v1.AggregationTemporality[e.aggregationTemporality]:e.aggregationTemporality),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.ExponentialHistogram"},l}(),c.Summary=function(){function l(i){if(this.dataPoints=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.dataPoints=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.dataPoints!=null&&e.dataPoints.length)for(var r=0;r<e.dataPoints.length;++r)p.opentelemetry.proto.metrics.v1.SummaryDataPoint.encode(e.dataPoints[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.Summary;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.dataPoints&&u.dataPoints.length||(u.dataPoints=[]),u.dataPoints.push(p.opentelemetry.proto.metrics.v1.SummaryDataPoint.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.dataPoints!=null&&e.hasOwnProperty("dataPoints")){if(!Array.isArray(e.dataPoints))return"dataPoints: array expected";for(var t=0;t<e.dataPoints.length;++t){var r=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.verify(e.dataPoints[t]);if(r)return"dataPoints."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.Summary)return e;var t=new p.opentelemetry.proto.metrics.v1.Summary;if(e.dataPoints){if(!Array.isArray(e.dataPoints))throw TypeError(".opentelemetry.proto.metrics.v1.Summary.dataPoints: array expected");t.dataPoints=[];for(var r=0;r<e.dataPoints.length;++r){if(typeof e.dataPoints[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Summary.dataPoints: object expected");t.dataPoints[r]=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.fromObject(e.dataPoints[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.dataPoints=[]),e.dataPoints&&e.dataPoints.length){r.dataPoints=[];for(var u=0;u<e.dataPoints.length;++u)r.dataPoints[u]=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.toObject(e.dataPoints[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.Summary"},l}(),c.AggregationTemporality=function(){var l={},i=Object.create(l);return i[l[0]="AGGREGATION_TEMPORALITY_UNSPECIFIED"]=0,i[l[1]="AGGREGATION_TEMPORALITY_DELTA"]=1,i[l[2]="AGGREGATION_TEMPORALITY_CUMULATIVE"]=2,i}(),c.DataPointFlags=function(){var l={},i=Object.create(l);return i[l[0]="DATA_POINT_FLAGS_DO_NOT_USE"]=0,i[l[1]="DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK"]=1,i}(),c.NumberDataPoint=function(){function l(e){if(this.attributes=[],this.exemplars=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.attributes=f.emptyArray,l.prototype.startTimeUnixNano=null,l.prototype.timeUnixNano=null,l.prototype.asDouble=null,l.prototype.asInt=null,l.prototype.exemplars=f.emptyArray,l.prototype.flags=null;var i;return Object.defineProperty(l.prototype,"value",{get:f.oneOfGetter(i=["asDouble","asInt"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){if(r||(r=S.create()),t.startTimeUnixNano!=null&&Object.hasOwnProperty.call(t,"startTimeUnixNano")&&r.uint32(17).fixed64(t.startTimeUnixNano),t.timeUnixNano!=null&&Object.hasOwnProperty.call(t,"timeUnixNano")&&r.uint32(25).fixed64(t.timeUnixNano),t.asDouble!=null&&Object.hasOwnProperty.call(t,"asDouble")&&r.uint32(33).double(t.asDouble),t.exemplars!=null&&t.exemplars.length)for(var u=0;u<t.exemplars.length;++u)p.opentelemetry.proto.metrics.v1.Exemplar.encode(t.exemplars[u],r.uint32(42).fork()).ldelim();if(t.asInt!=null&&Object.hasOwnProperty.call(t,"asInt")&&r.uint32(49).sfixed64(t.asInt),t.attributes!=null&&t.attributes.length)for(var u=0;u<t.attributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.attributes[u],r.uint32(58).fork()).ldelim();return t.flags!=null&&Object.hasOwnProperty.call(t,"flags")&&r.uint32(64).uint32(t.flags),r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.NumberDataPoint;t.pos<u;){var d=t.uint32();switch(d>>>3){case 7:{s.attributes&&s.attributes.length||(s.attributes=[]),s.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 2:{s.startTimeUnixNano=t.fixed64();break}case 3:{s.timeUnixNano=t.fixed64();break}case 4:{s.asDouble=t.double();break}case 6:{s.asInt=t.sfixed64();break}case 5:{s.exemplars&&s.exemplars.length||(s.exemplars=[]),s.exemplars.push(p.opentelemetry.proto.metrics.v1.Exemplar.decode(t,t.uint32()));break}case 8:{s.flags=t.uint32();break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.attributes!=null&&t.hasOwnProperty("attributes")){if(!Array.isArray(t.attributes))return"attributes: array expected";for(var u=0;u<t.attributes.length;++u){var s=p.opentelemetry.proto.common.v1.KeyValue.verify(t.attributes[u]);if(s)return"attributes."+s}}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&!f.isInteger(t.startTimeUnixNano)&&!(t.startTimeUnixNano&&f.isInteger(t.startTimeUnixNano.low)&&f.isInteger(t.startTimeUnixNano.high)))return"startTimeUnixNano: integer|Long expected";if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&!f.isInteger(t.timeUnixNano)&&!(t.timeUnixNano&&f.isInteger(t.timeUnixNano.low)&&f.isInteger(t.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(t.asDouble!=null&&t.hasOwnProperty("asDouble")&&(r.value=1,typeof t.asDouble!="number"))return"asDouble: number expected";if(t.asInt!=null&&t.hasOwnProperty("asInt")){if(r.value===1)return"value: multiple values";if(r.value=1,!f.isInteger(t.asInt)&&!(t.asInt&&f.isInteger(t.asInt.low)&&f.isInteger(t.asInt.high)))return"asInt: integer|Long expected"}if(t.exemplars!=null&&t.hasOwnProperty("exemplars")){if(!Array.isArray(t.exemplars))return"exemplars: array expected";for(var u=0;u<t.exemplars.length;++u){var s=p.opentelemetry.proto.metrics.v1.Exemplar.verify(t.exemplars[u]);if(s)return"exemplars."+s}}return t.flags!=null&&t.hasOwnProperty("flags")&&!f.isInteger(t.flags)?"flags: integer expected":null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.NumberDataPoint)return t;var r=new p.opentelemetry.proto.metrics.v1.NumberDataPoint;if(t.attributes){if(!Array.isArray(t.attributes))throw TypeError(".opentelemetry.proto.metrics.v1.NumberDataPoint.attributes: array expected");r.attributes=[];for(var u=0;u<t.attributes.length;++u){if(typeof t.attributes[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.NumberDataPoint.attributes: object expected");r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.attributes[u])}}if(t.startTimeUnixNano!=null&&(f.Long?(r.startTimeUnixNano=f.Long.fromValue(t.startTimeUnixNano)).unsigned=!1:typeof t.startTimeUnixNano=="string"?r.startTimeUnixNano=parseInt(t.startTimeUnixNano,10):typeof t.startTimeUnixNano=="number"?r.startTimeUnixNano=t.startTimeUnixNano:typeof t.startTimeUnixNano=="object"&&(r.startTimeUnixNano=new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber())),t.timeUnixNano!=null&&(f.Long?(r.timeUnixNano=f.Long.fromValue(t.timeUnixNano)).unsigned=!1:typeof t.timeUnixNano=="string"?r.timeUnixNano=parseInt(t.timeUnixNano,10):typeof t.timeUnixNano=="number"?r.timeUnixNano=t.timeUnixNano:typeof t.timeUnixNano=="object"&&(r.timeUnixNano=new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber())),t.asDouble!=null&&(r.asDouble=Number(t.asDouble)),t.asInt!=null&&(f.Long?(r.asInt=f.Long.fromValue(t.asInt)).unsigned=!1:typeof t.asInt=="string"?r.asInt=parseInt(t.asInt,10):typeof t.asInt=="number"?r.asInt=t.asInt:typeof t.asInt=="object"&&(r.asInt=new f.LongBits(t.asInt.low>>>0,t.asInt.high>>>0).toNumber())),t.exemplars){if(!Array.isArray(t.exemplars))throw TypeError(".opentelemetry.proto.metrics.v1.NumberDataPoint.exemplars: array expected");r.exemplars=[];for(var u=0;u<t.exemplars.length;++u){if(typeof t.exemplars[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.NumberDataPoint.exemplars: object expected");r.exemplars[u]=p.opentelemetry.proto.metrics.v1.Exemplar.fromObject(t.exemplars[u])}}return t.flags!=null&&(r.flags=t.flags>>>0),r},l.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.exemplars=[],u.attributes=[]),r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.startTimeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.startTimeUnixNano=r.longs===String?"0":0;if(f.Long){var s=new f.Long(0,0,!1);u.timeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.timeUnixNano=r.longs===String?"0":0;u.flags=0}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&(typeof t.startTimeUnixNano=="number"?u.startTimeUnixNano=r.longs===String?String(t.startTimeUnixNano):t.startTimeUnixNano:u.startTimeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.startTimeUnixNano):r.longs===Number?new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber():t.startTimeUnixNano),t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&(typeof t.timeUnixNano=="number"?u.timeUnixNano=r.longs===String?String(t.timeUnixNano):t.timeUnixNano:u.timeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.timeUnixNano):r.longs===Number?new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber():t.timeUnixNano),t.asDouble!=null&&t.hasOwnProperty("asDouble")&&(u.asDouble=r.json&&!isFinite(t.asDouble)?String(t.asDouble):t.asDouble,r.oneofs&&(u.value="asDouble")),t.exemplars&&t.exemplars.length){u.exemplars=[];for(var d=0;d<t.exemplars.length;++d)u.exemplars[d]=p.opentelemetry.proto.metrics.v1.Exemplar.toObject(t.exemplars[d],r)}if(t.asInt!=null&&t.hasOwnProperty("asInt")&&(typeof t.asInt=="number"?u.asInt=r.longs===String?String(t.asInt):t.asInt:u.asInt=r.longs===String?f.Long.prototype.toString.call(t.asInt):r.longs===Number?new f.LongBits(t.asInt.low>>>0,t.asInt.high>>>0).toNumber():t.asInt,r.oneofs&&(u.value="asInt")),t.attributes&&t.attributes.length){u.attributes=[];for(var d=0;d<t.attributes.length;++d)u.attributes[d]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.attributes[d],r)}return t.flags!=null&&t.hasOwnProperty("flags")&&(u.flags=t.flags),u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.NumberDataPoint"},l}(),c.HistogramDataPoint=function(){function l(e){if(this.attributes=[],this.bucketCounts=[],this.explicitBounds=[],this.exemplars=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.attributes=f.emptyArray,l.prototype.startTimeUnixNano=null,l.prototype.timeUnixNano=null,l.prototype.count=null,l.prototype.sum=null,l.prototype.bucketCounts=f.emptyArray,l.prototype.explicitBounds=f.emptyArray,l.prototype.exemplars=f.emptyArray,l.prototype.flags=null,l.prototype.min=null,l.prototype.max=null;var i;return Object.defineProperty(l.prototype,"_sum",{get:f.oneOfGetter(i=["sum"]),set:f.oneOfSetter(i)}),Object.defineProperty(l.prototype,"_min",{get:f.oneOfGetter(i=["min"]),set:f.oneOfSetter(i)}),Object.defineProperty(l.prototype,"_max",{get:f.oneOfGetter(i=["max"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){if(r||(r=S.create()),t.startTimeUnixNano!=null&&Object.hasOwnProperty.call(t,"startTimeUnixNano")&&r.uint32(17).fixed64(t.startTimeUnixNano),t.timeUnixNano!=null&&Object.hasOwnProperty.call(t,"timeUnixNano")&&r.uint32(25).fixed64(t.timeUnixNano),t.count!=null&&Object.hasOwnProperty.call(t,"count")&&r.uint32(33).fixed64(t.count),t.sum!=null&&Object.hasOwnProperty.call(t,"sum")&&r.uint32(41).double(t.sum),t.bucketCounts!=null&&t.bucketCounts.length){r.uint32(50).fork();for(var u=0;u<t.bucketCounts.length;++u)r.fixed64(t.bucketCounts[u]);r.ldelim()}if(t.explicitBounds!=null&&t.explicitBounds.length){r.uint32(58).fork();for(var u=0;u<t.explicitBounds.length;++u)r.double(t.explicitBounds[u]);r.ldelim()}if(t.exemplars!=null&&t.exemplars.length)for(var u=0;u<t.exemplars.length;++u)p.opentelemetry.proto.metrics.v1.Exemplar.encode(t.exemplars[u],r.uint32(66).fork()).ldelim();if(t.attributes!=null&&t.attributes.length)for(var u=0;u<t.attributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.attributes[u],r.uint32(74).fork()).ldelim();return t.flags!=null&&Object.hasOwnProperty.call(t,"flags")&&r.uint32(80).uint32(t.flags),t.min!=null&&Object.hasOwnProperty.call(t,"min")&&r.uint32(89).double(t.min),t.max!=null&&Object.hasOwnProperty.call(t,"max")&&r.uint32(97).double(t.max),r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.HistogramDataPoint;t.pos<u;){var d=t.uint32();switch(d>>>3){case 9:{s.attributes&&s.attributes.length||(s.attributes=[]),s.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 2:{s.startTimeUnixNano=t.fixed64();break}case 3:{s.timeUnixNano=t.fixed64();break}case 4:{s.count=t.fixed64();break}case 5:{s.sum=t.double();break}case 6:{if(s.bucketCounts&&s.bucketCounts.length||(s.bucketCounts=[]),(d&7)===2)for(var v=t.uint32()+t.pos;t.pos<v;)s.bucketCounts.push(t.fixed64());else s.bucketCounts.push(t.fixed64());break}case 7:{if(s.explicitBounds&&s.explicitBounds.length||(s.explicitBounds=[]),(d&7)===2)for(var v=t.uint32()+t.pos;t.pos<v;)s.explicitBounds.push(t.double());else s.explicitBounds.push(t.double());break}case 8:{s.exemplars&&s.exemplars.length||(s.exemplars=[]),s.exemplars.push(p.opentelemetry.proto.metrics.v1.Exemplar.decode(t,t.uint32()));break}case 10:{s.flags=t.uint32();break}case 11:{s.min=t.double();break}case 12:{s.max=t.double();break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.attributes!=null&&t.hasOwnProperty("attributes")){if(!Array.isArray(t.attributes))return"attributes: array expected";for(var u=0;u<t.attributes.length;++u){var s=p.opentelemetry.proto.common.v1.KeyValue.verify(t.attributes[u]);if(s)return"attributes."+s}}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&!f.isInteger(t.startTimeUnixNano)&&!(t.startTimeUnixNano&&f.isInteger(t.startTimeUnixNano.low)&&f.isInteger(t.startTimeUnixNano.high)))return"startTimeUnixNano: integer|Long expected";if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&!f.isInteger(t.timeUnixNano)&&!(t.timeUnixNano&&f.isInteger(t.timeUnixNano.low)&&f.isInteger(t.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(t.count!=null&&t.hasOwnProperty("count")&&!f.isInteger(t.count)&&!(t.count&&f.isInteger(t.count.low)&&f.isInteger(t.count.high)))return"count: integer|Long expected";if(t.sum!=null&&t.hasOwnProperty("sum")&&(r._sum=1,typeof t.sum!="number"))return"sum: number expected";if(t.bucketCounts!=null&&t.hasOwnProperty("bucketCounts")){if(!Array.isArray(t.bucketCounts))return"bucketCounts: array expected";for(var u=0;u<t.bucketCounts.length;++u)if(!f.isInteger(t.bucketCounts[u])&&!(t.bucketCounts[u]&&f.isInteger(t.bucketCounts[u].low)&&f.isInteger(t.bucketCounts[u].high)))return"bucketCounts: integer|Long[] expected"}if(t.explicitBounds!=null&&t.hasOwnProperty("explicitBounds")){if(!Array.isArray(t.explicitBounds))return"explicitBounds: array expected";for(var u=0;u<t.explicitBounds.length;++u)if(typeof t.explicitBounds[u]!="number")return"explicitBounds: number[] expected"}if(t.exemplars!=null&&t.hasOwnProperty("exemplars")){if(!Array.isArray(t.exemplars))return"exemplars: array expected";for(var u=0;u<t.exemplars.length;++u){var s=p.opentelemetry.proto.metrics.v1.Exemplar.verify(t.exemplars[u]);if(s)return"exemplars."+s}}return t.flags!=null&&t.hasOwnProperty("flags")&&!f.isInteger(t.flags)?"flags: integer expected":t.min!=null&&t.hasOwnProperty("min")&&(r._min=1,typeof t.min!="number")?"min: number expected":t.max!=null&&t.hasOwnProperty("max")&&(r._max=1,typeof t.max!="number")?"max: number expected":null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.HistogramDataPoint)return t;var r=new p.opentelemetry.proto.metrics.v1.HistogramDataPoint;if(t.attributes){if(!Array.isArray(t.attributes))throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.attributes: array expected");r.attributes=[];for(var u=0;u<t.attributes.length;++u){if(typeof t.attributes[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.attributes: object expected");r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.attributes[u])}}if(t.startTimeUnixNano!=null&&(f.Long?(r.startTimeUnixNano=f.Long.fromValue(t.startTimeUnixNano)).unsigned=!1:typeof t.startTimeUnixNano=="string"?r.startTimeUnixNano=parseInt(t.startTimeUnixNano,10):typeof t.startTimeUnixNano=="number"?r.startTimeUnixNano=t.startTimeUnixNano:typeof t.startTimeUnixNano=="object"&&(r.startTimeUnixNano=new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber())),t.timeUnixNano!=null&&(f.Long?(r.timeUnixNano=f.Long.fromValue(t.timeUnixNano)).unsigned=!1:typeof t.timeUnixNano=="string"?r.timeUnixNano=parseInt(t.timeUnixNano,10):typeof t.timeUnixNano=="number"?r.timeUnixNano=t.timeUnixNano:typeof t.timeUnixNano=="object"&&(r.timeUnixNano=new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber())),t.count!=null&&(f.Long?(r.count=f.Long.fromValue(t.count)).unsigned=!1:typeof t.count=="string"?r.count=parseInt(t.count,10):typeof t.count=="number"?r.count=t.count:typeof t.count=="object"&&(r.count=new f.LongBits(t.count.low>>>0,t.count.high>>>0).toNumber())),t.sum!=null&&(r.sum=Number(t.sum)),t.bucketCounts){if(!Array.isArray(t.bucketCounts))throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.bucketCounts: array expected");r.bucketCounts=[];for(var u=0;u<t.bucketCounts.length;++u)f.Long?(r.bucketCounts[u]=f.Long.fromValue(t.bucketCounts[u])).unsigned=!1:typeof t.bucketCounts[u]=="string"?r.bucketCounts[u]=parseInt(t.bucketCounts[u],10):typeof t.bucketCounts[u]=="number"?r.bucketCounts[u]=t.bucketCounts[u]:typeof t.bucketCounts[u]=="object"&&(r.bucketCounts[u]=new f.LongBits(t.bucketCounts[u].low>>>0,t.bucketCounts[u].high>>>0).toNumber())}if(t.explicitBounds){if(!Array.isArray(t.explicitBounds))throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.explicitBounds: array expected");r.explicitBounds=[];for(var u=0;u<t.explicitBounds.length;++u)r.explicitBounds[u]=Number(t.explicitBounds[u])}if(t.exemplars){if(!Array.isArray(t.exemplars))throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.exemplars: array expected");r.exemplars=[];for(var u=0;u<t.exemplars.length;++u){if(typeof t.exemplars[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.HistogramDataPoint.exemplars: object expected");r.exemplars[u]=p.opentelemetry.proto.metrics.v1.Exemplar.fromObject(t.exemplars[u])}}return t.flags!=null&&(r.flags=t.flags>>>0),t.min!=null&&(r.min=Number(t.min)),t.max!=null&&(r.max=Number(t.max)),r},l.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.bucketCounts=[],u.explicitBounds=[],u.exemplars=[],u.attributes=[]),r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.startTimeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.startTimeUnixNano=r.longs===String?"0":0;if(f.Long){var s=new f.Long(0,0,!1);u.timeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.timeUnixNano=r.longs===String?"0":0;if(f.Long){var s=new f.Long(0,0,!1);u.count=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.count=r.longs===String?"0":0;u.flags=0}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&(typeof t.startTimeUnixNano=="number"?u.startTimeUnixNano=r.longs===String?String(t.startTimeUnixNano):t.startTimeUnixNano:u.startTimeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.startTimeUnixNano):r.longs===Number?new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber():t.startTimeUnixNano),t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&(typeof t.timeUnixNano=="number"?u.timeUnixNano=r.longs===String?String(t.timeUnixNano):t.timeUnixNano:u.timeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.timeUnixNano):r.longs===Number?new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber():t.timeUnixNano),t.count!=null&&t.hasOwnProperty("count")&&(typeof t.count=="number"?u.count=r.longs===String?String(t.count):t.count:u.count=r.longs===String?f.Long.prototype.toString.call(t.count):r.longs===Number?new f.LongBits(t.count.low>>>0,t.count.high>>>0).toNumber():t.count),t.sum!=null&&t.hasOwnProperty("sum")&&(u.sum=r.json&&!isFinite(t.sum)?String(t.sum):t.sum,r.oneofs&&(u._sum="sum")),t.bucketCounts&&t.bucketCounts.length){u.bucketCounts=[];for(var d=0;d<t.bucketCounts.length;++d)typeof t.bucketCounts[d]=="number"?u.bucketCounts[d]=r.longs===String?String(t.bucketCounts[d]):t.bucketCounts[d]:u.bucketCounts[d]=r.longs===String?f.Long.prototype.toString.call(t.bucketCounts[d]):r.longs===Number?new f.LongBits(t.bucketCounts[d].low>>>0,t.bucketCounts[d].high>>>0).toNumber():t.bucketCounts[d]}if(t.explicitBounds&&t.explicitBounds.length){u.explicitBounds=[];for(var d=0;d<t.explicitBounds.length;++d)u.explicitBounds[d]=r.json&&!isFinite(t.explicitBounds[d])?String(t.explicitBounds[d]):t.explicitBounds[d]}if(t.exemplars&&t.exemplars.length){u.exemplars=[];for(var d=0;d<t.exemplars.length;++d)u.exemplars[d]=p.opentelemetry.proto.metrics.v1.Exemplar.toObject(t.exemplars[d],r)}if(t.attributes&&t.attributes.length){u.attributes=[];for(var d=0;d<t.attributes.length;++d)u.attributes[d]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.attributes[d],r)}return t.flags!=null&&t.hasOwnProperty("flags")&&(u.flags=t.flags),t.min!=null&&t.hasOwnProperty("min")&&(u.min=r.json&&!isFinite(t.min)?String(t.min):t.min,r.oneofs&&(u._min="min")),t.max!=null&&t.hasOwnProperty("max")&&(u.max=r.json&&!isFinite(t.max)?String(t.max):t.max,r.oneofs&&(u._max="max")),u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.HistogramDataPoint"},l}(),c.ExponentialHistogramDataPoint=function(){function l(e){if(this.attributes=[],this.exemplars=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.attributes=f.emptyArray,l.prototype.startTimeUnixNano=null,l.prototype.timeUnixNano=null,l.prototype.count=null,l.prototype.sum=null,l.prototype.scale=null,l.prototype.zeroCount=null,l.prototype.positive=null,l.prototype.negative=null,l.prototype.flags=null,l.prototype.exemplars=f.emptyArray,l.prototype.min=null,l.prototype.max=null,l.prototype.zeroThreshold=null;var i;return Object.defineProperty(l.prototype,"_sum",{get:f.oneOfGetter(i=["sum"]),set:f.oneOfSetter(i)}),Object.defineProperty(l.prototype,"_min",{get:f.oneOfGetter(i=["min"]),set:f.oneOfSetter(i)}),Object.defineProperty(l.prototype,"_max",{get:f.oneOfGetter(i=["max"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){if(r||(r=S.create()),t.attributes!=null&&t.attributes.length)for(var u=0;u<t.attributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.attributes[u],r.uint32(10).fork()).ldelim();if(t.startTimeUnixNano!=null&&Object.hasOwnProperty.call(t,"startTimeUnixNano")&&r.uint32(17).fixed64(t.startTimeUnixNano),t.timeUnixNano!=null&&Object.hasOwnProperty.call(t,"timeUnixNano")&&r.uint32(25).fixed64(t.timeUnixNano),t.count!=null&&Object.hasOwnProperty.call(t,"count")&&r.uint32(33).fixed64(t.count),t.sum!=null&&Object.hasOwnProperty.call(t,"sum")&&r.uint32(41).double(t.sum),t.scale!=null&&Object.hasOwnProperty.call(t,"scale")&&r.uint32(48).sint32(t.scale),t.zeroCount!=null&&Object.hasOwnProperty.call(t,"zeroCount")&&r.uint32(57).fixed64(t.zeroCount),t.positive!=null&&Object.hasOwnProperty.call(t,"positive")&&p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.encode(t.positive,r.uint32(66).fork()).ldelim(),t.negative!=null&&Object.hasOwnProperty.call(t,"negative")&&p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.encode(t.negative,r.uint32(74).fork()).ldelim(),t.flags!=null&&Object.hasOwnProperty.call(t,"flags")&&r.uint32(80).uint32(t.flags),t.exemplars!=null&&t.exemplars.length)for(var u=0;u<t.exemplars.length;++u)p.opentelemetry.proto.metrics.v1.Exemplar.encode(t.exemplars[u],r.uint32(90).fork()).ldelim();return t.min!=null&&Object.hasOwnProperty.call(t,"min")&&r.uint32(97).double(t.min),t.max!=null&&Object.hasOwnProperty.call(t,"max")&&r.uint32(105).double(t.max),t.zeroThreshold!=null&&Object.hasOwnProperty.call(t,"zeroThreshold")&&r.uint32(113).double(t.zeroThreshold),r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.attributes&&s.attributes.length||(s.attributes=[]),s.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 2:{s.startTimeUnixNano=t.fixed64();break}case 3:{s.timeUnixNano=t.fixed64();break}case 4:{s.count=t.fixed64();break}case 5:{s.sum=t.double();break}case 6:{s.scale=t.sint32();break}case 7:{s.zeroCount=t.fixed64();break}case 8:{s.positive=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.decode(t,t.uint32());break}case 9:{s.negative=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.decode(t,t.uint32());break}case 10:{s.flags=t.uint32();break}case 11:{s.exemplars&&s.exemplars.length||(s.exemplars=[]),s.exemplars.push(p.opentelemetry.proto.metrics.v1.Exemplar.decode(t,t.uint32()));break}case 12:{s.min=t.double();break}case 13:{s.max=t.double();break}case 14:{s.zeroThreshold=t.double();break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.attributes!=null&&t.hasOwnProperty("attributes")){if(!Array.isArray(t.attributes))return"attributes: array expected";for(var u=0;u<t.attributes.length;++u){var s=p.opentelemetry.proto.common.v1.KeyValue.verify(t.attributes[u]);if(s)return"attributes."+s}}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&!f.isInteger(t.startTimeUnixNano)&&!(t.startTimeUnixNano&&f.isInteger(t.startTimeUnixNano.low)&&f.isInteger(t.startTimeUnixNano.high)))return"startTimeUnixNano: integer|Long expected";if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&!f.isInteger(t.timeUnixNano)&&!(t.timeUnixNano&&f.isInteger(t.timeUnixNano.low)&&f.isInteger(t.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(t.count!=null&&t.hasOwnProperty("count")&&!f.isInteger(t.count)&&!(t.count&&f.isInteger(t.count.low)&&f.isInteger(t.count.high)))return"count: integer|Long expected";if(t.sum!=null&&t.hasOwnProperty("sum")&&(r._sum=1,typeof t.sum!="number"))return"sum: number expected";if(t.scale!=null&&t.hasOwnProperty("scale")&&!f.isInteger(t.scale))return"scale: integer expected";if(t.zeroCount!=null&&t.hasOwnProperty("zeroCount")&&!f.isInteger(t.zeroCount)&&!(t.zeroCount&&f.isInteger(t.zeroCount.low)&&f.isInteger(t.zeroCount.high)))return"zeroCount: integer|Long expected";if(t.positive!=null&&t.hasOwnProperty("positive")){var s=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.verify(t.positive);if(s)return"positive."+s}if(t.negative!=null&&t.hasOwnProperty("negative")){var s=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.verify(t.negative);if(s)return"negative."+s}if(t.flags!=null&&t.hasOwnProperty("flags")&&!f.isInteger(t.flags))return"flags: integer expected";if(t.exemplars!=null&&t.hasOwnProperty("exemplars")){if(!Array.isArray(t.exemplars))return"exemplars: array expected";for(var u=0;u<t.exemplars.length;++u){var s=p.opentelemetry.proto.metrics.v1.Exemplar.verify(t.exemplars[u]);if(s)return"exemplars."+s}}return t.min!=null&&t.hasOwnProperty("min")&&(r._min=1,typeof t.min!="number")?"min: number expected":t.max!=null&&t.hasOwnProperty("max")&&(r._max=1,typeof t.max!="number")?"max: number expected":t.zeroThreshold!=null&&t.hasOwnProperty("zeroThreshold")&&typeof t.zeroThreshold!="number"?"zeroThreshold: number expected":null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint)return t;var r=new p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint;if(t.attributes){if(!Array.isArray(t.attributes))throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.attributes: array expected");r.attributes=[];for(var u=0;u<t.attributes.length;++u){if(typeof t.attributes[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.attributes: object expected");r.attributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.attributes[u])}}if(t.startTimeUnixNano!=null&&(f.Long?(r.startTimeUnixNano=f.Long.fromValue(t.startTimeUnixNano)).unsigned=!1:typeof t.startTimeUnixNano=="string"?r.startTimeUnixNano=parseInt(t.startTimeUnixNano,10):typeof t.startTimeUnixNano=="number"?r.startTimeUnixNano=t.startTimeUnixNano:typeof t.startTimeUnixNano=="object"&&(r.startTimeUnixNano=new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber())),t.timeUnixNano!=null&&(f.Long?(r.timeUnixNano=f.Long.fromValue(t.timeUnixNano)).unsigned=!1:typeof t.timeUnixNano=="string"?r.timeUnixNano=parseInt(t.timeUnixNano,10):typeof t.timeUnixNano=="number"?r.timeUnixNano=t.timeUnixNano:typeof t.timeUnixNano=="object"&&(r.timeUnixNano=new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber())),t.count!=null&&(f.Long?(r.count=f.Long.fromValue(t.count)).unsigned=!1:typeof t.count=="string"?r.count=parseInt(t.count,10):typeof t.count=="number"?r.count=t.count:typeof t.count=="object"&&(r.count=new f.LongBits(t.count.low>>>0,t.count.high>>>0).toNumber())),t.sum!=null&&(r.sum=Number(t.sum)),t.scale!=null&&(r.scale=t.scale|0),t.zeroCount!=null&&(f.Long?(r.zeroCount=f.Long.fromValue(t.zeroCount)).unsigned=!1:typeof t.zeroCount=="string"?r.zeroCount=parseInt(t.zeroCount,10):typeof t.zeroCount=="number"?r.zeroCount=t.zeroCount:typeof t.zeroCount=="object"&&(r.zeroCount=new f.LongBits(t.zeroCount.low>>>0,t.zeroCount.high>>>0).toNumber())),t.positive!=null){if(typeof t.positive!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.positive: object expected");r.positive=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.fromObject(t.positive)}if(t.negative!=null){if(typeof t.negative!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.negative: object expected");r.negative=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.fromObject(t.negative)}if(t.flags!=null&&(r.flags=t.flags>>>0),t.exemplars){if(!Array.isArray(t.exemplars))throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.exemplars: array expected");r.exemplars=[];for(var u=0;u<t.exemplars.length;++u){if(typeof t.exemplars[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.exemplars: object expected");r.exemplars[u]=p.opentelemetry.proto.metrics.v1.Exemplar.fromObject(t.exemplars[u])}}return t.min!=null&&(r.min=Number(t.min)),t.max!=null&&(r.max=Number(t.max)),t.zeroThreshold!=null&&(r.zeroThreshold=Number(t.zeroThreshold)),r},l.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.attributes=[],u.exemplars=[]),r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.startTimeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.startTimeUnixNano=r.longs===String?"0":0;if(f.Long){var s=new f.Long(0,0,!1);u.timeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.timeUnixNano=r.longs===String?"0":0;if(f.Long){var s=new f.Long(0,0,!1);u.count=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.count=r.longs===String?"0":0;if(u.scale=0,f.Long){var s=new f.Long(0,0,!1);u.zeroCount=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.zeroCount=r.longs===String?"0":0;u.positive=null,u.negative=null,u.flags=0,u.zeroThreshold=0}if(t.attributes&&t.attributes.length){u.attributes=[];for(var d=0;d<t.attributes.length;++d)u.attributes[d]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.attributes[d],r)}if(t.startTimeUnixNano!=null&&t.hasOwnProperty("startTimeUnixNano")&&(typeof t.startTimeUnixNano=="number"?u.startTimeUnixNano=r.longs===String?String(t.startTimeUnixNano):t.startTimeUnixNano:u.startTimeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.startTimeUnixNano):r.longs===Number?new f.LongBits(t.startTimeUnixNano.low>>>0,t.startTimeUnixNano.high>>>0).toNumber():t.startTimeUnixNano),t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&(typeof t.timeUnixNano=="number"?u.timeUnixNano=r.longs===String?String(t.timeUnixNano):t.timeUnixNano:u.timeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.timeUnixNano):r.longs===Number?new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber():t.timeUnixNano),t.count!=null&&t.hasOwnProperty("count")&&(typeof t.count=="number"?u.count=r.longs===String?String(t.count):t.count:u.count=r.longs===String?f.Long.prototype.toString.call(t.count):r.longs===Number?new f.LongBits(t.count.low>>>0,t.count.high>>>0).toNumber():t.count),t.sum!=null&&t.hasOwnProperty("sum")&&(u.sum=r.json&&!isFinite(t.sum)?String(t.sum):t.sum,r.oneofs&&(u._sum="sum")),t.scale!=null&&t.hasOwnProperty("scale")&&(u.scale=t.scale),t.zeroCount!=null&&t.hasOwnProperty("zeroCount")&&(typeof t.zeroCount=="number"?u.zeroCount=r.longs===String?String(t.zeroCount):t.zeroCount:u.zeroCount=r.longs===String?f.Long.prototype.toString.call(t.zeroCount):r.longs===Number?new f.LongBits(t.zeroCount.low>>>0,t.zeroCount.high>>>0).toNumber():t.zeroCount),t.positive!=null&&t.hasOwnProperty("positive")&&(u.positive=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.toObject(t.positive,r)),t.negative!=null&&t.hasOwnProperty("negative")&&(u.negative=p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.toObject(t.negative,r)),t.flags!=null&&t.hasOwnProperty("flags")&&(u.flags=t.flags),t.exemplars&&t.exemplars.length){u.exemplars=[];for(var d=0;d<t.exemplars.length;++d)u.exemplars[d]=p.opentelemetry.proto.metrics.v1.Exemplar.toObject(t.exemplars[d],r)}return t.min!=null&&t.hasOwnProperty("min")&&(u.min=r.json&&!isFinite(t.min)?String(t.min):t.min,r.oneofs&&(u._min="min")),t.max!=null&&t.hasOwnProperty("max")&&(u.max=r.json&&!isFinite(t.max)?String(t.max):t.max,r.oneofs&&(u._max="max")),t.zeroThreshold!=null&&t.hasOwnProperty("zeroThreshold")&&(u.zeroThreshold=r.json&&!isFinite(t.zeroThreshold)?String(t.zeroThreshold):t.zeroThreshold),u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint"},l.Buckets=function(){function e(t){if(this.bucketCounts=[],t)for(var r=Object.keys(t),u=0;u<r.length;++u)t[r[u]]!=null&&(this[r[u]]=t[r[u]])}return e.prototype.offset=null,e.prototype.bucketCounts=f.emptyArray,e.create=function(r){return new e(r)},e.encode=function(r,u){if(u||(u=S.create()),r.offset!=null&&Object.hasOwnProperty.call(r,"offset")&&u.uint32(8).sint32(r.offset),r.bucketCounts!=null&&r.bucketCounts.length){u.uint32(18).fork();for(var s=0;s<r.bucketCounts.length;++s)u.uint64(r.bucketCounts[s]);u.ldelim()}return u},e.encodeDelimited=function(r,u){return this.encode(r,u).ldelim()},e.decode=function(r,u){r instanceof h||(r=h.create(r));for(var s=u===void 0?r.len:r.pos+u,d=new p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets;r.pos<s;){var v=r.uint32();switch(v>>>3){case 1:{d.offset=r.sint32();break}case 2:{if(d.bucketCounts&&d.bucketCounts.length||(d.bucketCounts=[]),(v&7)===2)for(var g=r.uint32()+r.pos;r.pos<g;)d.bucketCounts.push(r.uint64());else d.bucketCounts.push(r.uint64());break}default:r.skipType(v&7);break}}return d},e.decodeDelimited=function(r){return r instanceof h||(r=new h(r)),this.decode(r,r.uint32())},e.verify=function(r){if(typeof r!="object"||r===null)return"object expected";if(r.offset!=null&&r.hasOwnProperty("offset")&&!f.isInteger(r.offset))return"offset: integer expected";if(r.bucketCounts!=null&&r.hasOwnProperty("bucketCounts")){if(!Array.isArray(r.bucketCounts))return"bucketCounts: array expected";for(var u=0;u<r.bucketCounts.length;++u)if(!f.isInteger(r.bucketCounts[u])&&!(r.bucketCounts[u]&&f.isInteger(r.bucketCounts[u].low)&&f.isInteger(r.bucketCounts[u].high)))return"bucketCounts: integer|Long[] expected"}return null},e.fromObject=function(r){if(r instanceof p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets)return r;var u=new p.opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets;if(r.offset!=null&&(u.offset=r.offset|0),r.bucketCounts){if(!Array.isArray(r.bucketCounts))throw TypeError(".opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets.bucketCounts: array expected");u.bucketCounts=[];for(var s=0;s<r.bucketCounts.length;++s)f.Long?(u.bucketCounts[s]=f.Long.fromValue(r.bucketCounts[s])).unsigned=!0:typeof r.bucketCounts[s]=="string"?u.bucketCounts[s]=parseInt(r.bucketCounts[s],10):typeof r.bucketCounts[s]=="number"?u.bucketCounts[s]=r.bucketCounts[s]:typeof r.bucketCounts[s]=="object"&&(u.bucketCounts[s]=new f.LongBits(r.bucketCounts[s].low>>>0,r.bucketCounts[s].high>>>0).toNumber(!0))}return u},e.toObject=function(r,u){u||(u={});var s={};if((u.arrays||u.defaults)&&(s.bucketCounts=[]),u.defaults&&(s.offset=0),r.offset!=null&&r.hasOwnProperty("offset")&&(s.offset=r.offset),r.bucketCounts&&r.bucketCounts.length){s.bucketCounts=[];for(var d=0;d<r.bucketCounts.length;++d)typeof r.bucketCounts[d]=="number"?s.bucketCounts[d]=u.longs===String?String(r.bucketCounts[d]):r.bucketCounts[d]:s.bucketCounts[d]=u.longs===String?f.Long.prototype.toString.call(r.bucketCounts[d]):u.longs===Number?new f.LongBits(r.bucketCounts[d].low>>>0,r.bucketCounts[d].high>>>0).toNumber(!0):r.bucketCounts[d]}return s},e.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},e.getTypeUrl=function(r){return r===void 0&&(r="type.googleapis.com"),r+"/opentelemetry.proto.metrics.v1.ExponentialHistogramDataPoint.Buckets"},e}(),l}(),c.SummaryDataPoint=function(){function l(i){if(this.attributes=[],this.quantileValues=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.attributes=f.emptyArray,l.prototype.startTimeUnixNano=null,l.prototype.timeUnixNano=null,l.prototype.count=null,l.prototype.sum=null,l.prototype.quantileValues=f.emptyArray,l.prototype.flags=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.startTimeUnixNano!=null&&Object.hasOwnProperty.call(e,"startTimeUnixNano")&&t.uint32(17).fixed64(e.startTimeUnixNano),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,"timeUnixNano")&&t.uint32(25).fixed64(e.timeUnixNano),e.count!=null&&Object.hasOwnProperty.call(e,"count")&&t.uint32(33).fixed64(e.count),e.sum!=null&&Object.hasOwnProperty.call(e,"sum")&&t.uint32(41).double(e.sum),e.quantileValues!=null&&e.quantileValues.length)for(var r=0;r<e.quantileValues.length;++r)p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.encode(e.quantileValues[r],t.uint32(50).fork()).ldelim();if(e.attributes!=null&&e.attributes.length)for(var r=0;r<e.attributes.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[r],t.uint32(58).fork()).ldelim();return e.flags!=null&&Object.hasOwnProperty.call(e,"flags")&&t.uint32(64).uint32(e.flags),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.metrics.v1.SummaryDataPoint;e.pos<r;){var s=e.uint32();switch(s>>>3){case 7:{u.attributes&&u.attributes.length||(u.attributes=[]),u.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}case 2:{u.startTimeUnixNano=e.fixed64();break}case 3:{u.timeUnixNano=e.fixed64();break}case 4:{u.count=e.fixed64();break}case 5:{u.sum=e.double();break}case 6:{u.quantileValues&&u.quantileValues.length||(u.quantileValues=[]),u.quantileValues.push(p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.decode(e,e.uint32()));break}case 8:{u.flags=e.uint32();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.attributes!=null&&e.hasOwnProperty("attributes")){if(!Array.isArray(e.attributes))return"attributes: array expected";for(var t=0;t<e.attributes.length;++t){var r=p.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[t]);if(r)return"attributes."+r}}if(e.startTimeUnixNano!=null&&e.hasOwnProperty("startTimeUnixNano")&&!f.isInteger(e.startTimeUnixNano)&&!(e.startTimeUnixNano&&f.isInteger(e.startTimeUnixNano.low)&&f.isInteger(e.startTimeUnixNano.high)))return"startTimeUnixNano: integer|Long expected";if(e.timeUnixNano!=null&&e.hasOwnProperty("timeUnixNano")&&!f.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&f.isInteger(e.timeUnixNano.low)&&f.isInteger(e.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(e.count!=null&&e.hasOwnProperty("count")&&!f.isInteger(e.count)&&!(e.count&&f.isInteger(e.count.low)&&f.isInteger(e.count.high)))return"count: integer|Long expected";if(e.sum!=null&&e.hasOwnProperty("sum")&&typeof e.sum!="number")return"sum: number expected";if(e.quantileValues!=null&&e.hasOwnProperty("quantileValues")){if(!Array.isArray(e.quantileValues))return"quantileValues: array expected";for(var t=0;t<e.quantileValues.length;++t){var r=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.verify(e.quantileValues[t]);if(r)return"quantileValues."+r}}return e.flags!=null&&e.hasOwnProperty("flags")&&!f.isInteger(e.flags)?"flags: integer expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.metrics.v1.SummaryDataPoint)return e;var t=new p.opentelemetry.proto.metrics.v1.SummaryDataPoint;if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(".opentelemetry.proto.metrics.v1.SummaryDataPoint.attributes: array expected");t.attributes=[];for(var r=0;r<e.attributes.length;++r){if(typeof e.attributes[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.SummaryDataPoint.attributes: object expected");t.attributes[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[r])}}if(e.startTimeUnixNano!=null&&(f.Long?(t.startTimeUnixNano=f.Long.fromValue(e.startTimeUnixNano)).unsigned=!1:typeof e.startTimeUnixNano=="string"?t.startTimeUnixNano=parseInt(e.startTimeUnixNano,10):typeof e.startTimeUnixNano=="number"?t.startTimeUnixNano=e.startTimeUnixNano:typeof e.startTimeUnixNano=="object"&&(t.startTimeUnixNano=new f.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber())),e.timeUnixNano!=null&&(f.Long?(t.timeUnixNano=f.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano=="string"?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano=="number"?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano=="object"&&(t.timeUnixNano=new f.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.count!=null&&(f.Long?(t.count=f.Long.fromValue(e.count)).unsigned=!1:typeof e.count=="string"?t.count=parseInt(e.count,10):typeof e.count=="number"?t.count=e.count:typeof e.count=="object"&&(t.count=new f.LongBits(e.count.low>>>0,e.count.high>>>0).toNumber())),e.sum!=null&&(t.sum=Number(e.sum)),e.quantileValues){if(!Array.isArray(e.quantileValues))throw TypeError(".opentelemetry.proto.metrics.v1.SummaryDataPoint.quantileValues: array expected");t.quantileValues=[];for(var r=0;r<e.quantileValues.length;++r){if(typeof e.quantileValues[r]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.SummaryDataPoint.quantileValues: object expected");t.quantileValues[r]=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.fromObject(e.quantileValues[r])}}return e.flags!=null&&(t.flags=e.flags>>>0),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.quantileValues=[],r.attributes=[]),t.defaults){if(f.Long){var u=new f.Long(0,0,!1);r.startTimeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.startTimeUnixNano=t.longs===String?"0":0;if(f.Long){var u=new f.Long(0,0,!1);r.timeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.timeUnixNano=t.longs===String?"0":0;if(f.Long){var u=new f.Long(0,0,!1);r.count=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.count=t.longs===String?"0":0;r.sum=0,r.flags=0}if(e.startTimeUnixNano!=null&&e.hasOwnProperty("startTimeUnixNano")&&(typeof e.startTimeUnixNano=="number"?r.startTimeUnixNano=t.longs===String?String(e.startTimeUnixNano):e.startTimeUnixNano:r.startTimeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.startTimeUnixNano):t.longs===Number?new f.LongBits(e.startTimeUnixNano.low>>>0,e.startTimeUnixNano.high>>>0).toNumber():e.startTimeUnixNano),e.timeUnixNano!=null&&e.hasOwnProperty("timeUnixNano")&&(typeof e.timeUnixNano=="number"?r.timeUnixNano=t.longs===String?String(e.timeUnixNano):e.timeUnixNano:r.timeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new f.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.count!=null&&e.hasOwnProperty("count")&&(typeof e.count=="number"?r.count=t.longs===String?String(e.count):e.count:r.count=t.longs===String?f.Long.prototype.toString.call(e.count):t.longs===Number?new f.LongBits(e.count.low>>>0,e.count.high>>>0).toNumber():e.count),e.sum!=null&&e.hasOwnProperty("sum")&&(r.sum=t.json&&!isFinite(e.sum)?String(e.sum):e.sum),e.quantileValues&&e.quantileValues.length){r.quantileValues=[];for(var s=0;s<e.quantileValues.length;++s)r.quantileValues[s]=p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile.toObject(e.quantileValues[s],t)}if(e.attributes&&e.attributes.length){r.attributes=[];for(var s=0;s<e.attributes.length;++s)r.attributes[s]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[s],t)}return e.flags!=null&&e.hasOwnProperty("flags")&&(r.flags=e.flags),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.metrics.v1.SummaryDataPoint"},l.ValueAtQuantile=function(){function i(e){if(e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}return i.prototype.quantile=null,i.prototype.value=null,i.create=function(t){return new i(t)},i.encode=function(t,r){return r||(r=S.create()),t.quantile!=null&&Object.hasOwnProperty.call(t,"quantile")&&r.uint32(9).double(t.quantile),t.value!=null&&Object.hasOwnProperty.call(t,"value")&&r.uint32(17).double(t.value),r},i.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},i.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile;t.pos<u;){var d=t.uint32();switch(d>>>3){case 1:{s.quantile=t.double();break}case 2:{s.value=t.double();break}default:t.skipType(d&7);break}}return s},i.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},i.verify=function(t){return typeof t!="object"||t===null?"object expected":t.quantile!=null&&t.hasOwnProperty("quantile")&&typeof t.quantile!="number"?"quantile: number expected":t.value!=null&&t.hasOwnProperty("value")&&typeof t.value!="number"?"value: number expected":null},i.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile)return t;var r=new p.opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile;return t.quantile!=null&&(r.quantile=Number(t.quantile)),t.value!=null&&(r.value=Number(t.value)),r},i.toObject=function(t,r){r||(r={});var u={};return r.defaults&&(u.quantile=0,u.value=0),t.quantile!=null&&t.hasOwnProperty("quantile")&&(u.quantile=r.json&&!isFinite(t.quantile)?String(t.quantile):t.quantile),t.value!=null&&t.hasOwnProperty("value")&&(u.value=r.json&&!isFinite(t.value)?String(t.value):t.value),u},i.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},i.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.SummaryDataPoint.ValueAtQuantile"},i}(),l}(),c.Exemplar=function(){function l(e){if(this.filteredAttributes=[],e)for(var t=Object.keys(e),r=0;r<t.length;++r)e[t[r]]!=null&&(this[t[r]]=e[t[r]])}l.prototype.filteredAttributes=f.emptyArray,l.prototype.timeUnixNano=null,l.prototype.asDouble=null,l.prototype.asInt=null,l.prototype.spanId=null,l.prototype.traceId=null;var i;return Object.defineProperty(l.prototype,"value",{get:f.oneOfGetter(i=["asDouble","asInt"]),set:f.oneOfSetter(i)}),l.create=function(t){return new l(t)},l.encode=function(t,r){if(r||(r=S.create()),t.timeUnixNano!=null&&Object.hasOwnProperty.call(t,"timeUnixNano")&&r.uint32(17).fixed64(t.timeUnixNano),t.asDouble!=null&&Object.hasOwnProperty.call(t,"asDouble")&&r.uint32(25).double(t.asDouble),t.spanId!=null&&Object.hasOwnProperty.call(t,"spanId")&&r.uint32(34).bytes(t.spanId),t.traceId!=null&&Object.hasOwnProperty.call(t,"traceId")&&r.uint32(42).bytes(t.traceId),t.asInt!=null&&Object.hasOwnProperty.call(t,"asInt")&&r.uint32(49).sfixed64(t.asInt),t.filteredAttributes!=null&&t.filteredAttributes.length)for(var u=0;u<t.filteredAttributes.length;++u)p.opentelemetry.proto.common.v1.KeyValue.encode(t.filteredAttributes[u],r.uint32(58).fork()).ldelim();return r},l.encodeDelimited=function(t,r){return this.encode(t,r).ldelim()},l.decode=function(t,r){t instanceof h||(t=h.create(t));for(var u=r===void 0?t.len:t.pos+r,s=new p.opentelemetry.proto.metrics.v1.Exemplar;t.pos<u;){var d=t.uint32();switch(d>>>3){case 7:{s.filteredAttributes&&s.filteredAttributes.length||(s.filteredAttributes=[]),s.filteredAttributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(t,t.uint32()));break}case 2:{s.timeUnixNano=t.fixed64();break}case 3:{s.asDouble=t.double();break}case 6:{s.asInt=t.sfixed64();break}case 4:{s.spanId=t.bytes();break}case 5:{s.traceId=t.bytes();break}default:t.skipType(d&7);break}}return s},l.decodeDelimited=function(t){return t instanceof h||(t=new h(t)),this.decode(t,t.uint32())},l.verify=function(t){if(typeof t!="object"||t===null)return"object expected";var r={};if(t.filteredAttributes!=null&&t.hasOwnProperty("filteredAttributes")){if(!Array.isArray(t.filteredAttributes))return"filteredAttributes: array expected";for(var u=0;u<t.filteredAttributes.length;++u){var s=p.opentelemetry.proto.common.v1.KeyValue.verify(t.filteredAttributes[u]);if(s)return"filteredAttributes."+s}}if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&!f.isInteger(t.timeUnixNano)&&!(t.timeUnixNano&&f.isInteger(t.timeUnixNano.low)&&f.isInteger(t.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(t.asDouble!=null&&t.hasOwnProperty("asDouble")&&(r.value=1,typeof t.asDouble!="number"))return"asDouble: number expected";if(t.asInt!=null&&t.hasOwnProperty("asInt")){if(r.value===1)return"value: multiple values";if(r.value=1,!f.isInteger(t.asInt)&&!(t.asInt&&f.isInteger(t.asInt.low)&&f.isInteger(t.asInt.high)))return"asInt: integer|Long expected"}return t.spanId!=null&&t.hasOwnProperty("spanId")&&!(t.spanId&&typeof t.spanId.length=="number"||f.isString(t.spanId))?"spanId: buffer expected":t.traceId!=null&&t.hasOwnProperty("traceId")&&!(t.traceId&&typeof t.traceId.length=="number"||f.isString(t.traceId))?"traceId: buffer expected":null},l.fromObject=function(t){if(t instanceof p.opentelemetry.proto.metrics.v1.Exemplar)return t;var r=new p.opentelemetry.proto.metrics.v1.Exemplar;if(t.filteredAttributes){if(!Array.isArray(t.filteredAttributes))throw TypeError(".opentelemetry.proto.metrics.v1.Exemplar.filteredAttributes: array expected");r.filteredAttributes=[];for(var u=0;u<t.filteredAttributes.length;++u){if(typeof t.filteredAttributes[u]!="object")throw TypeError(".opentelemetry.proto.metrics.v1.Exemplar.filteredAttributes: object expected");r.filteredAttributes[u]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(t.filteredAttributes[u])}}return t.timeUnixNano!=null&&(f.Long?(r.timeUnixNano=f.Long.fromValue(t.timeUnixNano)).unsigned=!1:typeof t.timeUnixNano=="string"?r.timeUnixNano=parseInt(t.timeUnixNano,10):typeof t.timeUnixNano=="number"?r.timeUnixNano=t.timeUnixNano:typeof t.timeUnixNano=="object"&&(r.timeUnixNano=new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber())),t.asDouble!=null&&(r.asDouble=Number(t.asDouble)),t.asInt!=null&&(f.Long?(r.asInt=f.Long.fromValue(t.asInt)).unsigned=!1:typeof t.asInt=="string"?r.asInt=parseInt(t.asInt,10):typeof t.asInt=="number"?r.asInt=t.asInt:typeof t.asInt=="object"&&(r.asInt=new f.LongBits(t.asInt.low>>>0,t.asInt.high>>>0).toNumber())),t.spanId!=null&&(typeof t.spanId=="string"?f.base64.decode(t.spanId,r.spanId=f.newBuffer(f.base64.length(t.spanId)),0):t.spanId.length>=0&&(r.spanId=t.spanId)),t.traceId!=null&&(typeof t.traceId=="string"?f.base64.decode(t.traceId,r.traceId=f.newBuffer(f.base64.length(t.traceId)),0):t.traceId.length>=0&&(r.traceId=t.traceId)),r},l.toObject=function(t,r){r||(r={});var u={};if((r.arrays||r.defaults)&&(u.filteredAttributes=[]),r.defaults){if(f.Long){var s=new f.Long(0,0,!1);u.timeUnixNano=r.longs===String?s.toString():r.longs===Number?s.toNumber():s}else u.timeUnixNano=r.longs===String?"0":0;r.bytes===String?u.spanId="":(u.spanId=[],r.bytes!==Array&&(u.spanId=f.newBuffer(u.spanId))),r.bytes===String?u.traceId="":(u.traceId=[],r.bytes!==Array&&(u.traceId=f.newBuffer(u.traceId)))}if(t.timeUnixNano!=null&&t.hasOwnProperty("timeUnixNano")&&(typeof t.timeUnixNano=="number"?u.timeUnixNano=r.longs===String?String(t.timeUnixNano):t.timeUnixNano:u.timeUnixNano=r.longs===String?f.Long.prototype.toString.call(t.timeUnixNano):r.longs===Number?new f.LongBits(t.timeUnixNano.low>>>0,t.timeUnixNano.high>>>0).toNumber():t.timeUnixNano),t.asDouble!=null&&t.hasOwnProperty("asDouble")&&(u.asDouble=r.json&&!isFinite(t.asDouble)?String(t.asDouble):t.asDouble,r.oneofs&&(u.value="asDouble")),t.spanId!=null&&t.hasOwnProperty("spanId")&&(u.spanId=r.bytes===String?f.base64.encode(t.spanId,0,t.spanId.length):r.bytes===Array?Array.prototype.slice.call(t.spanId):t.spanId),t.traceId!=null&&t.hasOwnProperty("traceId")&&(u.traceId=r.bytes===String?f.base64.encode(t.traceId,0,t.traceId.length):r.bytes===Array?Array.prototype.slice.call(t.traceId):t.traceId),t.asInt!=null&&t.hasOwnProperty("asInt")&&(typeof t.asInt=="number"?u.asInt=r.longs===String?String(t.asInt):t.asInt:u.asInt=r.longs===String?f.Long.prototype.toString.call(t.asInt):r.longs===Number?new f.LongBits(t.asInt.low>>>0,t.asInt.high>>>0).toNumber():t.asInt,r.oneofs&&(u.value="asInt")),t.filteredAttributes&&t.filteredAttributes.length){u.filteredAttributes=[];for(var d=0;d<t.filteredAttributes.length;++d)u.filteredAttributes[d]=p.opentelemetry.proto.common.v1.KeyValue.toObject(t.filteredAttributes[d],r)}return u},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(t){return t===void 0&&(t="type.googleapis.com"),t+"/opentelemetry.proto.metrics.v1.Exemplar"},l}(),c}(),o}(),n.logs=function(){var o={};return o.v1=function(){var c={};return c.LogsData=function(){function l(i){if(this.resourceLogs=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resourceLogs=f.emptyArray,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resourceLogs!=null&&e.resourceLogs.length)for(var r=0;r<e.resourceLogs.length;++r)p.opentelemetry.proto.logs.v1.ResourceLogs.encode(e.resourceLogs[r],t.uint32(10).fork()).ldelim();return t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.logs.v1.LogsData;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resourceLogs&&u.resourceLogs.length||(u.resourceLogs=[]),u.resourceLogs.push(p.opentelemetry.proto.logs.v1.ResourceLogs.decode(e,e.uint32()));break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resourceLogs!=null&&e.hasOwnProperty("resourceLogs")){if(!Array.isArray(e.resourceLogs))return"resourceLogs: array expected";for(var t=0;t<e.resourceLogs.length;++t){var r=p.opentelemetry.proto.logs.v1.ResourceLogs.verify(e.resourceLogs[t]);if(r)return"resourceLogs."+r}}return null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.logs.v1.LogsData)return e;var t=new p.opentelemetry.proto.logs.v1.LogsData;if(e.resourceLogs){if(!Array.isArray(e.resourceLogs))throw TypeError(".opentelemetry.proto.logs.v1.LogsData.resourceLogs: array expected");t.resourceLogs=[];for(var r=0;r<e.resourceLogs.length;++r){if(typeof e.resourceLogs[r]!="object")throw TypeError(".opentelemetry.proto.logs.v1.LogsData.resourceLogs: object expected");t.resourceLogs[r]=p.opentelemetry.proto.logs.v1.ResourceLogs.fromObject(e.resourceLogs[r])}}return t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.resourceLogs=[]),e.resourceLogs&&e.resourceLogs.length){r.resourceLogs=[];for(var u=0;u<e.resourceLogs.length;++u)r.resourceLogs[u]=p.opentelemetry.proto.logs.v1.ResourceLogs.toObject(e.resourceLogs[u],t)}return r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.logs.v1.LogsData"},l}(),c.ResourceLogs=function(){function l(i){if(this.scopeLogs=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.resource=null,l.prototype.scopeLogs=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.resource!=null&&Object.hasOwnProperty.call(e,"resource")&&p.opentelemetry.proto.resource.v1.Resource.encode(e.resource,t.uint32(10).fork()).ldelim(),e.scopeLogs!=null&&e.scopeLogs.length)for(var r=0;r<e.scopeLogs.length;++r)p.opentelemetry.proto.logs.v1.ScopeLogs.encode(e.scopeLogs[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.logs.v1.ResourceLogs;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.resource=p.opentelemetry.proto.resource.v1.Resource.decode(e,e.uint32());break}case 2:{u.scopeLogs&&u.scopeLogs.length||(u.scopeLogs=[]),u.scopeLogs.push(p.opentelemetry.proto.logs.v1.ScopeLogs.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.resource!=null&&e.hasOwnProperty("resource")){var t=p.opentelemetry.proto.resource.v1.Resource.verify(e.resource);if(t)return"resource."+t}if(e.scopeLogs!=null&&e.hasOwnProperty("scopeLogs")){if(!Array.isArray(e.scopeLogs))return"scopeLogs: array expected";for(var r=0;r<e.scopeLogs.length;++r){var t=p.opentelemetry.proto.logs.v1.ScopeLogs.verify(e.scopeLogs[r]);if(t)return"scopeLogs."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.logs.v1.ResourceLogs)return e;var t=new p.opentelemetry.proto.logs.v1.ResourceLogs;if(e.resource!=null){if(typeof e.resource!="object")throw TypeError(".opentelemetry.proto.logs.v1.ResourceLogs.resource: object expected");t.resource=p.opentelemetry.proto.resource.v1.Resource.fromObject(e.resource)}if(e.scopeLogs){if(!Array.isArray(e.scopeLogs))throw TypeError(".opentelemetry.proto.logs.v1.ResourceLogs.scopeLogs: array expected");t.scopeLogs=[];for(var r=0;r<e.scopeLogs.length;++r){if(typeof e.scopeLogs[r]!="object")throw TypeError(".opentelemetry.proto.logs.v1.ResourceLogs.scopeLogs: object expected");t.scopeLogs[r]=p.opentelemetry.proto.logs.v1.ScopeLogs.fromObject(e.scopeLogs[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.scopeLogs=[]),t.defaults&&(r.resource=null,r.schemaUrl=""),e.resource!=null&&e.hasOwnProperty("resource")&&(r.resource=p.opentelemetry.proto.resource.v1.Resource.toObject(e.resource,t)),e.scopeLogs&&e.scopeLogs.length){r.scopeLogs=[];for(var u=0;u<e.scopeLogs.length;++u)r.scopeLogs[u]=p.opentelemetry.proto.logs.v1.ScopeLogs.toObject(e.scopeLogs[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.logs.v1.ResourceLogs"},l}(),c.ScopeLogs=function(){function l(i){if(this.logRecords=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.scope=null,l.prototype.logRecords=f.emptyArray,l.prototype.schemaUrl=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.scope!=null&&Object.hasOwnProperty.call(e,"scope")&&p.opentelemetry.proto.common.v1.InstrumentationScope.encode(e.scope,t.uint32(10).fork()).ldelim(),e.logRecords!=null&&e.logRecords.length)for(var r=0;r<e.logRecords.length;++r)p.opentelemetry.proto.logs.v1.LogRecord.encode(e.logRecords[r],t.uint32(18).fork()).ldelim();return e.schemaUrl!=null&&Object.hasOwnProperty.call(e,"schemaUrl")&&t.uint32(26).string(e.schemaUrl),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.logs.v1.ScopeLogs;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.decode(e,e.uint32());break}case 2:{u.logRecords&&u.logRecords.length||(u.logRecords=[]),u.logRecords.push(p.opentelemetry.proto.logs.v1.LogRecord.decode(e,e.uint32()));break}case 3:{u.schemaUrl=e.string();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.scope!=null&&e.hasOwnProperty("scope")){var t=p.opentelemetry.proto.common.v1.InstrumentationScope.verify(e.scope);if(t)return"scope."+t}if(e.logRecords!=null&&e.hasOwnProperty("logRecords")){if(!Array.isArray(e.logRecords))return"logRecords: array expected";for(var r=0;r<e.logRecords.length;++r){var t=p.opentelemetry.proto.logs.v1.LogRecord.verify(e.logRecords[r]);if(t)return"logRecords."+t}}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&!f.isString(e.schemaUrl)?"schemaUrl: string expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.logs.v1.ScopeLogs)return e;var t=new p.opentelemetry.proto.logs.v1.ScopeLogs;if(e.scope!=null){if(typeof e.scope!="object")throw TypeError(".opentelemetry.proto.logs.v1.ScopeLogs.scope: object expected");t.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.fromObject(e.scope)}if(e.logRecords){if(!Array.isArray(e.logRecords))throw TypeError(".opentelemetry.proto.logs.v1.ScopeLogs.logRecords: array expected");t.logRecords=[];for(var r=0;r<e.logRecords.length;++r){if(typeof e.logRecords[r]!="object")throw TypeError(".opentelemetry.proto.logs.v1.ScopeLogs.logRecords: object expected");t.logRecords[r]=p.opentelemetry.proto.logs.v1.LogRecord.fromObject(e.logRecords[r])}}return e.schemaUrl!=null&&(t.schemaUrl=String(e.schemaUrl)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.logRecords=[]),t.defaults&&(r.scope=null,r.schemaUrl=""),e.scope!=null&&e.hasOwnProperty("scope")&&(r.scope=p.opentelemetry.proto.common.v1.InstrumentationScope.toObject(e.scope,t)),e.logRecords&&e.logRecords.length){r.logRecords=[];for(var u=0;u<e.logRecords.length;++u)r.logRecords[u]=p.opentelemetry.proto.logs.v1.LogRecord.toObject(e.logRecords[u],t)}return e.schemaUrl!=null&&e.hasOwnProperty("schemaUrl")&&(r.schemaUrl=e.schemaUrl),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.logs.v1.ScopeLogs"},l}(),c.SeverityNumber=function(){var l={},i=Object.create(l);return i[l[0]="SEVERITY_NUMBER_UNSPECIFIED"]=0,i[l[1]="SEVERITY_NUMBER_TRACE"]=1,i[l[2]="SEVERITY_NUMBER_TRACE2"]=2,i[l[3]="SEVERITY_NUMBER_TRACE3"]=3,i[l[4]="SEVERITY_NUMBER_TRACE4"]=4,i[l[5]="SEVERITY_NUMBER_DEBUG"]=5,i[l[6]="SEVERITY_NUMBER_DEBUG2"]=6,i[l[7]="SEVERITY_NUMBER_DEBUG3"]=7,i[l[8]="SEVERITY_NUMBER_DEBUG4"]=8,i[l[9]="SEVERITY_NUMBER_INFO"]=9,i[l[10]="SEVERITY_NUMBER_INFO2"]=10,i[l[11]="SEVERITY_NUMBER_INFO3"]=11,i[l[12]="SEVERITY_NUMBER_INFO4"]=12,i[l[13]="SEVERITY_NUMBER_WARN"]=13,i[l[14]="SEVERITY_NUMBER_WARN2"]=14,i[l[15]="SEVERITY_NUMBER_WARN3"]=15,i[l[16]="SEVERITY_NUMBER_WARN4"]=16,i[l[17]="SEVERITY_NUMBER_ERROR"]=17,i[l[18]="SEVERITY_NUMBER_ERROR2"]=18,i[l[19]="SEVERITY_NUMBER_ERROR3"]=19,i[l[20]="SEVERITY_NUMBER_ERROR4"]=20,i[l[21]="SEVERITY_NUMBER_FATAL"]=21,i[l[22]="SEVERITY_NUMBER_FATAL2"]=22,i[l[23]="SEVERITY_NUMBER_FATAL3"]=23,i[l[24]="SEVERITY_NUMBER_FATAL4"]=24,i}(),c.LogRecordFlags=function(){var l={},i=Object.create(l);return i[l[0]="LOG_RECORD_FLAGS_DO_NOT_USE"]=0,i[l[255]="LOG_RECORD_FLAGS_TRACE_FLAGS_MASK"]=255,i}(),c.LogRecord=function(){function l(i){if(this.attributes=[],i)for(var e=Object.keys(i),t=0;t<e.length;++t)i[e[t]]!=null&&(this[e[t]]=i[e[t]])}return l.prototype.timeUnixNano=null,l.prototype.observedTimeUnixNano=null,l.prototype.severityNumber=null,l.prototype.severityText=null,l.prototype.body=null,l.prototype.attributes=f.emptyArray,l.prototype.droppedAttributesCount=null,l.prototype.flags=null,l.prototype.traceId=null,l.prototype.spanId=null,l.create=function(e){return new l(e)},l.encode=function(e,t){if(t||(t=S.create()),e.timeUnixNano!=null&&Object.hasOwnProperty.call(e,"timeUnixNano")&&t.uint32(9).fixed64(e.timeUnixNano),e.severityNumber!=null&&Object.hasOwnProperty.call(e,"severityNumber")&&t.uint32(16).int32(e.severityNumber),e.severityText!=null&&Object.hasOwnProperty.call(e,"severityText")&&t.uint32(26).string(e.severityText),e.body!=null&&Object.hasOwnProperty.call(e,"body")&&p.opentelemetry.proto.common.v1.AnyValue.encode(e.body,t.uint32(42).fork()).ldelim(),e.attributes!=null&&e.attributes.length)for(var r=0;r<e.attributes.length;++r)p.opentelemetry.proto.common.v1.KeyValue.encode(e.attributes[r],t.uint32(50).fork()).ldelim();return e.droppedAttributesCount!=null&&Object.hasOwnProperty.call(e,"droppedAttributesCount")&&t.uint32(56).uint32(e.droppedAttributesCount),e.flags!=null&&Object.hasOwnProperty.call(e,"flags")&&t.uint32(69).fixed32(e.flags),e.traceId!=null&&Object.hasOwnProperty.call(e,"traceId")&&t.uint32(74).bytes(e.traceId),e.spanId!=null&&Object.hasOwnProperty.call(e,"spanId")&&t.uint32(82).bytes(e.spanId),e.observedTimeUnixNano!=null&&Object.hasOwnProperty.call(e,"observedTimeUnixNano")&&t.uint32(89).fixed64(e.observedTimeUnixNano),t},l.encodeDelimited=function(e,t){return this.encode(e,t).ldelim()},l.decode=function(e,t){e instanceof h||(e=h.create(e));for(var r=t===void 0?e.len:e.pos+t,u=new p.opentelemetry.proto.logs.v1.LogRecord;e.pos<r;){var s=e.uint32();switch(s>>>3){case 1:{u.timeUnixNano=e.fixed64();break}case 11:{u.observedTimeUnixNano=e.fixed64();break}case 2:{u.severityNumber=e.int32();break}case 3:{u.severityText=e.string();break}case 5:{u.body=p.opentelemetry.proto.common.v1.AnyValue.decode(e,e.uint32());break}case 6:{u.attributes&&u.attributes.length||(u.attributes=[]),u.attributes.push(p.opentelemetry.proto.common.v1.KeyValue.decode(e,e.uint32()));break}case 7:{u.droppedAttributesCount=e.uint32();break}case 8:{u.flags=e.fixed32();break}case 9:{u.traceId=e.bytes();break}case 10:{u.spanId=e.bytes();break}default:e.skipType(s&7);break}}return u},l.decodeDelimited=function(e){return e instanceof h||(e=new h(e)),this.decode(e,e.uint32())},l.verify=function(e){if(typeof e!="object"||e===null)return"object expected";if(e.timeUnixNano!=null&&e.hasOwnProperty("timeUnixNano")&&!f.isInteger(e.timeUnixNano)&&!(e.timeUnixNano&&f.isInteger(e.timeUnixNano.low)&&f.isInteger(e.timeUnixNano.high)))return"timeUnixNano: integer|Long expected";if(e.observedTimeUnixNano!=null&&e.hasOwnProperty("observedTimeUnixNano")&&!f.isInteger(e.observedTimeUnixNano)&&!(e.observedTimeUnixNano&&f.isInteger(e.observedTimeUnixNano.low)&&f.isInteger(e.observedTimeUnixNano.high)))return"observedTimeUnixNano: integer|Long expected";if(e.severityNumber!=null&&e.hasOwnProperty("severityNumber"))switch(e.severityNumber){default:return"severityNumber: enum value expected";case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:case 8:case 9:case 10:case 11:case 12:case 13:case 14:case 15:case 16:case 17:case 18:case 19:case 20:case 21:case 22:case 23:case 24:break}if(e.severityText!=null&&e.hasOwnProperty("severityText")&&!f.isString(e.severityText))return"severityText: string expected";if(e.body!=null&&e.hasOwnProperty("body")){var t=p.opentelemetry.proto.common.v1.AnyValue.verify(e.body);if(t)return"body."+t}if(e.attributes!=null&&e.hasOwnProperty("attributes")){if(!Array.isArray(e.attributes))return"attributes: array expected";for(var r=0;r<e.attributes.length;++r){var t=p.opentelemetry.proto.common.v1.KeyValue.verify(e.attributes[r]);if(t)return"attributes."+t}}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&!f.isInteger(e.droppedAttributesCount)?"droppedAttributesCount: integer expected":e.flags!=null&&e.hasOwnProperty("flags")&&!f.isInteger(e.flags)?"flags: integer expected":e.traceId!=null&&e.hasOwnProperty("traceId")&&!(e.traceId&&typeof e.traceId.length=="number"||f.isString(e.traceId))?"traceId: buffer expected":e.spanId!=null&&e.hasOwnProperty("spanId")&&!(e.spanId&&typeof e.spanId.length=="number"||f.isString(e.spanId))?"spanId: buffer expected":null},l.fromObject=function(e){if(e instanceof p.opentelemetry.proto.logs.v1.LogRecord)return e;var t=new p.opentelemetry.proto.logs.v1.LogRecord;switch(e.timeUnixNano!=null&&(f.Long?(t.timeUnixNano=f.Long.fromValue(e.timeUnixNano)).unsigned=!1:typeof e.timeUnixNano=="string"?t.timeUnixNano=parseInt(e.timeUnixNano,10):typeof e.timeUnixNano=="number"?t.timeUnixNano=e.timeUnixNano:typeof e.timeUnixNano=="object"&&(t.timeUnixNano=new f.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber())),e.observedTimeUnixNano!=null&&(f.Long?(t.observedTimeUnixNano=f.Long.fromValue(e.observedTimeUnixNano)).unsigned=!1:typeof e.observedTimeUnixNano=="string"?t.observedTimeUnixNano=parseInt(e.observedTimeUnixNano,10):typeof e.observedTimeUnixNano=="number"?t.observedTimeUnixNano=e.observedTimeUnixNano:typeof e.observedTimeUnixNano=="object"&&(t.observedTimeUnixNano=new f.LongBits(e.observedTimeUnixNano.low>>>0,e.observedTimeUnixNano.high>>>0).toNumber())),e.severityNumber){default:if(typeof e.severityNumber=="number"){t.severityNumber=e.severityNumber;break}break;case"SEVERITY_NUMBER_UNSPECIFIED":case 0:t.severityNumber=0;break;case"SEVERITY_NUMBER_TRACE":case 1:t.severityNumber=1;break;case"SEVERITY_NUMBER_TRACE2":case 2:t.severityNumber=2;break;case"SEVERITY_NUMBER_TRACE3":case 3:t.severityNumber=3;break;case"SEVERITY_NUMBER_TRACE4":case 4:t.severityNumber=4;break;case"SEVERITY_NUMBER_DEBUG":case 5:t.severityNumber=5;break;case"SEVERITY_NUMBER_DEBUG2":case 6:t.severityNumber=6;break;case"SEVERITY_NUMBER_DEBUG3":case 7:t.severityNumber=7;break;case"SEVERITY_NUMBER_DEBUG4":case 8:t.severityNumber=8;break;case"SEVERITY_NUMBER_INFO":case 9:t.severityNumber=9;break;case"SEVERITY_NUMBER_INFO2":case 10:t.severityNumber=10;break;case"SEVERITY_NUMBER_INFO3":case 11:t.severityNumber=11;break;case"SEVERITY_NUMBER_INFO4":case 12:t.severityNumber=12;break;case"SEVERITY_NUMBER_WARN":case 13:t.severityNumber=13;break;case"SEVERITY_NUMBER_WARN2":case 14:t.severityNumber=14;break;case"SEVERITY_NUMBER_WARN3":case 15:t.severityNumber=15;break;case"SEVERITY_NUMBER_WARN4":case 16:t.severityNumber=16;break;case"SEVERITY_NUMBER_ERROR":case 17:t.severityNumber=17;break;case"SEVERITY_NUMBER_ERROR2":case 18:t.severityNumber=18;break;case"SEVERITY_NUMBER_ERROR3":case 19:t.severityNumber=19;break;case"SEVERITY_NUMBER_ERROR4":case 20:t.severityNumber=20;break;case"SEVERITY_NUMBER_FATAL":case 21:t.severityNumber=21;break;case"SEVERITY_NUMBER_FATAL2":case 22:t.severityNumber=22;break;case"SEVERITY_NUMBER_FATAL3":case 23:t.severityNumber=23;break;case"SEVERITY_NUMBER_FATAL4":case 24:t.severityNumber=24;break}if(e.severityText!=null&&(t.severityText=String(e.severityText)),e.body!=null){if(typeof e.body!="object")throw TypeError(".opentelemetry.proto.logs.v1.LogRecord.body: object expected");t.body=p.opentelemetry.proto.common.v1.AnyValue.fromObject(e.body)}if(e.attributes){if(!Array.isArray(e.attributes))throw TypeError(".opentelemetry.proto.logs.v1.LogRecord.attributes: array expected");t.attributes=[];for(var r=0;r<e.attributes.length;++r){if(typeof e.attributes[r]!="object")throw TypeError(".opentelemetry.proto.logs.v1.LogRecord.attributes: object expected");t.attributes[r]=p.opentelemetry.proto.common.v1.KeyValue.fromObject(e.attributes[r])}}return e.droppedAttributesCount!=null&&(t.droppedAttributesCount=e.droppedAttributesCount>>>0),e.flags!=null&&(t.flags=e.flags>>>0),e.traceId!=null&&(typeof e.traceId=="string"?f.base64.decode(e.traceId,t.traceId=f.newBuffer(f.base64.length(e.traceId)),0):e.traceId.length>=0&&(t.traceId=e.traceId)),e.spanId!=null&&(typeof e.spanId=="string"?f.base64.decode(e.spanId,t.spanId=f.newBuffer(f.base64.length(e.spanId)),0):e.spanId.length>=0&&(t.spanId=e.spanId)),t},l.toObject=function(e,t){t||(t={});var r={};if((t.arrays||t.defaults)&&(r.attributes=[]),t.defaults){if(f.Long){var u=new f.Long(0,0,!1);r.timeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.timeUnixNano=t.longs===String?"0":0;if(r.severityNumber=t.enums===String?"SEVERITY_NUMBER_UNSPECIFIED":0,r.severityText="",r.body=null,r.droppedAttributesCount=0,r.flags=0,t.bytes===String?r.traceId="":(r.traceId=[],t.bytes!==Array&&(r.traceId=f.newBuffer(r.traceId))),t.bytes===String?r.spanId="":(r.spanId=[],t.bytes!==Array&&(r.spanId=f.newBuffer(r.spanId))),f.Long){var u=new f.Long(0,0,!1);r.observedTimeUnixNano=t.longs===String?u.toString():t.longs===Number?u.toNumber():u}else r.observedTimeUnixNano=t.longs===String?"0":0}if(e.timeUnixNano!=null&&e.hasOwnProperty("timeUnixNano")&&(typeof e.timeUnixNano=="number"?r.timeUnixNano=t.longs===String?String(e.timeUnixNano):e.timeUnixNano:r.timeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.timeUnixNano):t.longs===Number?new f.LongBits(e.timeUnixNano.low>>>0,e.timeUnixNano.high>>>0).toNumber():e.timeUnixNano),e.severityNumber!=null&&e.hasOwnProperty("severityNumber")&&(r.severityNumber=t.enums===String?p.opentelemetry.proto.logs.v1.SeverityNumber[e.severityNumber]===void 0?e.severityNumber:p.opentelemetry.proto.logs.v1.SeverityNumber[e.severityNumber]:e.severityNumber),e.severityText!=null&&e.hasOwnProperty("severityText")&&(r.severityText=e.severityText),e.body!=null&&e.hasOwnProperty("body")&&(r.body=p.opentelemetry.proto.common.v1.AnyValue.toObject(e.body,t)),e.attributes&&e.attributes.length){r.attributes=[];for(var s=0;s<e.attributes.length;++s)r.attributes[s]=p.opentelemetry.proto.common.v1.KeyValue.toObject(e.attributes[s],t)}return e.droppedAttributesCount!=null&&e.hasOwnProperty("droppedAttributesCount")&&(r.droppedAttributesCount=e.droppedAttributesCount),e.flags!=null&&e.hasOwnProperty("flags")&&(r.flags=e.flags),e.traceId!=null&&e.hasOwnProperty("traceId")&&(r.traceId=t.bytes===String?f.base64.encode(e.traceId,0,e.traceId.length):t.bytes===Array?Array.prototype.slice.call(e.traceId):e.traceId),e.spanId!=null&&e.hasOwnProperty("spanId")&&(r.spanId=t.bytes===String?f.base64.encode(e.spanId,0,e.spanId.length):t.bytes===Array?Array.prototype.slice.call(e.spanId):e.spanId),e.observedTimeUnixNano!=null&&e.hasOwnProperty("observedTimeUnixNano")&&(typeof e.observedTimeUnixNano=="number"?r.observedTimeUnixNano=t.longs===String?String(e.observedTimeUnixNano):e.observedTimeUnixNano:r.observedTimeUnixNano=t.longs===String?f.Long.prototype.toString.call(e.observedTimeUnixNano):t.longs===Number?new f.LongBits(e.observedTimeUnixNano.low>>>0,e.observedTimeUnixNano.high>>>0).toNumber():e.observedTimeUnixNano),r},l.prototype.toJSON=function(){return this.constructor.toObject(this,E.util.toJSONOptions)},l.getTypeUrl=function(e){return e===void 0&&(e="type.googleapis.com"),e+"/opentelemetry.proto.logs.v1.LogRecord"},l}(),c}(),o}(),n}(),a}();Ol.exports=p});var To=m(Re=>{"use strict";Object.defineProperty(Re,"__esModule",{value:!0});Re.ServiceClientType=void 0;var Uf;(function(a){a[a.SPANS=0]="SPANS",a[a.METRICS=1]="METRICS",a[a.LOGS=2]="LOGS"})(Uf=Re.ServiceClientType||(Re.ServiceClientType={}))});var go=m(Fr=>{"use strict";Object.defineProperty(Fr,"__esModule",{value:!0});Fr.getExportRequestProto=void 0;var Oo=gl(),Al=To();function Mf(a){return a===Al.ServiceClientType.SPANS?Oo.opentelemetry.proto.collector.trace.v1.ExportTraceServiceRequest:a===Al.ServiceClientType.LOGS?Oo.opentelemetry.proto.collector.logs.v1.ExportLogsServiceRequest:Oo.opentelemetry.proto.collector.metrics.v1.ExportMetricsServiceRequest}Fr.getExportRequestProto=Mf});var Nl=m(qr=>{"use strict";Object.defineProperty(qr,"__esModule",{value:!0});qr.OTLPProtoExporterBrowserBase=void 0;var Df=(b(),D(y)),Ao=gu(),Vf=go(),No=class extends Ao.OTLPExporterBrowserBase{constructor(n={}){super(n)}send(n,o,c){if(this._shutdownOnce.isCalled){Df.diag.debug("Shutdown already started. Cannot send objects");return}let l=this.convert(n),i=(0,Vf.getExportRequestProto)(this.getServiceClientType()),e=i.create(l);if(e){let t=i.encode(e).finish();t&&(0,Ao.sendWithXhr)(new Blob([t],{type:"application/x-protobuf"}),this.url,Object.assign(Object.assign({},this._headers),{"Content-Type":"application/x-protobuf",Accept:"application/x-protobuf"}),this.timeoutMillis,o,c)}else c(new Ao.OTLPExporterError("No proto"))}};qr.OTLPProtoExporterBrowserBase=No});var Pl=m(le=>{"use strict";Object.defineProperty(le,"__esModule",{value:!0});le.ServiceClientType=le.OTLPProtoExporterBrowserBase=void 0;var kf=Nl();Object.defineProperty(le,"OTLPProtoExporterBrowserBase",{enumerable:!0,get:function(){return kf.OTLPProtoExporterBrowserBase}});var Bf=To();Object.defineProperty(le,"ServiceClientType",{enumerable:!0,get:function(){return Bf.ServiceClientType}})});b();var Qt=N(V());b();var C=N(V()),gt=N(Ot());var Vi="exception";var Hs=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},js=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},ki=function(){function a(n,o,c,l,i,e,t,r,u,s){t===void 0&&(t=[]),this.attributes={},this.links=[],this.events=[],this._droppedAttributesCount=0,this._droppedEventsCount=0,this._droppedLinksCount=0,this.status={code:y.SpanStatusCode.UNSET},this.endTime=[0,0],this._ended=!1,this._duration=[-1,-1],this.name=c,this._spanContext=l,this.parentSpanId=e,this.kind=i,this.links=t;var d=Date.now();this._performanceStartTime=C.otperformance.now(),this._performanceOffset=d-(this._performanceStartTime+(0,C.getTimeOrigin)()),this._startTimeProvided=r!=null,this.startTime=this._getTime(r??d),this.resource=n.resource,this.instrumentationLibrary=n.instrumentationLibrary,this._spanLimits=n.getSpanLimits(),s!=null&&this.setAttributes(s),this._spanProcessor=n.getActiveSpanProcessor(),this._spanProcessor.onStart(this,o),this._attributeValueLengthLimit=this._spanLimits.attributeValueLengthLimit||0}return a.prototype.spanContext=function(){return this._spanContext},a.prototype.setAttribute=function(n,o){return o==null||this._isSpanEnded()?this:n.length===0?(y.diag.warn("Invalid attribute key: "+n),this):(0,C.isAttributeValue)(o)?Object.keys(this.attributes).length>=this._spanLimits.attributeCountLimit&&!Object.prototype.hasOwnProperty.call(this.attributes,n)?(this._droppedAttributesCount++,this):(this.attributes[n]=this._truncateToSize(o),this):(y.diag.warn("Invalid attribute value set for key: "+n),this)},a.prototype.setAttributes=function(n){var o,c;try{for(var l=Hs(Object.entries(n)),i=l.next();!i.done;i=l.next()){var e=js(i.value,2),t=e[0],r=e[1];this.setAttribute(t,r)}}catch(u){o={error:u}}finally{try{i&&!i.done&&(c=l.return)&&c.call(l)}finally{if(o)throw o.error}}return this},a.prototype.addEvent=function(n,o,c){if(this._isSpanEnded())return this;if(this._spanLimits.eventCountLimit===0)return y.diag.warn("No events allowed."),this._droppedEventsCount++,this;this.events.length>=this._spanLimits.eventCountLimit&&(y.diag.warn("Dropping extra events."),this.events.shift(),this._droppedEventsCount++),(0,C.isTimeInput)(o)&&((0,C.isTimeInput)(c)||(c=o),o=void 0);var l=(0,C.sanitizeAttributes)(o);return this.events.push({name:n,attributes:l,time:this._getTime(c),droppedAttributesCount:0}),this},a.prototype.setStatus=function(n){return this._isSpanEnded()?this:(this.status=n,this)},a.prototype.updateName=function(n){return this._isSpanEnded()?this:(this.name=n,this)},a.prototype.end=function(n){if(this._isSpanEnded()){y.diag.error(this.name+" "+this._spanContext.traceId+"-"+this._spanContext.spanId+" - You can only call end() on a span once.");return}this._ended=!0,this.endTime=this._getTime(n),this._duration=(0,C.hrTimeDuration)(this.startTime,this.endTime),this._duration[0]<0&&(y.diag.warn("Inconsistent start and end time, startTime > endTime. Setting span duration to 0ms.",this.startTime,this.endTime),this.endTime=this.startTime.slice(),this._duration=[0,0]),this._spanProcessor.onEnd(this)},a.prototype._getTime=function(n){if(typeof n=="number"&&n<C.otperformance.now())return(0,C.hrTime)(n+this._performanceOffset);if(typeof n=="number")return(0,C.millisToHrTime)(n);if(n instanceof Date)return(0,C.millisToHrTime)(n.getTime());if((0,C.isTimeInputHrTime)(n))return n;if(this._startTimeProvided)return(0,C.millisToHrTime)(Date.now());var o=C.otperformance.now()-this._performanceStartTime;return(0,C.addHrTimes)(this.startTime,(0,C.millisToHrTime)(o))},a.prototype.isRecording=function(){return this._ended===!1},a.prototype.recordException=function(n,o){var c={};typeof n=="string"?c[gt.SemanticAttributes.EXCEPTION_MESSAGE]=n:n&&(n.code?c[gt.SemanticAttributes.EXCEPTION_TYPE]=n.code.toString():n.name&&(c[gt.SemanticAttributes.EXCEPTION_TYPE]=n.name),n.message&&(c[gt.SemanticAttributes.EXCEPTION_MESSAGE]=n.message),n.stack&&(c[gt.SemanticAttributes.EXCEPTION_STACKTRACE]=n.stack)),c[gt.SemanticAttributes.EXCEPTION_TYPE]||c[gt.SemanticAttributes.EXCEPTION_MESSAGE]?this.addEvent(Vi,c,o):y.diag.warn("Failed to record an exception "+n)},Object.defineProperty(a.prototype,"duration",{get:function(){return this._duration},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"ended",{get:function(){return this._ended},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"droppedAttributesCount",{get:function(){return this._droppedAttributesCount},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"droppedEventsCount",{get:function(){return this._droppedEventsCount},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"droppedLinksCount",{get:function(){return this._droppedLinksCount},enumerable:!1,configurable:!0}),a.prototype._isSpanEnded=function(){return this._ended&&y.diag.warn("Can not execute the operation on ended Span {traceId: "+this._spanContext.traceId+", spanId: "+this._spanContext.spanId+"}"),this._ended},a.prototype._truncateToLimitUtil=function(n,o){return n.length<=o?n:n.substr(0,o)},a.prototype._truncateToSize=function(n){var o=this,c=this._attributeValueLengthLimit;return c<=0?(y.diag.warn("Attribute value limit must be positive, got "+c),n):typeof n=="string"?this._truncateToLimitUtil(n,c):Array.isArray(n)?n.map(function(l){return typeof l=="string"?o._truncateToLimitUtil(l,c):l}):n},a}();b();var G=N(V());var pt;(function(a){a[a.NOT_RECORD=0]="NOT_RECORD",a[a.RECORD=1]="RECORD",a[a.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED"})(pt||(pt={}));var ft=function(){function a(){}return a.prototype.shouldSample=function(){return{decision:pt.NOT_RECORD}},a.prototype.toString=function(){return"AlwaysOffSampler"},a}();var $=function(){function a(){}return a.prototype.shouldSample=function(){return{decision:pt.RECORD_AND_SAMPLED}},a.prototype.toString=function(){return"AlwaysOnSampler"},a}();b();var Bi=N(V());var At=function(){function a(n){var o,c,l,i;this._root=n.root,this._root||((0,Bi.globalErrorHandler)(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new $),this._remoteParentSampled=(o=n.remoteParentSampled)!==null&&o!==void 0?o:new $,this._remoteParentNotSampled=(c=n.remoteParentNotSampled)!==null&&c!==void 0?c:new ft,this._localParentSampled=(l=n.localParentSampled)!==null&&l!==void 0?l:new $,this._localParentNotSampled=(i=n.localParentNotSampled)!==null&&i!==void 0?i:new ft}return a.prototype.shouldSample=function(n,o,c,l,i,e){var t=y.trace.getSpanContext(n);return!t||!(0,y.isSpanContextValid)(t)?this._root.shouldSample(n,o,c,l,i,e):t.isRemote?t.traceFlags&y.TraceFlags.SAMPLED?this._remoteParentSampled.shouldSample(n,o,c,l,i,e):this._remoteParentNotSampled.shouldSample(n,o,c,l,i,e):t.traceFlags&y.TraceFlags.SAMPLED?this._localParentSampled.shouldSample(n,o,c,l,i,e):this._localParentNotSampled.shouldSample(n,o,c,l,i,e)},a.prototype.toString=function(){return"ParentBased{root="+this._root.toString()+", remoteParentSampled="+this._remoteParentSampled.toString()+", remoteParentNotSampled="+this._remoteParentNotSampled.toString()+", localParentSampled="+this._localParentSampled.toString()+", localParentNotSampled="+this._localParentNotSampled.toString()+"}"},a}();b();var Jt=function(){function a(n){n===void 0&&(n=0),this._ratio=n,this._ratio=this._normalize(n),this._upperBound=Math.floor(this._ratio*4294967295)}return a.prototype.shouldSample=function(n,o){return{decision:(0,y.isValidTraceId)(o)&&this._accumulate(o)<this._upperBound?pt.RECORD_AND_SAMPLED:pt.NOT_RECORD}},a.prototype.toString=function(){return"TraceIdRatioBased{"+this._ratio+"}"},a.prototype._normalize=function(n){return typeof n!="number"||isNaN(n)?0:n>=1?1:n<=0?0:n},a.prototype._accumulate=function(n){for(var o=0,c=0;c<n.length/8;c++){var l=c*8,i=parseInt(n.slice(l,l+8),16);o=(o^i)>>>0}return o},a}();var Fs=(0,G.getEnv)(),qs=G.TracesSamplerValues.AlwaysOn,zt=1;function fr(){return{sampler:In(Fs),forceFlushTimeoutMillis:3e4,generalLimits:{attributeValueLengthLimit:(0,G.getEnv)().OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:(0,G.getEnv)().OTEL_ATTRIBUTE_COUNT_LIMIT},spanLimits:{attributeValueLengthLimit:(0,G.getEnv)().OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:(0,G.getEnv)().OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT,linkCountLimit:(0,G.getEnv)().OTEL_SPAN_LINK_COUNT_LIMIT,eventCountLimit:(0,G.getEnv)().OTEL_SPAN_EVENT_COUNT_LIMIT,attributePerEventCountLimit:(0,G.getEnv)().OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT,attributePerLinkCountLimit:(0,G.getEnv)().OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT}}}function In(a){switch(a===void 0&&(a=(0,G.getEnv)()),a.OTEL_TRACES_SAMPLER){case G.TracesSamplerValues.AlwaysOn:return new $;case G.TracesSamplerValues.AlwaysOff:return new ft;case G.TracesSamplerValues.ParentBasedAlwaysOn:return new At({root:new $});case G.TracesSamplerValues.ParentBasedAlwaysOff:return new At({root:new ft});case G.TracesSamplerValues.TraceIdRatio:return new Jt(Gi(a));case G.TracesSamplerValues.ParentBasedTraceIdRatio:return new At({root:new Jt(Gi(a))});default:return y.diag.error('OTEL_TRACES_SAMPLER value "'+a.OTEL_TRACES_SAMPLER+" invalid, defaulting to "+qs+'".'),new $}}function Gi(a){if(a.OTEL_TRACES_SAMPLER_ARG===void 0||a.OTEL_TRACES_SAMPLER_ARG==="")return y.diag.error("OTEL_TRACES_SAMPLER_ARG is blank, defaulting to "+zt+"."),zt;var n=Number(a.OTEL_TRACES_SAMPLER_ARG);return isNaN(n)?(y.diag.error("OTEL_TRACES_SAMPLER_ARG="+a.OTEL_TRACES_SAMPLER_ARG+" was given, but it is invalid, defaulting to "+zt+"."),zt):n<0||n>1?(y.diag.error("OTEL_TRACES_SAMPLER_ARG="+a.OTEL_TRACES_SAMPLER_ARG+" was given, but it is out of range ([0..1]), defaulting to "+zt+"."),zt):n}var Wt=N(V());function Hi(a){var n={sampler:In()},o=fr(),c=Object.assign({},o,n,a);return c.generalLimits=Object.assign({},o.generalLimits,a.generalLimits||{}),c.spanLimits=Object.assign({},o.spanLimits,a.spanLimits||{}),c}function ji(a){var n,o,c,l,i,e,t,r,u,s,d,v,g=Object.assign({},a.spanLimits),x=(0,Wt.getEnvWithoutDefaults)();return g.attributeCountLimit=(e=(i=(l=(o=(n=a.spanLimits)===null||n===void 0?void 0:n.attributeCountLimit)!==null&&o!==void 0?o:(c=a.generalLimits)===null||c===void 0?void 0:c.attributeCountLimit)!==null&&l!==void 0?l:x.OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT)!==null&&i!==void 0?i:x.OTEL_ATTRIBUTE_COUNT_LIMIT)!==null&&e!==void 0?e:Wt.DEFAULT_ATTRIBUTE_COUNT_LIMIT,g.attributeValueLengthLimit=(v=(d=(s=(r=(t=a.spanLimits)===null||t===void 0?void 0:t.attributeValueLengthLimit)!==null&&r!==void 0?r:(u=a.generalLimits)===null||u===void 0?void 0:u.attributeValueLengthLimit)!==null&&s!==void 0?s:x.OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT)!==null&&d!==void 0?d:x.OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT)!==null&&v!==void 0?v:Wt.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT,Object.assign({},a,{spanLimits:g})}b();var W=N(V()),Fi=function(){function a(n,o){this._exporter=n,this._isExporting=!1,this._finishedSpans=[],this._droppedSpansCount=0;var c=(0,W.getEnv)();this._maxExportBatchSize=typeof o?.maxExportBatchSize=="number"?o.maxExportBatchSize:c.OTEL_BSP_MAX_EXPORT_BATCH_SIZE,this._maxQueueSize=typeof o?.maxQueueSize=="number"?o.maxQueueSize:c.OTEL_BSP_MAX_QUEUE_SIZE,this._scheduledDelayMillis=typeof o?.scheduledDelayMillis=="number"?o.scheduledDelayMillis:c.OTEL_BSP_SCHEDULE_DELAY,this._exportTimeoutMillis=typeof o?.exportTimeoutMillis=="number"?o.exportTimeoutMillis:c.OTEL_BSP_EXPORT_TIMEOUT,this._shutdownOnce=new W.BindOnceFuture(this._shutdown,this),this._maxExportBatchSize>this._maxQueueSize&&(y.diag.warn("BatchSpanProcessor: maxExportBatchSize must be smaller or equal to maxQueueSize, setting maxExportBatchSize to match maxQueueSize"),this._maxExportBatchSize=this._maxQueueSize)}return a.prototype.forceFlush=function(){return this._shutdownOnce.isCalled?this._shutdownOnce.promise:this._flushAll()},a.prototype.onStart=function(n,o){},a.prototype.onEnd=function(n){this._shutdownOnce.isCalled||n.spanContext().traceFlags&y.TraceFlags.SAMPLED&&this._addToBuffer(n)},a.prototype.shutdown=function(){return this._shutdownOnce.call()},a.prototype._shutdown=function(){var n=this;return Promise.resolve().then(function(){return n.onShutdown()}).then(function(){return n._flushAll()}).then(function(){return n._exporter.shutdown()})},a.prototype._addToBuffer=function(n){if(this._finishedSpans.length>=this._maxQueueSize){this._droppedSpansCount===0&&y.diag.debug("maxQueueSize reached, dropping spans"),this._droppedSpansCount++;return}this._droppedSpansCount>0&&(y.diag.warn("Dropped "+this._droppedSpansCount+" spans because maxQueueSize reached"),this._droppedSpansCount=0),this._finishedSpans.push(n),this._maybeStartTimer()},a.prototype._flushAll=function(){var n=this;return new Promise(function(o,c){for(var l=[],i=Math.ceil(n._finishedSpans.length/n._maxExportBatchSize),e=0,t=i;e<t;e++)l.push(n._flushOneBatch());Promise.all(l).then(function(){o()}).catch(c)})},a.prototype._flushOneBatch=function(){var n=this;return this._clearTimer(),this._finishedSpans.length===0?Promise.resolve():new Promise(function(o,c){var l=setTimeout(function(){c(new Error("Timeout"))},n._exportTimeoutMillis);y.context.with((0,W.suppressTracing)(y.context.active()),function(){var i=n._finishedSpans.splice(0,n._maxExportBatchSize),e=function(){return n._exporter.export(i,function(r){var u;clearTimeout(l),r.code===W.ExportResultCode.SUCCESS?o():c((u=r.error)!==null&&u!==void 0?u:new Error("BatchSpanProcessor: span export failed"))})},t=i.map(function(r){return r.resource}).filter(function(r){return r.asyncAttributesPending});t.length===0?e():Promise.all(t.map(function(r){var u;return(u=r.waitForAsyncAttributes)===null||u===void 0?void 0:u.call(r)})).then(e,function(r){(0,W.globalErrorHandler)(r),c(r)})})})},a.prototype._maybeStartTimer=function(){var n=this;if(!this._isExporting){var o=function(){n._isExporting=!0,n._flushOneBatch().then(function(){n._isExporting=!1,n._finishedSpans.length>0&&(n._clearTimer(),n._maybeStartTimer())}).catch(function(c){n._isExporting=!1,(0,W.globalErrorHandler)(c)})};if(this._finishedSpans.length>=this._maxExportBatchSize)return o();this._timer===void 0&&(this._timer=setTimeout(function(){return o()},this._scheduledDelayMillis),(0,W.unrefTimer)(this._timer))}},a.prototype._clearTimer=function(){this._timer!==void 0&&(clearTimeout(this._timer),this._timer=void 0)},a}();var Ks=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),$t=function(a){Ks(n,a);function n(o,c){var l=a.call(this,o,c)||this;return l.onInit(c),l}return n.prototype.onInit=function(o){var c=this;o?.disableAutoFlushOnDocumentHide!==!0&&typeof document<"u"&&(this._visibilityChangeListener=function(){document.visibilityState==="hidden"&&c.forceFlush()},this._pageHideListener=function(){c.forceFlush()},document.addEventListener("visibilitychange",this._visibilityChangeListener),document.addEventListener("pagehide",this._pageHideListener))},n.prototype.onShutdown=function(){typeof document<"u"&&(this._visibilityChangeListener&&document.removeEventListener("visibilitychange",this._visibilityChangeListener),this._pageHideListener&&document.removeEventListener("pagehide",this._pageHideListener))},n}(Fi);var Xs=8,Ys=16,yr=function(){function a(){this.generateTraceId=qi(Ys),this.generateSpanId=qi(Xs)}return a}();var dr=Array(32);function qi(a){return function(){for(var o=0;o<a*2;o++)dr[o]=Math.floor(Math.random()*16)+48,dr[o]>=58&&(dr[o]+=39);return String.fromCharCode.apply(null,dr.slice(0,a*2))}}var Ki=function(){function a(n,o,c){this._tracerProvider=c;var l=Hi(o);this._sampler=l.sampler,this._generalLimits=l.generalLimits,this._spanLimits=l.spanLimits,this._idGenerator=o.idGenerator||new yr,this.resource=c.resource,this.instrumentationLibrary=n}return a.prototype.startSpan=function(n,o,c){var l,i,e;o===void 0&&(o={}),c===void 0&&(c=y.context.active()),o.root&&(c=y.trace.deleteSpan(c));var t=y.trace.getSpan(c);if((0,Qt.isTracingSuppressed)(c)){y.diag.debug("Instrumentation suppressed, returning Noop Span");var r=y.trace.wrapSpanContext(y.INVALID_SPAN_CONTEXT);return r}var u=t?.spanContext(),s=this._idGenerator.generateSpanId(),d,v,g;!u||!y.trace.isSpanContextValid(u)?d=this._idGenerator.generateTraceId():(d=u.traceId,v=u.traceState,g=u.spanId);var x=(l=o.kind)!==null&&l!==void 0?l:y.SpanKind.INTERNAL,I=((i=o.links)!==null&&i!==void 0?i:[]).map(function(Ie){return{context:Ie.context,attributes:(0,Qt.sanitizeAttributes)(Ie.attributes)}}),F=(0,Qt.sanitizeAttributes)(o.attributes),R=this._sampler.shouldSample(c,d,n,x,F,I);v=(e=R.traceState)!==null&&e!==void 0?e:v;var T=R.decision===y.SamplingDecision.RECORD_AND_SAMPLED?y.TraceFlags.SAMPLED:y.TraceFlags.NONE,st={traceId:d,spanId:s,traceFlags:T,traceState:v};if(R.decision===y.SamplingDecision.NOT_RECORD){y.diag.debug("Recording is off, propagating context in a non-recording span");var r=y.trace.wrapSpanContext(st);return r}var Le=(0,Qt.sanitizeAttributes)(Object.assign(F,R.attributes)),Xr=new ki(this,c,n,st,x,g,I,o.startTime,void 0,Le);return Xr},a.prototype.startActiveSpan=function(n,o,c,l){var i,e,t;if(!(arguments.length<2)){arguments.length===2?t=o:arguments.length===3?(i=o,t=c):(i=o,e=c,t=l);var r=e??y.context.active(),u=this.startSpan(n,i,r),s=y.trace.setSpan(r,u);return y.context.with(s,t,void 0,u)}},a.prototype.getGeneralLimits=function(){return this._generalLimits},a.prototype.getSpanLimits=function(){return this._spanLimits},a.prototype.getActiveSpanProcessor=function(){return this._tracerProvider.getActiveSpanProcessor()},a}();b();var rt=N(V());b();var Nt=N(Ot()),hr=N(V());function Xi(){return"unknown_service"}var Pt=function(){return Pt=Object.assign||function(a){for(var n,o=1,c=arguments.length;o<c;o++){n=arguments[o];for(var l in n)Object.prototype.hasOwnProperty.call(n,l)&&(a[l]=n[l])}return a},Pt.apply(this,arguments)},Js=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},zs=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Ws=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Y=function(){function a(n,o){var c=this,l;this._attributes=n,this.asyncAttributesPending=o!=null,this._syncAttributes=(l=this._attributes)!==null&&l!==void 0?l:{},this._asyncAttributesPromise=o?.then(function(i){return c._attributes=Object.assign({},c._attributes,i),c.asyncAttributesPending=!1,i},function(i){return y.diag.debug("a resource's async attributes promise rejected: %s",i),c.asyncAttributesPending=!1,{}})}return a.empty=function(){return a.EMPTY},a.default=function(){var n;return new a((n={},n[Nt.SemanticResourceAttributes.SERVICE_NAME]=Xi(),n[Nt.SemanticResourceAttributes.TELEMETRY_SDK_LANGUAGE]=hr.SDK_INFO[Nt.SemanticResourceAttributes.TELEMETRY_SDK_LANGUAGE],n[Nt.SemanticResourceAttributes.TELEMETRY_SDK_NAME]=hr.SDK_INFO[Nt.SemanticResourceAttributes.TELEMETRY_SDK_NAME],n[Nt.SemanticResourceAttributes.TELEMETRY_SDK_VERSION]=hr.SDK_INFO[Nt.SemanticResourceAttributes.TELEMETRY_SDK_VERSION],n))},Object.defineProperty(a.prototype,"attributes",{get:function(){var n;return this.asyncAttributesPending&&y.diag.error("Accessing resource attributes before async attributes settled"),(n=this._attributes)!==null&&n!==void 0?n:{}},enumerable:!1,configurable:!0}),a.prototype.waitForAsyncAttributes=function(){return Js(this,void 0,void 0,function(){return zs(this,function(n){switch(n.label){case 0:return this.asyncAttributesPending?[4,this._asyncAttributesPromise]:[3,2];case 1:n.sent(),n.label=2;case 2:return[2]}})})},a.prototype.merge=function(n){var o=this,c;if(!n)return this;var l=Pt(Pt({},this._syncAttributes),(c=n._syncAttributes)!==null&&c!==void 0?c:n.attributes);if(!this._asyncAttributesPromise&&!n._asyncAttributesPromise)return new a(l);var i=Promise.all([this._asyncAttributesPromise,n._asyncAttributesPromise]).then(function(e){var t,r=Ws(e,2),u=r[0],s=r[1];return Pt(Pt(Pt(Pt({},o._syncAttributes),u),(t=n._syncAttributes)!==null&&t!==void 0?t:n.attributes),s)});return new a(l,i)},a.EMPTY=new a({}),a}();b();var Yi=N(V()),Ji=N(Ot());var $s=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},Qs=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Zs=function(){function a(){this._MAX_LENGTH=255,this._COMMA_SEPARATOR=",",this._LABEL_KEY_VALUE_SPLITTER="=",this._ERROR_MESSAGE_INVALID_CHARS="should be a ASCII string with a length greater than 0 and not exceed "+this._MAX_LENGTH+" characters.",this._ERROR_MESSAGE_INVALID_VALUE="should be a ASCII string with a length not exceed "+this._MAX_LENGTH+" characters."}return a.prototype.detect=function(n){var o={},c=(0,Yi.getEnv)(),l=c.OTEL_RESOURCE_ATTRIBUTES,i=c.OTEL_SERVICE_NAME;if(l)try{var e=this._parseResourceAttributes(l);Object.assign(o,e)}catch(t){y.diag.debug("EnvDetector failed: "+t.message)}return i&&(o[Ji.SemanticResourceAttributes.SERVICE_NAME]=i),new Y(o)},a.prototype._parseResourceAttributes=function(n){var o,c;if(!n)return{};var l={},i=n.split(this._COMMA_SEPARATOR,-1);try{for(var e=$s(i),t=e.next();!t.done;t=e.next()){var r=t.value,u=r.split(this._LABEL_KEY_VALUE_SPLITTER,-1);if(u.length===2){var s=Qs(u,2),d=s[0],v=s[1];if(d=d.trim(),v=v.trim().split(/^"|"$/).join(""),!this._isValidAndNotEmpty(d))throw new Error("Attribute key "+this._ERROR_MESSAGE_INVALID_CHARS);if(!this._isValid(v))throw new Error("Attribute value "+this._ERROR_MESSAGE_INVALID_VALUE);l[d]=decodeURIComponent(v)}}}catch(g){o={error:g}}finally{try{t&&!t.done&&(c=e.return)&&c.call(e)}finally{if(o)throw o.error}}return l},a.prototype._isValid=function(n){return n.length<=this._MAX_LENGTH&&this._isBaggageOctetString(n)},a.prototype._isBaggageOctetString=function(n){for(var o=0;o<n.length;o++){var c=n.charCodeAt(o);if(c<33||c===44||c===59||c===92||c>126)return!1}return!0},a.prototype._isValidAndNotEmpty=function(n){return n.length>0&&this._isValid(n)},a}(),zi=new Zs;b();var Wi=function(a){return a!==null&&typeof a=="object"&&typeof a.then=="function"};var tp=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},ep=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}};var $i=function(a){var n;a===void 0&&(a={});var o=((n=a.detectors)!==null&&n!==void 0?n:[]).map(function(l){try{var i=l.detect(a),e;if(Wi(i)){var t=function(){return tp(void 0,void 0,void 0,function(){var r;return ep(this,function(u){switch(u.label){case 0:return[4,i];case 1:return r=u.sent(),[2,r.attributes]}})})};e=new Y({},t())}else e=i;return e.waitForAsyncAttributes?e.waitForAsyncAttributes().then(function(){return y.diag.debug(l.constructor.name+" found resource.",e)}):y.diag.debug(l.constructor.name+" found resource.",e),e}catch(r){return y.diag.error(l.constructor.name+" failed: "+r.message),Y.empty()}}),c=o.reduce(function(l,i){return l.merge(i)},Y.empty());return c.waitForAsyncAttributes&&c.waitForAsyncAttributes().then(function(){rp(o)}),c},rp=function(a){a.forEach(function(n){if(Object.keys(n.attributes).length>0){var o=JSON.stringify(n.attributes,null,4);y.diag.verbose(o)}})};var Qi=N(V()),mr=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},Zi=function(){function a(n){this._spanProcessors=n}return a.prototype.forceFlush=function(){var n,o,c=[];try{for(var l=mr(this._spanProcessors),i=l.next();!i.done;i=l.next()){var e=i.value;c.push(e.forceFlush())}}catch(t){n={error:t}}finally{try{i&&!i.done&&(o=l.return)&&o.call(l)}finally{if(n)throw n.error}}return new Promise(function(t){Promise.all(c).then(function(){t()}).catch(function(r){(0,Qi.globalErrorHandler)(r||new Error("MultiSpanProcessor: forceFlush failed")),t()})})},a.prototype.onStart=function(n,o){var c,l;try{for(var i=mr(this._spanProcessors),e=i.next();!e.done;e=i.next()){var t=e.value;t.onStart(n,o)}}catch(r){c={error:r}}finally{try{e&&!e.done&&(l=i.return)&&l.call(i)}finally{if(c)throw c.error}}},a.prototype.onEnd=function(n){var o,c;try{for(var l=mr(this._spanProcessors),i=l.next();!i.done;i=l.next()){var e=i.value;e.onEnd(n)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(c=l.return)&&c.call(l)}finally{if(o)throw o.error}}},a.prototype.shutdown=function(){var n,o,c=[];try{for(var l=mr(this._spanProcessors),i=l.next();!i.done;i=l.next()){var e=i.value;c.push(e.shutdown())}}catch(t){n={error:t}}finally{try{i&&!i.done&&(o=l.return)&&o.call(l)}finally{if(n)throw n.error}}return new Promise(function(t,r){Promise.all(c).then(function(){t()},r)})},a}();var ta=function(){function a(){}return a.prototype.onStart=function(n,o){},a.prototype.onEnd=function(n){},a.prototype.shutdown=function(){return Promise.resolve()},a.prototype.forceFlush=function(){return Promise.resolve()},a}();var Gt;(function(a){a[a.resolved=0]="resolved",a[a.timeout=1]="timeout",a[a.error=2]="error",a[a.unresolved=3]="unresolved"})(Gt||(Gt={}));var ea=function(){function a(n){n===void 0&&(n={});var o;this._registeredSpanProcessors=[],this._tracers=new Map;var c=(0,rt.merge)({},fr(),ji(n));this.resource=(o=c.resource)!==null&&o!==void 0?o:Y.empty(),this.resource=Y.default().merge(this.resource),this._config=Object.assign({},c,{resource:this.resource});var l=this._buildExporterFromEnv();if(l!==void 0){var i=new $t(l);this.activeSpanProcessor=i}else this.activeSpanProcessor=new ta}return a.prototype.getTracer=function(n,o,c){var l=n+"@"+(o||"")+":"+(c?.schemaUrl||"");return this._tracers.has(l)||this._tracers.set(l,new Ki({name:n,version:o,schemaUrl:c?.schemaUrl},this._config,this)),this._tracers.get(l)},a.prototype.addSpanProcessor=function(n){this._registeredSpanProcessors.length===0&&this.activeSpanProcessor.shutdown().catch(function(o){return y.diag.error("Error while trying to shutdown current span processor",o)}),this._registeredSpanProcessors.push(n),this.activeSpanProcessor=new Zi(this._registeredSpanProcessors)},a.prototype.getActiveSpanProcessor=function(){return this.activeSpanProcessor},a.prototype.register=function(n){n===void 0&&(n={}),y.trace.setGlobalTracerProvider(this),n.propagator===void 0&&(n.propagator=this._buildPropagatorFromEnv()),n.contextManager&&y.context.setGlobalContextManager(n.contextManager),n.propagator&&y.propagation.setGlobalPropagator(n.propagator)},a.prototype.forceFlush=function(){var n=this._config.forceFlushTimeoutMillis,o=this._registeredSpanProcessors.map(function(c){return new Promise(function(l){var i,e=setTimeout(function(){l(new Error("Span processor did not completed within timeout period of "+n+" ms")),i=Gt.timeout},n);c.forceFlush().then(function(){clearTimeout(e),i!==Gt.timeout&&(i=Gt.resolved,l(i))}).catch(function(t){clearTimeout(e),i=Gt.error,l(t)})})});return new Promise(function(c,l){Promise.all(o).then(function(i){var e=i.filter(function(t){return t!==Gt.resolved});e.length>0?l(e):c()}).catch(function(i){return l([i])})})},a.prototype.shutdown=function(){return this.activeSpanProcessor.shutdown()},a.prototype._getPropagator=function(n){var o;return(o=this.constructor._registeredPropagators.get(n))===null||o===void 0?void 0:o()},a.prototype._getSpanExporter=function(n){var o;return(o=this.constructor._registeredExporters.get(n))===null||o===void 0?void 0:o()},a.prototype._buildPropagatorFromEnv=function(){var n=this,o=Array.from(new Set((0,rt.getEnv)().OTEL_PROPAGATORS)),c=o.map(function(i){var e=n._getPropagator(i);return e||y.diag.warn('Propagator "'+i+'" requested through environment variable is unavailable.'),e}),l=c.reduce(function(i,e){return e&&i.push(e),i},[]);if(l.length!==0)return o.length===1?l[0]:new rt.CompositePropagator({propagators:l})},a.prototype._buildExporterFromEnv=function(){var n=(0,rt.getEnv)().OTEL_TRACES_EXPORTER;if(!(n==="none"||n==="")){var o=this._getSpanExporter(n);return o||y.diag.error('Exporter "'+n+'" requested through environment variable is unavailable.'),o}},a._registeredPropagators=new Map([["tracecontext",function(){return new rt.W3CTraceContextPropagator}],["baggage",function(){return new rt.W3CBaggagePropagator}]]),a._registeredExporters=new Map,a}();b();var dt={};tt(dt,Jy);import*as Jy from"@opentelemetry/api-logs";var Ml=N(ia(),1);b();var _r=N(V());b();b();b();var Zt=N(V()),ap=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},up=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},aa=function(){function a(n,o,c){this.attributes={},this.totalAttributesCount=0,this._isReadonly=!1;var l=c.timestamp,i=c.observedTimestamp,e=c.severityNumber,t=c.severityText,r=c.body,u=c.attributes,s=u===void 0?{}:u,d=c.context,v=Date.now();if(this.hrTime=(0,Zt.timeInputToHrTime)(l??v),this.hrTimeObserved=(0,Zt.timeInputToHrTime)(i??v),d){var g=y.trace.getSpanContext(d);g&&y.isSpanContextValid(g)&&(this.spanContext=g)}this.severityNumber=e,this.severityText=t,this.body=r,this.resource=n.resource,this.instrumentationScope=o,this._logRecordLimits=n.logRecordLimits,this.setAttributes(s)}return Object.defineProperty(a.prototype,"severityText",{get:function(){return this._severityText},set:function(n){this._isLogRecordReadonly()||(this._severityText=n)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"severityNumber",{get:function(){return this._severityNumber},set:function(n){this._isLogRecordReadonly()||(this._severityNumber=n)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"body",{get:function(){return this._body},set:function(n){this._isLogRecordReadonly()||(this._body=n)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"droppedAttributesCount",{get:function(){return this.totalAttributesCount-Object.keys(this.attributes).length},enumerable:!1,configurable:!0}),a.prototype.setAttribute=function(n,o){return this._isLogRecordReadonly()?this:o===null?this:n.length===0?(y.diag.warn("Invalid attribute key: "+n),this):!(0,Zt.isAttributeValue)(o)&&!(typeof o=="object"&&!Array.isArray(o)&&Object.keys(o).length>0)?(y.diag.warn("Invalid attribute value set for key: "+n),this):(this.totalAttributesCount+=1,Object.keys(this.attributes).length>=this._logRecordLimits.attributeCountLimit&&!Object.prototype.hasOwnProperty.call(this.attributes,n)?this:((0,Zt.isAttributeValue)(o)?this.attributes[n]=this._truncateToSize(o):this.attributes[n]=o,this))},a.prototype.setAttributes=function(n){var o,c;try{for(var l=ap(Object.entries(n)),i=l.next();!i.done;i=l.next()){var e=up(i.value,2),t=e[0],r=e[1];this.setAttribute(t,r)}}catch(u){o={error:u}}finally{try{i&&!i.done&&(c=l.return)&&c.call(l)}finally{if(o)throw o.error}}return this},a.prototype.setBody=function(n){return this.body=n,this},a.prototype.setSeverityNumber=function(n){return this.severityNumber=n,this},a.prototype.setSeverityText=function(n){return this.severityText=n,this},a.prototype._makeReadonly=function(){this._isReadonly=!0},a.prototype._truncateToSize=function(n){var o=this,c=this._logRecordLimits.attributeValueLengthLimit;return c<=0?(y.diag.warn("Attribute value limit must be positive, got "+c),n):typeof n=="string"?this._truncateToLimitUtil(n,c):Array.isArray(n)?n.map(function(l){return typeof l=="string"?o._truncateToLimitUtil(l,c):l}):n},a.prototype._truncateToLimitUtil=function(n,o){return n.length<=o?n:n.substring(0,o)},a.prototype._isLogRecordReadonly=function(){return this._isReadonly&&y.diag.warn("Can not execute the operation on emitted log record"),this._isReadonly},a}();var Cn=function(){return Cn=Object.assign||function(a){for(var n,o=1,c=arguments.length;o<c;o++){n=arguments[o];for(var l in n)Object.prototype.hasOwnProperty.call(n,l)&&(a[l]=n[l])}return a},Cn.apply(this,arguments)},ua=function(){function a(n,o){this.instrumentationScope=n,this._sharedState=o}return a.prototype.emit=function(n){var o=n.context||y.context.active(),c=new aa(this._sharedState,this.instrumentationScope,Cn({context:o},n));this._sharedState.activeProcessor.onEmit(c,o),c._makeReadonly()},a}();var yt=N(V());function la(){return{forceFlushTimeoutMillis:3e4,logRecordLimits:{attributeValueLengthLimit:(0,yt.getEnv)().OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:(0,yt.getEnv)().OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT},includeTraceContext:!0}}function ca(a){var n,o,c,l,i,e,t=(0,yt.getEnvWithoutDefaults)();return{attributeCountLimit:(c=(o=(n=a.attributeCountLimit)!==null&&n!==void 0?n:t.OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT)!==null&&o!==void 0?o:t.OTEL_ATTRIBUTE_COUNT_LIMIT)!==null&&c!==void 0?c:yt.DEFAULT_ATTRIBUTE_COUNT_LIMIT,attributeValueLengthLimit:(e=(i=(l=a.attributeValueLengthLimit)!==null&&l!==void 0?l:t.OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT)!==null&&i!==void 0?i:t.OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT)!==null&&e!==void 0?e:yt.DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT}}var fa=N(V()),sa=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},pa=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},da=function(){function a(n,o){this.processors=n,this.forceFlushTimeoutMillis=o}return a.prototype.forceFlush=function(){return sa(this,void 0,void 0,function(){var n;return pa(this,function(o){switch(o.label){case 0:return n=this.forceFlushTimeoutMillis,[4,Promise.all(this.processors.map(function(c){return(0,fa.callWithTimeout)(c.forceFlush(),n)}))];case 1:return o.sent(),[2]}})})},a.prototype.onEmit=function(n,o){this.processors.forEach(function(c){return c.onEmit(n,o)})},a.prototype.shutdown=function(){return sa(this,void 0,void 0,function(){return pa(this,function(n){switch(n.label){case 0:return[4,Promise.all(this.processors.map(function(o){return o.shutdown()}))];case 1:return n.sent(),[2]}})})},a}();var ya=function(){function a(){}return a.prototype.forceFlush=function(){return Promise.resolve()},a.prototype.onEmit=function(n,o){},a.prototype.shutdown=function(){return Promise.resolve()},a}();var ha=function(){function a(n,o,c){this.resource=n,this.forceFlushTimeoutMillis=o,this.logRecordLimits=c,this.loggers=new Map,this.registeredLogRecordProcessors=[],this.activeProcessor=new ya}return a}();var lp="unknown",Un=function(){function a(n){n===void 0&&(n={});var o=(0,_r.merge)({},la(),n),c=o.resource,l=c===void 0?Y.default():c,i=o.logRecordLimits,e=o.forceFlushTimeoutMillis;this._sharedState=new ha(l,e,ca(i)),this._shutdownOnce=new _r.BindOnceFuture(this._shutdown,this)}return a.prototype.getLogger=function(n,o,c){if(this._shutdownOnce.isCalled)return y.diag.warn("A shutdown LoggerProvider cannot provide a Logger"),dt.NOOP_LOGGER;n||y.diag.warn("Logger requested without instrumentation scope name.");var l=n||lp,i=l+"@"+(o||"")+":"+(c?.schemaUrl||"");return this._sharedState.loggers.has(i)||this._sharedState.loggers.set(i,new ua({name:l,version:o,schemaUrl:c?.schemaUrl},this._sharedState)),this._sharedState.loggers.get(i)},a.prototype.addLogRecordProcessor=function(n){this._sharedState.registeredLogRecordProcessors.length===0&&this._sharedState.activeProcessor.shutdown().catch(function(o){return y.diag.error("Error while trying to shutdown current log record processor",o)}),this._sharedState.registeredLogRecordProcessors.push(n),this._sharedState.activeProcessor=new da(this._sharedState.registeredLogRecordProcessors,this._sharedState.forceFlushTimeoutMillis)},a.prototype.forceFlush=function(){return this._shutdownOnce.isCalled?(y.diag.warn("invalid attempt to force flush after LoggerProvider shutdown"),this._shutdownOnce.promise):this._sharedState.activeProcessor.forceFlush()},a.prototype.shutdown=function(){return this._shutdownOnce.isCalled?(y.diag.warn("shutdown may only be called once per LoggerProvider"),this._shutdownOnce.promise):this._shutdownOnce.call()},a.prototype._shutdown=function(){return this._sharedState.activeProcessor.shutdown()},a}();var Er;(function(a){a[a.DELTA=0]="DELTA",a[a.CUMULATIVE=1]="CUMULATIVE"})(Er||(Er={}));var cp=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),ma=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},va=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}};var sp=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")};function _a(a){return a!=null}function Ea(a){var n=Object.keys(a);return n.length===0?"":(n=n.sort(),JSON.stringify(n.map(function(o){return[o,a[o]]})))}function ba(a){var n,o;return a.name+":"+((n=a.version)!==null&&n!==void 0?n:"")+":"+((o=a.schemaUrl)!==null&&o!==void 0?o:"")}var pp=function(a){cp(n,a);function n(o){var c=a.call(this,o)||this;return Object.setPrototypeOf(c,n.prototype),c}return n}(Error);function Mn(a,n){var o,c=new Promise(function(i,e){o=setTimeout(function(){e(new pp("Operation timed out."))},n)});return Promise.race([a,c]).then(function(l){return clearTimeout(o),l},function(l){throw clearTimeout(o),l})}function Sa(a){return ma(this,void 0,void 0,function(){var n=this;return va(this,function(o){return[2,Promise.all(a.map(function(c){return ma(n,void 0,void 0,function(){var l,i;return va(this,function(e){switch(e.label){case 0:return e.trys.push([0,2,,3]),[4,c];case 1:return l=e.sent(),[2,{status:"fulfilled",value:l}];case 2:return i=e.sent(),[2,{status:"rejected",reason:i}];case 3:return[2]}})})}))]})})}function Ta(a){return a.status==="rejected"}function Oa(a,n){var o,c;if(a.size!==n.size)return!1;try{for(var l=sp(a),i=l.next();!i.done;i=l.next()){var e=i.value;if(!n.has(e))return!1}}catch(t){o={error:t}}finally{try{i&&!i.done&&(c=l.return)&&c.call(l)}finally{if(o)throw o.error}}return!0}function ga(a,n){return a.toLowerCase()===n.toLowerCase()}b();var ht;(function(a){a.COUNTER="COUNTER",a.HISTOGRAM="HISTOGRAM",a.UP_DOWN_COUNTER="UP_DOWN_COUNTER",a.OBSERVABLE_COUNTER="OBSERVABLE_COUNTER",a.OBSERVABLE_GAUGE="OBSERVABLE_GAUGE",a.OBSERVABLE_UP_DOWN_COUNTER="OBSERVABLE_UP_DOWN_COUNTER"})(ht||(ht={}));function mt(a,n,o){var c,l,i,e;return dp(a)||y.diag.warn('Invalid metric name: "'+a+'". The metric name should be a ASCII string with a length no greater than 255 characters.'),{name:a,type:n,description:(c=o?.description)!==null&&c!==void 0?c:"",unit:(l=o?.unit)!==null&&l!==void 0?l:"",valueType:(i=o?.valueType)!==null&&i!==void 0?i:y.ValueType.DOUBLE,advice:(e=o?.advice)!==null&&e!==void 0?e:{}}}function Aa(a,n){var o,c;return{name:(o=a.name)!==null&&o!==void 0?o:n.name,description:(c=a.description)!==null&&c!==void 0?c:n.description,type:n.type,unit:n.unit,valueType:n.valueType,advice:n.advice}}function Na(a,n){return ga(a.name,n.name)&&a.unit===n.unit&&a.type===n.type&&a.valueType===n.valueType}var fp=/^[a-z][a-z0-9_.\-/]{0,254}$/i;function dp(a){return a.match(fp)!=null}b();var Pa=function(){function a(){this._registeredViews=[]}return a.prototype.addView=function(n){this._registeredViews.push(n)},a.prototype.findViews=function(n,o){var c=this,l=this._registeredViews.filter(function(i){return c._matchInstrument(i.instrumentSelector,n)&&c._matchMeter(i.meterSelector,o)});return l},a.prototype._matchInstrument=function(n,o){return(n.getType()===void 0||o.type===n.getType())&&n.getNameFilter().match(o.name)&&n.getUnitFilter().match(o.unit)},a.prototype._matchMeter=function(n,o){return n.getNameFilter().match(o.name)&&(o.version===void 0||n.getVersionFilter().match(o.version))&&(o.schemaUrl===void 0||n.getSchemaUrlFilter().match(o.schemaUrl))},a}();b();var xa=N(V()),te=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),Dn=function(){function a(n,o){this._writableMetricStorage=n,this._descriptor=o}return a.prototype._record=function(n,o,c){if(o===void 0&&(o={}),c===void 0&&(c=y.context.active()),typeof n!="number"){y.diag.warn("non-number value provided to metric "+this._descriptor.name+": "+n);return}this._descriptor.valueType===y.ValueType.INT&&!Number.isInteger(n)&&(y.diag.warn("INT value type cannot accept a floating-point value for "+this._descriptor.name+", ignoring the fractional digits."),n=Math.trunc(n),!Number.isInteger(n))||this._writableMetricStorage.record(n,o,c,(0,xa.millisToHrTime)(Date.now()))},a}();var Ra=function(a){te(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n.prototype.add=function(o,c,l){this._record(o,c,l)},n}(Dn);var La=function(a){te(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n.prototype.add=function(o,c,l){if(o<0){y.diag.warn("negative value provided to counter "+this._descriptor.name+": "+o);return}this._record(o,c,l)},n}(Dn);var Ia=function(a){te(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n.prototype.record=function(o,c,l){if(o<0){y.diag.warn("negative value provided to histogram "+this._descriptor.name+": "+o);return}this._record(o,c,l)},n}(Dn);var br=function(){function a(n,o,c){this._observableRegistry=c,this._descriptor=n,this._metricStorages=o}return a.prototype.addCallback=function(n){this._observableRegistry.addCallback(n,this)},a.prototype.removeCallback=function(n){this._observableRegistry.removeCallback(n,this)},a}();var wa=function(a){te(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n}(br);var Ca=function(a){te(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n}(br);var Ua=function(a){te(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n}(br);function _e(a){return a instanceof br}var Ma=function(){function a(n){this._meterSharedState=n}return a.prototype.createHistogram=function(n,o){var c=mt(n,ht.HISTOGRAM,o),l=this._meterSharedState.registerMetricStorage(c);return new Ia(l,c)},a.prototype.createCounter=function(n,o){var c=mt(n,ht.COUNTER,o),l=this._meterSharedState.registerMetricStorage(c);return new La(l,c)},a.prototype.createUpDownCounter=function(n,o){var c=mt(n,ht.UP_DOWN_COUNTER,o),l=this._meterSharedState.registerMetricStorage(c);return new Ra(l,c)},a.prototype.createObservableGauge=function(n,o){var c=mt(n,ht.OBSERVABLE_GAUGE,o),l=this._meterSharedState.registerAsyncMetricStorage(c);return new Ca(c,l,this._meterSharedState.observableRegistry)},a.prototype.createObservableCounter=function(n,o){var c=mt(n,ht.OBSERVABLE_COUNTER,o),l=this._meterSharedState.registerAsyncMetricStorage(c);return new wa(c,l,this._meterSharedState.observableRegistry)},a.prototype.createObservableUpDownCounter=function(n,o){var c=mt(n,ht.OBSERVABLE_UP_DOWN_COUNTER,o),l=this._meterSharedState.registerAsyncMetricStorage(c);return new Ua(c,l,this._meterSharedState.observableRegistry)},a.prototype.addBatchObservableCallback=function(n,o){this._meterSharedState.observableRegistry.addBatchCallback(n,o)},a.prototype.removeBatchObservableCallback=function(n,o){this._meterSharedState.observableRegistry.removeBatchCallback(n,o)},a}();var Sr=function(){function a(n){this._instrumentDescriptor=n}return a.prototype.getInstrumentDescriptor=function(){return this._instrumentDescriptor},a.prototype.updateDescription=function(n){this._instrumentDescriptor=mt(this._instrumentDescriptor.name,this._instrumentDescriptor.type,{description:n,valueType:this._instrumentDescriptor.valueType,unit:this._instrumentDescriptor.unit,advice:this._instrumentDescriptor.advice})},a}();var yp=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),Da=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},hp=function(){function a(n){this._hash=n,this._valueMap=new Map,this._keyMap=new Map}return a.prototype.get=function(n,o){return o??(o=this._hash(n)),this._valueMap.get(o)},a.prototype.getOrDefault=function(n,o){var c=this._hash(n);if(this._valueMap.has(c))return this._valueMap.get(c);var l=o();return this._keyMap.has(c)||this._keyMap.set(c,n),this._valueMap.set(c,l),l},a.prototype.set=function(n,o,c){c??(c=this._hash(n)),this._keyMap.has(c)||this._keyMap.set(c,n),this._valueMap.set(c,o)},a.prototype.has=function(n,o){return o??(o=this._hash(n)),this._valueMap.has(o)},a.prototype.keys=function(){var n,o;return Da(this,function(c){switch(c.label){case 0:n=this._keyMap.entries(),o=n.next(),c.label=1;case 1:return o.done===!0?[3,3]:[4,[o.value[1],o.value[0]]];case 2:return c.sent(),o=n.next(),[3,1];case 3:return[2]}})},a.prototype.entries=function(){var n,o;return Da(this,function(c){switch(c.label){case 0:n=this._valueMap.entries(),o=n.next(),c.label=1;case 1:return o.done===!0?[3,3]:[4,[this._keyMap.get(o.value[0]),o.value[1],o.value[0]]];case 2:return c.sent(),o=n.next(),[3,1];case 3:return[2]}})},Object.defineProperty(a.prototype,"size",{get:function(){return this._valueMap.size},enumerable:!1,configurable:!0}),a}();var nt=function(a){yp(n,a);function n(){return a.call(this,Ea)||this}return n}(hp);var mp=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Tr=function(){function a(n){this._aggregator=n,this._activeCollectionStorage=new nt,this._cumulativeMemoStorage=new nt}return a.prototype.record=function(n,o,c,l){var i=this,e=this._activeCollectionStorage.getOrDefault(o,function(){return i._aggregator.createAccumulation(l)});e?.record(n)},a.prototype.batchCumulate=function(n,o){var c=this;Array.from(n.entries()).forEach(function(l){var i=mp(l,3),e=i[0],t=i[1],r=i[2],u=c._aggregator.createAccumulation(o);u?.record(t);var s=u;if(c._cumulativeMemoStorage.has(e,r)){var d=c._cumulativeMemoStorage.get(e,r);s=c._aggregator.diff(d,u)}if(c._activeCollectionStorage.has(e,r)){var v=c._activeCollectionStorage.get(e,r);s=c._aggregator.merge(v,s)}c._cumulativeMemoStorage.set(e,u,r),c._activeCollectionStorage.set(e,s,r)})},a.prototype.collect=function(){var n=this._activeCollectionStorage;return this._activeCollectionStorage=new nt,n},a}();var Vn=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},Va=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Or=function(){function a(n,o){var c=this;this._aggregator=n,this._unreportedAccumulations=new Map,this._reportHistory=new Map,o.forEach(function(l){c._unreportedAccumulations.set(l,[])})}return a.prototype.buildMetrics=function(n,o,c,l){this._stashAccumulations(c);var i=this._getMergedUnreportedAccumulations(n),e=i,t;if(this._reportHistory.has(n)){var r=this._reportHistory.get(n),u=r.collectionTime;t=r.aggregationTemporality,t===Er.CUMULATIVE?e=a.merge(r.accumulations,i,this._aggregator):e=a.calibrateStartTime(r.accumulations,i,u)}else t=n.selectAggregationTemporality(o.type);this._reportHistory.set(n,{accumulations:e,collectionTime:l,aggregationTemporality:t});var s=vp(e);if(s.length!==0)return this._aggregator.toMetricData(o,t,s,l)},a.prototype._stashAccumulations=function(n){var o,c,l=this._unreportedAccumulations.keys();try{for(var i=Vn(l),e=i.next();!e.done;e=i.next()){var t=e.value,r=this._unreportedAccumulations.get(t);r===void 0&&(r=[],this._unreportedAccumulations.set(t,r)),r.push(n)}}catch(u){o={error:u}}finally{try{e&&!e.done&&(c=i.return)&&c.call(i)}finally{if(o)throw o.error}}},a.prototype._getMergedUnreportedAccumulations=function(n){var o,c,l=new nt,i=this._unreportedAccumulations.get(n);if(this._unreportedAccumulations.set(n,[]),i===void 0)return l;try{for(var e=Vn(i),t=e.next();!t.done;t=e.next()){var r=t.value;l=a.merge(l,r,this._aggregator)}}catch(u){o={error:u}}finally{try{t&&!t.done&&(c=e.return)&&c.call(e)}finally{if(o)throw o.error}}return l},a.merge=function(n,o,c){for(var l=n,i=o.entries(),e=i.next();e.done!==!0;){var t=Va(e.value,3),r=t[0],u=t[1],s=t[2];if(n.has(r,s)){var d=n.get(r,s),v=c.merge(d,u);l.set(r,v,s)}else l.set(r,u,s);e=i.next()}return l},a.calibrateStartTime=function(n,o,c){var l,i;try{for(var e=Vn(n.keys()),t=e.next();!t.done;t=e.next()){var r=Va(t.value,2),u=r[0],s=r[1],d=o.get(u,s);d?.setStartTime(c)}}catch(v){l={error:v}}finally{try{t&&!t.done&&(i=e.return)&&i.call(e)}finally{if(l)throw l.error}}return o},a}();function vp(a){return Array.from(a.entries())}var _p=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),Ep=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},ka=function(a){_p(n,a);function n(o,c,l,i){var e=a.call(this,o)||this;return e._attributesProcessor=l,e._deltaMetricStorage=new Tr(c),e._temporalMetricStorage=new Or(c,i),e}return n.prototype.record=function(o,c){var l=this,i=new nt;Array.from(o.entries()).forEach(function(e){var t=Ep(e,2),r=t[0],u=t[1];i.set(l._attributesProcessor.process(r),u)}),this._deltaMetricStorage.batchCumulate(i,c)},n.prototype.collect=function(o,c){var l=this._deltaMetricStorage.collect();return this._temporalMetricStorage.buildMetrics(o,this._instrumentDescriptor,l,c)},n}(Sr);b();function kn(a,n){var o="";return a.unit!==n.unit&&(o+=" - Unit '"+a.unit+"' does not match '"+n.unit+`'
|
|
5
5
|
`),a.type!==n.type&&(o+=" - Type '"+a.type+"' does not match '"+n.type+`'
|
|
6
6
|
`),a.valueType!==n.valueType&&(o+=" - Value Type '"+a.valueType+"' does not match '"+n.valueType+`'
|
|
7
7
|
`),a.description!==n.description&&(o+=" - Description '"+a.description+"' does not match '"+n.description+`'
|
|
8
8
|
`),o}function bp(a,n){return" - use valueType '"+a.valueType+"' on instrument creation or use an instrument name other than '"+n.name+"'"}function Sp(a,n){return" - use unit '"+a.unit+"' on instrument creation or use an instrument name other than '"+n.name+"'"}function Tp(a,n){var o={name:n.name,type:n.type,unit:n.unit},c=JSON.stringify(o);return" - create a new view with a name other than '"+a.name+"' and InstrumentSelector '"+c+"'"}function Op(a,n){var o={name:n.name,type:n.type,unit:n.unit},c=JSON.stringify(o);return" - create a new view with a name other than '"+a.name+"' and InstrumentSelector '"+c+`'
|
|
9
9
|
- OR - create a new view with the name `+a.name+" and description '"+a.description+"' and InstrumentSelector "+c+`
|
|
10
|
-
- OR - create a new view with the name `+n.name+" and description '"+a.description+"' and InstrumentSelector "+c}function
|
|
10
|
+
- OR - create a new view with the name `+n.name+" and description '"+a.description+"' and InstrumentSelector "+c}function Bn(a,n){return a.valueType!==n.valueType?bp(a,n):a.unit!==n.unit?Sp(a,n):a.type!==n.type?Tp(a,n):a.description!==n.description?Op(a,n):""}var Gn=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},Ba=function(){function a(){this._sharedRegistry=new Map,this._perCollectorRegistry=new Map}return a.create=function(){return new a},a.prototype.getStorages=function(n){var o,c,l,i,e=[];try{for(var t=Gn(this._sharedRegistry.values()),r=t.next();!r.done;r=t.next()){var u=r.value;e=e.concat(u)}}catch(g){o={error:g}}finally{try{r&&!r.done&&(c=t.return)&&c.call(t)}finally{if(o)throw o.error}}var s=this._perCollectorRegistry.get(n);if(s!=null)try{for(var d=Gn(s.values()),v=d.next();!v.done;v=d.next()){var u=v.value;e=e.concat(u)}}catch(g){l={error:g}}finally{try{v&&!v.done&&(i=d.return)&&i.call(d)}finally{if(l)throw l.error}}return e},a.prototype.register=function(n){this._registerStorage(n,this._sharedRegistry)},a.prototype.registerForCollector=function(n,o){var c=this._perCollectorRegistry.get(n);c==null&&(c=new Map,this._perCollectorRegistry.set(n,c)),this._registerStorage(o,c)},a.prototype.findOrUpdateCompatibleStorage=function(n){var o=this._sharedRegistry.get(n.name);return o===void 0?null:this._findOrUpdateCompatibleStorage(n,o)},a.prototype.findOrUpdateCompatibleCollectorStorage=function(n,o){var c=this._perCollectorRegistry.get(n);if(c===void 0)return null;var l=c.get(o.name);return l===void 0?null:this._findOrUpdateCompatibleStorage(o,l)},a.prototype._registerStorage=function(n,o){var c=n.getInstrumentDescriptor(),l=o.get(c.name);if(l===void 0){o.set(c.name,[n]);return}l.push(n)},a.prototype._findOrUpdateCompatibleStorage=function(n,o){var c,l,i=null;try{for(var e=Gn(o),t=e.next();!t.done;t=e.next()){var r=t.value,u=r.getInstrumentDescriptor();Na(u,n)?(u.description!==n.description&&(n.description.length>u.description.length&&r.updateDescription(n.description),y.diag.warn("A view or instrument with the name ",n.name,` has already been registered, but has a different description and is incompatible with another registered view.
|
|
11
11
|
`,`Details:
|
|
12
|
-
`,
|
|
13
|
-
To resolve the conflict:`,
|
|
12
|
+
`,kn(u,n),`The longer description will be used.
|
|
13
|
+
To resolve the conflict:`,Bn(u,n))),i=r):y.diag.warn("A view or instrument with the name ",n.name,` has already been registered and is incompatible with another registered view.
|
|
14
14
|
`,`Details:
|
|
15
|
-
`,
|
|
16
|
-
`,Vn(u,n))}}catch(s){c={error:s}}finally{try{t&&!t.done&&(l=e.return)&&l.call(e)}finally{if(c)throw c.error}}return i},a}();var Ga=function(){function a(n){this._backingStorages=n}return a.prototype.record=function(n,o,c,l){this._backingStorages.forEach(function(i){i.record(n,o,c,l)})},a}();b();b();var Ha=function(){function a(n,o){this._instrumentName=n,this._valueType=o,this._buffer=new nt}return a.prototype.observe=function(n,o){if(o===void 0&&(o={}),typeof n!="number"){y.diag.warn("non-number value provided to metric "+this._instrumentName+": "+n);return}this._valueType===y.ValueType.INT&&!Number.isInteger(n)&&(y.diag.warn("INT value type cannot accept a floating-point value for "+this._instrumentName+", ignoring the fractional digits."),n=Math.trunc(n),!Number.isInteger(n))||this._buffer.set(o,n)},a}();var ja=function(){function a(){this._buffer=new Map}return a.prototype.observe=function(n,o,c){if(c===void 0&&(c={}),!!_e(n)){var l=this._buffer.get(n);if(l==null&&(l=new nt,this._buffer.set(n,l)),typeof o!="number"){y.diag.warn("non-number value provided to metric "+n._descriptor.name+": "+o);return}n._descriptor.valueType===y.ValueType.INT&&!Number.isInteger(o)&&(y.diag.warn("INT value type cannot accept a floating-point value for "+n._descriptor.name+", ignoring the fractional digits."),o=Math.trunc(o),!Number.isInteger(o))||l.set(c,o)}},a}();var Hn=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},jn=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Fa=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},qa=function(a,n,o){if(o||arguments.length===2)for(var c=0,l=n.length,i;c<l;c++)(i||!(c in n))&&(i||(i=Array.prototype.slice.call(n,0,c)),i[c]=n[c]);return a.concat(i||Array.prototype.slice.call(n))},Ka=function(){function a(){this._callbacks=[],this._batchCallbacks=[]}return a.prototype.addCallback=function(n,o){var c=this._findCallback(n,o);c>=0||this._callbacks.push({callback:n,instrument:o})},a.prototype.removeCallback=function(n,o){var c=this._findCallback(n,o);c<0||this._callbacks.splice(c,1)},a.prototype.addBatchCallback=function(n,o){var c=new Set(o.filter(_e));if(c.size===0){y.diag.error("BatchObservableCallback is not associated with valid instruments",o);return}var l=this._findBatchCallback(n,c);l>=0||this._batchCallbacks.push({callback:n,instruments:c})},a.prototype.removeBatchCallback=function(n,o){var c=new Set(o.filter(_e)),l=this._findBatchCallback(n,c);l<0||this._batchCallbacks.splice(l,1)},a.prototype.observe=function(n,o){return Hn(this,void 0,void 0,function(){var c,l,i,e;return jn(this,function(t){switch(t.label){case 0:return c=this._observeCallbacks(n,o),l=this._observeBatchCallbacks(n,o),[4,Sa(qa(qa([],Fa(c),!1),Fa(l),!1))];case 1:return i=t.sent(),e=i.filter(Ta).map(function(r){return r.reason}),[2,e]}})})},a.prototype._observeCallbacks=function(n,o){var c=this;return this._callbacks.map(function(l){var i=l.callback,e=l.instrument;return Hn(c,void 0,void 0,function(){var t,r;return jn(this,function(u){switch(u.label){case 0:return t=new Ha(e._descriptor.name,e._descriptor.valueType),r=Promise.resolve(i(t)),o!=null&&(r=Mn(r,o)),[4,r];case 1:return u.sent(),e._metricStorages.forEach(function(s){s.record(t._buffer,n)}),[2]}})})})},a.prototype._observeBatchCallbacks=function(n,o){var c=this;return this._batchCallbacks.map(function(l){var i=l.callback,e=l.instruments;return Hn(c,void 0,void 0,function(){var t,r;return jn(this,function(u){switch(u.label){case 0:return t=new ja,r=Promise.resolve(i(t)),o!=null&&(r=Mn(r,o)),[4,r];case 1:return u.sent(),e.forEach(function(s){var d=t._buffer.get(s);d!=null&&s._metricStorages.forEach(function(v){v.record(d,n)})}),[2]}})})})},a.prototype._findCallback=function(n,o){return this._callbacks.findIndex(function(c){return c.callback===n&&c.instrument===o})},a.prototype._findBatchCallback=function(n,o){return this._batchCallbacks.findIndex(function(c){return c.callback===n&&Oa(c.instruments,o)})},a}();var gp=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),Xa=function(a){gp(n,a);function n(o,c,l,i){var e=a.call(this,o)||this;return e._attributesProcessor=l,e._deltaMetricStorage=new Tr(c),e._temporalMetricStorage=new Or(c,i),e}return n.prototype.record=function(o,c,l,i){c=this._attributesProcessor.process(c,l),this._deltaMetricStorage.record(o,c,l,i)},n.prototype.collect=function(o,c){var l=this._deltaMetricStorage.collect();return this._temporalMetricStorage.buildMetrics(o,this._instrumentDescriptor,l,c)},n}(Sr);var Ya=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),gr=function(){function a(){}return a.Noop=function(){return Np},a}();var Ap=function(a){Ya(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n.prototype.process=function(o,c){return o},n}(gr);var om=function(a){Ya(n,a);function n(o){var c=a.call(this)||this;return c._allowedAttributeNames=o,c}return n.prototype.process=function(o,c){var l=this,i={};return Object.keys(o).filter(function(e){return l._allowedAttributeNames.includes(e)}).forEach(function(e){return i[e]=o[e]}),i},n}(gr);var Np=new Ap;var Pp=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},xp=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Rp=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Ja=function(){function a(n,o){this._meterProviderSharedState=n,this._instrumentationScope=o,this.metricStorageRegistry=new Va,this.observableRegistry=new Ka,this.meter=new Ma(this)}return a.prototype.registerMetricStorage=function(n){var o=this._registerMetricStorage(n,Xa);return o.length===1?o[0]:new Ga(o)},a.prototype.registerAsyncMetricStorage=function(n){var o=this._registerMetricStorage(n,Ba);return o},a.prototype.collect=function(n,o,c){return Pp(this,void 0,void 0,function(){var l,i,e;return xp(this,function(t){switch(t.label){case 0:return[4,this.observableRegistry.observe(o,c?.timeoutMillis)];case 1:return l=t.sent(),i=this.metricStorageRegistry.getStorages(n),i.length===0?[2,null]:(e=i.map(function(r){return r.collect(n,o)}).filter(_a),e.length===0?[2,{errors:l}]:[2,{scopeMetrics:{scope:this._instrumentationScope,metrics:e},errors:l}])}})})},a.prototype._registerMetricStorage=function(n,o){var c=this,l=this._meterProviderSharedState.viewRegistry.findViews(n,this._instrumentationScope),i=l.map(function(r){var u=Aa(r,n),s=c.metricStorageRegistry.findOrUpdateCompatibleStorage(u);if(s!=null)return s;var d=r.aggregation.createAggregator(u),v=new o(u,d,r.attributesProcessor,c._meterProviderSharedState.metricCollectors);return c.metricStorageRegistry.register(v),v});if(i.length===0){var e=this._meterProviderSharedState.selectAggregations(n.type),t=e.map(function(r){var u=Rp(r,2),s=u[0],d=u[1],v=c.metricStorageRegistry.findOrUpdateCompatibleCollectorStorage(s,n);if(v!=null)return v;var g=d.createAggregator(n),x=new o(n,g,gr.Noop(),[s]);return c.metricStorageRegistry.registerForCollector(s,x),x});i=i.concat(t)}return i},a}();var Lp=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},za=function(){function a(n){this.resource=n,this.viewRegistry=new Pa,this.metricCollectors=[],this.meterSharedStates=new Map}return a.prototype.getMeterSharedState=function(n){var o=ba(n),c=this.meterSharedStates.get(o);return c==null&&(c=new Ja(this,n),this.meterSharedStates.set(o,c)),c},a.prototype.selectAggregations=function(n){var o,c,l=[];try{for(var i=Lp(this.metricCollectors),e=i.next();!e.done;e=i.next()){var t=e.value;l.push([t,t.selectAggregation(n)])}}catch(r){o={error:r}}finally{try{e&&!e.done&&(c=i.return)&&c.call(i)}finally{if(o)throw o.error}}return l},a}();var Wa=N(k()),Ar=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},Nr=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Ip=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},wp=function(a,n,o){if(o||arguments.length===2)for(var c=0,l=n.length,i;c<l;c++)(i||!(c in n))&&(i||(i=Array.prototype.slice.call(n,0,c)),i[c]=n[c]);return a.concat(i||Array.prototype.slice.call(n))},$a=function(){function a(n,o){this._sharedState=n,this._metricReader=o}return a.prototype.collect=function(n){return Ar(this,void 0,void 0,function(){var o,c,l,i,e=this;return Nr(this,function(t){switch(t.label){case 0:return o=(0,Wa.millisToHrTime)(Date.now()),c=[],l=[],i=Array.from(this._sharedState.meterSharedStates.values()).map(function(r){return Ar(e,void 0,void 0,function(){var u;return Nr(this,function(s){switch(s.label){case 0:return[4,r.collect(this,o,n)];case 1:return u=s.sent(),u?.scopeMetrics!=null&&c.push(u.scopeMetrics),u?.errors!=null&&l.push.apply(l,wp([],Ip(u.errors),!1)),[2]}})})}),[4,Promise.all(i)];case 1:return t.sent(),[2,{resourceMetrics:{resource:this._sharedState.resource,scopeMetrics:c},errors:l}]}})})},a.prototype.forceFlush=function(n){return Ar(this,void 0,void 0,function(){return Nr(this,function(o){switch(o.label){case 0:return[4,this._metricReader.forceFlush(n)];case 1:return o.sent(),[2]}})})},a.prototype.shutdown=function(n){return Ar(this,void 0,void 0,function(){return Nr(this,function(o){switch(o.label){case 0:return[4,this._metricReader.shutdown(n)];case 1:return o.sent(),[2]}})})},a.prototype.selectAggregationTemporality=function(n){return this._metricReader.selectAggregationTemporality(n)},a.prototype.selectAggregation=function(n){return this._metricReader.selectAggregation(n)},a}();var Qa=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},Za=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Cp=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},Fn=function(){function a(n){var o,c,l;this._shutdown=!1;var i=Y.default().merge((l=n?.resource)!==null&&l!==void 0?l:Y.empty());if(this._sharedState=new za(i),n?.views!=null&&n.views.length>0)try{for(var e=Cp(n.views),t=e.next();!t.done;t=e.next()){var r=t.value;this._sharedState.viewRegistry.addView(r)}}catch(u){o={error:u}}finally{try{t&&!t.done&&(c=e.return)&&c.call(e)}finally{if(o)throw o.error}}}return a.prototype.getMeter=function(n,o,c){return o===void 0&&(o=""),c===void 0&&(c={}),this._shutdown?(y.diag.warn("A shutdown MeterProvider cannot provide a Meter"),(0,y.createNoopMeter)()):this._sharedState.getMeterSharedState({name:n,version:o,schemaUrl:c.schemaUrl}).meter},a.prototype.addMetricReader=function(n){var o=new $a(this._sharedState,n);n.setMetricProducer(o),this._sharedState.metricCollectors.push(o)},a.prototype.shutdown=function(n){return Qa(this,void 0,void 0,function(){return Za(this,function(o){switch(o.label){case 0:return this._shutdown?(y.diag.warn("shutdown may only be called once per MeterProvider"),[2]):(this._shutdown=!0,[4,Promise.all(this._sharedState.metricCollectors.map(function(c){return c.shutdown(n)}))]);case 1:return o.sent(),[2]}})})},a.prototype.forceFlush=function(n){return Qa(this,void 0,void 0,function(){return Za(this,function(o){switch(o.label){case 0:return this._shutdown?(y.diag.warn("invalid attempt to force flush after MeterProvider shutdown"),[2]):[4,Promise.all(this._sharedState.metricCollectors.map(function(c){return c.forceFlush(n)}))];case 1:return o.sent(),[2]}})})},a}();var Dl=N(Ot(),1),se=N(Ve(),1),kl=N(nu(),1),ut=N(k(),1);b();var Vp=Symbol.for("@vercel/request-context");function te(){return globalThis[Vp]?.get()}var Xn=N(Ot(),1);function Rr(a){return Object.fromEntries(Object.entries(a).filter(([n,o])=>o!==void 0))}function ou(a){return a?a.split("::").at(-1):void 0}function iu(a=te()){if(a)return Rr({[Xn.SemanticAttributes.HTTP_HOST]:a.headers.host,[Xn.SemanticAttributes.HTTP_USER_AGENT]:a.headers["user-agent"],"http.referer":a.headers.referer,"vercel.request_id":ou(a.headers["x-vercel-id"]),"vercel.matched_path":a.headers["x-matched-path"],"vercel.edge_region":a.headers["x-vercel-edge-region"]})}b();function Se(a){return(a&y.TraceFlags.SAMPLED)!==0}var Lr=class{constructor(n){this.processors=n;this.rootSpanIds=new Map;this.waitSpanEnd=new Map}forceFlush(){return Promise.all(this.processors.map(n=>n.forceFlush().catch(o=>{y.diag.error("@vercel/otel: forceFlush failed:",o)}))).then(()=>{})}shutdown(){return Promise.all(this.processors.map(n=>n.shutdown().catch(()=>{}))).then(()=>{})}onStart(n,o){let{traceId:c,spanId:l,traceFlags:i}=n.spanContext(),e=!n.parentSpanId||!this.rootSpanIds.has(c);if(e?this.rootSpanIds.set(c,{rootSpanId:l,open:[]}):this.rootSpanIds.get(c)?.open.push(n),e&&Se(i)){let t=iu();t&&n.setAttributes(t);let r=te();r&&r.waitUntil(async()=>{if(this.rootSpanIds.has(c)){let u=new Promise(d=>{this.waitSpanEnd.set(c,d)}),s;await Promise.race([u,new Promise(d=>{s=setTimeout(()=>{this.waitSpanEnd.delete(c),d(void 0)},50)})]),s&&clearTimeout(s)}return this.forceFlush()})}for(let t of this.processors)t.onStart(n,o)}onEnd(n){let{traceId:o,spanId:c,traceFlags:l}=n.spanContext(),i=Se(l),e=this.rootSpanIds.get(o),t=e?.rootSpanId===c;if(i){let r=Hp(n);r&&Object.assign(n.attributes,r)}if(t){if(this.rootSpanIds.delete(o),e.open.length>0){for(let r of e.open)if(!r.ended&&r.spanContext().spanId!==c)try{r.end()}catch(u){y.diag.error("@vercel/otel: onEnd failed:",u)}}}else if(e)for(let r=0;r<e.open.length;r++)e.open[r]?.spanContext().spanId===c&&e.open.splice(r,1);for(let r of this.processors)r.onEnd(n);if(t){let r=this.waitSpanEnd.get(o);r&&(this.waitSpanEnd.delete(o),r())}}},Gp={[y.SpanKind.INTERNAL]:"internal",[y.SpanKind.SERVER]:"server",[y.SpanKind.CLIENT]:"client",[y.SpanKind.PRODUCER]:"producer",[y.SpanKind.CONSUMER]:"consumer"};function Hp(a){let{kind:n,attributes:o}=a,{"operation.name":c,"resouce.name":l,"span.type":i,"next.span_type":e,"http.method":t,"http.route":r}=o;if(c)return;let u=l??(t&&typeof t=="string"&&r&&typeof r=="string"?`${t} ${r}`:r);if(a.kind===y.SpanKind.SERVER&&t&&r&&typeof t=="string"&&typeof r=="string")return{"operation.name":"web.request","resource.name":u};let s=a.instrumentationLibrary.name,d=e??i;if(d&&typeof d=="string"){let v=au(s,d);return r?{"operation.name":v,"resource.name":u}:{"operation.name":v}}return{"operation.name":au(s,n===y.SpanKind.INTERNAL?"":Gp[n])}}function au(a,n){if(!a)return n;let o=a.replace(/[ @./]/g,"_");return o.startsWith("_")&&(o=o.slice(1)),n?`${o}.${n}`:o}var Eu=N(Zn(),1);var _u=N(Ur(),1);b();var ee=class extends _u.OTLPExporterBase{constructor(n={}){super(n),n.headers&&(this._headers=n.headers)}onShutdown(){y.diag.debug("@vercel/otel/otlp: onShutdown")}onInit(){y.diag.debug("@vercel/otel/otlp: onInit")}send(n,o,c){if(this._shutdownOnce.isCalled){y.diag.debug("@vercel/otel/otlp: Shutdown already started. Cannot send objects");return}let l=this.convert(n),i,e,t;try{({body:i,contentType:e,headers:t}=this.toMessage(l))}catch(u){y.diag.warn("@vercel/otel/otlp: no proto",u);return}let r=fetch(this.url,{method:"POST",body:i,headers:{...this._headers,...t,"Content-Type":e,"User-Agent":"OTel-OTLP-Exporter-JavaScript/0.46.0"},next:{internal:!0}}).then(u=>{y.diag.debug("@vercel/otel/otlp: onSuccess",u.status,u.statusText),o(),u.arrayBuffer().catch(()=>{})}).catch(u=>{y.diag.error("@vercel/otel/otlp: onError",u),c(u)}).finally(()=>{let u=this._sendingPromises.indexOf(r);this._sendingPromises.splice(u,1)});this._sendingPromises.push(r)}getDefaultUrl(n){throw new Error("Method not implemented.")}};var cf="v1/traces",sf=`http://localhost:4318/${cf}`;function Mr(a){return typeof a.url=="string"?a.url:sf}var re=class{constructor(n={}){this.impl=new no(n)}export(n,o){this.impl.export(n,o)}shutdown(){return this.impl.shutdown()}forceFlush(){return this.impl.forceFlush()}},no=class extends ee{convert(n){return(0,Eu.createExportTraceServiceRequest)(n,{useHex:!0,useLongBits:!1})}toMessage(n){return{body:JSON.stringify(n),contentType:"application/json"}}getDefaultUrl(n){return Mr(n)}};var xl=N(Zn(),1),Rl=N(Pl(),1),Ll=N(go(),1);var Ft=class{constructor(n={}){this.impl=new Po(n)}export(n,o){this.impl.export(n,o)}shutdown(){return this.impl.shutdown()}forceFlush(){return this.impl.forceFlush()}},Po=class extends ee{convert(n){return(0,xl.createExportTraceServiceRequest)(n,void 0)}toMessage(n){let o=Rl.ServiceClientType.SPANS,c=(0,Ll.getExportRequestProto)(o),l=c.create(n);return{body:c.encode(l).finish(),contentType:"application/x-protobuf",headers:{accept:"application/x-protobuf"}}}getDefaultUrl(n){return Mr(n)}};b();var vt=N(Ot(),1);function Il(a,n){return a.replace(/\{(?<temp1>[^{}]+)\}/g,(o,c)=>{let l=n[c];return l!==void 0?String(l):o})}var le=class{constructor(n={}){this.instrumentationName="@vercel/otel/fetch";this.instrumentationVersion="1.0.0";this.config=n}getConfig(){return this.config}setConfig(){}setTracerProvider(n){this.tracerProvider=n}setMeterProvider(){}enable(){this.disable();let{tracerProvider:n}=this;if(!n)return;let o=n.getTracer(this.instrumentationName,this.instrumentationVersion),c=this.config.ignoreUrls??[],l=(I,F)=>{if(F?.opentelemetry?.ignore!==void 0)return F.opentelemetry.ignore;if(c.length===0)return!1;let R=I.toString();return c.some(T=>typeof T=="string"?T==="*"?!0:R.startsWith(T):T.test(R))},i=process.env.VERCEL_URL||process.env.NEXT_PUBLIC_VERCEL_URL||null,e=process.env.VERCEL_BRANCH_URL||process.env.NEXT_PUBLIC_VERCEL_BRANCH_URL||null,t=this.config.propagateContextUrls??[],r=this.config.dontPropagateContextUrls??[],u=this.config.resourceNameTemplate,{attributesFromRequestHeaders:s,attributesFromResponseHeaders:d}=this.config,v=(I,F)=>{if(F?.opentelemetry?.propagateContext)return F.opentelemetry.propagateContext;let R=I.toString();return r.length>0&&r.some(T=>typeof T=="string"?T==="*"?!0:R.startsWith(T):T.test(R))?!1:i&&I.protocol==="https:"&&(I.host===i||I.host===e||I.host===te()?.headers.host)||!i&&I.protocol==="http:"&&I.hostname==="localhost"?!0:t.some(T=>typeof T=="string"?T==="*"?!0:R.startsWith(T):T.test(R))};process.env.NEXT_OTEL_FETCH_DISABLED="1";let g=globalThis.fetch;this.originalFetch=g;let x=async(I,F)=>{let R=F;if(R?.next?.internal)return g(I,R);let T=new Request(I instanceof Request?I.clone():I,R),st=new URL(T.url);if(l(st,R))return g(I,R);let Le={[vt.SemanticAttributes.HTTP_METHOD]:T.method,[vt.SemanticAttributes.HTTP_URL]:T.url,[vt.SemanticAttributes.HTTP_HOST]:st.host,[vt.SemanticAttributes.HTTP_SCHEME]:st.protocol.replace(":",""),[vt.SemanticAttributes.NET_PEER_NAME]:st.hostname,[vt.SemanticAttributes.NET_PEER_PORT]:st.port},Xr=u?Il(u,Le):Vf(T.url),Ie=R?.opentelemetry?.spanName??`fetch ${T.method} ${T.url}`,j=o.startSpan(Ie,{kind:y.SpanKind.CLIENT,attributes:{...Le,"operation.name":`fetch.${T.method}`,"resource.name":Xr,...R?.opentelemetry?.attributes}},y.context.active());if(!j.isRecording()||!Se(j.spanContext().traceFlags))return j.end(),g(I,R);s&&wl(j,s,T.headers),v(st,R)&&y.propagation.inject(y.context.active(),T.headers,Bf);try{let we=Date.now(),_t=await g(I,{...R,headers:T.headers}),Vl=Date.now()-we;return j.setAttribute(vt.SemanticAttributes.HTTP_STATUS_CODE,_t.status),j.setAttribute("http.response_time",Vl),d&&wl(j,d,_t.headers),_t.status>=500&&xo(j,`Status: ${_t.status} (${_t.statusText})`),_t.body?Gf(_t).then(Yr=>{j.isRecording()&&(j.setAttribute(vt.SemanticAttributes.HTTP_RESPONSE_CONTENT_LENGTH_UNCOMPRESSED,Yr),j.end())},Yr=>{j.isRecording()&&(xo(j,Yr),j.end())}):j.end(),_t}catch(we){throw xo(j,we),j.end(),we}};globalThis.fetch=x}disable(){this.originalFetch&&(globalThis.fetch=this.originalFetch)}},Bf={set(a,n,o){a.set(n,o)}};function Vf(a){let n=a.indexOf("?");return n===-1?a:a.substring(0,n)}function Gf(a){let n=0,c=a.clone().body?.getReader();if(!c)return Promise.resolve(0);let l=()=>c.read().then(({done:i,value:e})=>{if(!i)return n+=e.byteLength,l()});return l().then(()=>n)}function xo(a,n){if(n instanceof Error)a.recordException(n),a.setStatus({code:y.SpanStatusCode.ERROR,message:n.message});else{let o=String(n);a.setStatus({code:y.SpanStatusCode.ERROR,message:o})}}function wl(a,n,o){for(let[c,l]of Object.entries(n)){let i=o.get(l);i!==null&&a.setAttribute(c,i)}}var Kr=class{constructor(n={}){this.configuration=n}start(){let n=Hf(),o=(0,se.getEnvWithoutDefaults)(),c=this.configuration,l=process.env.NEXT_RUNTIME||"nodejs",i=!!n.OTEL_SDK_DISABLED;if(o.OTEL_LOG_LEVEL&&y.diag.setLogger(new y.DiagConsoleLogger,{logLevel:o.OTEL_LOG_LEVEL}),i)return;let e=c.idGenerator??new yr,t=c.contextManager??new kl.AsyncLocalStorageContextManager;t.enable(),this.contextManager=t;let r=n.OTEL_SERVICE_NAME||c.serviceName||"app",u=new Y(Rr({[Dl.SemanticResourceAttributes.SERVICE_NAME]:r,"node.ci":process.env.CI?!0:void 0,"node.env":"production",env:process.env.VERCEL_ENV||process.env.NEXT_PUBLIC_VERCEL_ENV,"vercel.region":process.env.VERCEL_REGION,"vercel.runtime":l,"vercel.sha":process.env.VERCEL_GIT_COMMIT_SHA||process.env.NEXT_PUBLIC_VERCEL_GIT_COMMIT_SHA,"vercel.host":process.env.VERCEL_URL||process.env.NEXT_PUBLIC_VERCEL_URL||void 0,"vercel.branch_host":process.env.VERCEL_BRANCH_URL||process.env.NEXT_PUBLIC_VERCEL_BRANCH_URL||void 0,...c.attributes})),s=c.resourceDetectors??[zi];if(c.autoDetectResources??!0){let T={detectors:s};u=u.merge($i(T))}let v=Ff(c.propagators,n),g=qf(c.traceSampler,n),x=Kf(c.spanProcessors,c,n);x.length===0&&y.diag.warn("@vercel/otel: No span processors configured. No spans will be exported.");let I=c.spanLimits,F=new ea({resource:u,idGenerator:e,sampler:g,spanLimits:I});if(F.addSpanProcessor(new Lr(x)),F.register({contextManager:t,propagator:new ut.CompositePropagator({propagators:v})}),this.tracerProvider=F,c.logRecordProcessor){let T=new Un({resource:u});this.loggerProvider=T,T.addLogRecordProcessor(c.logRecordProcessor),dt.logs.setGlobalLoggerProvider(T)}if(c.metricReader||c.views){let T=new Fn({resource:u,views:c.views??[]});c.metricReader&&T.addMetricReader(c.metricReader),y.metrics.setGlobalMeterProvider(T),this.meterProvider=T}let R=jf(c.instrumentations,c.instrumentationConfig);this.disableInstumentations=(0,Ml.registerInstrumentations)({instrumentations:R}),y.diag.info("@vercel/otel: started",r,l)}async shutdown(){let n=[];this.tracerProvider&&n.push(this.tracerProvider.shutdown()),this.loggerProvider&&n.push(this.loggerProvider.shutdown()),this.meterProvider&&n.push(this.meterProvider.shutdown()),y.diag.info("@vercel/otel: shutting down",n.length,process.env.NEXT_RUNTIME),await Promise.all(n),this.contextManager&&this.contextManager.disable();let{disableInstumentations:o}=this;o&&o()}};function Hf(){let a=(0,se.parseEnvironment)(process.env);return{...se.DEFAULT_ENVIRONMENT,...a}}function jf(a,n){return(a??["auto"]).map(o=>o==="auto"?(y.diag.debug("@vercel/otel: Configure instrumentations: fetch",n?.fetch),[new le(n?.fetch)]):o==="fetch"?(y.diag.debug("@vercel/otel: Configure instrumentations: fetch",n?.fetch),new le(n?.fetch)):o).flat()}function Ff(a,n){let o=n.OTEL_PROPAGATORS&&n.OTEL_PROPAGATORS.length>0?n.OTEL_PROPAGATORS:void 0;return(a??o??["auto"]).map(c=>{if(c==="none")return[];if(c==="auto")return y.diag.debug("@vercel/otel: Configure propagators: tracecontext, baggage"),[new ut.W3CTraceContextPropagator,new ut.W3CBaggagePropagator];if(c==="tracecontext")return y.diag.debug("@vercel/otel: Configure propagator: tracecontext"),new ut.W3CTraceContextPropagator;if(c==="baggage")return y.diag.debug("@vercel/otel: Configure propagator: baggage"),new ut.W3CBaggagePropagator;if(typeof c=="string")throw new Error(`Unknown propagator: "${c}"`);return c}).flat()}var Cl="always_on",ce=1;function qf(a,n){if(a&&typeof a!="string")return a;let o=a&&a!=="auto"?a:n.OTEL_TRACES_SAMPLER||Cl;switch(y.diag.debug("@vercel/otel: Configure sampler: ",o),o){case"always_on":return new $;case"always_off":return new ft;case"parentbased_always_on":return new At({root:new $});case"parentbased_always_off":return new At({root:new ft});case"traceidratio":return new Jt(Ul(n));case"parentbased_traceidratio":return new At({root:new Jt(Ul(n))});default:return y.diag.error(`@vercel/otel: OTEL_TRACES_SAMPLER value "${String(n.OTEL_TRACES_SAMPLER)} invalid, defaulting to ${Cl}".`),new $}}function Ul(a){if(a.OTEL_TRACES_SAMPLER_ARG===void 0||a.OTEL_TRACES_SAMPLER_ARG==="")return y.diag.error(`@vercel/otel: OTEL_TRACES_SAMPLER_ARG is blank, defaulting to ${ce}.`),ce;y.diag.debug("@vercel/otel: Configure sampler probability: ",a.OTEL_TRACES_SAMPLER_ARG);let n=Number(a.OTEL_TRACES_SAMPLER_ARG);return isNaN(n)?(y.diag.error(`@vercel/otel: OTEL_TRACES_SAMPLER_ARG=${a.OTEL_TRACES_SAMPLER_ARG} was given, but it is invalid, defaulting to ${ce}.`),ce):n<0||n>1?(y.diag.error(`@vercel/otel: OTEL_TRACES_SAMPLER_ARG=${a.OTEL_TRACES_SAMPLER_ARG} was given, but it is out of range ([0..1]), defaulting to ${ce}.`),ce):n}function Kf(a,n,o){return(a??["auto"]).map(c=>{if(c==="auto"){if(process.env.VERCEL_OTEL_ENDPOINTS){let l=process.env.VERCEL_OTEL_ENDPOINTS_PORT||"4318",i=process.env.VERCEL_OTEL_ENDPOINTS_PROTOCOL||"http/protobuf";y.diag.debug("@vercel/otel: Configure vercel otel collector on port: ",l,i);let e={url:`http://localhost:${l}/v1/traces`,headers:{}},t=i==="http/protobuf"?new Ft(e):new re(e);return new ve(t)}return n.traceExporter||o.OTEL_EXPORTER_OTLP_TRACES_ENDPOINT||o.OTEL_EXPORTER_OTLP_ENDPOINT?new ve(Xf(n.traceExporter,o)):void 0}return c}).filter(zf)}function Xf(a,n){if(a&&a!=="auto")return a;let o=process.env.OTEL_EXPORTER_OTLP_TRACES_PROTOCOL??process.env.OTEL_EXPORTER_OTLP_PROTOCOL??"http/protobuf",c=Jf(n),l={...ut.baggageUtils.parseKeyPairsIntoRecord(n.OTEL_EXPORTER_OTLP_HEADERS),...ut.baggageUtils.parseKeyPairsIntoRecord(n.OTEL_EXPORTER_OTLP_TRACES_HEADERS)};switch(y.diag.debug("@vercel/otel: Configure trace exporter: ",o,c,`headers: ${Object.keys(l).join(",")||"<none>"}`),o){case"http/json":return new re({url:c,headers:l});case"http/protobuf":return new Ft({url:c,headers:l});default:return y.diag.warn(`@vercel/otel: Unsupported OTLP traces protocol: ${o}. Using http/protobuf.`),new Ft}}var Bl="v1/traces",Yf=`http://localhost:4318/${Bl}`;function Jf(a){let n=a.OTEL_EXPORTER_OTLP_TRACES_ENDPOINT;if(n&&typeof n=="string")return n;let o=a.OTEL_EXPORTER_OTLP_ENDPOINT;return o&&typeof o=="string"?`${o}/${Bl}`:Yf}function zf(a){return a!=null}function t_(a){let n;a?typeof a=="string"?n={serviceName:a}:n=a:n={},new Kr(n).start()}export{le as FetchInstrumentation,re as OTLPHttpJsonTraceExporter,Ft as OTLPHttpProtoTraceExporter,t_ as registerOTel};
|
|
15
|
+
`,kn(u,n),`To resolve the conflict:
|
|
16
|
+
`,Bn(u,n))}}catch(s){c={error:s}}finally{try{t&&!t.done&&(l=e.return)&&l.call(e)}finally{if(c)throw c.error}}return i},a}();var Ga=function(){function a(n){this._backingStorages=n}return a.prototype.record=function(n,o,c,l){this._backingStorages.forEach(function(i){i.record(n,o,c,l)})},a}();b();b();var Ha=function(){function a(n,o){this._instrumentName=n,this._valueType=o,this._buffer=new nt}return a.prototype.observe=function(n,o){if(o===void 0&&(o={}),typeof n!="number"){y.diag.warn("non-number value provided to metric "+this._instrumentName+": "+n);return}this._valueType===y.ValueType.INT&&!Number.isInteger(n)&&(y.diag.warn("INT value type cannot accept a floating-point value for "+this._instrumentName+", ignoring the fractional digits."),n=Math.trunc(n),!Number.isInteger(n))||this._buffer.set(o,n)},a}();var ja=function(){function a(){this._buffer=new Map}return a.prototype.observe=function(n,o,c){if(c===void 0&&(c={}),!!_e(n)){var l=this._buffer.get(n);if(l==null&&(l=new nt,this._buffer.set(n,l)),typeof o!="number"){y.diag.warn("non-number value provided to metric "+n._descriptor.name+": "+o);return}n._descriptor.valueType===y.ValueType.INT&&!Number.isInteger(o)&&(y.diag.warn("INT value type cannot accept a floating-point value for "+n._descriptor.name+", ignoring the fractional digits."),o=Math.trunc(o),!Number.isInteger(o))||l.set(c,o)}},a}();var Hn=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},jn=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Fa=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},qa=function(a,n,o){if(o||arguments.length===2)for(var c=0,l=n.length,i;c<l;c++)(i||!(c in n))&&(i||(i=Array.prototype.slice.call(n,0,c)),i[c]=n[c]);return a.concat(i||Array.prototype.slice.call(n))},Ka=function(){function a(){this._callbacks=[],this._batchCallbacks=[]}return a.prototype.addCallback=function(n,o){var c=this._findCallback(n,o);c>=0||this._callbacks.push({callback:n,instrument:o})},a.prototype.removeCallback=function(n,o){var c=this._findCallback(n,o);c<0||this._callbacks.splice(c,1)},a.prototype.addBatchCallback=function(n,o){var c=new Set(o.filter(_e));if(c.size===0){y.diag.error("BatchObservableCallback is not associated with valid instruments",o);return}var l=this._findBatchCallback(n,c);l>=0||this._batchCallbacks.push({callback:n,instruments:c})},a.prototype.removeBatchCallback=function(n,o){var c=new Set(o.filter(_e)),l=this._findBatchCallback(n,c);l<0||this._batchCallbacks.splice(l,1)},a.prototype.observe=function(n,o){return Hn(this,void 0,void 0,function(){var c,l,i,e;return jn(this,function(t){switch(t.label){case 0:return c=this._observeCallbacks(n,o),l=this._observeBatchCallbacks(n,o),[4,Sa(qa(qa([],Fa(c),!1),Fa(l),!1))];case 1:return i=t.sent(),e=i.filter(Ta).map(function(r){return r.reason}),[2,e]}})})},a.prototype._observeCallbacks=function(n,o){var c=this;return this._callbacks.map(function(l){var i=l.callback,e=l.instrument;return Hn(c,void 0,void 0,function(){var t,r;return jn(this,function(u){switch(u.label){case 0:return t=new Ha(e._descriptor.name,e._descriptor.valueType),r=Promise.resolve(i(t)),o!=null&&(r=Mn(r,o)),[4,r];case 1:return u.sent(),e._metricStorages.forEach(function(s){s.record(t._buffer,n)}),[2]}})})})},a.prototype._observeBatchCallbacks=function(n,o){var c=this;return this._batchCallbacks.map(function(l){var i=l.callback,e=l.instruments;return Hn(c,void 0,void 0,function(){var t,r;return jn(this,function(u){switch(u.label){case 0:return t=new ja,r=Promise.resolve(i(t)),o!=null&&(r=Mn(r,o)),[4,r];case 1:return u.sent(),e.forEach(function(s){var d=t._buffer.get(s);d!=null&&s._metricStorages.forEach(function(v){v.record(d,n)})}),[2]}})})})},a.prototype._findCallback=function(n,o){return this._callbacks.findIndex(function(c){return c.callback===n&&c.instrument===o})},a.prototype._findBatchCallback=function(n,o){return this._batchCallbacks.findIndex(function(c){return c.callback===n&&Oa(c.instruments,o)})},a}();var gp=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),Xa=function(a){gp(n,a);function n(o,c,l,i){var e=a.call(this,o)||this;return e._attributesProcessor=l,e._deltaMetricStorage=new Tr(c),e._temporalMetricStorage=new Or(c,i),e}return n.prototype.record=function(o,c,l,i){c=this._attributesProcessor.process(c,l),this._deltaMetricStorage.record(o,c,l,i)},n.prototype.collect=function(o,c){var l=this._deltaMetricStorage.collect();return this._temporalMetricStorage.buildMetrics(o,this._instrumentDescriptor,l,c)},n}(Sr);var Ya=function(){var a=function(n,o){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&(c[i]=l[i])},a(n,o)};return function(n,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");a(n,o);function c(){this.constructor=n}n.prototype=o===null?Object.create(o):(c.prototype=o.prototype,new c)}}(),gr=function(){function a(){}return a.Noop=function(){return Np},a}();var Ap=function(a){Ya(n,a);function n(){return a!==null&&a.apply(this,arguments)||this}return n.prototype.process=function(o,c){return o},n}(gr);var am=function(a){Ya(n,a);function n(o){var c=a.call(this)||this;return c._allowedAttributeNames=o,c}return n.prototype.process=function(o,c){var l=this,i={};return Object.keys(o).filter(function(e){return l._allowedAttributeNames.includes(e)}).forEach(function(e){return i[e]=o[e]}),i},n}(gr);var Np=new Ap;var Pp=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},xp=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Rp=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},Ja=function(){function a(n,o){this._meterProviderSharedState=n,this._instrumentationScope=o,this.metricStorageRegistry=new Ba,this.observableRegistry=new Ka,this.meter=new Ma(this)}return a.prototype.registerMetricStorage=function(n){var o=this._registerMetricStorage(n,Xa);return o.length===1?o[0]:new Ga(o)},a.prototype.registerAsyncMetricStorage=function(n){var o=this._registerMetricStorage(n,ka);return o},a.prototype.collect=function(n,o,c){return Pp(this,void 0,void 0,function(){var l,i,e;return xp(this,function(t){switch(t.label){case 0:return[4,this.observableRegistry.observe(o,c?.timeoutMillis)];case 1:return l=t.sent(),i=this.metricStorageRegistry.getStorages(n),i.length===0?[2,null]:(e=i.map(function(r){return r.collect(n,o)}).filter(_a),e.length===0?[2,{errors:l}]:[2,{scopeMetrics:{scope:this._instrumentationScope,metrics:e},errors:l}])}})})},a.prototype._registerMetricStorage=function(n,o){var c=this,l=this._meterProviderSharedState.viewRegistry.findViews(n,this._instrumentationScope),i=l.map(function(r){var u=Aa(r,n),s=c.metricStorageRegistry.findOrUpdateCompatibleStorage(u);if(s!=null)return s;var d=r.aggregation.createAggregator(u),v=new o(u,d,r.attributesProcessor,c._meterProviderSharedState.metricCollectors);return c.metricStorageRegistry.register(v),v});if(i.length===0){var e=this._meterProviderSharedState.selectAggregations(n.type),t=e.map(function(r){var u=Rp(r,2),s=u[0],d=u[1],v=c.metricStorageRegistry.findOrUpdateCompatibleCollectorStorage(s,n);if(v!=null)return v;var g=d.createAggregator(n),x=new o(n,g,gr.Noop(),[s]);return c.metricStorageRegistry.registerForCollector(s,x),x});i=i.concat(t)}return i},a}();var Lp=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},za=function(){function a(n){this.resource=n,this.viewRegistry=new Pa,this.metricCollectors=[],this.meterSharedStates=new Map}return a.prototype.getMeterSharedState=function(n){var o=ba(n),c=this.meterSharedStates.get(o);return c==null&&(c=new Ja(this,n),this.meterSharedStates.set(o,c)),c},a.prototype.selectAggregations=function(n){var o,c,l=[];try{for(var i=Lp(this.metricCollectors),e=i.next();!e.done;e=i.next()){var t=e.value;l.push([t,t.selectAggregation(n)])}}catch(r){o={error:r}}finally{try{e&&!e.done&&(c=i.return)&&c.call(i)}finally{if(o)throw o.error}}return l},a}();var Wa=N(V()),Ar=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},Nr=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Ip=function(a,n){var o=typeof Symbol=="function"&&a[Symbol.iterator];if(!o)return a;var c=o.call(a),l,i=[],e;try{for(;(n===void 0||n-- >0)&&!(l=c.next()).done;)i.push(l.value)}catch(t){e={error:t}}finally{try{l&&!l.done&&(o=c.return)&&o.call(c)}finally{if(e)throw e.error}}return i},wp=function(a,n,o){if(o||arguments.length===2)for(var c=0,l=n.length,i;c<l;c++)(i||!(c in n))&&(i||(i=Array.prototype.slice.call(n,0,c)),i[c]=n[c]);return a.concat(i||Array.prototype.slice.call(n))},$a=function(){function a(n,o){this._sharedState=n,this._metricReader=o}return a.prototype.collect=function(n){return Ar(this,void 0,void 0,function(){var o,c,l,i,e=this;return Nr(this,function(t){switch(t.label){case 0:return o=(0,Wa.millisToHrTime)(Date.now()),c=[],l=[],i=Array.from(this._sharedState.meterSharedStates.values()).map(function(r){return Ar(e,void 0,void 0,function(){var u;return Nr(this,function(s){switch(s.label){case 0:return[4,r.collect(this,o,n)];case 1:return u=s.sent(),u?.scopeMetrics!=null&&c.push(u.scopeMetrics),u?.errors!=null&&l.push.apply(l,wp([],Ip(u.errors),!1)),[2]}})})}),[4,Promise.all(i)];case 1:return t.sent(),[2,{resourceMetrics:{resource:this._sharedState.resource,scopeMetrics:c},errors:l}]}})})},a.prototype.forceFlush=function(n){return Ar(this,void 0,void 0,function(){return Nr(this,function(o){switch(o.label){case 0:return[4,this._metricReader.forceFlush(n)];case 1:return o.sent(),[2]}})})},a.prototype.shutdown=function(n){return Ar(this,void 0,void 0,function(){return Nr(this,function(o){switch(o.label){case 0:return[4,this._metricReader.shutdown(n)];case 1:return o.sent(),[2]}})})},a.prototype.selectAggregationTemporality=function(n){return this._metricReader.selectAggregationTemporality(n)},a.prototype.selectAggregation=function(n){return this._metricReader.selectAggregation(n)},a}();var Qa=function(a,n,o,c){function l(i){return i instanceof o?i:new o(function(e){e(i)})}return new(o||(o=Promise))(function(i,e){function t(s){try{u(c.next(s))}catch(d){e(d)}}function r(s){try{u(c.throw(s))}catch(d){e(d)}}function u(s){s.done?i(s.value):l(s.value).then(t,r)}u((c=c.apply(a,n||[])).next())})},Za=function(a,n){var o={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},c,l,i,e;return e={next:t(0),throw:t(1),return:t(2)},typeof Symbol=="function"&&(e[Symbol.iterator]=function(){return this}),e;function t(u){return function(s){return r([u,s])}}function r(u){if(c)throw new TypeError("Generator is already executing.");for(;o;)try{if(c=1,l&&(i=u[0]&2?l.return:u[0]?l.throw||((i=l.return)&&i.call(l),0):l.next)&&!(i=i.call(l,u[1])).done)return i;switch(l=0,i&&(u=[u[0]&2,i.value]),u[0]){case 0:case 1:i=u;break;case 4:return o.label++,{value:u[1],done:!1};case 5:o.label++,l=u[1],u=[0];continue;case 7:u=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!(i=i.length>0&&i[i.length-1])&&(u[0]===6||u[0]===2)){o=0;continue}if(u[0]===3&&(!i||u[1]>i[0]&&u[1]<i[3])){o.label=u[1];break}if(u[0]===6&&o.label<i[1]){o.label=i[1],i=u;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(u);break}i[2]&&o.ops.pop(),o.trys.pop();continue}u=n.call(a,o)}catch(s){u=[6,s],l=0}finally{c=i=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Cp=function(a){var n=typeof Symbol=="function"&&Symbol.iterator,o=n&&a[n],c=0;if(o)return o.call(a);if(a&&typeof a.length=="number")return{next:function(){return a&&c>=a.length&&(a=void 0),{value:a&&a[c++],done:!a}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")},Fn=function(){function a(n){var o,c,l;this._shutdown=!1;var i=Y.default().merge((l=n?.resource)!==null&&l!==void 0?l:Y.empty());if(this._sharedState=new za(i),n?.views!=null&&n.views.length>0)try{for(var e=Cp(n.views),t=e.next();!t.done;t=e.next()){var r=t.value;this._sharedState.viewRegistry.addView(r)}}catch(u){o={error:u}}finally{try{t&&!t.done&&(c=e.return)&&c.call(e)}finally{if(o)throw o.error}}}return a.prototype.getMeter=function(n,o,c){return o===void 0&&(o=""),c===void 0&&(c={}),this._shutdown?(y.diag.warn("A shutdown MeterProvider cannot provide a Meter"),(0,y.createNoopMeter)()):this._sharedState.getMeterSharedState({name:n,version:o,schemaUrl:c.schemaUrl}).meter},a.prototype.addMetricReader=function(n){var o=new $a(this._sharedState,n);n.setMetricProducer(o),this._sharedState.metricCollectors.push(o)},a.prototype.shutdown=function(n){return Qa(this,void 0,void 0,function(){return Za(this,function(o){switch(o.label){case 0:return this._shutdown?(y.diag.warn("shutdown may only be called once per MeterProvider"),[2]):(this._shutdown=!0,[4,Promise.all(this._sharedState.metricCollectors.map(function(c){return c.shutdown(n)}))]);case 1:return o.sent(),[2]}})})},a.prototype.forceFlush=function(n){return Qa(this,void 0,void 0,function(){return Za(this,function(o){switch(o.label){case 0:return this._shutdown?(y.diag.warn("invalid attempt to force flush after MeterProvider shutdown"),[2]):[4,Promise.all(this._sharedState.metricCollectors.map(function(c){return c.forceFlush(n)}))];case 1:return o.sent(),[2]}})})},a}();var Dl=N(Ot(),1),pe=N(Be(),1),Vl=N(nu(),1),ut=N(V(),1);b();var Bp=Symbol.for("@vercel/request-context");function ee(){return globalThis[Bp]?.get()}var Xn=N(Ot(),1);function Rr(a){return Object.fromEntries(Object.entries(a).filter(([n,o])=>o!==void 0))}function ou(a){return a?a.split("::").at(-1):void 0}function iu(a=ee(),n){if(!a)return;let o=n?Hp(n,a.headers):void 0;return Rr({[Xn.SemanticAttributes.HTTP_HOST]:a.headers.host,[Xn.SemanticAttributes.HTTP_USER_AGENT]:a.headers["user-agent"],"http.referer":a.headers.referer,"vercel.request_id":ou(a.headers["x-vercel-id"]),"vercel.matched_path":a.headers["x-matched-path"],"vercel.edge_region":a.headers["x-vercel-edge-region"],...o})}var Gp={keys(a){return[]},get(a,n){return a[n.toLocaleLowerCase()]}};function Hp(a,n){if(typeof a=="function")return a(n,Gp);let o={};for(let[c,l]of Object.entries(a)){let i=n[l.toLocaleLowerCase()];i!==void 0&&(o[c]=i)}return o}b();function Se(a){return(a&y.TraceFlags.SAMPLED)!==0}var Lr=class{constructor(n,o){this.processors=n;this.attributesFromHeaders=o;this.rootSpanIds=new Map;this.waitSpanEnd=new Map}forceFlush(){return Promise.all(this.processors.map(n=>n.forceFlush().catch(o=>{y.diag.error("@vercel/otel: forceFlush failed:",o)}))).then(()=>{})}shutdown(){return Promise.all(this.processors.map(n=>n.shutdown().catch(()=>{}))).then(()=>{})}onStart(n,o){let{traceId:c,spanId:l,traceFlags:i}=n.spanContext(),e=!n.parentSpanId||!this.rootSpanIds.has(c);if(e?this.rootSpanIds.set(c,{rootSpanId:l,open:[]}):this.rootSpanIds.get(c)?.open.push(n),e&&Se(i)){let t=ee(),r=iu(t,this.attributesFromHeaders);r&&n.setAttributes(r),t&&t.waitUntil(async()=>{if(this.rootSpanIds.has(c)){let u=new Promise(d=>{this.waitSpanEnd.set(c,d)}),s;await Promise.race([u,new Promise(d=>{s=setTimeout(()=>{this.waitSpanEnd.delete(c),d(void 0)},50)})]),s&&clearTimeout(s)}return this.forceFlush()})}for(let t of this.processors)t.onStart(n,o)}onEnd(n){let{traceId:o,spanId:c,traceFlags:l}=n.spanContext(),i=Se(l),e=this.rootSpanIds.get(o),t=e?.rootSpanId===c;if(i){let r=Fp(n);r&&Object.assign(n.attributes,r)}if(t){if(this.rootSpanIds.delete(o),e.open.length>0){for(let r of e.open)if(!r.ended&&r.spanContext().spanId!==c)try{r.end()}catch(u){y.diag.error("@vercel/otel: onEnd failed:",u)}}}else if(e)for(let r=0;r<e.open.length;r++)e.open[r]?.spanContext().spanId===c&&e.open.splice(r,1);for(let r of this.processors)r.onEnd(n);if(t){let r=this.waitSpanEnd.get(o);r&&(this.waitSpanEnd.delete(o),r())}}},jp={[y.SpanKind.INTERNAL]:"internal",[y.SpanKind.SERVER]:"server",[y.SpanKind.CLIENT]:"client",[y.SpanKind.PRODUCER]:"producer",[y.SpanKind.CONSUMER]:"consumer"};function Fp(a){let{kind:n,attributes:o}=a,{"operation.name":c,"resouce.name":l,"span.type":i,"next.span_type":e,"http.method":t,"http.route":r}=o;if(c)return;let u=l??(t&&typeof t=="string"&&r&&typeof r=="string"?`${t} ${r}`:r);if(a.kind===y.SpanKind.SERVER&&t&&r&&typeof t=="string"&&typeof r=="string")return{"operation.name":"web.request","resource.name":u};let s=a.instrumentationLibrary.name,d=e??i;if(d&&typeof d=="string"){let v=au(s,d);return r?{"operation.name":v,"resource.name":u}:{"operation.name":v}}return{"operation.name":au(s,n===y.SpanKind.INTERNAL?"":jp[n])}}function au(a,n){if(!a)return n;let o=a.replace(/[ @./]/g,"_");return o.startsWith("_")&&(o=o.slice(1)),n?`${o}.${n}`:o}var Eu=N(Zn(),1);var _u=N(Ur(),1);b();var re=class extends _u.OTLPExporterBase{constructor(n={}){super(n),n.headers&&(this._headers=n.headers)}onShutdown(){y.diag.debug("@vercel/otel/otlp: onShutdown")}onInit(){y.diag.debug("@vercel/otel/otlp: onInit")}send(n,o,c){if(this._shutdownOnce.isCalled){y.diag.debug("@vercel/otel/otlp: Shutdown already started. Cannot send objects");return}let l=this.convert(n),i,e,t;try{({body:i,contentType:e,headers:t}=this.toMessage(l))}catch(u){y.diag.warn("@vercel/otel/otlp: no proto",u);return}let r=fetch(this.url,{method:"POST",body:i,headers:{...this._headers,...t,"Content-Type":e,"User-Agent":"OTel-OTLP-Exporter-JavaScript/0.46.0"},next:{internal:!0}}).then(u=>{y.diag.debug("@vercel/otel/otlp: onSuccess",u.status,u.statusText),o(),u.arrayBuffer().catch(()=>{})}).catch(u=>{y.diag.error("@vercel/otel/otlp: onError",u),c(u)}).finally(()=>{let u=this._sendingPromises.indexOf(r);this._sendingPromises.splice(u,1)});this._sendingPromises.push(r)}getDefaultUrl(n){throw new Error("Method not implemented.")}};var pf="v1/traces",ff=`http://localhost:4318/${pf}`;function Mr(a){return typeof a.url=="string"?a.url:ff}var ne=class{constructor(n={}){this.impl=new no(n)}export(n,o){this.impl.export(n,o)}shutdown(){return this.impl.shutdown()}forceFlush(){return this.impl.forceFlush()}},no=class extends re{convert(n){return(0,Eu.createExportTraceServiceRequest)(n,{useHex:!0,useLongBits:!1})}toMessage(n){return{body:JSON.stringify(n),contentType:"application/json"}}getDefaultUrl(n){return Mr(n)}};var xl=N(Zn(),1),Rl=N(Pl(),1),Ll=N(go(),1);var Ft=class{constructor(n={}){this.impl=new Po(n)}export(n,o){this.impl.export(n,o)}shutdown(){return this.impl.shutdown()}forceFlush(){return this.impl.forceFlush()}},Po=class extends re{convert(n){return(0,xl.createExportTraceServiceRequest)(n,void 0)}toMessage(n){let o=Rl.ServiceClientType.SPANS,c=(0,Ll.getExportRequestProto)(o),l=c.create(n);return{body:c.encode(l).finish(),contentType:"application/x-protobuf",headers:{accept:"application/x-protobuf"}}}getDefaultUrl(n){return Mr(n)}};b();var vt=N(Ot(),1);function Il(a,n){return a.replace(/\{(?<temp1>[^{}]+)\}/g,(o,c)=>{let l=n[c];return l!==void 0?String(l):o})}var ce=class{constructor(n={}){this.instrumentationName="@vercel/otel/fetch";this.instrumentationVersion="1.0.0";this.config=n}getConfig(){return this.config}setConfig(){}setTracerProvider(n){this.tracerProvider=n}setMeterProvider(){}enable(){this.disable();let{tracerProvider:n}=this;if(!n)return;let o=n.getTracer(this.instrumentationName,this.instrumentationVersion),c=this.config.ignoreUrls??[],l=(I,F)=>{if(F?.opentelemetry?.ignore!==void 0)return F.opentelemetry.ignore;if(c.length===0)return!1;let R=I.toString();return c.some(T=>typeof T=="string"?T==="*"?!0:R.startsWith(T):T.test(R))},i=process.env.VERCEL_URL||process.env.NEXT_PUBLIC_VERCEL_URL||null,e=process.env.VERCEL_BRANCH_URL||process.env.NEXT_PUBLIC_VERCEL_BRANCH_URL||null,t=this.config.propagateContextUrls??[],r=this.config.dontPropagateContextUrls??[],u=this.config.resourceNameTemplate,{attributesFromRequestHeaders:s,attributesFromResponseHeaders:d}=this.config,v=(I,F)=>{if(F?.opentelemetry?.propagateContext)return F.opentelemetry.propagateContext;let R=I.toString();return r.length>0&&r.some(T=>typeof T=="string"?T==="*"?!0:R.startsWith(T):T.test(R))?!1:i&&I.protocol==="https:"&&(I.host===i||I.host===e||I.host===ee()?.headers.host)||!i&&I.protocol==="http:"&&I.hostname==="localhost"?!0:t.some(T=>typeof T=="string"?T==="*"?!0:R.startsWith(T):T.test(R))};process.env.NEXT_OTEL_FETCH_DISABLED="1";let g=globalThis.fetch;this.originalFetch=g;let x=async(I,F)=>{let R=F;if(R?.next?.internal)return g(I,R);let T=new Request(I instanceof Request?I.clone():I,R),st=new URL(T.url);if(l(st,R))return g(I,R);let Le={[vt.SemanticAttributes.HTTP_METHOD]:T.method,[vt.SemanticAttributes.HTTP_URL]:T.url,[vt.SemanticAttributes.HTTP_HOST]:st.host,[vt.SemanticAttributes.HTTP_SCHEME]:st.protocol.replace(":",""),[vt.SemanticAttributes.NET_PEER_NAME]:st.hostname,[vt.SemanticAttributes.NET_PEER_PORT]:st.port},Xr=u?Il(u,Le):Hf(T.url),Ie=R?.opentelemetry?.spanName??`fetch ${T.method} ${T.url}`,j=o.startSpan(Ie,{kind:y.SpanKind.CLIENT,attributes:{...Le,"operation.name":`fetch.${T.method}`,"resource.name":Xr,...R?.opentelemetry?.attributes}},y.context.active());if(!j.isRecording()||!Se(j.spanContext().traceFlags))return j.end(),g(I,R);v(st,R)&&y.propagation.inject(y.context.active(),T.headers,Gf),s&&wl(j,s,T.headers);try{let we=Date.now(),_t=await g(I,{...R,headers:T.headers}),Bl=Date.now()-we;return j.setAttribute(vt.SemanticAttributes.HTTP_STATUS_CODE,_t.status),j.setAttribute("http.response_time",Bl),d&&wl(j,d,_t.headers),_t.status>=500&&xo(j,`Status: ${_t.status} (${_t.statusText})`),_t.body?jf(_t).then(Yr=>{j.isRecording()&&(j.setAttribute(vt.SemanticAttributes.HTTP_RESPONSE_CONTENT_LENGTH_UNCOMPRESSED,Yr),j.end())},Yr=>{j.isRecording()&&(xo(j,Yr),j.end())}):j.end(),_t}catch(we){throw xo(j,we),j.end(),we}};globalThis.fetch=x}disable(){this.originalFetch&&(globalThis.fetch=this.originalFetch)}},Gf={set(a,n,o){a.set(n,o)}};function Hf(a){let n=a.indexOf("?");return n===-1?a:a.substring(0,n)}function jf(a){let n=0,c=a.clone().body?.getReader();if(!c)return Promise.resolve(0);let l=()=>c.read().then(({done:i,value:e})=>{if(!i)return n+=e.byteLength,l()});return l().then(()=>n)}function xo(a,n){if(n instanceof Error)a.recordException(n),a.setStatus({code:y.SpanStatusCode.ERROR,message:n.message});else{let o=String(n);a.setStatus({code:y.SpanStatusCode.ERROR,message:o})}}function wl(a,n,o){for(let[c,l]of Object.entries(n)){let i=o.get(l);i!==null&&a.setAttribute(c,i)}}var Kr=class{constructor(n={}){this.configuration=n}start(){let n=Ff(),o=(0,pe.getEnvWithoutDefaults)(),c=this.configuration,l=process.env.NEXT_RUNTIME||"nodejs",i=!!n.OTEL_SDK_DISABLED;if(o.OTEL_LOG_LEVEL&&y.diag.setLogger(new y.DiagConsoleLogger,{logLevel:o.OTEL_LOG_LEVEL}),i)return;let e=c.idGenerator??new yr,t=c.contextManager??new Vl.AsyncLocalStorageContextManager;t.enable(),this.contextManager=t;let r=n.OTEL_SERVICE_NAME||c.serviceName||"app",u=new Y(Rr({[Dl.SemanticResourceAttributes.SERVICE_NAME]:r,"node.ci":process.env.CI?!0:void 0,"node.env":"production",env:process.env.VERCEL_ENV||process.env.NEXT_PUBLIC_VERCEL_ENV,"vercel.region":process.env.VERCEL_REGION,"vercel.runtime":l,"vercel.sha":process.env.VERCEL_GIT_COMMIT_SHA||process.env.NEXT_PUBLIC_VERCEL_GIT_COMMIT_SHA,"vercel.host":process.env.VERCEL_URL||process.env.NEXT_PUBLIC_VERCEL_URL||void 0,"vercel.branch_host":process.env.VERCEL_BRANCH_URL||process.env.NEXT_PUBLIC_VERCEL_BRANCH_URL||void 0,...c.attributes})),s=c.resourceDetectors??[zi];if(c.autoDetectResources??!0){let T={detectors:s};u=u.merge($i(T))}let v=Kf(c.propagators,n),g=Xf(c.traceSampler,n),x=Yf(c.spanProcessors,c,n);x.length===0&&y.diag.warn("@vercel/otel: No span processors configured. No spans will be exported.");let I=c.spanLimits,F=new ea({resource:u,idGenerator:e,sampler:g,spanLimits:I});if(F.addSpanProcessor(new Lr(x,c.attributesFromHeaders)),F.register({contextManager:t,propagator:new ut.CompositePropagator({propagators:v})}),this.tracerProvider=F,c.logRecordProcessor){let T=new Un({resource:u});this.loggerProvider=T,T.addLogRecordProcessor(c.logRecordProcessor),dt.logs.setGlobalLoggerProvider(T)}if(c.metricReader||c.views){let T=new Fn({resource:u,views:c.views??[]});c.metricReader&&T.addMetricReader(c.metricReader),y.metrics.setGlobalMeterProvider(T),this.meterProvider=T}let R=qf(c.instrumentations,c.instrumentationConfig);this.disableInstumentations=(0,Ml.registerInstrumentations)({instrumentations:R}),y.diag.info("@vercel/otel: started",r,l)}async shutdown(){let n=[];this.tracerProvider&&n.push(this.tracerProvider.shutdown()),this.loggerProvider&&n.push(this.loggerProvider.shutdown()),this.meterProvider&&n.push(this.meterProvider.shutdown()),y.diag.info("@vercel/otel: shutting down",n.length,process.env.NEXT_RUNTIME),await Promise.all(n),this.contextManager&&this.contextManager.disable();let{disableInstumentations:o}=this;o&&o()}};function Ff(){let a=(0,pe.parseEnvironment)(process.env);return{...pe.DEFAULT_ENVIRONMENT,...a}}function qf(a,n){return(a??["auto"]).map(o=>o==="auto"?(y.diag.debug("@vercel/otel: Configure instrumentations: fetch",n?.fetch),[new ce(n?.fetch)]):o==="fetch"?(y.diag.debug("@vercel/otel: Configure instrumentations: fetch",n?.fetch),new ce(n?.fetch)):o).flat()}function Kf(a,n){let o=n.OTEL_PROPAGATORS&&n.OTEL_PROPAGATORS.length>0?n.OTEL_PROPAGATORS:void 0;return(a??o??["auto"]).map(c=>{if(c==="none")return[];if(c==="auto")return y.diag.debug("@vercel/otel: Configure propagators: tracecontext, baggage"),[new ut.W3CTraceContextPropagator,new ut.W3CBaggagePropagator];if(c==="tracecontext")return y.diag.debug("@vercel/otel: Configure propagator: tracecontext"),new ut.W3CTraceContextPropagator;if(c==="baggage")return y.diag.debug("@vercel/otel: Configure propagator: baggage"),new ut.W3CBaggagePropagator;if(typeof c=="string")throw new Error(`Unknown propagator: "${c}"`);return c}).flat()}var Cl="always_on",se=1;function Xf(a,n){if(a&&typeof a!="string")return a;let o=a&&a!=="auto"?a:n.OTEL_TRACES_SAMPLER||Cl;switch(y.diag.debug("@vercel/otel: Configure sampler: ",o),o){case"always_on":return new $;case"always_off":return new ft;case"parentbased_always_on":return new At({root:new $});case"parentbased_always_off":return new At({root:new ft});case"traceidratio":return new Jt(Ul(n));case"parentbased_traceidratio":return new At({root:new Jt(Ul(n))});default:return y.diag.error(`@vercel/otel: OTEL_TRACES_SAMPLER value "${String(n.OTEL_TRACES_SAMPLER)} invalid, defaulting to ${Cl}".`),new $}}function Ul(a){if(a.OTEL_TRACES_SAMPLER_ARG===void 0||a.OTEL_TRACES_SAMPLER_ARG==="")return y.diag.error(`@vercel/otel: OTEL_TRACES_SAMPLER_ARG is blank, defaulting to ${se}.`),se;y.diag.debug("@vercel/otel: Configure sampler probability: ",a.OTEL_TRACES_SAMPLER_ARG);let n=Number(a.OTEL_TRACES_SAMPLER_ARG);return isNaN(n)?(y.diag.error(`@vercel/otel: OTEL_TRACES_SAMPLER_ARG=${a.OTEL_TRACES_SAMPLER_ARG} was given, but it is invalid, defaulting to ${se}.`),se):n<0||n>1?(y.diag.error(`@vercel/otel: OTEL_TRACES_SAMPLER_ARG=${a.OTEL_TRACES_SAMPLER_ARG} was given, but it is out of range ([0..1]), defaulting to ${se}.`),se):n}function Yf(a,n,o){return[...(a??["auto"]).map(c=>{if(c==="auto"){if(process.env.VERCEL_OTEL_ENDPOINTS){let l=process.env.VERCEL_OTEL_ENDPOINTS_PORT||"4318",i=process.env.VERCEL_OTEL_ENDPOINTS_PROTOCOL||"http/protobuf";y.diag.debug("@vercel/otel: Configure vercel otel collector on port: ",l,i);let e={url:`http://localhost:${l}/v1/traces`,headers:{}},t=i==="http/protobuf"?new Ft(e):new ne(e);return new $t(t)}return!n.traceExporter||n.traceExporter==="auto"||o.OTEL_EXPORTER_OTLP_TRACES_ENDPOINT||o.OTEL_EXPORTER_OTLP_ENDPOINT?new $t(Jf(o)):void 0}return c}).filter($f),...n.traceExporter&&n.traceExporter!=="auto"?[new $t(n.traceExporter)]:[]]}function Jf(a){let n=process.env.OTEL_EXPORTER_OTLP_TRACES_PROTOCOL??process.env.OTEL_EXPORTER_OTLP_PROTOCOL??"http/protobuf",o=Wf(a),c={...ut.baggageUtils.parseKeyPairsIntoRecord(a.OTEL_EXPORTER_OTLP_HEADERS),...ut.baggageUtils.parseKeyPairsIntoRecord(a.OTEL_EXPORTER_OTLP_TRACES_HEADERS)};switch(y.diag.debug("@vercel/otel: Configure trace exporter: ",n,o,`headers: ${Object.keys(c).join(",")||"<none>"}`),n){case"http/json":return new ne({url:o,headers:c});case"http/protobuf":return new Ft({url:o,headers:c});default:return y.diag.warn(`@vercel/otel: Unsupported OTLP traces protocol: ${n}. Using http/protobuf.`),new Ft}}var kl="v1/traces",zf=`http://localhost:4318/${kl}`;function Wf(a){let n=a.OTEL_EXPORTER_OTLP_TRACES_ENDPOINT;if(n&&typeof n=="string")return n;let o=a.OTEL_EXPORTER_OTLP_ENDPOINT;return o&&typeof o=="string"?`${o}/${kl}`:zf}function $f(a){return a!=null}function r_(a){let n;a?typeof a=="string"?n={serviceName:a}:n=a:n={},new Kr(n).start()}export{ce as FetchInstrumentation,ne as OTLPHttpJsonTraceExporter,Ft as OTLPHttpProtoTraceExporter,r_ as registerOTel};
|