You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// requested `maxRealtimeDistance` vs. actual `worstCaseDistance`
49
-
if(worstCaseDistance>maxRealtimeDistance){
50
+
// requested `maxWorstCaseDistance` vs. actual `worstCaseDistance`
51
+
if(worstCaseDistance>maxWorstCaseDistance){
50
52
returnerrorResponse(
51
53
c,
52
-
`Indexing Status 'worstCaseDistance' must be below or equal to the requested 'maxRealtimeDistance'; worstCaseDistance = ${worstCaseDistance}; maxRealtimeDistance = ${maxRealtimeDistance}`,
54
+
`Indexing Status 'worstCaseDistance' must be below or equal to the requested 'maxWorstCaseDistance'; worstCaseDistance = ${worstCaseDistance}; maxWorstCaseDistance = ${maxWorstCaseDistance}`,
53
55
503,
54
56
);
55
57
}
56
58
57
-
// return 200 response OK with current details on `maxRealtimeDistance`,
59
+
// return 200 response OK with current details on `maxWorstCaseDistance`,
58
60
// `slowestChainIndexingCursor`, and `worstCaseDistance`
`ENSIndexer is NOT guaranteed to be within ${maxRealtimeDistance} seconds of realtime. Current indexing status has not been successfully fetched by this ENSApi instance yet and is therefore unknown to this ENSApi instance because: ${c.var.indexingStatus.message}.`,
27
+
`ENSIndexer is NOT guaranteed to be within ${maxWorstCaseDistance} seconds of realtime. Current indexing status has not been successfully fetched by this ENSApi instance yet and is therefore unknown to this ENSApi instance because: ${c.var.indexingStatus.message}.`,
`ENSIndexer is guaranteed to be within ${maxRealtimeDistance} seconds of realtime.`,
43
+
`ENSIndexer is guaranteed to be within ${maxWorstCaseDistance} seconds of realtime`,
44
44
);
45
45
}else{
46
46
logger.warn(
47
-
`ENSIndexer is NOT guaranteed to be within ${maxRealtimeDistance} seconds of realtime. (Worst Case distance: ${c.var.indexingStatus.worstCaseDistance} seconds > ${maxRealtimeDistance} seconds).`,
47
+
`ENSIndexer is NOT guaranteed to be within ${maxWorstCaseDistance} seconds of realtime. (Worst Case distance: ${c.var.indexingStatus.worstCaseDistance} seconds > ${maxWorstCaseDistance} seconds).`,
Copy file name to clipboardExpand all lines: packages/ensnode-sdk/README.md
+1-10Lines changed: 1 addition & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -169,14 +169,10 @@ console.log(config);
169
169
170
170
#### Indexing Status API
171
171
172
-
##### `indexingStatus(options)`
172
+
##### `indexingStatus()`
173
173
174
174
Fetches the ENSNode's multichain indexing status.
175
175
176
-
-`options`: (optional) additional options
177
-
-`maxRealtimeDistance`: (optional) The max allowed distance in seconds between the latest indexed block of the slowest indexed chain and the current time. Setting this parameter influences the HTTP response code:
178
-
- Success (200 OK): The latest indexed block of each chain is within the requested distance from realtime
179
-
- Service Unavailable (503): The latest indexed block of each chain is NOT within the requested distance from realtime
180
176
- Returns: `IndexingStatusResponse` - The indexing status data for all indexed chains
181
177
- Throws: Error if the request fails or the ENSNode API returns an error response
182
178
@@ -185,11 +181,6 @@ Fetches the ENSNode's multichain indexing status.
185
181
const status =awaitclient.indexingStatus();
186
182
console.log(status);
187
183
// Returns indexing status for all indexed chains
188
-
189
-
// Check if omnichain indexing is within 60 seconds of realtime
190
-
const status =awaitclient.indexingStatus({ maxRealtimeDistance: 60 });
191
-
console.log(status);
192
-
// Returns indexing status, throws if not within 60 seconds of realtime
0 commit comments