@crawlee/fs-storage 4.0.0-beta.80 → 4.0.0-beta.82
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
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@crawlee/fs-storage",
|
|
3
|
-
"version": "4.0.0-beta.
|
|
3
|
+
"version": "4.0.0-beta.82",
|
|
4
4
|
"description": "A file-system storage implementation of the Apify API",
|
|
5
5
|
"engines": {
|
|
6
6
|
"node": ">=22.0.0"
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
},
|
|
44
44
|
"dependencies": {
|
|
45
45
|
"@crawlee/fs-storage-native": "0.1.5-beta.18",
|
|
46
|
-
"@crawlee/types": "4.0.0-beta.
|
|
46
|
+
"@crawlee/types": "4.0.0-beta.82",
|
|
47
47
|
"@sapphire/shapeshift": "^4.0.0"
|
|
48
48
|
},
|
|
49
49
|
"lerna": {
|
|
@@ -53,5 +53,5 @@
|
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
},
|
|
56
|
-
"gitHead": "
|
|
56
|
+
"gitHead": "eb1096f7c7743d124375ef011fbbadb19476822e"
|
|
57
57
|
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
export declare abstract class CachedIdClient {
|
|
7
7
|
/** The storage id assigned by the native client. Set once by the subclass `create()`. */
|
|
8
|
-
protected
|
|
8
|
+
protected cachedId: string;
|
|
9
9
|
/** The storage id assigned by the native client. */
|
|
10
10
|
get id(): string;
|
|
11
11
|
}
|
|
@@ -5,9 +5,9 @@
|
|
|
5
5
|
*/
|
|
6
6
|
export class CachedIdClient {
|
|
7
7
|
/** The storage id assigned by the native client. Set once by the subclass `create()`. */
|
|
8
|
-
|
|
8
|
+
cachedId;
|
|
9
9
|
/** The storage id assigned by the native client. */
|
|
10
10
|
get id() {
|
|
11
|
-
return this.
|
|
11
|
+
return this.cachedId;
|
|
12
12
|
}
|
|
13
13
|
}
|
|
@@ -33,7 +33,7 @@ export class DatasetBackend extends CachedIdClient {
|
|
|
33
33
|
}
|
|
34
34
|
static async create(options) {
|
|
35
35
|
const backend = new DatasetBackend(options);
|
|
36
|
-
backend.
|
|
36
|
+
backend.cachedId = (await options.nativeBackend.getMetadata()).id;
|
|
37
37
|
return backend;
|
|
38
38
|
}
|
|
39
39
|
async getMetadata() {
|
|
@@ -58,7 +58,7 @@ export class KeyValueStoreBackend extends CachedIdClient {
|
|
|
58
58
|
}
|
|
59
59
|
static async create(options) {
|
|
60
60
|
const backend = new KeyValueStoreBackend(options);
|
|
61
|
-
backend.
|
|
61
|
+
backend.cachedId = (await options.nativeBackend.getMetadata()).id;
|
|
62
62
|
return backend;
|
|
63
63
|
}
|
|
64
64
|
async getMetadata() {
|
|
@@ -52,7 +52,7 @@ export class RequestQueueBackend extends CachedIdClient {
|
|
|
52
52
|
}
|
|
53
53
|
static async create(options) {
|
|
54
54
|
const backend = new RequestQueueBackend(options);
|
|
55
|
-
backend.
|
|
55
|
+
backend.cachedId = (await options.nativeBackend.getMetadata()).id;
|
|
56
56
|
return backend;
|
|
57
57
|
}
|
|
58
58
|
/**
|