@crvouga/mockingbird-service-google 0.2.0 → 0.4.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/CHANGELOG.md +18 -4
- package/dist/chunk-HNG6OQSB.js +4792 -0
- package/dist/chunk-HNG6OQSB.js.map +7 -0
- package/dist/{chunk-DI2MWIYZ.js → chunk-PF2EJVUZ.js} +108 -5
- package/dist/chunk-PF2EJVUZ.js.map +7 -0
- package/dist/cli.js +2 -2
- package/dist/index.d.ts +15 -1
- package/dist/index.js +1 -1
- package/dist/server.d.ts +31 -2
- package/dist/server.js +2 -2
- package/package.json +1 -1
- package/dist/chunk-DI2MWIYZ.js.map +0 -7
- package/dist/chunk-QV342ARR.js +0 -984
- package/dist/chunk-QV342ARR.js.map +0 -7
package/dist/cli.js
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1322,6 +1322,8 @@ type SnapshotDocument = {
|
|
|
1322
1322
|
faults?: unknown;
|
|
1323
1323
|
latency?: unknown;
|
|
1324
1324
|
virtualTime?: boolean;
|
|
1325
|
+
/** Quiescent webhook endpoints, delivery history and fault state. Contains private configuration. */
|
|
1326
|
+
webhooks?: unknown;
|
|
1325
1327
|
};
|
|
1326
1328
|
/** Controls for one namespace. */
|
|
1327
1329
|
type NamespaceControls = {
|
|
@@ -1551,6 +1553,8 @@ type CredentialRegistry = {
|
|
|
1551
1553
|
}[];
|
|
1552
1554
|
};
|
|
1553
1555
|
|
|
1556
|
+
type OwnedTransport = (request: Request, namespace: string, send: typeof fetch) => Promise<Response>;
|
|
1557
|
+
|
|
1554
1558
|
/**
|
|
1555
1559
|
* A point-in-time copy of everything a service namespace holds.
|
|
1556
1560
|
*
|
|
@@ -1737,8 +1741,16 @@ type PublishInput = {
|
|
|
1737
1741
|
id?: string;
|
|
1738
1742
|
};
|
|
1739
1743
|
type WebhookHub = {
|
|
1744
|
+
observeDeliveries(listener: (event: {
|
|
1745
|
+
namespace: string;
|
|
1746
|
+
state: string;
|
|
1747
|
+
deliveryId: string;
|
|
1748
|
+
}) => void): () => void;
|
|
1749
|
+
setTransportPolicy(policy: OwnedTransport): void;
|
|
1740
1750
|
pending(namespace: string): number;
|
|
1741
1751
|
snapshot(namespace: string): unknown;
|
|
1752
|
+
exportSnapshot(handle: unknown): unknown;
|
|
1753
|
+
importSnapshot(namespace: string, document: unknown): unknown;
|
|
1742
1754
|
restore(namespace: string, snapshot: unknown): void;
|
|
1743
1755
|
publish(input: PublishInput): WebhookMessage;
|
|
1744
1756
|
/** Replace a namespace's own endpoints (`PUT /__admin/webhook-endpoints`). */
|
|
@@ -1751,7 +1763,7 @@ type WebhookHub = {
|
|
|
1751
1763
|
/** Run every pending retry (and release held reordered messages) now, and every retry those attempts schedule, until nothing is pending. */
|
|
1752
1764
|
flush(): Promise<void>;
|
|
1753
1765
|
/** Resolve once nothing is in flight. */
|
|
1754
|
-
idle(): Promise<void>;
|
|
1766
|
+
idle(namespace?: string): Promise<void>;
|
|
1755
1767
|
fault(namespace: string, fault: WebhookFault): void;
|
|
1756
1768
|
clear(namespace?: string): void;
|
|
1757
1769
|
};
|
|
@@ -1883,6 +1895,8 @@ type ServiceRuntime<T extends ServiceInstance> = FetchAPI & {
|
|
|
1883
1895
|
/** Opaque in-process checkpoint including records, controls and webhook history. */
|
|
1884
1896
|
fleetSnapshot(namespace: string): object;
|
|
1885
1897
|
fleetRestore(snapshot: unknown, namespace: string): void;
|
|
1898
|
+
fleetExport(snapshot: unknown): SnapshotDocument;
|
|
1899
|
+
fleetImport(namespace: string, document: unknown): object;
|
|
1886
1900
|
/** Expand a named preset into fault rules (and webhook faults) for `namespace`. */
|
|
1887
1901
|
applyPreset(name: string, namespace?: string, overrides?: Partial<FaultRule>): FaultRule[];
|
|
1888
1902
|
/** The instance behind `namespace` (the default one when omitted), created on first use. */
|
package/dist/index.js
CHANGED
package/dist/server.d.ts
CHANGED
|
@@ -444,6 +444,8 @@ type SnapshotDocument$1 = {
|
|
|
444
444
|
faults?: unknown;
|
|
445
445
|
latency?: unknown;
|
|
446
446
|
virtualTime?: boolean;
|
|
447
|
+
/** Quiescent webhook endpoints, delivery history and fault state. Contains private configuration. */
|
|
448
|
+
webhooks?: unknown;
|
|
447
449
|
};
|
|
448
450
|
/** Controls for one namespace. */
|
|
449
451
|
type NamespaceControls$1 = {
|
|
@@ -657,6 +659,8 @@ type CredentialRegistry$1 = {
|
|
|
657
659
|
}[];
|
|
658
660
|
};
|
|
659
661
|
|
|
662
|
+
type OwnedTransport$1 = (request: Request, namespace: string, send: typeof fetch) => Promise<Response>;
|
|
663
|
+
|
|
660
664
|
/**
|
|
661
665
|
* A point-in-time copy of everything a service namespace holds.
|
|
662
666
|
*
|
|
@@ -774,8 +778,16 @@ type PublishInput$1 = {
|
|
|
774
778
|
id?: string;
|
|
775
779
|
};
|
|
776
780
|
type WebhookHub$1 = {
|
|
781
|
+
observeDeliveries(listener: (event: {
|
|
782
|
+
namespace: string;
|
|
783
|
+
state: string;
|
|
784
|
+
deliveryId: string;
|
|
785
|
+
}) => void): () => void;
|
|
786
|
+
setTransportPolicy(policy: OwnedTransport$1): void;
|
|
777
787
|
pending(namespace: string): number;
|
|
778
788
|
snapshot(namespace: string): unknown;
|
|
789
|
+
exportSnapshot(handle: unknown): unknown;
|
|
790
|
+
importSnapshot(namespace: string, document: unknown): unknown;
|
|
779
791
|
restore(namespace: string, snapshot: unknown): void;
|
|
780
792
|
publish(input: PublishInput$1): WebhookMessage$1;
|
|
781
793
|
/** Replace a namespace's own endpoints (`PUT /__admin/webhook-endpoints`). */
|
|
@@ -788,7 +800,7 @@ type WebhookHub$1 = {
|
|
|
788
800
|
/** Run every pending retry (and release held reordered messages) now, and every retry those attempts schedule, until nothing is pending. */
|
|
789
801
|
flush(): Promise<void>;
|
|
790
802
|
/** Resolve once nothing is in flight. */
|
|
791
|
-
idle(): Promise<void>;
|
|
803
|
+
idle(namespace?: string): Promise<void>;
|
|
792
804
|
fault(namespace: string, fault: WebhookFault$1): void;
|
|
793
805
|
clear(namespace?: string): void;
|
|
794
806
|
};
|
|
@@ -832,6 +844,8 @@ type ServiceRuntime$1<T extends ServiceInstance$1> = FetchAPI$1 & {
|
|
|
832
844
|
/** Opaque in-process checkpoint including records, controls and webhook history. */
|
|
833
845
|
fleetSnapshot(namespace: string): object;
|
|
834
846
|
fleetRestore(snapshot: unknown, namespace: string): void;
|
|
847
|
+
fleetExport(snapshot: unknown): SnapshotDocument$1;
|
|
848
|
+
fleetImport(namespace: string, document: unknown): object;
|
|
835
849
|
/** Expand a named preset into fault rules (and webhook faults) for `namespace`. */
|
|
836
850
|
applyPreset(name: string, namespace?: string, overrides?: Partial<FaultRule$1>): FaultRule$1[];
|
|
837
851
|
/** The instance behind `namespace` (the default one when omitted), created on first use. */
|
|
@@ -924,6 +938,7 @@ type CommonServeOptions = {
|
|
|
924
938
|
* `serveTarget`, which is also how `serve --config` finds services by name.
|
|
925
939
|
*/
|
|
926
940
|
type ServeTarget = {
|
|
941
|
+
packageVersion?: string;
|
|
927
942
|
name: string;
|
|
928
943
|
defaultPort: number;
|
|
929
944
|
/** Serve flags beyond the common ones. */
|
|
@@ -1557,6 +1572,8 @@ type SnapshotDocument = {
|
|
|
1557
1572
|
faults?: unknown;
|
|
1558
1573
|
latency?: unknown;
|
|
1559
1574
|
virtualTime?: boolean;
|
|
1575
|
+
/** Quiescent webhook endpoints, delivery history and fault state. Contains private configuration. */
|
|
1576
|
+
webhooks?: unknown;
|
|
1560
1577
|
};
|
|
1561
1578
|
/** Controls for one namespace. */
|
|
1562
1579
|
type NamespaceControls = {
|
|
@@ -1786,6 +1803,8 @@ type CredentialRegistry = {
|
|
|
1786
1803
|
}[];
|
|
1787
1804
|
};
|
|
1788
1805
|
|
|
1806
|
+
type OwnedTransport = (request: Request, namespace: string, send: typeof fetch) => Promise<Response>;
|
|
1807
|
+
|
|
1789
1808
|
/**
|
|
1790
1809
|
* A point-in-time copy of everything a service namespace holds.
|
|
1791
1810
|
*
|
|
@@ -1972,8 +1991,16 @@ type PublishInput = {
|
|
|
1972
1991
|
id?: string;
|
|
1973
1992
|
};
|
|
1974
1993
|
type WebhookHub = {
|
|
1994
|
+
observeDeliveries(listener: (event: {
|
|
1995
|
+
namespace: string;
|
|
1996
|
+
state: string;
|
|
1997
|
+
deliveryId: string;
|
|
1998
|
+
}) => void): () => void;
|
|
1999
|
+
setTransportPolicy(policy: OwnedTransport): void;
|
|
1975
2000
|
pending(namespace: string): number;
|
|
1976
2001
|
snapshot(namespace: string): unknown;
|
|
2002
|
+
exportSnapshot(handle: unknown): unknown;
|
|
2003
|
+
importSnapshot(namespace: string, document: unknown): unknown;
|
|
1977
2004
|
restore(namespace: string, snapshot: unknown): void;
|
|
1978
2005
|
publish(input: PublishInput): WebhookMessage;
|
|
1979
2006
|
/** Replace a namespace's own endpoints (`PUT /__admin/webhook-endpoints`). */
|
|
@@ -1986,7 +2013,7 @@ type WebhookHub = {
|
|
|
1986
2013
|
/** Run every pending retry (and release held reordered messages) now, and every retry those attempts schedule, until nothing is pending. */
|
|
1987
2014
|
flush(): Promise<void>;
|
|
1988
2015
|
/** Resolve once nothing is in flight. */
|
|
1989
|
-
idle(): Promise<void>;
|
|
2016
|
+
idle(namespace?: string): Promise<void>;
|
|
1990
2017
|
fault(namespace: string, fault: WebhookFault): void;
|
|
1991
2018
|
clear(namespace?: string): void;
|
|
1992
2019
|
};
|
|
@@ -2118,6 +2145,8 @@ type ServiceRuntime<T extends ServiceInstance> = FetchAPI & {
|
|
|
2118
2145
|
/** Opaque in-process checkpoint including records, controls and webhook history. */
|
|
2119
2146
|
fleetSnapshot(namespace: string): object;
|
|
2120
2147
|
fleetRestore(snapshot: unknown, namespace: string): void;
|
|
2148
|
+
fleetExport(snapshot: unknown): SnapshotDocument;
|
|
2149
|
+
fleetImport(namespace: string, document: unknown): object;
|
|
2121
2150
|
/** Expand a named preset into fault rules (and webhook faults) for `namespace`. */
|
|
2122
2151
|
applyPreset(name: string, namespace?: string, overrides?: Partial<FaultRule>): FaultRule[];
|
|
2123
2152
|
/** The instance behind `namespace` (the default one when omitted), created on first use. */
|
package/dist/server.js
CHANGED
package/package.json
CHANGED