@ytsaurus/ui 1.20.0 → 1.22.0
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/build/cjs/@types/core.d.ts +1 -1
- package/build/cjs/server/ServerFactory.d.ts +3 -0
- package/build/cjs/server/ServerFactory.js +3 -0
- package/build/cjs/server/ServerFactory.js.map +1 -1
- package/build/cjs/server/controllers/availability.js +36 -18
- package/build/cjs/server/controllers/availability.js.map +1 -1
- package/build/cjs/server/controllers/odin-proxy-api.js +3 -4
- package/build/cjs/server/controllers/odin-proxy-api.js.map +1 -1
- package/build/cjs/ui/pages/navigation/Navigation/ContentViewer/helpers/getComponentByContentType.js +2 -0
- package/build/cjs/ui/pages/navigation/Navigation/ContentViewer/helpers/getComponentByContentType.js.map +1 -1
- package/build/cjs/ui/pages/odin/_actions/odin-overview.js +1 -1
- package/build/cjs/ui/pages/odin/_actions/odin-overview.js.map +1 -1
- package/build/cjs/ui/pages/odin/controls/OdinToolbar.js +2 -1
- package/build/cjs/ui/pages/odin/controls/OdinToolbar.js.map +1 -1
- package/build/cjs/ui/pages/odin/odin-utils.d.ts +1 -1
- package/build/cjs/ui/pages/odin/odin-utils.js +2 -2
- package/build/cjs/ui/pages/odin/odin-utils.js.map +1 -1
- package/build/cjs/ui/store/actions/operations/jobs-monitor.js +5 -3
- package/build/cjs/ui/store/actions/operations/jobs-monitor.js.map +1 -1
- package/build/cjs/ui/store/selectors/operations/operation.d.ts +8 -1676
- package/build/cjs/ui/store/selectors/operations/operation.js +9 -12
- package/build/cjs/ui/store/selectors/operations/operation.js.map +1 -1
- package/build/cjs/ui/utils/navigation/path-editor.js +1 -0
- package/build/cjs/ui/utils/navigation/path-editor.js.map +1 -1
- package/build/esm/@types/core.d.ts +1 -1
- package/build/esm/server/ServerFactory.d.ts +3 -0
- package/build/esm/server/ServerFactory.js +4 -0
- package/build/esm/server/ServerFactory.js.map +1 -1
- package/build/esm/server/controllers/availability.js +43 -23
- package/build/esm/server/controllers/availability.js.map +1 -1
- package/build/esm/server/controllers/odin-proxy-api.js +9 -10
- package/build/esm/server/controllers/odin-proxy-api.js.map +1 -1
- package/build/esm/ui/pages/navigation/Navigation/ContentViewer/helpers/getComponentByContentType.js +2 -0
- package/build/esm/ui/pages/navigation/Navigation/ContentViewer/helpers/getComponentByContentType.js.map +1 -1
- package/build/esm/ui/pages/odin/_actions/odin-overview.js +1 -1
- package/build/esm/ui/pages/odin/_actions/odin-overview.js.map +1 -1
- package/build/esm/ui/pages/odin/controls/OdinToolbar.js +3 -2
- package/build/esm/ui/pages/odin/controls/OdinToolbar.js.map +1 -1
- package/build/esm/ui/pages/odin/odin-utils.d.ts +1 -1
- package/build/esm/ui/pages/odin/odin-utils.js +2 -2
- package/build/esm/ui/pages/odin/odin-utils.js.map +1 -1
- package/build/esm/ui/store/actions/operations/jobs-monitor.js +6 -4
- package/build/esm/ui/store/actions/operations/jobs-monitor.js.map +1 -1
- package/build/esm/ui/store/selectors/operations/operation.d.ts +8 -1676
- package/build/esm/ui/store/selectors/operations/operation.js +8 -11
- package/build/esm/ui/store/selectors/operations/operation.js.map +1 -1
- package/build/esm/ui/utils/navigation/path-editor.js +1 -0
- package/build/esm/ui/utils/navigation/path-editor.js.map +1 -1
- package/dist/public/build/assets-manifest.json +8 -8
- package/dist/public/build/js/main.724df837.js +3 -0
- package/dist/public/build/js/{main.5ce7c259.js.map → main.724df837.js.map} +1 -1
- package/dist/public/build/js/vendors.e6a251eb.js +3 -0
- package/dist/public/build/js/vendors.e6a251eb.js.map +1 -0
- package/dist/public/build/manifest.json +4 -4
- package/dist/server/ServerFactory.d.ts +3 -0
- package/dist/server/ServerFactory.js +3 -0
- package/dist/server/controllers/availability.js +36 -18
- package/dist/server/controllers/odin-proxy-api.js +3 -4
- package/package.json +2 -2
- package/dist/public/build/js/main.5ce7c259.js +0 -3
- package/dist/public/build/js/vendors.3a95f920.js +0 -3
- package/dist/public/build/js/vendors.3a95f920.js.map +0 -1
- /package/dist/public/build/js/{main.5ce7c259.js.LICENSE.txt → main.724df837.js.LICENSE.txt} +0 -0
- /package/dist/public/build/js/{vendors.3a95f920.js.LICENSE.txt → vendors.e6a251eb.js.LICENSE.txt} +0 -0
@@ -3,8 +3,7 @@
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
4
4
|
value: true
|
5
5
|
});
|
6
|
-
exports.
|
7
|
-
var _some2 = _interopRequireDefault(require("lodash/some"));
|
6
|
+
exports.getOperationsMonitorChartStatesFinishedCount = exports.getOperationTypedAttributes = exports.getOperationTasksNames = exports.getOperationTasks = exports.getOperationPools = exports.getOperationPoolNames = exports.getOperationMonitorChartStates = exports.getOperationJobsMonitorTabSettings = exports.getOperationJobsLoadingStatus = exports.getOperationId = exports.getOperationExperimentAssignments = exports.getOperationErasedTrees = exports.getOperationDetailsLoadingStatus = exports.getOperationAlertEventsItems = exports.getOperation = void 0;
|
8
7
|
var _map2 = _interopRequireDefault(require("lodash/map"));
|
9
8
|
var _reduce2 = _interopRequireDefault(require("lodash/reduce"));
|
10
9
|
var _reselect = require("reselect");
|
@@ -74,18 +73,16 @@ var getOperationJobsLoadingStatus = exports.getOperationJobsLoadingStatus = (0,
|
|
74
73
|
var getOperationExperimentAssignments = exports.getOperationExperimentAssignments = (0, _reselect.createSelector)([getOperation], function (operation) {
|
75
74
|
return _ypath.default.getValue(operation, '/@experiment_assignments');
|
76
75
|
});
|
77
|
-
var
|
78
|
-
var res = _ypath.default.getNumberDeprecated(operation, '/@brief_progress/
|
76
|
+
var getOperationMonitoredJobCount = (0, _reselect.createSelector)([getOperation], function (operation) {
|
77
|
+
var res = _ypath.default.getNumberDeprecated(operation, '/@brief_progress/registered_monitoring_descriptor_count');
|
79
78
|
return res;
|
80
79
|
});
|
81
|
-
var
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
}
|
87
|
-
var isOperationWithJobsMonitorTab = exports.isOperationWithJobsMonitorTab = (0, _reselect.createSelector)([getOperationJobsCount, isOperationWithExperiment_ytadmin_11194], function (jobsCount, hasRequiredExperiment) {
|
88
|
-
return hasRequiredExperiment && jobsCount > 0 && jobsCount <= 200;
|
80
|
+
var getOperationJobsMonitorTabSettings = exports.getOperationJobsMonitorTabSettings = (0, _reselect.createSelector)([getOperationMonitoredJobCount], function (jobsCount) {
|
81
|
+
var maxJobCount = 200;
|
82
|
+
return {
|
83
|
+
visible: jobsCount > 0 && jobsCount <= maxJobCount,
|
84
|
+
maxJobCount: maxJobCount
|
85
|
+
};
|
89
86
|
});
|
90
87
|
var getOperationAlertEventsItems = exports.getOperationAlertEventsItems = (0, _reselect.createSelector)([getOperationAlertEvents], function (alertEvents) {
|
91
88
|
return alertEvents;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["_reselect","require","_ypath","_interopRequireDefault","_utils","obj","__esModule","default","getOperationErasedTreesRaw","state","ypath","getValue","operations","detail","getOperationErasedTrees","exports","createSelector","rawTrees","_reduce","acc","item","poolTree","getOperationAlertEvents","details","alert_events","getOperation","operation","getOperationId","getOperationTasks","getOperationTasksNames","tasks","_map","sort","getOperationDetailsLoadingStatus","loading","loaded","error","calculateLoadingStatus","getOperationTypedAttributes","$typedAttributes","getOperationMonitorChartStates","monitorChartStates","getOperationPools","pools","getOperationPoolNames","getOperationsMonitorChartStatesFinishedCount","states","value","getOperationJobsLoadingStatus","jobs","getOperationExperimentAssignments","
|
1
|
+
{"version":3,"names":["_reselect","require","_ypath","_interopRequireDefault","_utils","obj","__esModule","default","getOperationErasedTreesRaw","state","ypath","getValue","operations","detail","getOperationErasedTrees","exports","createSelector","rawTrees","_reduce","acc","item","poolTree","getOperationAlertEvents","details","alert_events","getOperation","operation","getOperationId","getOperationTasks","getOperationTasksNames","tasks","_map","sort","getOperationDetailsLoadingStatus","loading","loaded","error","calculateLoadingStatus","getOperationTypedAttributes","$typedAttributes","getOperationMonitorChartStates","monitorChartStates","getOperationPools","pools","getOperationPoolNames","getOperationsMonitorChartStatesFinishedCount","states","value","getOperationJobsLoadingStatus","jobs","getOperationExperimentAssignments","getOperationMonitoredJobCount","res","getNumberDeprecated","getOperationJobsMonitorTabSettings","jobsCount","maxJobCount","visible","getOperationAlertEventsItems","alertEvents"],"sources":["operation.ts"],"sourcesContent":["import _ from 'lodash';\nimport {createSelector} from 'reselect';\n\nimport {RootState} from '../../../store/reducers';\nimport ypath from '../../../common/thor/ypath';\nimport {calculateLoadingStatus} from '../../../utils/utils';\nimport {FIX_MY_TYPE} from '../../../types';\n\nconst getOperationErasedTreesRaw = (state: RootState) => {\n return ypath.getValue(state.operations.detail, '/operation/@runtime_parameters/erased_trees');\n};\n\nexport const getOperationErasedTrees = createSelector(\n [getOperationErasedTreesRaw],\n (rawTrees: Array<unknown>) => {\n return _.reduce(\n rawTrees,\n (acc, item) => {\n const poolTree = ypath.getValue(item);\n acc[poolTree] = true;\n return acc;\n },\n {} as {[poolTree: string]: boolean},\n );\n },\n);\n\ninterface OperationTask {\n task_name: string;\n}\n\nconst getOperationAlertEvents = (state: RootState) => state.operations.detail.details.alert_events;\n\nexport const getOperation = (state: RootState) => state.operations.detail.operation;\nexport const getOperationId = (state: RootState) =>\n ypath.getValue(state.operations.detail.operation);\nexport const getOperationTasks = createSelector(\n [getOperation],\n (operation): Array<OperationTask> | undefined => {\n return ypath.getValue(operation, '/@progress/tasks');\n },\n);\nexport const getOperationTasksNames = createSelector(\n [getOperationTasks],\n (tasks?: Array<{task_name: string}>) => {\n return _.map(tasks, 'task_name').sort();\n },\n);\n\nexport const getOperationDetailsLoadingStatus = createSelector(\n [\n (state: RootState) => (state.operations.detail as FIX_MY_TYPE).loading,\n (state: RootState) => (state.operations.detail as FIX_MY_TYPE).loaded,\n (state: RootState) => (state.operations.detail as FIX_MY_TYPE).error,\n ],\n (loading, loaded, error) => {\n return calculateLoadingStatus(loading, loaded, error);\n },\n);\n\nexport const getOperationTypedAttributes = (state: RootState) =>\n (state.operations.detail.operation as FIX_MY_TYPE).$typedAttributes;\n\nexport const getOperationMonitorChartStates = (state: RootState) =>\n state.operations.detail.monitorChartStates;\n\nexport const getOperationPools = (state: RootState) =>\n (state.operations.detail.operation as FIX_MY_TYPE).pools;\n\nexport const getOperationPoolNames = createSelector([getOperationPools], (pools): Array<string> => {\n return _.map(pools, 'pool');\n});\n\nexport const getOperationsMonitorChartStatesFinishedCount = createSelector(\n [getOperationMonitorChartStates],\n (states) => {\n return _.reduce(\n states,\n (acc, value) => {\n return value ? acc + 1 : acc;\n },\n 0,\n );\n },\n);\n\nexport const getOperationJobsLoadingStatus = createSelector(\n [\n (state: RootState) => (state.operations.jobs as FIX_MY_TYPE).loading,\n (state: RootState) => (state.operations.jobs as FIX_MY_TYPE).loaded,\n (state: RootState) => (state.operations.jobs as FIX_MY_TYPE).error,\n ],\n (loading, loaded, error) => {\n return calculateLoadingStatus(loading, loaded, error);\n },\n);\n\nexport interface OperationExperimentItem {\n experiment: string;\n group: string;\n ticket: string;\n dimension: string;\n effect: unknown;\n}\n\nexport const getOperationExperimentAssignments = createSelector(\n [getOperation],\n (operation): Array<OperationExperimentItem> => {\n return ypath.getValue(operation, '/@experiment_assignments');\n },\n);\n\nconst getOperationMonitoredJobCount = createSelector([getOperation], (operation) => {\n const res = ypath.getNumberDeprecated(\n operation,\n '/@brief_progress/registered_monitoring_descriptor_count',\n );\n return res;\n});\n\nexport const getOperationJobsMonitorTabSettings = createSelector(\n [getOperationMonitoredJobCount],\n (jobsCount) => {\n const maxJobCount = 200;\n return {visible: jobsCount > 0 && jobsCount <= maxJobCount, maxJobCount};\n },\n);\n\nexport const getOperationAlertEventsItems = createSelector(\n [getOperationAlertEvents],\n (alertEvents) => {\n return alertEvents;\n },\n);\n"],"mappings":";;;;;;;;AACA,IAAAA,SAAA,GAAAC,OAAA;AAGA,IAAAC,MAAA,GAAAC,sBAAA,CAAAF,OAAA;AACA,IAAAG,MAAA,GAAAH,OAAA;AAA2D,SAAAE,uBAAAE,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,U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c,EAAC,CAACS,YAAY,CAAC,EAAE,UAACC,SAAS,EAAK;EAChF,IAAM0B,GAAG,GAAG1C,cAAK,CAAC2C,mBAAmB,CACjC3B,SAAS,EACT,yDACJ,CAAC;EACD,OAAO0B,GAAG;AACd,CAAC,CAAC;AAEK,IAAME,kCAAkC,GAAAvC,OAAA,CAAAuC,kCAAA,GAAG,IAAAtC,wBAAc,EAC5D,CAACmC,6BAA6B,CAAC,EAC/B,UAACI,SAAS,EAAK;EACX,IAAMC,WAAW,GAAG,GAAG;EACvB,OAAO;IAACC,OAAO,EAAEF,SAAS,GAAG,CAAC,IAAIA,SAAS,IAAIC,WAAW;IAAEA,WAAW,EAAXA;EAAW,CAAC;AAC5E,CACJ,CAAC;AAEM,IAAME,4BAA4B,GAAA3C,OAAA,CAAA2C,4BAAA,GAAG,IAAA1C,wBAAc,EACtD,CAACM,uBAAuB,CAAC,EACzB,UAACqC,WAAW,EAAK;EACb,OAAOA,WAAW;AACtB,CACJ,CAAC"}
|
@@ -98,6 +98,7 @@ function getIconNameForType(type, targetPathBroken) {
|
|
98
98
|
transaction: 'code-branch',
|
99
99
|
nested_transaction: 'code-branch',
|
100
100
|
link: _ypath.default.getBoolean(targetPathBroken) ? 'unlink' : 'link',
|
101
|
+
rootstock: 'link',
|
101
102
|
portal_entrance: 'link',
|
102
103
|
cell_node: 'circle',
|
103
104
|
cell_node_map: 'far circle',
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["_unipika","_interopRequireDefault","require","_ypath","_cancelHelper","_rumWrapApi","obj","__esModule","default","pathEditorRequests","exports","CancelHelper","prepareSuggestions","initialPath","parentPath","children","suggestions","_map","child","prepared","childPath","unipika","decode","ypath","getValue","path","type","dynamic","targetPathBroken","_sortBy","preparePath","currentPath","YPath","create","toSubpath","stringify","loadSuggestions","customFilter","ytApiV3Id","list","YTApiId","pathEditorLoadSuggestions","parameters","attributes","cancellation","saveCancelToken","then","nodes","filterByCurrentPath","toLowerCase","_filter","hasPartOfPath","startsWith","isShowCurrentChild","getNextSelectedIndex","suggestion","selectedIndex","length","getPrevSelectedIndex","getCompletedPath","getIconNameForType","icons","document","string_node","int64_node","uint64_node","double_node","boolean_node","map_node","scheduler_pool_tree_map","scheduler_pool","tablet_cell","journal","table","table_dynamic","replicated_table","chaos_replicated_table","replication_log_table","file","topmost_transaction_map","transaction_map","transaction","nested_transaction","link","getBoolean","portal_entrance","cell_node","cell_node_map","sys_node","access_control_object_namespace_map","access_control_object_namespace","access_control_object","icon"],"sources":["path-editor.js"],"sourcesContent":["import _ from 'lodash';\nimport unipika from '../../common/thor/unipika';\nimport ypath from '../../common/thor/ypath';\n\nimport CancelHelper from '../cancel-helper';\nimport {YTApiId, ytApiV3Id} from '../../rum/rum-wrap-api';\n\nexport const pathEditorRequests = new CancelHelper();\n\nfunction prepareSuggestions(initialPath, parentPath, children) {\n let suggestions = _.map(children, (child) => {\n const prepared = {};\n\n prepared.parentPath = parentPath;\n prepared.childPath = '/' + unipika.decode(ypath.getValue(child));\n prepared.path = prepared.parentPath + prepared.childPath;\n prepared.type = ypath.getValue(child, '/@type');\n prepared.dynamic = ypath.getValue(child, '/@dynamic');\n prepared.targetPathBroken = ypath.getValue(child, '/@broken');\n\n return prepared;\n });\n\n suggestions = _.sortBy(suggestions, 'childPath');\n\n return suggestions;\n}\n\nexport function preparePath(currentPath) {\n return ypath.YPath.create(currentPath, 'absolute').toSubpath(-2).stringify();\n}\n\nexport function loadSuggestions(path, customFilter) {\n const parentPath = preparePath(path);\n\n return ytApiV3Id\n .list(YTApiId.pathEditorLoadSuggestions, {\n parameters: {path: parentPath, attributes: ['type', 'dynamic']},\n cancellation: pathEditorRequests.saveCancelToken,\n })\n .then(ypath.getValue)\n .then((nodes) => prepareSuggestions(path, parentPath, nodes))\n .then((suggestions) => (customFilter ? customFilter(suggestions) : suggestions));\n}\n\nexport function filterByCurrentPath(currentPath, suggestions) {\n const path = currentPath.toLowerCase();\n\n return _.filter(suggestions, (child) => {\n const hasPartOfPath = child.path.startsWith(path);\n const isShowCurrentChild = child.path !== path || child.type === 'map_node';\n\n return hasPartOfPath && isShowCurrentChild;\n });\n}\n\nexport function getNextSelectedIndex(suggestion, selectedIndex) {\n if (selectedIndex === -1 || selectedIndex === suggestion.length - 1) {\n return 0;\n }\n\n return selectedIndex + 1;\n}\n\nexport function getPrevSelectedIndex(suggestions, selectedIndex) {\n if (selectedIndex === -1 || selectedIndex === 0) {\n return suggestions.length - 1;\n }\n\n return selectedIndex - 1;\n}\n\nexport function getCompletedPath(suggestion) {\n return suggestion.type === 'map_node' ? suggestion.path + '/' : suggestion.path;\n}\n\nexport function getIconNameForType(type, targetPathBroken) {\n const icons = {\n document: 'file-alt',\n string_node: 'file-alt',\n int64_node: 'file-alt',\n uint64_node: 'file-alt',\n double_node: 'file-alt',\n boolean_node: 'file-alt',\n map_node: 'folder',\n scheduler_pool_tree_map: 'folder-tree',\n scheduler_pool: 'tasks',\n tablet_cell: 'th',\n journal: 'book',\n table: 'th',\n table_dynamic: 'dyn-th',\n replicated_table: 'th',\n chaos_replicated_table: 'chaos-replicated-table',\n replication_log_table: 'replication-log-table',\n file: 'file',\n topmost_transaction_map: 'folder',\n transaction_map: 'folder',\n transaction: 'code-branch',\n nested_transaction: 'code-branch',\n link: ypath.getBoolean(targetPathBroken) ? 'unlink' : 'link',\n portal_entrance: 'link',\n cell_node: 'circle',\n cell_node_map: 'far circle',\n sys_node: 'cog',\n access_control_object_namespace_map: 'acl-namespace-map',\n access_control_object_namespace: 'acl-namespace',\n access_control_object: 'acl-object',\n };\n\n const icon = type ? icons[type] || 'not-suported' : 'eye-slash';\n\n return icon;\n}\n"],"mappings":";;;;;;;;;;;;;;;;AACA,IAAAA,QAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,MAAA,GAAAF,sBAAA,CAAAC,OAAA;AAEA,IAAAE,aAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,WAAA,GAAAH,OAAA;AAAyD,SAAAD,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E;EAC3B,CAAC;EAED,IAAMC,IAAI,
|
1
|
+
{"version":3,"names":["_unipika","_interopRequireDefault","require","_ypath","_cancelHelper","_rumWrapApi","obj","__esModule","default","pathEditorRequests","exports","CancelHelper","prepareSuggestions","initialPath","parentPath","children","suggestions","_map","child","prepared","childPath","unipika","decode","ypath","getValue","path","type","dynamic","targetPathBroken","_sortBy","preparePath","currentPath","YPath","create","toSubpath","stringify","loadSuggestions","customFilter","ytApiV3Id","list","YTApiId","pathEditorLoadSuggestions","parameters","attributes","cancellation","saveCancelToken","then","nodes","filterByCurrentPath","toLowerCase","_filter","hasPartOfPath","startsWith","isShowCurrentChild","getNextSelectedIndex","suggestion","selectedIndex","length","getPrevSelectedIndex","getCompletedPath","getIconNameForType","icons","document","string_node","int64_node","uint64_node","double_node","boolean_node","map_node","scheduler_pool_tree_map","scheduler_pool","tablet_cell","journal","table","table_dynamic","replicated_table","chaos_replicated_table","replication_log_table","file","topmost_transaction_map","transaction_map","transaction","nested_transaction","link","getBoolean","rootstock","portal_entrance","cell_node","cell_node_map","sys_node","access_control_object_namespace_map","access_control_object_namespace","access_control_object","icon"],"sources":["path-editor.js"],"sourcesContent":["import _ from 'lodash';\nimport unipika from '../../common/thor/unipika';\nimport ypath from '../../common/thor/ypath';\n\nimport CancelHelper from '../cancel-helper';\nimport {YTApiId, ytApiV3Id} from '../../rum/rum-wrap-api';\n\nexport const pathEditorRequests = new CancelHelper();\n\nfunction prepareSuggestions(initialPath, parentPath, children) {\n let suggestions = _.map(children, (child) => {\n const prepared = {};\n\n prepared.parentPath = parentPath;\n prepared.childPath = '/' + unipika.decode(ypath.getValue(child));\n prepared.path = prepared.parentPath + prepared.childPath;\n prepared.type = ypath.getValue(child, '/@type');\n prepared.dynamic = ypath.getValue(child, '/@dynamic');\n prepared.targetPathBroken = ypath.getValue(child, '/@broken');\n\n return prepared;\n });\n\n suggestions = _.sortBy(suggestions, 'childPath');\n\n return suggestions;\n}\n\nexport function preparePath(currentPath) {\n return ypath.YPath.create(currentPath, 'absolute').toSubpath(-2).stringify();\n}\n\nexport function loadSuggestions(path, customFilter) {\n const parentPath = preparePath(path);\n\n return ytApiV3Id\n .list(YTApiId.pathEditorLoadSuggestions, {\n parameters: {path: parentPath, attributes: ['type', 'dynamic']},\n cancellation: pathEditorRequests.saveCancelToken,\n })\n .then(ypath.getValue)\n .then((nodes) => prepareSuggestions(path, parentPath, nodes))\n .then((suggestions) => (customFilter ? customFilter(suggestions) : suggestions));\n}\n\nexport function filterByCurrentPath(currentPath, suggestions) {\n const path = currentPath.toLowerCase();\n\n return _.filter(suggestions, (child) => {\n const hasPartOfPath = child.path.startsWith(path);\n const isShowCurrentChild = child.path !== path || child.type === 'map_node';\n\n return hasPartOfPath && isShowCurrentChild;\n });\n}\n\nexport function getNextSelectedIndex(suggestion, selectedIndex) {\n if (selectedIndex === -1 || selectedIndex === suggestion.length - 1) {\n return 0;\n }\n\n return selectedIndex + 1;\n}\n\nexport function getPrevSelectedIndex(suggestions, selectedIndex) {\n if (selectedIndex === -1 || selectedIndex === 0) {\n return suggestions.length - 1;\n }\n\n return selectedIndex - 1;\n}\n\nexport function getCompletedPath(suggestion) {\n return suggestion.type === 'map_node' ? suggestion.path + '/' : suggestion.path;\n}\n\nexport function getIconNameForType(type, targetPathBroken) {\n const icons = {\n document: 'file-alt',\n string_node: 'file-alt',\n int64_node: 'file-alt',\n uint64_node: 'file-alt',\n double_node: 'file-alt',\n boolean_node: 'file-alt',\n map_node: 'folder',\n scheduler_pool_tree_map: 'folder-tree',\n scheduler_pool: 'tasks',\n tablet_cell: 'th',\n journal: 'book',\n table: 'th',\n table_dynamic: 'dyn-th',\n replicated_table: 'th',\n chaos_replicated_table: 'chaos-replicated-table',\n replication_log_table: 'replication-log-table',\n file: 'file',\n topmost_transaction_map: 'folder',\n transaction_map: 'folder',\n transaction: 'code-branch',\n nested_transaction: 'code-branch',\n link: ypath.getBoolean(targetPathBroken) ? 'unlink' : 'link',\n rootstock: 'link',\n portal_entrance: 'link',\n cell_node: 'circle',\n cell_node_map: 'far circle',\n sys_node: 'cog',\n access_control_object_namespace_map: 'acl-namespace-map',\n access_control_object_namespace: 'acl-namespace',\n access_control_object: 'acl-object',\n };\n\n const icon = type ? icons[type] || 'not-suported' : 'eye-slash';\n\n return icon;\n}\n"],"mappings":";;;;;;;;;;;;;;;;AACA,IAAAA,QAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,MAAA,GAAAF,sBAAA,CAAAC,OAAA;AAEA,IAAAE,aAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,WAAA,GAAAH,OAAA;AAAyD,SAAAD,uBAAAK,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAElD,IAAMG,kBAAkB,GAAAC,OAAA,CAAAD,kBAAA,GAAG,IAAIE,qBAAY,CAAC,CAAC;AAEpD,SAASC,kBAAkBA,CAACC,WAAW,EAAEC,UAAU,EAAEC,QAAQ,EAAE;EAC3D,IAAIC,WAAW,GAAG,IAAAC,aAAA,EAAMF,QAAQ,EAAE,UAACG,KAAK,EAAK;IACzC,IAAMC,QAAQ,GAAG,CAAC,CAAC;IAEnBA,QAAQ,CAACL,UAAU,GAAGA,UAAU;IAChCK,QAAQ,CAACC,SAAS,GAAG,GAAG,GAAGC,gBAAO,CAACC,MAAM,CAACC,cAAK,CAACC,QAAQ,CAACN,KAAK,CAAC,CAAC;IAChEC,QAAQ,CAACM,IAAI,GAAGN,QAAQ,CAACL,UAAU,GAAGK,QAAQ,CAACC,SAAS;IACxDD,QAAQ,CAACO,IAAI,GAAGH,cAAK,CAACC,QAAQ,CAACN,KAAK,EAAE,QAAQ,CAAC;IAC/CC,QAAQ,CAACQ,OAAO,GAAGJ,cAAK,CAACC,QAAQ,CAACN,KAAK,EAAE,WAAW,CAAC;IACrDC,QAAQ,CAACS,gBAAgB,GAAGL,cAAK,CAACC,QAAQ,CAACN,KAAK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,IAAI,EAAE,MAAM;IACZC,uBAAuB,EAAE,QAAQ;IACjCC,eAAe,EAAE,QAAQ;IACzBC,WAAW,EAAE,aAAa;IAC1BC,kBAAkB,EAAE,aAAa;IACjCC,IAAI,EAAE5D,cAAK,CAAC6D,UAAU,CAACxD,gBAAgB,CAAC,GAAG,QAAQ,GAAG,MAAM;IAC5DyD,SAAS,EAAE,MAAM;IACjBC,eAAe,EAAE,MAAM;IACvBC,SAAS,EAAE,QAAQ;IACnBC,aAAa,EAAE,YAAY;IAC3BC,QAAQ,EAAE,KAAK;IACfC,mCAAmC,EAAE,mBAAmB;IACxDC,+BAA+B,EAAE,eAAe;IAChDC,qBAAqB,EAAE;EAC3B,CAAC;EAED,IAAMC,IAAI,GAAGnE,IAAI,GAAGmC,KAAK,CAACnC,IAAI,CAAC,IAAI,cAAc,GAAG,WAAW;EAE/D,OAAOmE,IAAI;AACf"}
|
@@ -51,7 +51,7 @@ export interface YTCoreConfig {
|
|
51
51
|
* Odin is a service for monitoring the availability of YTsaurus clusters
|
52
52
|
* This parameter sets service base url and enables UI page
|
53
53
|
*/
|
54
|
-
odinBaseUrl?: string;
|
54
|
+
odinBaseUrl?: Record<string, string> | string;
|
55
55
|
|
56
56
|
/**
|
57
57
|
* The OAuthRobot should have read/write access to mapNodePath
|
@@ -8,6 +8,9 @@ export interface ServerFactory {
|
|
8
8
|
renderLayout(params: AppLayoutConfig, req: Request, res: Response): Promise<string>;
|
9
9
|
}
|
10
10
|
export declare function rememberApp(v: ExpressKit): void;
|
11
|
+
/**
|
12
|
+
* @deprecated use req.ctx.config instead of App().config
|
13
|
+
*/
|
11
14
|
export declare function getApp(): ExpressKit;
|
12
15
|
export declare function configureServerFactory(overrides: Partial<ServerFactory>): void;
|
13
16
|
declare const _default: ServerFactory;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["isLocalClusterId","renderLayout","isLocalModeByEnvironment","app","rememberApp","v","Error","getApp","serverFactory","getExtraRootPages","cluster","getHomeRedirectedUrl","Promise","resolve","undefined","params","_asyncToGenerator","_regeneratorRuntime","mark","_callee","wrap","_callee$","_context","prev","next","abrupt","sent","stop","configureServerFactoryItem","k","redefinition","configureServerFactory","overrides","_forEach","_v","key","Proxy","set"],"sources":["ServerFactory.ts"],"sourcesContent":["import type {Request, Response} from 'express';\nimport type {ExpressKit} from '@gravity-ui/expresskit';\nimport _ from 'lodash';\nimport {isLocalClusterId} from '../shared/utils';\nimport {ConfigData} from '../shared/yt-types';\nimport renderLayout, {AppLayoutConfig} from './render-layout';\nimport {isLocalModeByEnvironment} from './utils';\n\nexport interface ServerFactory {\n getExtraRootPages(): Array<string>;\n isLocalClusterId(cluster: string): boolean;\n getHomeRedirectedUrl(cluster: string | undefined, req: Request): Promise<string | undefined>;\n renderLayout(params: AppLayoutConfig, req: Request, res: Response): Promise<string>;\n}\n\nlet app: ExpressKit;\n\nexport function rememberApp(v: ExpressKit) {\n if (app) {\n throw new Error('The method must not be called more than once');\n }\n app = v;\n}\n\nexport function getApp() {\n return app!;\n}\n\nconst serverFactory: ServerFactory = {\n getExtraRootPages() {\n return [];\n },\n isLocalClusterId(cluster) {\n return isLocalModeByEnvironment() || isLocalClusterId(cluster);\n },\n getHomeRedirectedUrl() {\n return Promise.resolve(undefined);\n },\n async renderLayout(params) {\n return await renderLayout<ConfigData>(params);\n },\n};\n\nfunction configureServerFactoryItem<K extends keyof ServerFactory>(\n k: K,\n redefinition: ServerFactory[K],\n) {\n serverFactory[k] = redefinition;\n}\n\nexport function configureServerFactory(overrides: Partial<ServerFactory>) {\n _.forEach(overrides, (_v, k) => {\n const key = k as keyof ServerFactory;\n configureServerFactoryItem(key, overrides[key]!);\n });\n}\n\nexport default new Proxy(serverFactory, {\n set: () => {\n throw new Error('Use configureUIFactory(...) method instead of direct modifications');\n },\n});\n"],"mappings":";;;AAGA,SAAQA,gBAAgB,IAAhBA,iBAAgB,QAAO,iBAAiB;AAEhD,OAAOC,aAAY,MAAyB,iBAAiB;AAC7D,SAAQC,wBAAwB,QAAO,SAAS;AAShD,IAAIC,GAAe;AAEnB,OAAO,SAASC,WAAWA,CAACC,CAAa,EAAE;EACvC,IAAIF,GAAG,EAAE;IACL,MAAM,IAAIG,KAAK,CAAC,8CAA8C,CAAC;EACnE;EACAH,GAAG,GAAGE,CAAC;AACX;
|
1
|
+
{"version":3,"names":["isLocalClusterId","renderLayout","isLocalModeByEnvironment","app","rememberApp","v","Error","getApp","serverFactory","getExtraRootPages","cluster","getHomeRedirectedUrl","Promise","resolve","undefined","params","_asyncToGenerator","_regeneratorRuntime","mark","_callee","wrap","_callee$","_context","prev","next","abrupt","sent","stop","configureServerFactoryItem","k","redefinition","configureServerFactory","overrides","_forEach","_v","key","Proxy","set"],"sources":["ServerFactory.ts"],"sourcesContent":["import type {Request, Response} from 'express';\nimport type {ExpressKit} from '@gravity-ui/expresskit';\nimport _ from 'lodash';\nimport {isLocalClusterId} from '../shared/utils';\nimport {ConfigData} from '../shared/yt-types';\nimport renderLayout, {AppLayoutConfig} from './render-layout';\nimport {isLocalModeByEnvironment} from './utils';\n\nexport interface ServerFactory {\n getExtraRootPages(): Array<string>;\n isLocalClusterId(cluster: string): boolean;\n getHomeRedirectedUrl(cluster: string | undefined, req: Request): Promise<string | undefined>;\n renderLayout(params: AppLayoutConfig, req: Request, res: Response): Promise<string>;\n}\n\nlet app: ExpressKit;\n\nexport function rememberApp(v: ExpressKit) {\n if (app) {\n throw new Error('The method must not be called more than once');\n }\n app = v;\n}\n\n/**\n * @deprecated use req.ctx.config instead of App().config\n */\nexport function getApp() {\n return app!;\n}\n\nconst serverFactory: ServerFactory = {\n getExtraRootPages() {\n return [];\n },\n isLocalClusterId(cluster) {\n return isLocalModeByEnvironment() || isLocalClusterId(cluster);\n },\n getHomeRedirectedUrl() {\n return Promise.resolve(undefined);\n },\n async renderLayout(params) {\n return await renderLayout<ConfigData>(params);\n },\n};\n\nfunction configureServerFactoryItem<K extends keyof ServerFactory>(\n k: K,\n redefinition: ServerFactory[K],\n) {\n serverFactory[k] = redefinition;\n}\n\nexport function configureServerFactory(overrides: Partial<ServerFactory>) {\n _.forEach(overrides, (_v, k) => {\n const key = k as keyof ServerFactory;\n configureServerFactoryItem(key, overrides[key]!);\n });\n}\n\nexport default new Proxy(serverFactory, {\n set: () => {\n throw new Error('Use configureUIFactory(...) method instead of direct modifications');\n },\n});\n"],"mappings":";;;AAGA,SAAQA,gBAAgB,IAAhBA,iBAAgB,QAAO,iBAAiB;AAEhD,OAAOC,aAAY,MAAyB,iBAAiB;AAC7D,SAAQC,wBAAwB,QAAO,SAAS;AAShD,IAAIC,GAAe;AAEnB,OAAO,SAASC,WAAWA,CAACC,CAAa,EAAE;EACvC,IAAIF,GAAG,EAAE;IACL,MAAM,IAAIG,KAAK,CAAC,8CAA8C,CAAC;EACnE;EACAH,GAAG,GAAGE,CAAC;AACX;;AAEA;AACA;AACA;AACA,OAAO,SAASE,MAAMA,CAAA,EAAG;EACrB,OAAOJ,GAAG;AACd;AAEA,IAAMK,aAA4B,GAAG;EACjCC,iBAAiB,WAAAA,kBAAA,EAAG;IAChB,OAAO,EAAE;EACb,CAAC;EACDT,gBAAgB,WAAAA,iBAACU,OAAO,EAAE;IACtB,OAAOR,wBAAwB,CAAC,CAAC,IAAIF,iBAAgB,CAACU,OAAO,CAAC;EAClE,CAAC;EACDC,oBAAoB,WAAAA,qBAAA,EAAG;IACnB,OAAOC,OAAO,CAACC,OAAO,CAACC,SAAS,CAAC;EACrC,CAAC;EACKb,YAAY,WAAAA,aAACc,MAAM,EAAE;IAAA,OAAAC,iBAAA,eAAAC,mBAAA,CAAAC,IAAA,UAAAC,QAAA;MAAA,OAAAF,mBAAA,CAAAG,IAAA,UAAAC,SAAAC,QAAA;QAAA,kBAAAA,QAAA,CAAAC,IAAA,GAAAD,QAAA,CAAAE,IAAA;UAAA;YAAAF,QAAA,CAAAE,IAAA;YAAA,OACVvB,aAAY,CAAac,MAAM,CAAC;UAAA;YAAA,OAAAO,QAAA,CAAAG,MAAA,WAAAH,QAAA,CAAAI,IAAA;UAAA;UAAA;YAAA,OAAAJ,QAAA,CAAAK,IAAA;QAAA;MAAA,GAAAR,OAAA;IAAA;EACjD;AACJ,CAAC;AAED,SAASS,0BAA0BA,CAC/BC,CAAI,EACJC,YAA8B,EAChC;EACEtB,aAAa,CAACqB,CAAC,CAAC,GAAGC,YAAY;AACnC;AAEA,OAAO,SAASC,sBAAsBA,CAACC,SAAiC,EAAE;EACtEC,QAAA,CAAUD,SAAS,EAAE,UAACE,EAAE,EAAEL,CAAC,EAAK;IAC5B,IAAMM,GAAG,GAAGN,CAAwB;IACpCD,0BAA0B,CAACO,GAAG,EAAEH,SAAS,CAACG,GAAG,CAAE,CAAC;EACpD,CAAC,CAAC;AACN;AAEA,eAAe,IAAIC,KAAK,CAAC5B,aAAa,EAAE;EACpC6B,GAAG,EAAE,SAAAA,IAAA,EAAM;IACP,MAAM,IAAI/B,KAAK,CAAC,oEAAoE,CAAC;EACzF;AACJ,CAAC,CAAC"}
|
@@ -4,7 +4,6 @@ import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
4
4
|
import axios from 'axios';
|
5
5
|
import { getClustersFromConfig } from '../components/utils';
|
6
6
|
import { sendAndLogError, sendError, sendResponse } from '../utils';
|
7
|
-
import { getApp } from '../ServerFactory';
|
8
7
|
function getClusterAvailability(clusterConfig, odinPath) {
|
9
8
|
var ODIN_PERIOD = 5;
|
10
9
|
var ODIN_METRIC = 'master';
|
@@ -22,31 +21,53 @@ function getClusterAvailability(clusterConfig, odinPath) {
|
|
22
21
|
return response.data;
|
23
22
|
});
|
24
23
|
}
|
25
|
-
function getAvailability(req, clusters
|
26
|
-
var
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
}
|
31
|
-
|
24
|
+
function getAvailability(req, clusters) {
|
25
|
+
var odinBaseUrl = req.ctx.config.odinBaseUrl;
|
26
|
+
var isMultiOdinBaseUrl = 'string' !== typeof odinBaseUrl;
|
27
|
+
var makeOdinIsAliveUrl = function makeOdinIsAliveUrl(odinBaseUrl) {
|
28
|
+
return "".concat(odinBaseUrl, "/is_alive");
|
29
|
+
};
|
30
|
+
var commonIsAlive = isMultiOdinBaseUrl ? Promise.resolve({
|
31
|
+
data: true
|
32
|
+
}) : axios.request({
|
33
|
+
url: makeOdinIsAliveUrl(odinBaseUrl)
|
34
|
+
});
|
35
|
+
return commonIsAlive.then(function (_ref) {
|
36
|
+
var commonAlive = _ref.data;
|
37
|
+
if (!commonAlive) {
|
32
38
|
return [];
|
33
39
|
}
|
34
40
|
return Promise.all(_map(clusters, function (clusterConfig) {
|
35
|
-
var
|
36
|
-
|
37
|
-
return {
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
})["catch"](function (error) {
|
42
|
-
req.ctx.logError('getAvailability error', error);
|
41
|
+
var odinPath = isMultiOdinBaseUrl ? odinBaseUrl === null || odinBaseUrl === void 0 ? void 0 : odinBaseUrl[clusterConfig.id] : odinBaseUrl;
|
42
|
+
if (!odinPath) {
|
43
|
+
return {};
|
44
|
+
}
|
45
|
+
var alive = isMultiOdinBaseUrl ? axios.get(makeOdinIsAliveUrl(odinPath))["catch"](function (e) {
|
46
|
+
req.ctx.logError("Error of getting ".concat(odinPath), e);
|
43
47
|
return {
|
44
|
-
|
48
|
+
data: false
|
45
49
|
};
|
50
|
+
}) : Promise.resolve({
|
51
|
+
data: true
|
52
|
+
});
|
53
|
+
return alive.then(function (_ref2) {
|
54
|
+
var data = _ref2.data;
|
55
|
+
if (data != true) {
|
56
|
+
return {};
|
57
|
+
}
|
58
|
+
return getClusterAvailability(clusterConfig, odinPath).then(function (availability) {
|
59
|
+
return {
|
60
|
+
id: clusterConfig.id,
|
61
|
+
availability: availability
|
62
|
+
};
|
63
|
+
})["catch"](function (error) {
|
64
|
+
req.ctx.logError('getAvailability error', error);
|
65
|
+
return {};
|
66
|
+
});
|
46
67
|
});
|
47
68
|
}));
|
48
69
|
})["catch"](function (e) {
|
49
|
-
req.ctx.logError("Error of getting ".concat(
|
70
|
+
req.ctx.logError("Error of getting ".concat(odinBaseUrl), e);
|
50
71
|
return [];
|
51
72
|
});
|
52
73
|
}
|
@@ -55,13 +76,12 @@ export function getClustersAvailability(_x, _x2) {
|
|
55
76
|
}
|
56
77
|
function _getClustersAvailability() {
|
57
78
|
_getClustersAvailability = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(req, res) {
|
58
|
-
var
|
59
|
-
var odinPath, clusters;
|
79
|
+
var odinBaseUrl, clusters;
|
60
80
|
return _regeneratorRuntime.wrap(function _callee$(_context) {
|
61
81
|
while (1) switch (_context.prev = _context.next) {
|
62
82
|
case 0:
|
63
|
-
|
64
|
-
if (
|
83
|
+
odinBaseUrl = req.ctx.config.odinBaseUrl;
|
84
|
+
if (odinBaseUrl) {
|
65
85
|
_context.next = 4;
|
66
86
|
break;
|
67
87
|
}
|
@@ -70,7 +90,7 @@ function _getClustersAvailability() {
|
|
70
90
|
case 4:
|
71
91
|
clusters = getClustersFromConfig();
|
72
92
|
_context.next = 7;
|
73
|
-
return getAvailability(req, clusters
|
93
|
+
return getAvailability(req, clusters).then(function (data) {
|
74
94
|
return sendResponse(res, data);
|
75
95
|
})["catch"](function (error) {
|
76
96
|
return sendError(res, error);
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["axios","getClustersFromConfig","sendAndLogError","sendError","sendResponse","
|
1
|
+
{"version":3,"names":["axios","getClustersFromConfig","sendAndLogError","sendError","sendResponse","getClusterAvailability","clusterConfig","odinPath","ODIN_PERIOD","ODIN_METRIC","TIMEOUT","request","url","id","params","period","target","method","timeout","responseType","then","response","data","getAvailability","req","clusters","odinBaseUrl","ctx","config","isMultiOdinBaseUrl","makeOdinIsAliveUrl","concat","commonIsAlive","Promise","resolve","_ref","commonAlive","all","_map","alive","get","e","logError","_ref2","availability","error","getClustersAvailability","_x","_x2","_getClustersAvailability","apply","arguments","_asyncToGenerator","_regeneratorRuntime","mark","_callee","res","wrap","_callee$","_context","prev","next","Error","abrupt","stop"],"sources":["availability.ts"],"sourcesContent":["import axios, {AxiosResponse} from 'axios';\nimport _ from 'lodash';\nimport type {Request, Response} from '@gravity-ui/expresskit';\nimport {getClustersFromConfig} from '../components/utils';\nimport {sendAndLogError, sendError, sendResponse} from '../utils';\n\nfunction getClusterAvailability(clusterConfig: {id: string}, odinPath: string) {\n const ODIN_PERIOD = 5;\n const ODIN_METRIC = 'master';\n const TIMEOUT = 15 * 1000;\n\n return axios\n .request({\n url: odinPath + '/availability_stat/' + clusterConfig.id,\n params: {\n period: ODIN_PERIOD,\n target: ODIN_METRIC,\n },\n method: 'GET',\n timeout: TIMEOUT,\n responseType: 'json',\n })\n .then((response: AxiosResponse<1 | undefined>) => {\n return response.data;\n });\n}\n\nfunction getAvailability(req: Request, clusters: Record<string, {id: string}>) {\n const odinBaseUrl = req.ctx.config.odinBaseUrl;\n const isMultiOdinBaseUrl = 'string' !== typeof odinBaseUrl;\n const makeOdinIsAliveUrl = (odinBaseUrl: string) => `${odinBaseUrl}/is_alive`;\n\n const commonIsAlive = isMultiOdinBaseUrl\n ? Promise.resolve({data: true})\n : axios.request({url: makeOdinIsAliveUrl(odinBaseUrl)});\n\n return commonIsAlive\n .then(({data: commonAlive}) => {\n if (!commonAlive) {\n return [];\n }\n\n return Promise.all(\n _.map(clusters, (clusterConfig) => {\n const odinPath = isMultiOdinBaseUrl\n ? odinBaseUrl?.[clusterConfig.id]\n : odinBaseUrl;\n\n if (!odinPath) {\n return {};\n }\n\n const alive = isMultiOdinBaseUrl\n ? axios.get(makeOdinIsAliveUrl(odinPath)).catch((e) => {\n req.ctx.logError(`Error of getting ${odinPath}`, e);\n return {data: false};\n })\n : Promise.resolve({data: true});\n\n return alive.then(({data}) => {\n if (data != true) {\n return {};\n }\n\n return getClusterAvailability(clusterConfig, odinPath)\n .then((availability) => ({id: clusterConfig.id, availability}))\n .catch((error) => {\n req.ctx.logError('getAvailability error', error);\n return {};\n });\n });\n }),\n );\n })\n .catch((e) => {\n req.ctx.logError(`Error of getting ${odinBaseUrl}`, e);\n return [];\n });\n}\n\nexport async function getClustersAvailability(req: Request, res: Response) {\n const odinBaseUrl = req.ctx.config.odinBaseUrl;\n\n if (!odinBaseUrl) {\n sendAndLogError(req.ctx, res, 500, new Error('odin base url is not configured'));\n return;\n }\n const clusters = getClustersFromConfig();\n\n await getAvailability(req, clusters)\n .then((data: object) => sendResponse(res, data))\n .catch((error) => sendError(res, error));\n}\n"],"mappings":";;;AAAA,OAAOA,KAAK,MAAuB,OAAO;AAG1C,SAAQC,qBAAqB,QAAO,qBAAqB;AACzD,SAAQC,eAAe,EAAEC,SAAS,EAAEC,YAAY,QAAO,UAAU;AAEjE,SAASC,sBAAsBA,CAACC,aAA2B,EAAEC,QAAgB,EAAE;EAC3E,IAAMC,WAAW,GAAG,CAAC;EACrB,IAAMC,WAAW,GAAG,QAAQ;EAC5B,IAAMC,OAAO,GAAG,EAAE,GAAG,IAAI;EAEzB,OAAOV,KAAK,CACPW,OAAO,CAAC;IACLC,GAAG,EAAEL,QAAQ,GAAG,qBAAqB,GAAGD,aAAa,CAACO,EAAE;IACxDC,MAAM,EAAE;MACJC,MAAM,EAAEP,WAAW;MACnBQ,MAAM,EAAEP;IACZ,CAAC;IACDQ,MAAM,EAAE,KAAK;IACbC,OAAO,EAAER,OAAO;IAChBS,YAAY,EAAE;EAClB,CAAC,CAAC,CACDC,IAAI,CAAC,UAACC,QAAsC,EAAK;IAC9C,OAAOA,QAAQ,CAACC,IAAI;EACxB,CAAC,CAAC;AACV;AAEA,SAASC,eAAeA,CAACC,GAAY,EAAEC,QAAsC,EAAE;EAC3E,IAAMC,WAAW,GAAGF,GAAG,CAACG,GAAG,CAACC,MAAM,CAACF,WAAW;EAC9C,IAAMG,kBAAkB,GAAG,QAAQ,KAAK,OAAOH,WAAW;EAC1D,IAAMI,kBAAkB,GAAG,SAArBA,kBAAkBA,CAAIJ,WAAmB;IAAA,UAAAK,MAAA,CAAQL,WAAW;EAAA,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e,CAACC,GAAG,EAAEC,QAAQ,CAAC,CAC/BL,IAAI,CAAC,UAACE,IAAY;YAAA,OAAKlB,YAAY,CAACoD,GAAG,EAAElC,IAAI,CAAC;UAAA,EAAC,SAC1C,CAAC,UAACuB,KAAK;YAAA,OAAK1C,SAAS,CAACqD,GAAG,EAAEX,KAAK,CAAC;UAAA,EAAC;QAAA;QAAA;UAAA,OAAAc,QAAA,CAAAK,IAAA;MAAA;IAAA,GAAAT,OAAA;EAAA,CAC/C;EAAA,OAAAN,wBAAA,CAAAC,KAAA,OAAAC,SAAA;AAAA"}
|
@@ -6,7 +6,6 @@ import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
6
6
|
import axios from 'axios';
|
7
7
|
import qs from 'qs';
|
8
8
|
import { UNEXPECTED_PIPE_AXIOS_RESPONSE, pipeAxiosResponse, sendAndLogError } from '../utils';
|
9
|
-
import { getApp } from '../ServerFactory';
|
10
9
|
export function odinProxyApi(_x, _x2) {
|
11
10
|
return _odinProxyApi.apply(this, arguments);
|
12
11
|
}
|
@@ -43,32 +42,32 @@ function odinProxyApiImpl(_x3, _x4) {
|
|
43
42
|
}
|
44
43
|
function _odinProxyApiImpl() {
|
45
44
|
_odinProxyApiImpl = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee3(req, res) {
|
46
|
-
var
|
47
|
-
var odinPath, ctx, query, search, _req$params, action, cluster, allowedActionsUrls, url;
|
45
|
+
var _req$params, action, cluster, odinBaseUrl, odinPath, ctx, query, search, allowedActionsUrls, url;
|
48
46
|
return _regeneratorRuntime.wrap(function _callee3$(_context3) {
|
49
47
|
while (1) switch (_context3.prev = _context3.next) {
|
50
48
|
case 0:
|
51
|
-
|
49
|
+
_req$params = req.params, action = _req$params.action, cluster = _req$params.ytAuthCluster;
|
50
|
+
odinBaseUrl = req.ctx.config.odinBaseUrl;
|
51
|
+
odinPath = typeof odinBaseUrl === 'string' ? odinBaseUrl : odinBaseUrl === null || odinBaseUrl === void 0 ? void 0 : odinBaseUrl[cluster];
|
52
52
|
if (odinPath) {
|
53
|
-
_context3.next =
|
53
|
+
_context3.next = 5;
|
54
54
|
break;
|
55
55
|
}
|
56
56
|
return _context3.abrupt("return", sendAndLogError(req.ctx, res, 500, new Error('Odin base url is not configured')));
|
57
|
-
case
|
57
|
+
case 5:
|
58
58
|
ctx = req.ctx, query = req.query;
|
59
59
|
search = _isEmpty(query) ? '' : "?".concat(qs.stringify(query));
|
60
|
-
_req$params = req.params, action = _req$params.action, cluster = _req$params.ytAuthCluster;
|
61
60
|
allowedActionsUrls = {
|
62
61
|
service_list: "".concat(odinPath, "/service_list"),
|
63
62
|
exists: "".concat(odinPath, "/").concat(action, "/").concat(cluster),
|
64
63
|
availability: "".concat(odinPath, "/").concat(action, "/").concat(cluster).concat(search)
|
65
64
|
};
|
66
65
|
if (_has(allowedActionsUrls, action)) {
|
67
|
-
_context3.next =
|
66
|
+
_context3.next = 10;
|
68
67
|
break;
|
69
68
|
}
|
70
69
|
return _context3.abrupt("return", sendAndLogError(req.ctx, res, 400, new Error("Odin action - ".concat(action, ", is not supported"))));
|
71
|
-
case
|
70
|
+
case 10:
|
72
71
|
url = allowedActionsUrls[action];
|
73
72
|
return _context3.abrupt("return", axios.request({
|
74
73
|
url: url,
|
@@ -104,7 +103,7 @@ function _odinProxyApiImpl() {
|
|
104
103
|
return _ref.apply(this, arguments);
|
105
104
|
};
|
106
105
|
}()));
|
107
|
-
case
|
106
|
+
case 12:
|
108
107
|
case "end":
|
109
108
|
return _context3.stop();
|
110
109
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["axios","qs","UNEXPECTED_PIPE_AXIOS_RESPONSE","pipeAxiosResponse","sendAndLogError","
|
1
|
+
{"version":3,"names":["axios","qs","UNEXPECTED_PIPE_AXIOS_RESPONSE","pipeAxiosResponse","sendAndLogError","odinProxyApi","_x","_x2","_odinProxyApi","apply","arguments","_asyncToGenerator","_regeneratorRuntime","mark","_callee","req","res","wrap","_callee$","_context","prev","next","odinProxyApiImpl","t0","ctx","method","query","page","headers","referer","stop","_x3","_x4","_odinProxyApiImpl","_callee3","_req$params","action","cluster","odinBaseUrl","odinPath","search","allowedActionsUrls","url","_callee3$","_context3","params","ytAuthCluster","config","abrupt","Error","_isEmpty","concat","stringify","service_list","exists","availability","_has","request","_objectSpread","getMetadata","data","body","timeout","responseType","then","_ref","_callee2","response","pipedSize","_callee2$","_context2","sent","_x5"],"sources":["odin-proxy-api.ts"],"sourcesContent":["import _ from 'lodash';\nimport axios from 'axios';\nimport qs from 'qs';\n\nimport type {Request, Response} from 'express';\nimport {UNEXPECTED_PIPE_AXIOS_RESPONSE, pipeAxiosResponse, sendAndLogError} from '../utils';\n\nexport async function odinProxyApi(req: Request, res: Response) {\n try {\n await odinProxyApiImpl(req, res);\n } catch (e: any) {\n await sendAndLogError(req.ctx, res, 500, e, {\n method: 'nodejs',\n query: req.query,\n page: req.headers.referer,\n });\n }\n}\n\nasync function odinProxyApiImpl(req: Request, res: Response) {\n const {action, ytAuthCluster: cluster} = req.params;\n const {odinBaseUrl} = req.ctx.config;\n const odinPath = typeof odinBaseUrl === 'string' ? odinBaseUrl : odinBaseUrl?.[cluster];\n\n if (!odinPath) {\n return sendAndLogError(req.ctx, res, 500, new Error('Odin base url is not configured'));\n }\n const {ctx, query} = req;\n\n const search = _.isEmpty(query) ? '' : `?${qs.stringify(query)}`;\n\n const allowedActionsUrls: Record<string, string> = {\n service_list: `${odinPath}/service_list`,\n exists: `${odinPath}/${action}/${cluster}`,\n availability: `${odinPath}/${action}/${cluster}${search}`,\n };\n\n if (!_.has(allowedActionsUrls, action)) {\n return sendAndLogError(\n req.ctx,\n res,\n 400,\n new Error(`Odin action - ${action}, is not supported`),\n );\n }\n\n const url = allowedActionsUrls[action];\n\n return axios\n .request({\n url: url,\n method: req.method as any,\n headers: {...ctx.getMetadata(), 'accept-encoding': 'gzip'},\n data: req.body,\n timeout: 100000,\n responseType: 'stream',\n })\n .then(async (response) => {\n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qB,GAAG,EAAER,GAAG,EAAEmD,QAAQ,CAAC;kBAAA;oBAAvDC,SAAS,GAAAE,SAAA,CAAAC,IAAA;oBAAA,IACVH,SAAS;sBAAAE,SAAA,CAAAjD,IAAA;sBAAA;oBAAA;oBAAA,MACJ,IAAI4B,KAAK,CAAC/C,8BAA8B,CAAC;kBAAA;kBAAA;oBAAA,OAAAoE,SAAA,CAAAxC,IAAA;gBAAA;cAAA,GAAAoC,QAAA;YAAA,CAEtD;YAAA,iBAAAM,GAAA;cAAA,OAAAP,IAAA,CAAAxD,KAAA,OAAAC,SAAA;YAAA;UAAA,IAAC;QAAA;QAAA;UAAA,OAAAkC,SAAA,CAAAd,IAAA;MAAA;IAAA,GAAAI,QAAA;EAAA,CACT;EAAA,OAAAD,iBAAA,CAAAxB,KAAA,OAAAC,SAAA;AAAA"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["AccessAclTab","ReplicatedTable","ReplicatedTableMeta","Link","File","Table","MapNode","Document","Transaction","TransactionMap","supportedContentTypes","map_node","portal_entrance","portal_exit","cell_node_map","sys_node","access_control_object_namespace_map","access_control_object_namespace","access_control_object","tablet_cell","scheduler_pool_tree_map","scheduler_pool","document","string_node","int64_node","uint64_node","double_node","boolean_node","link","file","table","replicated_table","chaos_replicated_table","replication_log_table","transaction","nested_transaction","topmost_transaction_map","transaction_map","type"],"sources":["getComponentByContentType.ts"],"sourcesContent":["import {AccessAclTab} from '../../../tabs/ACL/ACL';\nimport ReplicatedTable from '../../../../../pages/navigation/content/ReplicatedTable/ReplicatedTable';\nimport ReplicatedTableMeta from '../../../content/ReplicatedTable/ReplicatedTableMeta';\n\nimport Link from '../../../../../pages/navigation/content/Link/Link';\nimport File from '../../../../../pages/navigation/content/File/File';\nimport Table from '../../../../../pages/navigation/content/Table/Table';\nimport MapNode from '../../../../../pages/navigation/content/MapNode/MapNode';\nimport Document from '../../../content/Document/DocumentWithRum';\nimport Transaction from '../../../../../pages/navigation/content/Transaction/Transaction';\nimport TransactionMap from '../../../../../pages/navigation/content/TransactionMap/TransactionMap';\n\nconst supportedContentTypes = {\n map_node: MapNode,\n portal_entrance: MapNode,\n portal_exit: MapNode,\n cell_node_map: MapNode,\n sys_node: MapNode,\n access_control_object_namespace_map: MapNode,\n access_control_object_namespace: MapNode,\n access_control_object: AccessAclTab,\n tablet_cell: MapNode,\n scheduler_pool_tree_map: MapNode,\n scheduler_pool: MapNode,\n document: Document,\n string_node: Document,\n int64_node: Document,\n uint64_node: Document,\n double_node: Document,\n boolean_node: Document,\n link: Link,\n file: File,\n table: Table,\n replicated_table: ReplicatedTable,\n chaos_replicated_table: ReplicatedTable,\n replication_log_table: ReplicatedTableMeta,\n transaction: Transaction,\n nested_transaction: Transaction,\n topmost_transaction_map: TransactionMap,\n transaction_map: TransactionMap,\n};\n\nexport default (type: string) => supportedContentTypes[type as keyof typeof supportedContentTypes];\n"],"mappings":"AAAA,SAAQA,YAAY,QAAO,uBAAuB;AAClD,OAAOC,eAAe,MAAM,yEAAyE;AACrG,OAAOC,mBAAmB,MAAM,sDAAsD;AAEtF,OAAOC,IAAI,MAAM,mDAAmD;AACpE,OAAOC,IAAI,MAAM,mDAAmD;AACpE,OAAOC,KAAK,MAAM,qDAAqD;AACvE,OAAOC,OAAO,MAAM,yDAAyD;AAC7E,OAAOC,QAAQ,MAAM,2CAA2C;AAChE,OAAOC,WAAW,MAAM,iEAAiE;AACzF,OAAOC,cAAc,MAAM,uEAAuE;AAElG,IAAMC,qBAAqB,GAAG;EAC1BC,QAAQ,EAAEL,OAAO;EACjBM,eAAe,EAAEN,OAAO;EACxBO,WAAW,EAAEP,OAAO;EACpBQ,
|
1
|
+
{"version":3,"names":["AccessAclTab","ReplicatedTable","ReplicatedTableMeta","Link","File","Table","MapNode","Document","Transaction","TransactionMap","supportedContentTypes","map_node","portal_entrance","portal_exit","rootstock","scion","cell_node_map","sys_node","access_control_object_namespace_map","access_control_object_namespace","access_control_object","tablet_cell","scheduler_pool_tree_map","scheduler_pool","document","string_node","int64_node","uint64_node","double_node","boolean_node","link","file","table","replicated_table","chaos_replicated_table","replication_log_table","transaction","nested_transaction","topmost_transaction_map","transaction_map","type"],"sources":["getComponentByContentType.ts"],"sourcesContent":["import {AccessAclTab} from '../../../tabs/ACL/ACL';\nimport ReplicatedTable from '../../../../../pages/navigation/content/ReplicatedTable/ReplicatedTable';\nimport ReplicatedTableMeta from '../../../content/ReplicatedTable/ReplicatedTableMeta';\n\nimport Link from '../../../../../pages/navigation/content/Link/Link';\nimport File from '../../../../../pages/navigation/content/File/File';\nimport Table from '../../../../../pages/navigation/content/Table/Table';\nimport MapNode from '../../../../../pages/navigation/content/MapNode/MapNode';\nimport Document from '../../../content/Document/DocumentWithRum';\nimport Transaction from '../../../../../pages/navigation/content/Transaction/Transaction';\nimport TransactionMap from '../../../../../pages/navigation/content/TransactionMap/TransactionMap';\n\nconst supportedContentTypes = {\n map_node: MapNode,\n portal_entrance: MapNode,\n portal_exit: MapNode,\n rootstock: MapNode,\n scion: MapNode,\n cell_node_map: MapNode,\n sys_node: MapNode,\n access_control_object_namespace_map: MapNode,\n access_control_object_namespace: MapNode,\n access_control_object: AccessAclTab,\n tablet_cell: MapNode,\n scheduler_pool_tree_map: MapNode,\n scheduler_pool: MapNode,\n document: Document,\n string_node: Document,\n int64_node: Document,\n uint64_node: Document,\n double_node: Document,\n boolean_node: Document,\n link: Link,\n file: File,\n table: Table,\n replicated_table: ReplicatedTable,\n chaos_replicated_table: ReplicatedTable,\n replication_log_table: ReplicatedTableMeta,\n transaction: Transaction,\n nested_transaction: Transaction,\n topmost_transaction_map: TransactionMap,\n transaction_map: TransactionMap,\n};\n\nexport default (type: string) => supportedContentTypes[type as keyof typeof supportedContentTypes];\n"],"mappings":"AAAA,SAAQA,YAAY,QAAO,uBAAuB;AAClD,OAAOC,eAAe,MAAM,yEAAyE;AACrG,OAAOC,mBAAmB,MAAM,sDAAsD;AAEtF,OAAOC,IAAI,MAAM,mDAAmD;AACpE,OAAOC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