@abtnode/core 1.16.14-beta-d802cd3c → 1.16.14-beta-1936d3d0
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/lib/blocklet/manager/disk.js +25 -3
- package/package.json +19 -19
|
@@ -77,7 +77,7 @@ const {
|
|
|
77
77
|
SUSPENDED_REASON,
|
|
78
78
|
} = require('@blocklet/constant');
|
|
79
79
|
const isUndefined = require('lodash/isUndefined');
|
|
80
|
-
const { WELLKNOWN_SERVICE_PATH_PREFIX } = require('@abtnode/constant');
|
|
80
|
+
const { WELLKNOWN_SERVICE_PATH_PREFIX, WELLKNOWN_BLOCKLET_ADMIN_PATH } = require('@abtnode/constant');
|
|
81
81
|
const { signV2 } = require('@arcblock/jwt');
|
|
82
82
|
const normalizePathPrefix = require('@abtnode/util/lib/normalize-path-prefix');
|
|
83
83
|
const pLimit = require('p-limit');
|
|
@@ -610,6 +610,16 @@ class DiskBlockletManager extends BaseBlockletManager {
|
|
|
610
610
|
components: getComponentsInternalInfo(res),
|
|
611
611
|
});
|
|
612
612
|
|
|
613
|
+
this._createNotification(did, {
|
|
614
|
+
title: '',
|
|
615
|
+
description: `${
|
|
616
|
+
componentDids?.length ? getComponentNamesWithVersion(blocklet, componentDids) : 'All components'
|
|
617
|
+
} is successfully stopped for ${blocklet.meta.title}.`,
|
|
618
|
+
entityType: 'blocklet',
|
|
619
|
+
entityId: did,
|
|
620
|
+
severity: 'success',
|
|
621
|
+
});
|
|
622
|
+
|
|
613
623
|
return res;
|
|
614
624
|
}
|
|
615
625
|
|
|
@@ -1299,7 +1309,7 @@ class DiskBlockletManager extends BaseBlockletManager {
|
|
|
1299
1309
|
const enabled = newConfig?.email?.enabled;
|
|
1300
1310
|
if (enabled) {
|
|
1301
1311
|
const { error } = emailConfigSchema.validate(
|
|
1302
|
-
pick(newConfig?.email || {}, ['from', 'host', 'port', 'user', 'password'])
|
|
1312
|
+
pick(newConfig?.email || {}, ['from', 'host', 'port', 'user', 'password', 'secure'])
|
|
1303
1313
|
);
|
|
1304
1314
|
if (error) {
|
|
1305
1315
|
logger.error('configNotification validate error', { error });
|
|
@@ -2011,6 +2021,16 @@ class DiskBlockletManager extends BaseBlockletManager {
|
|
|
2011
2021
|
|
|
2012
2022
|
this.emit(BlockletEvents.statusChange, res);
|
|
2013
2023
|
this.emit(BlockletEvents.started, { ...res, componentDids });
|
|
2024
|
+
this._createNotification(did, {
|
|
2025
|
+
title: '',
|
|
2026
|
+
description: `${getComponentNamesWithVersion(blocklet, componentDids)} is successfully started for ${
|
|
2027
|
+
blocklet.meta.title
|
|
2028
|
+
}.`,
|
|
2029
|
+
entityType: 'blocklet',
|
|
2030
|
+
entityId: did,
|
|
2031
|
+
severity: 'success',
|
|
2032
|
+
});
|
|
2033
|
+
|
|
2014
2034
|
logger.info('blocklet healthy', { did, name, time: Date.now() - startedAt });
|
|
2015
2035
|
} catch (error) {
|
|
2016
2036
|
const status = await states.blocklet.getBlockletStatus(did);
|
|
@@ -2963,7 +2983,9 @@ class DiskBlockletManager extends BaseBlockletManager {
|
|
|
2963
2983
|
if (blocklet) {
|
|
2964
2984
|
const urls = blocklet.site?.domainAliases || [];
|
|
2965
2985
|
const customUrl = urls.find((x) => !x.isProtected)?.value;
|
|
2966
|
-
blockletUrl = `http://${
|
|
2986
|
+
blockletUrl = `http://${
|
|
2987
|
+
customUrl || getDidDomainForBlocklet({ appPid: blocklet.appPid })
|
|
2988
|
+
}${WELLKNOWN_BLOCKLET_ADMIN_PATH}`;
|
|
2967
2989
|
}
|
|
2968
2990
|
} catch (error) {
|
|
2969
2991
|
logger.error('[_createNotification] get blocklet url failed', { error });
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
|
-
"version": "1.16.14-beta-
|
|
6
|
+
"version": "1.16.14-beta-1936d3d0",
|
|
7
7
|
"description": "",
|
|
8
8
|
"main": "lib/index.js",
|
|
9
9
|
"files": [
|
|
@@ -19,19 +19,19 @@
|
|
|
19
19
|
"author": "wangshijun <wangshijun2010@gmail.com> (http://github.com/wangshijun)",
|
|
20
20
|
"license": "Apache-2.0",
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@abtnode/analytics": "1.16.14-beta-
|
|
23
|
-
"@abtnode/auth": "1.16.14-beta-
|
|
24
|
-
"@abtnode/certificate-manager": "1.16.14-beta-
|
|
25
|
-
"@abtnode/constant": "1.16.14-beta-
|
|
26
|
-
"@abtnode/cron": "1.16.14-beta-
|
|
27
|
-
"@abtnode/logger": "1.16.14-beta-
|
|
28
|
-
"@abtnode/models": "1.16.14-beta-
|
|
29
|
-
"@abtnode/queue": "1.16.14-beta-
|
|
30
|
-
"@abtnode/rbac": "1.16.14-beta-
|
|
31
|
-
"@abtnode/router-provider": "1.16.14-beta-
|
|
32
|
-
"@abtnode/static-server": "1.16.14-beta-
|
|
33
|
-
"@abtnode/timemachine": "1.16.14-beta-
|
|
34
|
-
"@abtnode/util": "1.16.14-beta-
|
|
22
|
+
"@abtnode/analytics": "1.16.14-beta-1936d3d0",
|
|
23
|
+
"@abtnode/auth": "1.16.14-beta-1936d3d0",
|
|
24
|
+
"@abtnode/certificate-manager": "1.16.14-beta-1936d3d0",
|
|
25
|
+
"@abtnode/constant": "1.16.14-beta-1936d3d0",
|
|
26
|
+
"@abtnode/cron": "1.16.14-beta-1936d3d0",
|
|
27
|
+
"@abtnode/logger": "1.16.14-beta-1936d3d0",
|
|
28
|
+
"@abtnode/models": "1.16.14-beta-1936d3d0",
|
|
29
|
+
"@abtnode/queue": "1.16.14-beta-1936d3d0",
|
|
30
|
+
"@abtnode/rbac": "1.16.14-beta-1936d3d0",
|
|
31
|
+
"@abtnode/router-provider": "1.16.14-beta-1936d3d0",
|
|
32
|
+
"@abtnode/static-server": "1.16.14-beta-1936d3d0",
|
|
33
|
+
"@abtnode/timemachine": "1.16.14-beta-1936d3d0",
|
|
34
|
+
"@abtnode/util": "1.16.14-beta-1936d3d0",
|
|
35
35
|
"@arcblock/did": "1.18.87",
|
|
36
36
|
"@arcblock/did-auth": "1.18.87",
|
|
37
37
|
"@arcblock/did-ext": "^1.18.87",
|
|
@@ -42,10 +42,10 @@
|
|
|
42
42
|
"@arcblock/pm2-events": "^0.0.5",
|
|
43
43
|
"@arcblock/validator": "^1.18.87",
|
|
44
44
|
"@arcblock/vc": "1.18.87",
|
|
45
|
-
"@blocklet/constant": "1.16.14-beta-
|
|
46
|
-
"@blocklet/meta": "1.16.14-beta-
|
|
47
|
-
"@blocklet/resolver": "1.16.14-beta-
|
|
48
|
-
"@blocklet/sdk": "1.16.14-beta-
|
|
45
|
+
"@blocklet/constant": "1.16.14-beta-1936d3d0",
|
|
46
|
+
"@blocklet/meta": "1.16.14-beta-1936d3d0",
|
|
47
|
+
"@blocklet/resolver": "1.16.14-beta-1936d3d0",
|
|
48
|
+
"@blocklet/sdk": "1.16.14-beta-1936d3d0",
|
|
49
49
|
"@did-space/client": "^0.2.129",
|
|
50
50
|
"@fidm/x509": "^1.2.1",
|
|
51
51
|
"@ocap/mcrypto": "1.18.87",
|
|
@@ -99,5 +99,5 @@
|
|
|
99
99
|
"jest": "^27.5.1",
|
|
100
100
|
"unzipper": "^0.10.11"
|
|
101
101
|
},
|
|
102
|
-
"gitHead": "
|
|
102
|
+
"gitHead": "32bcf5b55889ebd7302887eedd306d331e9cd3b8"
|
|
103
103
|
}
|