@miradorlabs/web-grpc 2.30.0 → 2.32.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/package.json +1 -1
- package/proto/gateway/web/v1/metric_gateway.ts +551 -0
- package/proto/gateway/web/v1/metric_gateway_grpc_pb.js +40 -0
- package/proto/gateway/web/v1/metric_gateway_pb.js +1246 -0
- package/proto/gateway/web/v1/trace_gateway.ts +118 -420
- package/proto/gateway/web/v1/trace_gateway_grpc_pb.js +0 -33
- package/proto/gateway/web/v1/trace_gateway_pb.js +208 -828
package/package.json
CHANGED
|
@@ -503,6 +503,48 @@ export interface WidgetQueryError {
|
|
|
503
503
|
message: string;
|
|
504
504
|
}
|
|
505
505
|
|
|
506
|
+
export interface StreamDashboardPreviewsRequest {
|
|
507
|
+
/** Verified against the caller's identity before proxying. */
|
|
508
|
+
organizationId: string;
|
|
509
|
+
projectId: string;
|
|
510
|
+
/**
|
|
511
|
+
* The boards in/near the viewport: 1–64 dashboard UUIDs, de-duplicated. An
|
|
512
|
+
* unknown or foreign id yields an in-band error frame, not a failed stream.
|
|
513
|
+
*/
|
|
514
|
+
dashboardIds: string[];
|
|
515
|
+
}
|
|
516
|
+
|
|
517
|
+
export interface DashboardPreviewEnvelope {
|
|
518
|
+
dashboardId: string;
|
|
519
|
+
manifest?: DashboardPreviewManifest | undefined;
|
|
520
|
+
queryResult?:
|
|
521
|
+
| DashboardPreviewQueryResult
|
|
522
|
+
| undefined;
|
|
523
|
+
/** Fatal for THIS dashboard only (e.g. not found); the batch continues. */
|
|
524
|
+
error?: DashboardPreviewError | undefined;
|
|
525
|
+
}
|
|
526
|
+
|
|
527
|
+
/**
|
|
528
|
+
* DashboardPreviewManifest is the widget set the card should render, chosen
|
|
529
|
+
* server-side. time_window / time_interval are cleared: they do NOT apply to the
|
|
530
|
+
* preview data. Read the QuerySnapshot bounds, never the widget pins.
|
|
531
|
+
*/
|
|
532
|
+
export interface DashboardPreviewManifest {
|
|
533
|
+
widgets: Widget[];
|
|
534
|
+
dashboardVersion: number;
|
|
535
|
+
}
|
|
536
|
+
|
|
537
|
+
export interface DashboardPreviewQueryResult {
|
|
538
|
+
widgetId: string;
|
|
539
|
+
queryIndex: number;
|
|
540
|
+
snapshot?: QuerySnapshot | undefined;
|
|
541
|
+
error?: WidgetQueryError | undefined;
|
|
542
|
+
}
|
|
543
|
+
|
|
544
|
+
export interface DashboardPreviewError {
|
|
545
|
+
message: string;
|
|
546
|
+
}
|
|
547
|
+
|
|
506
548
|
function createBaseStreamMetricsRequest(): StreamMetricsRequest {
|
|
507
549
|
return { organizationId: "", projectId: "" };
|
|
508
550
|
}
|
|
@@ -4268,6 +4310,492 @@ export const WidgetQueryError: MessageFns<WidgetQueryError> = {
|
|
|
4268
4310
|
},
|
|
4269
4311
|
};
|
|
4270
4312
|
|
|
4313
|
+
function createBaseStreamDashboardPreviewsRequest(): StreamDashboardPreviewsRequest {
|
|
4314
|
+
return { organizationId: "", projectId: "", dashboardIds: [] };
|
|
4315
|
+
}
|
|
4316
|
+
|
|
4317
|
+
export const StreamDashboardPreviewsRequest: MessageFns<StreamDashboardPreviewsRequest> = {
|
|
4318
|
+
encode(message: StreamDashboardPreviewsRequest, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
|
|
4319
|
+
if (message.organizationId !== "") {
|
|
4320
|
+
writer.uint32(10).string(message.organizationId);
|
|
4321
|
+
}
|
|
4322
|
+
if (message.projectId !== "") {
|
|
4323
|
+
writer.uint32(18).string(message.projectId);
|
|
4324
|
+
}
|
|
4325
|
+
for (const v of message.dashboardIds) {
|
|
4326
|
+
writer.uint32(26).string(v!);
|
|
4327
|
+
}
|
|
4328
|
+
return writer;
|
|
4329
|
+
},
|
|
4330
|
+
|
|
4331
|
+
decode(input: BinaryReader | Uint8Array, length?: number): StreamDashboardPreviewsRequest {
|
|
4332
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
4333
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
4334
|
+
const message = createBaseStreamDashboardPreviewsRequest();
|
|
4335
|
+
while (reader.pos < end) {
|
|
4336
|
+
const tag = reader.uint32();
|
|
4337
|
+
switch (tag >>> 3) {
|
|
4338
|
+
case 1: {
|
|
4339
|
+
if (tag !== 10) {
|
|
4340
|
+
break;
|
|
4341
|
+
}
|
|
4342
|
+
|
|
4343
|
+
message.organizationId = reader.string();
|
|
4344
|
+
continue;
|
|
4345
|
+
}
|
|
4346
|
+
case 2: {
|
|
4347
|
+
if (tag !== 18) {
|
|
4348
|
+
break;
|
|
4349
|
+
}
|
|
4350
|
+
|
|
4351
|
+
message.projectId = reader.string();
|
|
4352
|
+
continue;
|
|
4353
|
+
}
|
|
4354
|
+
case 3: {
|
|
4355
|
+
if (tag !== 26) {
|
|
4356
|
+
break;
|
|
4357
|
+
}
|
|
4358
|
+
|
|
4359
|
+
message.dashboardIds.push(reader.string());
|
|
4360
|
+
continue;
|
|
4361
|
+
}
|
|
4362
|
+
}
|
|
4363
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
4364
|
+
break;
|
|
4365
|
+
}
|
|
4366
|
+
reader.skip(tag & 7);
|
|
4367
|
+
}
|
|
4368
|
+
return message;
|
|
4369
|
+
},
|
|
4370
|
+
|
|
4371
|
+
fromJSON(object: any): StreamDashboardPreviewsRequest {
|
|
4372
|
+
return {
|
|
4373
|
+
organizationId: isSet(object.organizationId)
|
|
4374
|
+
? globalThis.String(object.organizationId)
|
|
4375
|
+
: isSet(object.organization_id)
|
|
4376
|
+
? globalThis.String(object.organization_id)
|
|
4377
|
+
: "",
|
|
4378
|
+
projectId: isSet(object.projectId)
|
|
4379
|
+
? globalThis.String(object.projectId)
|
|
4380
|
+
: isSet(object.project_id)
|
|
4381
|
+
? globalThis.String(object.project_id)
|
|
4382
|
+
: "",
|
|
4383
|
+
dashboardIds: globalThis.Array.isArray(object?.dashboardIds)
|
|
4384
|
+
? object.dashboardIds.map((e: any) => globalThis.String(e))
|
|
4385
|
+
: globalThis.Array.isArray(object?.dashboard_ids)
|
|
4386
|
+
? object.dashboard_ids.map((e: any) => globalThis.String(e))
|
|
4387
|
+
: [],
|
|
4388
|
+
};
|
|
4389
|
+
},
|
|
4390
|
+
|
|
4391
|
+
toJSON(message: StreamDashboardPreviewsRequest): unknown {
|
|
4392
|
+
const obj: any = {};
|
|
4393
|
+
if (message.organizationId !== "") {
|
|
4394
|
+
obj.organizationId = message.organizationId;
|
|
4395
|
+
}
|
|
4396
|
+
if (message.projectId !== "") {
|
|
4397
|
+
obj.projectId = message.projectId;
|
|
4398
|
+
}
|
|
4399
|
+
if (message.dashboardIds?.length) {
|
|
4400
|
+
obj.dashboardIds = message.dashboardIds;
|
|
4401
|
+
}
|
|
4402
|
+
return obj;
|
|
4403
|
+
},
|
|
4404
|
+
|
|
4405
|
+
create<I extends Exact<DeepPartial<StreamDashboardPreviewsRequest>, I>>(base?: I): StreamDashboardPreviewsRequest {
|
|
4406
|
+
return StreamDashboardPreviewsRequest.fromPartial(base ?? ({} as any));
|
|
4407
|
+
},
|
|
4408
|
+
fromPartial<I extends Exact<DeepPartial<StreamDashboardPreviewsRequest>, I>>(
|
|
4409
|
+
object: I,
|
|
4410
|
+
): StreamDashboardPreviewsRequest {
|
|
4411
|
+
const message = createBaseStreamDashboardPreviewsRequest();
|
|
4412
|
+
message.organizationId = object.organizationId ?? "";
|
|
4413
|
+
message.projectId = object.projectId ?? "";
|
|
4414
|
+
message.dashboardIds = object.dashboardIds?.map((e) => e) || [];
|
|
4415
|
+
return message;
|
|
4416
|
+
},
|
|
4417
|
+
};
|
|
4418
|
+
|
|
4419
|
+
function createBaseDashboardPreviewEnvelope(): DashboardPreviewEnvelope {
|
|
4420
|
+
return { dashboardId: "", manifest: undefined, queryResult: undefined, error: undefined };
|
|
4421
|
+
}
|
|
4422
|
+
|
|
4423
|
+
export const DashboardPreviewEnvelope: MessageFns<DashboardPreviewEnvelope> = {
|
|
4424
|
+
encode(message: DashboardPreviewEnvelope, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
|
|
4425
|
+
if (message.dashboardId !== "") {
|
|
4426
|
+
writer.uint32(10).string(message.dashboardId);
|
|
4427
|
+
}
|
|
4428
|
+
if (message.manifest !== undefined) {
|
|
4429
|
+
DashboardPreviewManifest.encode(message.manifest, writer.uint32(18).fork()).join();
|
|
4430
|
+
}
|
|
4431
|
+
if (message.queryResult !== undefined) {
|
|
4432
|
+
DashboardPreviewQueryResult.encode(message.queryResult, writer.uint32(26).fork()).join();
|
|
4433
|
+
}
|
|
4434
|
+
if (message.error !== undefined) {
|
|
4435
|
+
DashboardPreviewError.encode(message.error, writer.uint32(34).fork()).join();
|
|
4436
|
+
}
|
|
4437
|
+
return writer;
|
|
4438
|
+
},
|
|
4439
|
+
|
|
4440
|
+
decode(input: BinaryReader | Uint8Array, length?: number): DashboardPreviewEnvelope {
|
|
4441
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
4442
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
4443
|
+
const message = createBaseDashboardPreviewEnvelope();
|
|
4444
|
+
while (reader.pos < end) {
|
|
4445
|
+
const tag = reader.uint32();
|
|
4446
|
+
switch (tag >>> 3) {
|
|
4447
|
+
case 1: {
|
|
4448
|
+
if (tag !== 10) {
|
|
4449
|
+
break;
|
|
4450
|
+
}
|
|
4451
|
+
|
|
4452
|
+
message.dashboardId = reader.string();
|
|
4453
|
+
continue;
|
|
4454
|
+
}
|
|
4455
|
+
case 2: {
|
|
4456
|
+
if (tag !== 18) {
|
|
4457
|
+
break;
|
|
4458
|
+
}
|
|
4459
|
+
|
|
4460
|
+
message.manifest = DashboardPreviewManifest.decode(reader, reader.uint32());
|
|
4461
|
+
continue;
|
|
4462
|
+
}
|
|
4463
|
+
case 3: {
|
|
4464
|
+
if (tag !== 26) {
|
|
4465
|
+
break;
|
|
4466
|
+
}
|
|
4467
|
+
|
|
4468
|
+
message.queryResult = DashboardPreviewQueryResult.decode(reader, reader.uint32());
|
|
4469
|
+
continue;
|
|
4470
|
+
}
|
|
4471
|
+
case 4: {
|
|
4472
|
+
if (tag !== 34) {
|
|
4473
|
+
break;
|
|
4474
|
+
}
|
|
4475
|
+
|
|
4476
|
+
message.error = DashboardPreviewError.decode(reader, reader.uint32());
|
|
4477
|
+
continue;
|
|
4478
|
+
}
|
|
4479
|
+
}
|
|
4480
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
4481
|
+
break;
|
|
4482
|
+
}
|
|
4483
|
+
reader.skip(tag & 7);
|
|
4484
|
+
}
|
|
4485
|
+
return message;
|
|
4486
|
+
},
|
|
4487
|
+
|
|
4488
|
+
fromJSON(object: any): DashboardPreviewEnvelope {
|
|
4489
|
+
return {
|
|
4490
|
+
dashboardId: isSet(object.dashboardId)
|
|
4491
|
+
? globalThis.String(object.dashboardId)
|
|
4492
|
+
: isSet(object.dashboard_id)
|
|
4493
|
+
? globalThis.String(object.dashboard_id)
|
|
4494
|
+
: "",
|
|
4495
|
+
manifest: isSet(object.manifest) ? DashboardPreviewManifest.fromJSON(object.manifest) : undefined,
|
|
4496
|
+
queryResult: isSet(object.queryResult)
|
|
4497
|
+
? DashboardPreviewQueryResult.fromJSON(object.queryResult)
|
|
4498
|
+
: isSet(object.query_result)
|
|
4499
|
+
? DashboardPreviewQueryResult.fromJSON(object.query_result)
|
|
4500
|
+
: undefined,
|
|
4501
|
+
error: isSet(object.error) ? DashboardPreviewError.fromJSON(object.error) : undefined,
|
|
4502
|
+
};
|
|
4503
|
+
},
|
|
4504
|
+
|
|
4505
|
+
toJSON(message: DashboardPreviewEnvelope): unknown {
|
|
4506
|
+
const obj: any = {};
|
|
4507
|
+
if (message.dashboardId !== "") {
|
|
4508
|
+
obj.dashboardId = message.dashboardId;
|
|
4509
|
+
}
|
|
4510
|
+
if (message.manifest !== undefined) {
|
|
4511
|
+
obj.manifest = DashboardPreviewManifest.toJSON(message.manifest);
|
|
4512
|
+
}
|
|
4513
|
+
if (message.queryResult !== undefined) {
|
|
4514
|
+
obj.queryResult = DashboardPreviewQueryResult.toJSON(message.queryResult);
|
|
4515
|
+
}
|
|
4516
|
+
if (message.error !== undefined) {
|
|
4517
|
+
obj.error = DashboardPreviewError.toJSON(message.error);
|
|
4518
|
+
}
|
|
4519
|
+
return obj;
|
|
4520
|
+
},
|
|
4521
|
+
|
|
4522
|
+
create<I extends Exact<DeepPartial<DashboardPreviewEnvelope>, I>>(base?: I): DashboardPreviewEnvelope {
|
|
4523
|
+
return DashboardPreviewEnvelope.fromPartial(base ?? ({} as any));
|
|
4524
|
+
},
|
|
4525
|
+
fromPartial<I extends Exact<DeepPartial<DashboardPreviewEnvelope>, I>>(object: I): DashboardPreviewEnvelope {
|
|
4526
|
+
const message = createBaseDashboardPreviewEnvelope();
|
|
4527
|
+
message.dashboardId = object.dashboardId ?? "";
|
|
4528
|
+
message.manifest = (object.manifest !== undefined && object.manifest !== null)
|
|
4529
|
+
? DashboardPreviewManifest.fromPartial(object.manifest)
|
|
4530
|
+
: undefined;
|
|
4531
|
+
message.queryResult = (object.queryResult !== undefined && object.queryResult !== null)
|
|
4532
|
+
? DashboardPreviewQueryResult.fromPartial(object.queryResult)
|
|
4533
|
+
: undefined;
|
|
4534
|
+
message.error = (object.error !== undefined && object.error !== null)
|
|
4535
|
+
? DashboardPreviewError.fromPartial(object.error)
|
|
4536
|
+
: undefined;
|
|
4537
|
+
return message;
|
|
4538
|
+
},
|
|
4539
|
+
};
|
|
4540
|
+
|
|
4541
|
+
function createBaseDashboardPreviewManifest(): DashboardPreviewManifest {
|
|
4542
|
+
return { widgets: [], dashboardVersion: 0 };
|
|
4543
|
+
}
|
|
4544
|
+
|
|
4545
|
+
export const DashboardPreviewManifest: MessageFns<DashboardPreviewManifest> = {
|
|
4546
|
+
encode(message: DashboardPreviewManifest, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
|
|
4547
|
+
for (const v of message.widgets) {
|
|
4548
|
+
Widget.encode(v!, writer.uint32(10).fork()).join();
|
|
4549
|
+
}
|
|
4550
|
+
if (message.dashboardVersion !== 0) {
|
|
4551
|
+
writer.uint32(16).int64(message.dashboardVersion);
|
|
4552
|
+
}
|
|
4553
|
+
return writer;
|
|
4554
|
+
},
|
|
4555
|
+
|
|
4556
|
+
decode(input: BinaryReader | Uint8Array, length?: number): DashboardPreviewManifest {
|
|
4557
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
4558
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
4559
|
+
const message = createBaseDashboardPreviewManifest();
|
|
4560
|
+
while (reader.pos < end) {
|
|
4561
|
+
const tag = reader.uint32();
|
|
4562
|
+
switch (tag >>> 3) {
|
|
4563
|
+
case 1: {
|
|
4564
|
+
if (tag !== 10) {
|
|
4565
|
+
break;
|
|
4566
|
+
}
|
|
4567
|
+
|
|
4568
|
+
message.widgets.push(Widget.decode(reader, reader.uint32()));
|
|
4569
|
+
continue;
|
|
4570
|
+
}
|
|
4571
|
+
case 2: {
|
|
4572
|
+
if (tag !== 16) {
|
|
4573
|
+
break;
|
|
4574
|
+
}
|
|
4575
|
+
|
|
4576
|
+
message.dashboardVersion = longToNumber(reader.int64());
|
|
4577
|
+
continue;
|
|
4578
|
+
}
|
|
4579
|
+
}
|
|
4580
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
4581
|
+
break;
|
|
4582
|
+
}
|
|
4583
|
+
reader.skip(tag & 7);
|
|
4584
|
+
}
|
|
4585
|
+
return message;
|
|
4586
|
+
},
|
|
4587
|
+
|
|
4588
|
+
fromJSON(object: any): DashboardPreviewManifest {
|
|
4589
|
+
return {
|
|
4590
|
+
widgets: globalThis.Array.isArray(object?.widgets) ? object.widgets.map((e: any) => Widget.fromJSON(e)) : [],
|
|
4591
|
+
dashboardVersion: isSet(object.dashboardVersion)
|
|
4592
|
+
? globalThis.Number(object.dashboardVersion)
|
|
4593
|
+
: isSet(object.dashboard_version)
|
|
4594
|
+
? globalThis.Number(object.dashboard_version)
|
|
4595
|
+
: 0,
|
|
4596
|
+
};
|
|
4597
|
+
},
|
|
4598
|
+
|
|
4599
|
+
toJSON(message: DashboardPreviewManifest): unknown {
|
|
4600
|
+
const obj: any = {};
|
|
4601
|
+
if (message.widgets?.length) {
|
|
4602
|
+
obj.widgets = message.widgets.map((e) => Widget.toJSON(e));
|
|
4603
|
+
}
|
|
4604
|
+
if (message.dashboardVersion !== 0) {
|
|
4605
|
+
obj.dashboardVersion = Math.round(message.dashboardVersion);
|
|
4606
|
+
}
|
|
4607
|
+
return obj;
|
|
4608
|
+
},
|
|
4609
|
+
|
|
4610
|
+
create<I extends Exact<DeepPartial<DashboardPreviewManifest>, I>>(base?: I): DashboardPreviewManifest {
|
|
4611
|
+
return DashboardPreviewManifest.fromPartial(base ?? ({} as any));
|
|
4612
|
+
},
|
|
4613
|
+
fromPartial<I extends Exact<DeepPartial<DashboardPreviewManifest>, I>>(object: I): DashboardPreviewManifest {
|
|
4614
|
+
const message = createBaseDashboardPreviewManifest();
|
|
4615
|
+
message.widgets = object.widgets?.map((e) => Widget.fromPartial(e)) || [];
|
|
4616
|
+
message.dashboardVersion = object.dashboardVersion ?? 0;
|
|
4617
|
+
return message;
|
|
4618
|
+
},
|
|
4619
|
+
};
|
|
4620
|
+
|
|
4621
|
+
function createBaseDashboardPreviewQueryResult(): DashboardPreviewQueryResult {
|
|
4622
|
+
return { widgetId: "", queryIndex: 0, snapshot: undefined, error: undefined };
|
|
4623
|
+
}
|
|
4624
|
+
|
|
4625
|
+
export const DashboardPreviewQueryResult: MessageFns<DashboardPreviewQueryResult> = {
|
|
4626
|
+
encode(message: DashboardPreviewQueryResult, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
|
|
4627
|
+
if (message.widgetId !== "") {
|
|
4628
|
+
writer.uint32(10).string(message.widgetId);
|
|
4629
|
+
}
|
|
4630
|
+
if (message.queryIndex !== 0) {
|
|
4631
|
+
writer.uint32(16).int32(message.queryIndex);
|
|
4632
|
+
}
|
|
4633
|
+
if (message.snapshot !== undefined) {
|
|
4634
|
+
QuerySnapshot.encode(message.snapshot, writer.uint32(26).fork()).join();
|
|
4635
|
+
}
|
|
4636
|
+
if (message.error !== undefined) {
|
|
4637
|
+
WidgetQueryError.encode(message.error, writer.uint32(34).fork()).join();
|
|
4638
|
+
}
|
|
4639
|
+
return writer;
|
|
4640
|
+
},
|
|
4641
|
+
|
|
4642
|
+
decode(input: BinaryReader | Uint8Array, length?: number): DashboardPreviewQueryResult {
|
|
4643
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
4644
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
4645
|
+
const message = createBaseDashboardPreviewQueryResult();
|
|
4646
|
+
while (reader.pos < end) {
|
|
4647
|
+
const tag = reader.uint32();
|
|
4648
|
+
switch (tag >>> 3) {
|
|
4649
|
+
case 1: {
|
|
4650
|
+
if (tag !== 10) {
|
|
4651
|
+
break;
|
|
4652
|
+
}
|
|
4653
|
+
|
|
4654
|
+
message.widgetId = reader.string();
|
|
4655
|
+
continue;
|
|
4656
|
+
}
|
|
4657
|
+
case 2: {
|
|
4658
|
+
if (tag !== 16) {
|
|
4659
|
+
break;
|
|
4660
|
+
}
|
|
4661
|
+
|
|
4662
|
+
message.queryIndex = reader.int32();
|
|
4663
|
+
continue;
|
|
4664
|
+
}
|
|
4665
|
+
case 3: {
|
|
4666
|
+
if (tag !== 26) {
|
|
4667
|
+
break;
|
|
4668
|
+
}
|
|
4669
|
+
|
|
4670
|
+
message.snapshot = QuerySnapshot.decode(reader, reader.uint32());
|
|
4671
|
+
continue;
|
|
4672
|
+
}
|
|
4673
|
+
case 4: {
|
|
4674
|
+
if (tag !== 34) {
|
|
4675
|
+
break;
|
|
4676
|
+
}
|
|
4677
|
+
|
|
4678
|
+
message.error = WidgetQueryError.decode(reader, reader.uint32());
|
|
4679
|
+
continue;
|
|
4680
|
+
}
|
|
4681
|
+
}
|
|
4682
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
4683
|
+
break;
|
|
4684
|
+
}
|
|
4685
|
+
reader.skip(tag & 7);
|
|
4686
|
+
}
|
|
4687
|
+
return message;
|
|
4688
|
+
},
|
|
4689
|
+
|
|
4690
|
+
fromJSON(object: any): DashboardPreviewQueryResult {
|
|
4691
|
+
return {
|
|
4692
|
+
widgetId: isSet(object.widgetId)
|
|
4693
|
+
? globalThis.String(object.widgetId)
|
|
4694
|
+
: isSet(object.widget_id)
|
|
4695
|
+
? globalThis.String(object.widget_id)
|
|
4696
|
+
: "",
|
|
4697
|
+
queryIndex: isSet(object.queryIndex)
|
|
4698
|
+
? globalThis.Number(object.queryIndex)
|
|
4699
|
+
: isSet(object.query_index)
|
|
4700
|
+
? globalThis.Number(object.query_index)
|
|
4701
|
+
: 0,
|
|
4702
|
+
snapshot: isSet(object.snapshot) ? QuerySnapshot.fromJSON(object.snapshot) : undefined,
|
|
4703
|
+
error: isSet(object.error) ? WidgetQueryError.fromJSON(object.error) : undefined,
|
|
4704
|
+
};
|
|
4705
|
+
},
|
|
4706
|
+
|
|
4707
|
+
toJSON(message: DashboardPreviewQueryResult): unknown {
|
|
4708
|
+
const obj: any = {};
|
|
4709
|
+
if (message.widgetId !== "") {
|
|
4710
|
+
obj.widgetId = message.widgetId;
|
|
4711
|
+
}
|
|
4712
|
+
if (message.queryIndex !== 0) {
|
|
4713
|
+
obj.queryIndex = Math.round(message.queryIndex);
|
|
4714
|
+
}
|
|
4715
|
+
if (message.snapshot !== undefined) {
|
|
4716
|
+
obj.snapshot = QuerySnapshot.toJSON(message.snapshot);
|
|
4717
|
+
}
|
|
4718
|
+
if (message.error !== undefined) {
|
|
4719
|
+
obj.error = WidgetQueryError.toJSON(message.error);
|
|
4720
|
+
}
|
|
4721
|
+
return obj;
|
|
4722
|
+
},
|
|
4723
|
+
|
|
4724
|
+
create<I extends Exact<DeepPartial<DashboardPreviewQueryResult>, I>>(base?: I): DashboardPreviewQueryResult {
|
|
4725
|
+
return DashboardPreviewQueryResult.fromPartial(base ?? ({} as any));
|
|
4726
|
+
},
|
|
4727
|
+
fromPartial<I extends Exact<DeepPartial<DashboardPreviewQueryResult>, I>>(object: I): DashboardPreviewQueryResult {
|
|
4728
|
+
const message = createBaseDashboardPreviewQueryResult();
|
|
4729
|
+
message.widgetId = object.widgetId ?? "";
|
|
4730
|
+
message.queryIndex = object.queryIndex ?? 0;
|
|
4731
|
+
message.snapshot = (object.snapshot !== undefined && object.snapshot !== null)
|
|
4732
|
+
? QuerySnapshot.fromPartial(object.snapshot)
|
|
4733
|
+
: undefined;
|
|
4734
|
+
message.error = (object.error !== undefined && object.error !== null)
|
|
4735
|
+
? WidgetQueryError.fromPartial(object.error)
|
|
4736
|
+
: undefined;
|
|
4737
|
+
return message;
|
|
4738
|
+
},
|
|
4739
|
+
};
|
|
4740
|
+
|
|
4741
|
+
function createBaseDashboardPreviewError(): DashboardPreviewError {
|
|
4742
|
+
return { message: "" };
|
|
4743
|
+
}
|
|
4744
|
+
|
|
4745
|
+
export const DashboardPreviewError: MessageFns<DashboardPreviewError> = {
|
|
4746
|
+
encode(message: DashboardPreviewError, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
|
|
4747
|
+
if (message.message !== "") {
|
|
4748
|
+
writer.uint32(10).string(message.message);
|
|
4749
|
+
}
|
|
4750
|
+
return writer;
|
|
4751
|
+
},
|
|
4752
|
+
|
|
4753
|
+
decode(input: BinaryReader | Uint8Array, length?: number): DashboardPreviewError {
|
|
4754
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
4755
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
4756
|
+
const message = createBaseDashboardPreviewError();
|
|
4757
|
+
while (reader.pos < end) {
|
|
4758
|
+
const tag = reader.uint32();
|
|
4759
|
+
switch (tag >>> 3) {
|
|
4760
|
+
case 1: {
|
|
4761
|
+
if (tag !== 10) {
|
|
4762
|
+
break;
|
|
4763
|
+
}
|
|
4764
|
+
|
|
4765
|
+
message.message = reader.string();
|
|
4766
|
+
continue;
|
|
4767
|
+
}
|
|
4768
|
+
}
|
|
4769
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
4770
|
+
break;
|
|
4771
|
+
}
|
|
4772
|
+
reader.skip(tag & 7);
|
|
4773
|
+
}
|
|
4774
|
+
return message;
|
|
4775
|
+
},
|
|
4776
|
+
|
|
4777
|
+
fromJSON(object: any): DashboardPreviewError {
|
|
4778
|
+
return { message: isSet(object.message) ? globalThis.String(object.message) : "" };
|
|
4779
|
+
},
|
|
4780
|
+
|
|
4781
|
+
toJSON(message: DashboardPreviewError): unknown {
|
|
4782
|
+
const obj: any = {};
|
|
4783
|
+
if (message.message !== "") {
|
|
4784
|
+
obj.message = message.message;
|
|
4785
|
+
}
|
|
4786
|
+
return obj;
|
|
4787
|
+
},
|
|
4788
|
+
|
|
4789
|
+
create<I extends Exact<DeepPartial<DashboardPreviewError>, I>>(base?: I): DashboardPreviewError {
|
|
4790
|
+
return DashboardPreviewError.fromPartial(base ?? ({} as any));
|
|
4791
|
+
},
|
|
4792
|
+
fromPartial<I extends Exact<DeepPartial<DashboardPreviewError>, I>>(object: I): DashboardPreviewError {
|
|
4793
|
+
const message = createBaseDashboardPreviewError();
|
|
4794
|
+
message.message = object.message ?? "";
|
|
4795
|
+
return message;
|
|
4796
|
+
},
|
|
4797
|
+
};
|
|
4798
|
+
|
|
4271
4799
|
/**
|
|
4272
4800
|
* MetricGatewayService is the web surface of telemetry.api.v1 MetricService — the types
|
|
4273
4801
|
* are domain-isolated copies converted in gateways/internal/convert. It covers the
|
|
@@ -4302,6 +4830,19 @@ export interface MetricGatewayService {
|
|
|
4302
4830
|
* conditions.
|
|
4303
4831
|
*/
|
|
4304
4832
|
StreamDashboardData(request: StreamDashboardDataRequest, metadata?: Metadata): Observable<DashboardDataEnvelope>;
|
|
4833
|
+
/**
|
|
4834
|
+
* Batched preview for the dashboards LIST pane: one stream previews many
|
|
4835
|
+
* boards. Per dashboard the backend picks a couple of representative widgets,
|
|
4836
|
+
* emits their definitions (manifest) so the card renders without a per-board
|
|
4837
|
+
* GetDashboard, then streams one cached snapshot per (widget, query) as each
|
|
4838
|
+
* resolves. Fixed recent window, snapshot-once (never live); widget time pins
|
|
4839
|
+
* are ignored — a card is an approximate teaser. See the telemetry-api service
|
|
4840
|
+
* definition for the full ordering/cardinality guarantees.
|
|
4841
|
+
*/
|
|
4842
|
+
StreamDashboardPreviews(
|
|
4843
|
+
request: StreamDashboardPreviewsRequest,
|
|
4844
|
+
metadata?: Metadata,
|
|
4845
|
+
): Observable<DashboardPreviewEnvelope>;
|
|
4305
4846
|
}
|
|
4306
4847
|
|
|
4307
4848
|
export const MetricGatewayServiceServiceName = "gateway.web.v1.MetricGatewayService";
|
|
@@ -4320,6 +4861,7 @@ export class MetricGatewayServiceClientImpl implements MetricGatewayService {
|
|
|
4320
4861
|
this.UpdateDashboard = this.UpdateDashboard.bind(this);
|
|
4321
4862
|
this.DeleteDashboard = this.DeleteDashboard.bind(this);
|
|
4322
4863
|
this.StreamDashboardData = this.StreamDashboardData.bind(this);
|
|
4864
|
+
this.StreamDashboardPreviews = this.StreamDashboardPreviews.bind(this);
|
|
4323
4865
|
}
|
|
4324
4866
|
StreamMetrics(request: StreamMetricsRequest, metadata?: Metadata): Observable<MetricCatalogEnvelope> {
|
|
4325
4867
|
const data = StreamMetricsRequest.encode(request).finish();
|
|
@@ -4377,6 +4919,15 @@ export class MetricGatewayServiceClientImpl implements MetricGatewayService {
|
|
|
4377
4919
|
const result = this.rpc.serverStreamingRequest(this.service, "StreamDashboardData", data, metadata);
|
|
4378
4920
|
return result.pipe(map((data) => DashboardDataEnvelope.decode(new BinaryReader(data))));
|
|
4379
4921
|
}
|
|
4922
|
+
|
|
4923
|
+
StreamDashboardPreviews(
|
|
4924
|
+
request: StreamDashboardPreviewsRequest,
|
|
4925
|
+
metadata?: Metadata,
|
|
4926
|
+
): Observable<DashboardPreviewEnvelope> {
|
|
4927
|
+
const data = StreamDashboardPreviewsRequest.encode(request).finish();
|
|
4928
|
+
const result = this.rpc.serverStreamingRequest(this.service, "StreamDashboardPreviews", data, metadata);
|
|
4929
|
+
return result.pipe(map((data) => DashboardPreviewEnvelope.decode(new BinaryReader(data))));
|
|
4930
|
+
}
|
|
4380
4931
|
}
|
|
4381
4932
|
|
|
4382
4933
|
interface Rpc {
|
|
@@ -40,6 +40,17 @@ function deserialize_gateway_web_v1_DashboardDataEnvelope(buffer_arg) {
|
|
|
40
40
|
return proto_gateway_web_v1_metric_gateway_pb.DashboardDataEnvelope.deserializeBinary(new Uint8Array(buffer_arg));
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
+
function serialize_gateway_web_v1_DashboardPreviewEnvelope(arg) {
|
|
44
|
+
if (!(arg instanceof proto_gateway_web_v1_metric_gateway_pb.DashboardPreviewEnvelope)) {
|
|
45
|
+
throw new Error('Expected argument of type gateway.web.v1.DashboardPreviewEnvelope');
|
|
46
|
+
}
|
|
47
|
+
return Buffer.from(arg.serializeBinary());
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
function deserialize_gateway_web_v1_DashboardPreviewEnvelope(buffer_arg) {
|
|
51
|
+
return proto_gateway_web_v1_metric_gateway_pb.DashboardPreviewEnvelope.deserializeBinary(new Uint8Array(buffer_arg));
|
|
52
|
+
}
|
|
53
|
+
|
|
43
54
|
function serialize_gateway_web_v1_DeleteDashboardRequest(arg) {
|
|
44
55
|
if (!(arg instanceof proto_gateway_web_v1_metric_gateway_pb.DeleteDashboardRequest)) {
|
|
45
56
|
throw new Error('Expected argument of type gateway.web.v1.DeleteDashboardRequest');
|
|
@@ -150,6 +161,17 @@ function deserialize_gateway_web_v1_StreamDashboardDataRequest(buffer_arg) {
|
|
|
150
161
|
return proto_gateway_web_v1_metric_gateway_pb.StreamDashboardDataRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
151
162
|
}
|
|
152
163
|
|
|
164
|
+
function serialize_gateway_web_v1_StreamDashboardPreviewsRequest(arg) {
|
|
165
|
+
if (!(arg instanceof proto_gateway_web_v1_metric_gateway_pb.StreamDashboardPreviewsRequest)) {
|
|
166
|
+
throw new Error('Expected argument of type gateway.web.v1.StreamDashboardPreviewsRequest');
|
|
167
|
+
}
|
|
168
|
+
return Buffer.from(arg.serializeBinary());
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
function deserialize_gateway_web_v1_StreamDashboardPreviewsRequest(buffer_arg) {
|
|
172
|
+
return proto_gateway_web_v1_metric_gateway_pb.StreamDashboardPreviewsRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
173
|
+
}
|
|
174
|
+
|
|
153
175
|
function serialize_gateway_web_v1_StreamMetricAttributesRequest(arg) {
|
|
154
176
|
if (!(arg instanceof proto_gateway_web_v1_metric_gateway_pb.StreamMetricAttributesRequest)) {
|
|
155
177
|
throw new Error('Expected argument of type gateway.web.v1.StreamMetricAttributesRequest');
|
|
@@ -321,6 +343,24 @@ streamDashboardData: {
|
|
|
321
343
|
responseSerialize: serialize_gateway_web_v1_DashboardDataEnvelope,
|
|
322
344
|
responseDeserialize: deserialize_gateway_web_v1_DashboardDataEnvelope,
|
|
323
345
|
},
|
|
346
|
+
// Batched preview for the dashboards LIST pane: one stream previews many
|
|
347
|
+
// boards. Per dashboard the backend picks a couple of representative widgets,
|
|
348
|
+
// emits their definitions (manifest) so the card renders without a per-board
|
|
349
|
+
// GetDashboard, then streams one cached snapshot per (widget, query) as each
|
|
350
|
+
// resolves. Fixed recent window, snapshot-once (never live); widget time pins
|
|
351
|
+
// are ignored — a card is an approximate teaser. See the telemetry-api service
|
|
352
|
+
// definition for the full ordering/cardinality guarantees.
|
|
353
|
+
streamDashboardPreviews: {
|
|
354
|
+
path: '/gateway.web.v1.MetricGatewayService/StreamDashboardPreviews',
|
|
355
|
+
requestStream: false,
|
|
356
|
+
responseStream: true,
|
|
357
|
+
requestType: proto_gateway_web_v1_metric_gateway_pb.StreamDashboardPreviewsRequest,
|
|
358
|
+
responseType: proto_gateway_web_v1_metric_gateway_pb.DashboardPreviewEnvelope,
|
|
359
|
+
requestSerialize: serialize_gateway_web_v1_StreamDashboardPreviewsRequest,
|
|
360
|
+
requestDeserialize: deserialize_gateway_web_v1_StreamDashboardPreviewsRequest,
|
|
361
|
+
responseSerialize: serialize_gateway_web_v1_DashboardPreviewEnvelope,
|
|
362
|
+
responseDeserialize: deserialize_gateway_web_v1_DashboardPreviewEnvelope,
|
|
363
|
+
},
|
|
324
364
|
};
|
|
325
365
|
|
|
326
366
|
exports.MetricGatewayServiceClient = grpc.makeGenericClientConstructor(MetricGatewayServiceService, 'MetricGatewayService');
|