@crawlee/types 4.0.0-beta.66 → 4.0.0-beta.68

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/README.md CHANGED
@@ -1,23 +1,23 @@
1
1
  <h1 align="center">
2
2
  <a href="https://crawlee.dev">
3
3
  <picture>
4
- <source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/apify/crawlee/master/website/static/img/crawlee-dark.svg?sanitize=true">
5
- <img alt="Crawlee" src="https://raw.githubusercontent.com/apify/crawlee/master/website/static/img/crawlee-light.svg?sanitize=true" width="500">
4
+ <source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/apify/crawlee/master/website/static/img/crawlee-dark.svg?sanitize=true" />
5
+ <img alt="Crawlee" src="https://raw.githubusercontent.com/apify/crawlee/master/website/static/img/crawlee-light.svg?sanitize=true" width="500" />
6
6
  </picture>
7
7
  </a>
8
- <br>
8
+ <br />
9
9
  <small>A web scraping and browser automation library</small>
10
10
  </h1>
11
11
 
12
- <p align=center>
13
- <a href="https://trendshift.io/repositories/5179" target="_blank"><img src="https://trendshift.io/api/badge/repositories/5179" alt="apify%2Fcrawlee | Trendshift" style="width: 250px; height: 55px;" width="250" height="55"/></a>
12
+ <p align="center">
13
+ <a href="https://trendshift.io/repositories/5179" target="_blank"><img src="https://trendshift.io/api/badge/repositories/5179" alt="apify%2Fcrawlee | Trendshift" width="250" height="55"/></a>
14
14
  </p>
15
15
 
16
- <p align=center>
17
- <a href="https://www.npmjs.com/package/@crawlee/core" rel="nofollow"><img src="https://img.shields.io/npm/v/@crawlee/core.svg" alt="NPM latest version" data-canonical-src="https://img.shields.io/npm/v/@crawlee/core/next.svg" style="max-width: 100%;"></a>
18
- <a href="https://www.npmjs.com/package/@crawlee/core" rel="nofollow"><img src="https://img.shields.io/npm/dm/@crawlee/core.svg" alt="Downloads" data-canonical-src="https://img.shields.io/npm/dm/@crawlee/core.svg" style="max-width: 100%;"></a>
19
- <a href="https://discord.gg/jyEM2PRvMU" rel="nofollow"><img src="https://img.shields.io/discord/801163717915574323?label=discord" alt="Chat on discord" data-canonical-src="https://img.shields.io/discord/801163717915574323?label=discord" style="max-width: 100%;"></a>
20
- <a href="https://github.com/apify/crawlee/actions/workflows/test-ci.yml"><img src="https://github.com/apify/crawlee/actions/workflows/test-ci.yml/badge.svg?branch=master" alt="Build Status" style="max-width: 100%;"></a>
16
+ <p align="center">
17
+ <a href="https://www.npmjs.com/package/@crawlee/core" rel="nofollow"><img src="https://img.shields.io/npm/v/@crawlee/core.svg" alt="NPM latest version" data-canonical-src="https://img.shields.io/npm/v/@crawlee/core/next.svg" /></a>
18
+ <a href="https://www.npmjs.com/package/@crawlee/core" rel="nofollow"><img src="https://img.shields.io/npm/dm/@crawlee/core.svg" alt="Downloads" data-canonical-src="https://img.shields.io/npm/dm/@crawlee/core.svg" /></a>
19
+ <a href="https://discord.gg/jyEM2PRvMU" rel="nofollow"><img src="https://img.shields.io/discord/801163717915574323?label=discord" alt="Chat on discord" data-canonical-src="https://img.shields.io/discord/801163717915574323?label=discord" /></a>
20
+ <a href="https://github.com/apify/crawlee/actions/workflows/test-ci.yml"><img src="https://github.com/apify/crawlee/actions/workflows/test-ci.yml/badge.svg?branch=master" alt="Build Status" /></a>
21
21
  </p>
22
22
 
23
23
  Crawlee covers your crawling and scraping end-to-end and **helps you build reliable scrapers. Fast.**
package/index.d.ts CHANGED
@@ -1,3 +1,4 @@
1
+ export type * from './status-message.js';
1
2
  export type * from './storages.js';
2
3
  export type * from './utility-types.js';
3
4
  export type * from './browser.js';
package/index.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,mBAAmB,eAAe,CAAC;AACnC,mBAAmB,oBAAoB,CAAC;AACxC,mBAAmB,cAAc,CAAC;AAClC,mBAAmB,kBAAkB,CAAC;AACtC,mBAAmB,cAAc,CAAC;AAClC,mBAAmB,aAAa,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,mBAAmB,qBAAqB,CAAC;AACzC,mBAAmB,eAAe,CAAC;AACnC,mBAAmB,oBAAoB,CAAC;AACxC,mBAAmB,cAAc,CAAC;AAClC,mBAAmB,kBAAkB,CAAC;AACtC,mBAAmB,cAAc,CAAC;AAClC,mBAAmB,aAAa,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@crawlee/types",
3
- "version": "4.0.0-beta.66",
3
+ "version": "4.0.0-beta.68",
4
4
  "description": "Shared types for the crawlee projects",
5
5
  "engines": {
6
6
  "node": ">=22.0.0"
@@ -53,5 +53,5 @@
53
53
  }
54
54
  }
55
55
  },
56
- "gitHead": "3a7bed61f54a8bf2c8b2efef17ffa3a37cb18940"
56
+ "gitHead": "0856e557d3eaa0ec8a5facc775bf4ba98dd6b020"
57
57
  }
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Options for setting a crawler run's status message via {@link BasicCrawler.setStatusMessage}.
3
+ *
4
+ * Setting a status message is not a storage concern — the crawler broadcasts it through the event
5
+ * system (`EventType.STATUS_MESSAGE`), and integrations such as the Apify SDK forward it to their
6
+ * status-reporting backend.
7
+ */
8
+ export interface SetStatusMessageOptions {
9
+ /** Whether this is the final status message of the run. */
10
+ isStatusMessageTerminal?: boolean;
11
+ /** The log level to log the message with. Defaults to `'DEBUG'`. */
12
+ level?: 'DEBUG' | 'INFO' | 'WARNING' | 'ERROR';
13
+ }
14
+ //# sourceMappingURL=status-message.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"status-message.d.ts","sourceRoot":"","sources":["../src/status-message.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,MAAM,WAAW,uBAAuB;IACpC,2DAA2D;IAC3D,uBAAuB,CAAC,EAAE,OAAO,CAAC;IAClC,oEAAoE;IACpE,KAAK,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,OAAO,CAAC;CAClD"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=status-message.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"status-message.js","sourceRoot":"","sources":["../src/status-message.ts"],"names":[],"mappings":""}
package/storages.d.ts CHANGED
@@ -11,6 +11,13 @@ export interface QueueOperationInfo {
11
11
  /** The ID of the added request */
12
12
  requestId: string;
13
13
  }
14
+ /**
15
+ * A single page of items returned by {@link DatasetBackend.getData}.
16
+ *
17
+ * Datasets paginate by offset, so a page is self-describing via `total` / `offset` / `limit`: a
18
+ * frontend assembling all pages knows it has reached the end once `offset + items.length >= total`.
19
+ * The cursor-based counterpart for key-value stores is {@link KeyValueStoreListKeysResult}.
20
+ */
14
21
  export interface PaginatedList<Data> {
15
22
  /** Total count of entries in the dataset. */
16
23
  total: number;
@@ -25,7 +32,7 @@ export interface PaginatedList<Data> {
25
32
  /** Dataset entries based on chosen format parameter. */
26
33
  items: Data[];
27
34
  }
28
- export interface DatasetClientListOptions {
35
+ export interface DatasetBackendListOptions {
29
36
  desc?: boolean;
30
37
  limit?: number;
31
38
  offset?: number;
@@ -37,16 +44,8 @@ export interface DatasetInfo {
37
44
  modifiedAt: Date;
38
45
  accessedAt: Date;
39
46
  itemCount: number;
40
- actId?: string;
41
- actRunId?: string;
42
47
  }
43
- export interface DatasetStats {
44
- readCount?: number;
45
- writeCount?: number;
46
- deleteCount?: number;
47
- storageBytes?: number;
48
- }
49
- export interface DatasetClient<Data extends Dictionary = Dictionary> {
48
+ export interface DatasetBackend<Data extends Dictionary = Dictionary> {
50
49
  /**
51
50
  * Returns metadata about the dataset (id, name, timestamps, item count, etc.).
52
51
  *
@@ -62,29 +61,42 @@ export interface DatasetClient<Data extends Dictionary = Dictionary> {
62
61
  /** Add items to the dataset. */
63
62
  pushData(items: Data[]): Promise<void>;
64
63
  /** Fetch a page of items from the dataset. */
65
- getData(options?: DatasetClientListOptions): Promise<PaginatedList<Data>>;
66
- }
67
- export interface KeyValueStoreStats {
68
- readCount?: number;
69
- writeCount?: number;
70
- deleteCount?: number;
71
- listCount?: number;
72
- storageBytes?: number;
64
+ getData(options?: DatasetBackendListOptions): Promise<PaginatedList<Data>>;
73
65
  }
74
66
  export interface KeyValueStoreInfo {
75
67
  id: string;
76
68
  name?: string;
77
- userId?: string;
78
69
  createdAt: Date;
79
70
  modifiedAt: Date;
80
71
  accessedAt: Date;
81
- actId?: string;
82
- actRunId?: string;
83
- stats?: KeyValueStoreStats;
84
72
  }
73
+ /**
74
+ * The value a serialized record carries on the way *into* a storage backend (`setValue`).
75
+ *
76
+ * The `KeyValueStore` frontend has already serialized by this point, so it is a pre-serialized
77
+ * string, raw bytes (`Buffer` / `ArrayBuffer` / typed array), or a stream the client drains.
78
+ */
79
+ export type KeyValueStoreRecordInputValue = Buffer | ArrayBuffer | ArrayBufferView | string | NodeJS.ReadableStream | ReadableStream;
80
+ /**
81
+ * A record as returned by a storage backend (`getValue`).
82
+ *
83
+ * Storage backends are byte transports: they persist and return bytes verbatim and never serialize
84
+ * or parse. Interpretation is the `KeyValueStore` frontend's job (it parses according to the content
85
+ * type via `parseValue`). The value is therefore always raw bytes — a `Buffer` (Node) or an
86
+ * `ArrayBuffer` (browser backends).
87
+ */
85
88
  export interface KeyValueStoreRecord {
86
89
  key: string;
87
- value: any;
90
+ value: Buffer | ArrayBuffer;
91
+ contentType?: string;
92
+ }
93
+ /**
94
+ * A record passed to a storage backend for writing (`setValue`). Like {@link KeyValueStoreRecord} but
95
+ * with the lenient, pre-serialized {@link KeyValueStoreRecordInputValue} for the value.
96
+ */
97
+ export interface KeyValueStoreInputRecord {
98
+ key: string;
99
+ value: KeyValueStoreRecordInputValue;
88
100
  contentType?: string;
89
101
  }
90
102
  export interface KeyValueStoreListKeysOptions {
@@ -98,11 +110,37 @@ export interface KeyValueStoreListKeysOptions {
98
110
  export interface KeyValueStoreItemData {
99
111
  key: string;
100
112
  size: number;
113
+ /** The MIME content type the record was stored with, if known. */
114
+ contentType: string;
115
+ }
116
+ /**
117
+ * A single page of keys returned by {@link KeyValueStoreBackend.listKeys}.
118
+ *
119
+ * This mirrors {@link PaginatedList} (the shape returned by {@link DatasetBackend.getData}) so that
120
+ * both listing operations on the storage backend layer return a self-describing page. The difference
121
+ * is the pagination model: datasets are offset-based (`total` / `offset`), whereas key-value stores
122
+ * are cursor-based. A frontend assembling all pages should therefore not guess "is this the last
123
+ * page?" from `items.length < limit` — it should rely on {@link isTruncated} and resume from
124
+ * {@link nextExclusiveStartKey}.
125
+ */
126
+ export interface KeyValueStoreListKeysResult {
127
+ /** Keys returned on this page. */
128
+ items: KeyValueStoreItemData[];
129
+ /** Number of keys returned on this page (`items.length`). */
130
+ count: number;
131
+ /** Maximum number of keys requested for this page. */
132
+ limit: number;
133
+ /** The `exclusiveStartKey` that produced this page, if any. */
134
+ exclusiveStartKey?: string;
135
+ /** `true` if there are more keys beyond this page. When `true`, {@link nextExclusiveStartKey} is set. */
136
+ isTruncated: boolean;
137
+ /** Cursor to pass as the next call's `exclusiveStartKey`, or `undefined` when {@link isTruncated} is `false`. */
138
+ nextExclusiveStartKey?: string;
101
139
  }
102
140
  /**
103
141
  * Key-value Store client.
104
142
  */
105
- export interface KeyValueStoreClient {
143
+ export interface KeyValueStoreBackend {
106
144
  /**
107
145
  * Returns metadata about the key-value store (id, name, timestamps, etc.).
108
146
  *
@@ -115,81 +153,49 @@ export interface KeyValueStoreClient {
115
153
  drop(): Promise<void>;
116
154
  /** Remove all records from the store but keep the store itself. */
117
155
  purge(): Promise<void>;
118
- /** Get a record value by key. Returns the parsed value or `undefined` if not found. */
156
+ /**
157
+ * Get a record by key. Returns the raw bytes plus content type, or `undefined` if not found.
158
+ *
159
+ * Clients are byte transports and must not parse the body — the `KeyValueStore` frontend
160
+ * interprets it according to the content type.
161
+ */
119
162
  getValue(key: string): Promise<KeyValueStoreRecord | undefined>;
120
163
  /** Set a record value. */
121
- setValue(record: KeyValueStoreRecord): Promise<void>;
164
+ setValue(record: KeyValueStoreInputRecord): Promise<void>;
122
165
  /** Delete a record by key. */
123
166
  deleteValue(key: string): Promise<void>;
124
- /** List keys in the store. Returns at most `limit` keys starting after `exclusiveStartKey`. */
125
- listKeys(options?: KeyValueStoreListKeysOptions): Promise<KeyValueStoreItemData[]>;
167
+ /**
168
+ * List a single page of keys in the store. Returns at most `limit` keys starting after
169
+ * `exclusiveStartKey`, wrapped in a self-describing page.
170
+ *
171
+ * Like {@link DatasetBackend.getData}, this returns one page rather than the whole collection;
172
+ * assembling all pages (e.g. for `KeyValueStore.keys()`) is the frontend's job. The result carries
173
+ * a cursor (`isTruncated` / `nextExclusiveStartKey`) so the frontend can paginate deterministically
174
+ * instead of inferring the end from `items.length < limit`.
175
+ */
176
+ listKeys(options?: KeyValueStoreListKeysOptions): Promise<KeyValueStoreListKeysResult>;
126
177
  /** Get the public URL for a record, or `undefined` if unavailable. */
127
178
  getPublicUrl(key: string): Promise<string | undefined>;
128
179
  /** Check whether a record with the given key exists. */
129
180
  recordExists(key: string): Promise<boolean>;
130
181
  }
131
- export interface RequestQueueStats {
132
- readCount?: number;
133
- writeCount?: number;
134
- deleteCount?: number;
135
- headItemReadCount?: number;
136
- storageBytes?: number;
137
- }
138
182
  export interface RequestQueueInfo {
139
183
  id: string;
140
184
  name?: string;
141
- userId?: string;
142
185
  createdAt: Date;
143
186
  modifiedAt: Date;
144
187
  accessedAt: Date;
145
- expireAt?: string;
146
188
  totalRequestCount: number;
147
189
  handledRequestCount: number;
148
190
  pendingRequestCount: number;
149
- actId?: string;
150
- actRunId?: string;
151
- hadMultipleClients?: boolean;
152
- stats?: RequestQueueStats;
153
- }
154
- export interface RequestQueueHeadItem {
155
- id: string;
156
- retryCount: number;
157
- uniqueKey: string;
158
- url: string;
159
- method: AllowedHttpMethods;
160
- }
161
- export interface QueueHead {
162
- limit: number;
163
- queueModifiedAt: Date;
164
- hadMultipleClients?: boolean;
165
- items: RequestQueueHeadItem[];
166
- }
167
- export interface ListOptions {
168
- /**
169
- * @default 100
170
- */
171
- limit?: number;
172
- }
173
- export interface ListAndLockOptions extends ListOptions {
174
- lockSecs: number;
175
- }
176
- export interface ListAndLockHeadResult extends QueueHead {
177
- lockSecs: number;
178
- queueHasLockedRequests?: boolean;
179
- }
180
- export interface ProlongRequestLockOptions {
181
- lockSecs: number;
182
- forefront?: boolean;
183
191
  }
184
- export interface ProlongRequestLockResult {
185
- lockExpiresAt: Date;
186
- }
187
- export interface DeleteRequestLockOptions {
188
- forefront?: boolean;
189
- }
190
- export interface RequestOptions {
192
+ /**
193
+ * Options for request-queue operations that add or return requests to the queue
194
+ * ({@link RequestQueueBackend.addBatchOfRequests}, {@link RequestQueueBackend.reclaimRequest}).
195
+ */
196
+ export interface RequestQueueOperationOptions {
197
+ /** Place the affected request(s) at the beginning of the queue so they are processed sooner. */
191
198
  forefront?: boolean;
192
- [k: string]: unknown;
193
199
  }
194
200
  export interface RequestSchema {
195
201
  id?: string;
@@ -223,7 +229,15 @@ export interface BatchAddRequestsResult {
223
229
  processedRequests: ProcessedRequest[];
224
230
  unprocessedRequests: UnprocessedRequest[];
225
231
  }
226
- export interface RequestQueueClient {
232
+ /**
233
+ * Operations on a single request queue.
234
+ *
235
+ * A backend implementation owns all request bookkeeping (pending, in-progress, handled). Any
236
+ * coordination required between multiple distributed clients accessing the same queue (e.g. request
237
+ * locking on the Apify platform) is an internal concern of the implementation and is not exposed on
238
+ * this interface.
239
+ */
240
+ export interface RequestQueueBackend {
227
241
  /**
228
242
  * Returns metadata about the request queue (id, name, timestamps, request counts, etc.).
229
243
  *
@@ -236,18 +250,85 @@ export interface RequestQueueClient {
236
250
  drop(): Promise<void>;
237
251
  /** Remove all requests from the queue but keep the queue itself. */
238
252
  purge(): Promise<void>;
239
- listHead(options?: ListOptions): Promise<QueueHead>;
240
- addRequest(request: RequestSchema, options?: RequestOptions): Promise<QueueOperationInfo>;
241
- batchAddRequests(requests: RequestSchema[], options?: RequestOptions): Promise<BatchAddRequestsResult>;
242
- getRequest(id: string): Promise<RequestOptions | undefined>;
243
- updateRequest(request: UpdateRequestSchema, options?: RequestOptions): Promise<QueueOperationInfo>;
244
- listAndLockHead(options: ListAndLockOptions): Promise<ListAndLockHeadResult>;
245
- prolongRequestLock(id: string, options: ProlongRequestLockOptions): Promise<ProlongRequestLockResult>;
246
- deleteRequestLock(id: string, options?: DeleteRequestLockOptions): Promise<void>;
247
- }
248
- export interface SetStatusMessageOptions {
249
- isStatusMessageTerminal?: boolean;
250
- level?: 'DEBUG' | 'INFO' | 'WARNING' | 'ERROR';
253
+ /**
254
+ * Add a batch of requests to the queue.
255
+ *
256
+ * Each request is deduplicated by its `uniqueKey`. Duplicates are reported in the result
257
+ * but not re-added. With `forefront`, requests are placed at the beginning of the queue so
258
+ * they are processed sooner.
259
+ */
260
+ addBatchOfRequests(requests: RequestSchema[], options?: RequestQueueOperationOptions): Promise<BatchAddRequestsResult>;
261
+ /**
262
+ * Retrieve a request from the queue by its `uniqueKey`, or `undefined` if it does not exist.
263
+ */
264
+ getRequest(uniqueKey: string): Promise<UpdateRequestSchema | undefined>;
265
+ /**
266
+ * Return the next request in the queue to be processed, or `undefined` if there are currently no
267
+ * pending requests.
268
+ *
269
+ * The returned request is marked as in-progress; it will not be returned again until it is
270
+ * either reclaimed via {@link reclaimRequest} or marked as handled via {@link markRequestAsHandled}.
271
+ *
272
+ * An `undefined` return value does not mean processing is finished — only that there are no pending
273
+ * requests right now. Use {@link isEmpty} (together with the frontend's knowledge of pending
274
+ * add operations) to determine whether the queue is truly finished.
275
+ */
276
+ fetchNextRequest(): Promise<UpdateRequestSchema | undefined>;
277
+ /**
278
+ * Mark a request previously returned by {@link fetchNextRequest} as handled.
279
+ *
280
+ * Handled requests are never returned again by {@link fetchNextRequest}. Returns information
281
+ * about the operation, or `undefined` if the request was not in progress.
282
+ *
283
+ * An `undefined` result is a no-op, not an error: the request is simply not something this client is
284
+ * currently processing, so nothing is changed and the request is never added to the queue as a side
285
+ * effect. (Marking an already-handled request is idempotent and still returns operation info with
286
+ * `wasAlreadyHandled: true` rather than `undefined`.)
287
+ */
288
+ markRequestAsHandled(request: UpdateRequestSchema): Promise<QueueOperationInfo | undefined>;
289
+ /**
290
+ * Reclaim a failed request back to the queue so it can be processed again by a later call to
291
+ * {@link fetchNextRequest}. With `forefront`, the request is returned to the beginning of the
292
+ * queue. Returns information about the operation, or `undefined` if the request was not in progress.
293
+ *
294
+ * The request is expected to already be present in the queue (it should have been obtained via
295
+ * {@link fetchNextRequest}); reclaiming releases its lock rather than inserting it. An `undefined` result
296
+ * is a no-op, not an error: the request is simply not something this client is currently processing,
297
+ * so nothing is changed and the request is never added to the queue as a side effect. Use
298
+ * {@link addBatchOfRequests} to insert a new request.
299
+ */
300
+ reclaimRequest(request: UpdateRequestSchema, options?: RequestQueueOperationOptions): Promise<QueueOperationInfo | undefined>;
301
+ /**
302
+ * Resolves to `true` if the next call to {@link fetchNextRequest} would return `undefined` — i.e. there
303
+ * are no pending requests to fetch right now.
304
+ *
305
+ * Requests that are currently in progress (fetched but not yet handled or reclaimed, including
306
+ * requests locked by other clients sharing the same queue) are **not** counted. An empty queue
307
+ * therefore does not mean crawling is finished — those in-progress requests may still be reclaimed,
308
+ * and background tasks may still add more requests. Use {@link isFinished} to detect completion.
309
+ */
310
+ isEmpty(): Promise<boolean>;
311
+ /**
312
+ * Resolves to `true` only when there is no outstanding work left in the queue at all — i.e. there
313
+ * are no pending requests to fetch **and** no requests currently in progress (fetched but not yet
314
+ * handled or reclaimed, including requests locked by other clients sharing the same queue).
315
+ *
316
+ * This is the strong counterpart of {@link isEmpty}: a queue whose only remaining requests are in
317
+ * progress is empty (nothing to fetch) but not finished (that work might still be reclaimed). It is
318
+ * the building block for determining whether crawling is done — though a frontend may still need to
319
+ * account for its own pending background add operations on top of this.
320
+ */
321
+ isFinished(): Promise<boolean>;
322
+ /**
323
+ * Tells the client how long (in seconds) a consumer expects to hold a request fetched via
324
+ * {@link fetchNextRequest} before marking it handled or reclaiming it — typically the consumer's
325
+ * request-processing timeout plus some padding.
326
+ *
327
+ * A client that coordinates consumers via locking uses this to keep the request reserved for at least
328
+ * this long, so that a long-running consumer does not have its request handed out again while it is
329
+ * still being processed. Clients that do not lock may ignore it.
330
+ */
331
+ setExpectedRequestProcessingTimeSecs?(secs: number): Promise<void>;
251
332
  }
252
333
  /**
253
334
  * Identifies a storage by its ID, name, or alias. At most one may be provided.
@@ -277,17 +358,17 @@ export type StorageIdentifier = {
277
358
  alias?: never;
278
359
  };
279
360
  /**
280
- * Options for creating a dataset client via {@link StorageClient.createDatasetClient}.
361
+ * Options for creating a dataset backend via {@link StorageBackend.createDatasetBackend}.
281
362
  */
282
- export type CreateDatasetClientOptions = StorageIdentifier;
363
+ export type CreateDatasetBackendOptions = StorageIdentifier;
283
364
  /**
284
- * Options for creating a key-value store client via {@link StorageClient.createKeyValueStoreClient}.
365
+ * Options for creating a key-value store backend via {@link StorageBackend.createKeyValueStoreBackend}.
285
366
  */
286
- export type CreateKeyValueStoreClientOptions = StorageIdentifier;
367
+ export type CreateKeyValueStoreBackendOptions = StorageIdentifier;
287
368
  /**
288
- * Options for creating a request queue client via {@link StorageClient.createRequestQueueClient}.
369
+ * Options for creating a request queue backend via {@link StorageBackend.createRequestQueueBackend}.
289
370
  */
290
- export type CreateRequestQueueClientOptions = StorageIdentifier & {
371
+ export type CreateRequestQueueBackendOptions = StorageIdentifier & {
291
372
  /**
292
373
  * Client key for request locking.
293
374
  * TODO: This is an Apify-platform concern and should eventually be pushed down
@@ -307,36 +388,36 @@ export type CreateRequestQueueClientOptions = StorageIdentifier & {
307
388
  * Represents a storage backend capable of working with datasets, key-value stores and request queues.
308
389
  *
309
390
  * A new storage backend needs to implement 4 classes:
310
- * - `StorageClient` - the factory that creates sub-clients
311
- * - `DatasetClient` - operations on a single dataset
312
- * - `KeyValueStoreClient` - operations on a single key-value store
313
- * - `RequestQueueClient` - operations on a single request queue
391
+ * - `StorageBackend` - the factory that creates sub-backends
392
+ * - `DatasetBackend` - operations on a single dataset
393
+ * - `KeyValueStoreBackend` - operations on a single key-value store
394
+ * - `RequestQueueBackend` - operations on a single request queue
314
395
  *
315
- * The `StorageClient` acts as an async factory: each `create*` method either opens an existing
316
- * storage or creates a new one, returning a sub-client bound to that storage instance.
396
+ * The `StorageBackend` acts as an async factory: each `create*` method either opens an existing
397
+ * storage or creates a new one, returning a sub-backend bound to that storage instance.
317
398
  */
318
- export interface StorageClient {
399
+ export interface StorageBackend {
319
400
  /**
320
- * Create (or open) a dataset client.
401
+ * Create (or open) a dataset backend.
321
402
  * If `id` is provided, opens the dataset with that ID.
322
403
  * If `name` is provided, opens an existing dataset with that name or creates a new one.
323
404
  * If neither is provided, opens or creates the default dataset.
324
405
  */
325
- createDatasetClient(options?: CreateDatasetClientOptions): Promise<DatasetClient>;
406
+ createDatasetBackend(options?: CreateDatasetBackendOptions): Promise<DatasetBackend>;
326
407
  /**
327
- * Create (or open) a key-value store client.
408
+ * Create (or open) a key-value store backend.
328
409
  * If `id` is provided, opens the key-value store with that ID.
329
410
  * If `name` is provided, opens an existing store with that name or creates a new one.
330
411
  * If neither is provided, opens or creates the default key-value store.
331
412
  */
332
- createKeyValueStoreClient(options?: CreateKeyValueStoreClientOptions): Promise<KeyValueStoreClient>;
413
+ createKeyValueStoreBackend(options?: CreateKeyValueStoreBackendOptions): Promise<KeyValueStoreBackend>;
333
414
  /**
334
- * Create (or open) a request queue client.
415
+ * Create (or open) a request queue backend.
335
416
  * If `id` is provided, opens the request queue with that ID.
336
417
  * If `name` is provided, opens an existing queue with that name or creates a new one.
337
418
  * If neither is provided, opens or creates the default request queue.
338
419
  */
339
- createRequestQueueClient(options?: CreateRequestQueueClientOptions): Promise<RequestQueueClient>;
420
+ createRequestQueueBackend(options?: CreateRequestQueueBackendOptions): Promise<RequestQueueBackend>;
340
421
  /**
341
422
  * Check whether a storage with the given ID exists.
342
423
  *
@@ -349,15 +430,14 @@ export interface StorageClient {
349
430
  *
350
431
  * The key is used by `StorageInstanceManager` to partition the storage cache per-backend,
351
432
  * so that two storages with the same name but backed by different clients
352
- * (e.g. a local `MemoryStorage` and a cloud `ApifyClient`) are cached as separate instances.
433
+ * (e.g. a local `MemoryStorageBackend` and a cloud `ApifyClient`) are cached as separate instances.
353
434
  *
354
435
  * When not provided, the fallback uses the client's constructor name, so different
355
- * `StorageClient` implementations automatically get separate cache partitions.
436
+ * `StorageBackend` implementations automatically get separate cache partitions.
356
437
  */
357
- getStorageClientCacheKey?(): string;
438
+ getStorageBackendCacheKey?(): string;
358
439
  purge?(): Promise<void>;
359
440
  teardown?(): Promise<void>;
360
- setStatusMessage?(message: string, options?: SetStatusMessageOptions): Promise<void>;
361
441
  stats?: {
362
442
  rateLimitErrors: number[];
363
443
  };
package/storages.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"storages.d.ts","sourceRoot":"","sources":["../src/storages.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAEzE;;;GAGG;AACH,MAAM,WAAW,kBAAkB;IAC/B,6DAA6D;IAC7D,iBAAiB,EAAE,OAAO,CAAC;IAE3B,0DAA0D;IAC1D,iBAAiB,EAAE,OAAO,CAAC;IAE3B,kCAAkC;IAClC,SAAS,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,aAAa,CAAC,IAAI;IAC/B,6CAA6C;IAC7C,KAAK,EAAE,MAAM,CAAC;IACd,qDAAqD;IACrD,KAAK,EAAE,MAAM,CAAC;IACd,2DAA2D;IAC3D,MAAM,EAAE,MAAM,CAAC;IACf,mDAAmD;IACnD,KAAK,EAAE,MAAM,CAAC;IACd,iDAAiD;IACjD,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,wDAAwD;IACxD,KAAK,EAAE,IAAI,EAAE,CAAC;CACjB;AAED,MAAM,WAAW,wBAAwB;IACrC,IAAI,CAAC,EAAE,OAAO,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