@camunda/ccma-saas-frontend 0.35.10 → 0.35.12
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.
|
@@ -209,10 +209,10 @@ export const C4ManagementApi = ({ clients, loading, showIpWhitelistColumn, showH
|
|
|
209
209
|
// inherit a color that is too dark in dark mode.
|
|
210
210
|
_jsxs(UnorderedList, { style: { color: 'var(--neutral-foreground-strong)' }, children: [_jsxs(ListItem, { style: { minHeight: '30px' }, children: [text.expandedClientSecret, ": ", text.expandedClientSecretNotVisible] }), _jsxs(ListItem, { style: { minHeight: '30px' }, children: [text.expandedApiUrl, ":", ' ', _jsx(CodeSnippet, { type: 'inline', feedback: text.urlCopiedFeedback, children: urls.apiUrl })] }), _jsxs(ListItem, { style: { minHeight: '30px' }, children: [text.expandedOauthUrl, ":", ' ', _jsx(CodeSnippet, { type: 'inline', feedback: text.urlCopiedFeedback, children: urls.oauthUrl })] })] }));
|
|
211
211
|
};
|
|
212
|
-
const component = (_jsxs(Stack, { gap: 3, children: [_jsx(
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
212
|
+
const component = (_jsxs(Stack, { gap: 3, children: [_jsx(C4DataTable, { headers: headerData, data: clients.map((item) => {
|
|
213
|
+
return { ...item, expansion: expandedRow() };
|
|
214
|
+
}), title: text.title, toolbar: toolbar, actions: actions, options: {
|
|
215
|
+
actionsUseOverflowMenuMinItems: 1,
|
|
216
|
+
}, queryPrefix: 'management-api' }), _jsx("p", { className: 'legalText', children: text.description })] }));
|
|
217
217
|
return component;
|
|
218
218
|
};
|
|
@@ -4,9 +4,11 @@ import { C4ActionableNotification } from '../c4-actionable-notification/c4-actio
|
|
|
4
4
|
import { C4DataTable } from '../c4-data-table/c4-data-table.js';
|
|
5
5
|
export const C4ManagementUsers = ({ users, loading, headers, actions, toolbar, banner, }) => {
|
|
6
6
|
const bannerNotification = banner.show ? (_jsx(C4ActionableNotification, { appearance: 'banner', kind: 'info', title: '', subtitle: banner.subtitle, actionButtonLabel: banner.actionButtonLabel, onActionButtonClick: banner.onActionClick, lowContrast: false })) : null;
|
|
7
|
+
// No `overflow-x: auto` wrapper: the DS DataTable scrolls itself, and a
|
|
8
|
+
// scroll container would clip the focus ring of the search field.
|
|
7
9
|
const dataTable = (_jsx(C4DataTable, { headers: headers, data: users, actions: actions, toolbar: toolbar, title: 'Users', isLoading: loading, options: {
|
|
8
10
|
actionsUseOverflowMenuMinItems: 2,
|
|
9
11
|
}, queryPrefix: 'management-users' }));
|
|
10
|
-
const component = (_jsxs(Stack, { gap: 3, children: [bannerNotification,
|
|
12
|
+
const component = (_jsxs(Stack, { gap: 3, children: [bannerNotification, dataTable] }));
|
|
11
13
|
return component;
|
|
12
14
|
};
|
|
@@ -204,6 +204,15 @@ function persistDismissedFailoverUriNotices(ids) {
|
|
|
204
204
|
// localStorage unavailable (private mode / SSR) — dismissal is best-effort.
|
|
205
205
|
}
|
|
206
206
|
}
|
|
207
|
+
// HDP adds an hour of cluster load about 30 minutes after the hour ends, and
|
|
208
|
+
// accounts-ng caches a read for up to an hour, so the newest point of a
|
|
209
|
+
// running cluster can start 3.5 hours before now. The lag below adds half an
|
|
210
|
+
// hour of margin to that. While the newest point is newer than the lag, the
|
|
211
|
+
// hours after it have not arrived yet, so the 24-hour chart pads nothing.
|
|
212
|
+
// When the newest point is older than the lag, the cluster stopped
|
|
213
|
+
// reporting, and the chart pads every hour from that point to now with zero.
|
|
214
|
+
// The per-day chart does the same with one day plus the lag.
|
|
215
|
+
const CLUSTER_LOAD_LAG_MS = 4 * 60 * 60 * 1000;
|
|
207
216
|
export function ensureClusterLoadPerDay(perDay) {
|
|
208
217
|
const DAY = 24 * 60 * 60 * 1000;
|
|
209
218
|
const now = Date.now();
|
|
@@ -225,7 +234,7 @@ export function ensureClusterLoadPerDay(perDay) {
|
|
|
225
234
|
return generated;
|
|
226
235
|
}
|
|
227
236
|
const max = Math.max(...updatedPerDay.map((item) => item.ts));
|
|
228
|
-
if (max < now - DAY) {
|
|
237
|
+
if (max < now - DAY - CLUSTER_LOAD_LAG_MS) {
|
|
229
238
|
const missingDays = Math.floor((now - max) / DAY);
|
|
230
239
|
for (let i = 1; i < missingDays + 1; i += 1) {
|
|
231
240
|
updatedPerDay.push({
|
|
@@ -267,9 +276,11 @@ export function ensureClusterLoad24h(last24h) {
|
|
|
267
276
|
}
|
|
268
277
|
// We have real data (e.g. a cluster younger than 24h only has a handful of
|
|
269
278
|
// hourly buckets) — never discard it. Only backfill the gap between the
|
|
270
|
-
// most recent real point and "now" when that point is
|
|
271
|
-
// still-fresh but incomplete window keeps its
|
|
272
|
-
// spikes) instead of being wiped and replaced
|
|
279
|
+
// most recent real point and "now" when that point is older than
|
|
280
|
+
// `CLUSTER_LOAD_LAG_MS`, so a still-fresh but incomplete window keeps its
|
|
281
|
+
// real values (including any spikes) instead of being wiped and replaced
|
|
282
|
+
// with zeros. Such a window can have fewer than 24 points and end up to
|
|
283
|
+
// 4 hours before now.
|
|
273
284
|
const max24h = Math.max(...updated24h.map((item) => item.ts));
|
|
274
285
|
// The most recent real point is itself very stale (e.g. the cluster was
|
|
275
286
|
// paused and its newest hourly bucket is many hours/days old). Padding
|
|
@@ -289,7 +300,7 @@ export function ensureClusterLoad24h(last24h) {
|
|
|
289
300
|
}
|
|
290
301
|
return sortAscendingByTs(updated24h);
|
|
291
302
|
}
|
|
292
|
-
if (max24h < now -
|
|
303
|
+
if (max24h < now - CLUSTER_LOAD_LAG_MS) {
|
|
293
304
|
const missingHours = Math.floor((now - max24h) / HOUR);
|
|
294
305
|
for (let i = 1; i < missingHours + 1; i += 1) {
|
|
295
306
|
updated24h.push({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@camunda/ccma-saas-frontend",
|
|
3
|
-
"version": "0.35.
|
|
3
|
+
"version": "0.35.12",
|
|
4
4
|
"description": "Camunda Composite Components",
|
|
5
5
|
"bugs": {
|
|
6
6
|
"url": "https://github.com/camunda/camunda-cloud-management-apps/issues"
|
|
@@ -85,8 +85,8 @@
|
|
|
85
85
|
"react-markdown": "^8.0.7 || ^10.0.0"
|
|
86
86
|
},
|
|
87
87
|
"dependencies": {
|
|
88
|
-
"@camunda/ccma-api": "13.0
|
|
89
|
-
"@camunda/ccma-shared-types": "18.
|
|
88
|
+
"@camunda/ccma-api": "13.1.0",
|
|
89
|
+
"@camunda/ccma-shared-types": "18.3.0",
|
|
90
90
|
"@pactsafe/pactsafe-react-sdk": "2.15.0",
|
|
91
91
|
"cron-parser": "5.10.2",
|
|
92
92
|
"mobx": "6.16.1",
|