@delta-base/core 1.2.8 → 1.2.10
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/index.d.ts +42 -2
- package/dist/index.js +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -1582,6 +1582,13 @@ declare class EventBusDurableObject extends DurableObject<Env$1> {
|
|
|
1582
1582
|
private readonly BATCH_SIZE;
|
|
1583
1583
|
private readonly RETRY_DELAY_HOURS;
|
|
1584
1584
|
sql: SqlStorage;
|
|
1585
|
+
/**
|
|
1586
|
+
* Converts SQLite DATETIME string to ISO format
|
|
1587
|
+
* @param sqliteDate - SQLite DATETIME string like "2024-01-15 12:30:45"
|
|
1588
|
+
* @returns ISO formatted date string
|
|
1589
|
+
* @private
|
|
1590
|
+
*/
|
|
1591
|
+
private formatDateToISO;
|
|
1585
1592
|
constructor(state: DurableObjectState, env: Env$1);
|
|
1586
1593
|
private initializeTables;
|
|
1587
1594
|
initialize(eventStoreID: string): void;
|
|
@@ -1616,7 +1623,22 @@ declare class EventBusDurableObject extends DurableObject<Env$1> {
|
|
|
1616
1623
|
private deliverEvent;
|
|
1617
1624
|
private logProcessingMetrics;
|
|
1618
1625
|
alarm(alarmInfo: AlarmInvocationInfo): Promise<void>;
|
|
1619
|
-
|
|
1626
|
+
/**
|
|
1627
|
+
* Gets the current database size in bytes (consistent with EventStoreDO)
|
|
1628
|
+
* @returns Database size in bytes
|
|
1629
|
+
*/
|
|
1630
|
+
getDatabaseSize(): Promise<number>;
|
|
1631
|
+
/**
|
|
1632
|
+
* Gets basic metrics for the event bus
|
|
1633
|
+
* @returns Basic metrics including database size and subscription counts
|
|
1634
|
+
*/
|
|
1635
|
+
getMetrics(): {
|
|
1636
|
+
database_size_bytes: number;
|
|
1637
|
+
database_size_mb: number;
|
|
1638
|
+
total_subscriptions: number;
|
|
1639
|
+
active_subscriptions: number;
|
|
1640
|
+
pending_messages: number;
|
|
1641
|
+
};
|
|
1620
1642
|
private validateEventFilter;
|
|
1621
1643
|
}
|
|
1622
1644
|
|
|
@@ -1785,6 +1807,13 @@ declare class EventStoreDurableObject extends DurableObject<Env> {
|
|
|
1785
1807
|
* @private
|
|
1786
1808
|
*/
|
|
1787
1809
|
private parseStreamMetadata;
|
|
1810
|
+
/**
|
|
1811
|
+
* Converts SQLite DATETIME string to ISO format
|
|
1812
|
+
* @param sqliteDate - SQLite DATETIME string like "2024-01-15 12:30:45"
|
|
1813
|
+
* @returns ISO formatted date string
|
|
1814
|
+
* @private
|
|
1815
|
+
*/
|
|
1816
|
+
private formatDateToISO;
|
|
1788
1817
|
/**
|
|
1789
1818
|
* Maps a database row to an event object
|
|
1790
1819
|
* @param row - The database row containing event data
|
|
@@ -1850,6 +1879,16 @@ declare class EventStoreDurableObject extends DurableObject<Env> {
|
|
|
1850
1879
|
* @private
|
|
1851
1880
|
*/
|
|
1852
1881
|
private processPendingEventBusMessages;
|
|
1882
|
+
/**
|
|
1883
|
+
* Gets the current database size in bytes (consistent with EventBusDO)
|
|
1884
|
+
* @returns Database size in bytes
|
|
1885
|
+
*/
|
|
1886
|
+
getDatabaseSize(): Promise<number>;
|
|
1887
|
+
/**
|
|
1888
|
+
* Gets the current database size in MB (for internal use)
|
|
1889
|
+
* @returns Database size in megabytes
|
|
1890
|
+
* @private
|
|
1891
|
+
*/
|
|
1853
1892
|
private getDatabaseSizeInMB;
|
|
1854
1893
|
private getStoragePressureLevel;
|
|
1855
1894
|
private checkDatabaseSize;
|
|
@@ -1926,10 +1965,11 @@ declare class EventStoreDurableObject extends DurableObject<Env> {
|
|
|
1926
1965
|
*/
|
|
1927
1966
|
private notifyStreamArchived;
|
|
1928
1967
|
/**
|
|
1929
|
-
* Gets current metrics for this event store
|
|
1968
|
+
* Gets current metrics for this event store (consistent with EventBusDO)
|
|
1930
1969
|
* @returns Current metrics including size, pressure, and event counts
|
|
1931
1970
|
*/
|
|
1932
1971
|
getMetrics(): Promise<{
|
|
1972
|
+
database_size_bytes: number;
|
|
1933
1973
|
database_size_mb: number;
|
|
1934
1974
|
pressure_level: string;
|
|
1935
1975
|
total_streams: number;
|