Commit aaff679
committed
Resolves #7406 ([FR-2891](https://lablup.atlassian.net/browse/FR-2891))
## Summary
### Schema
- **`ModelDeploymentMetadata`** gains `resourceGroupName: String!` and `resourceGroup: ResourceGroup` (DataLoader-resolved). Resource group now lives at the deployment level rather than per revision.
- **`ResourceConfigInput.resourceGroup` removed** and **`ModelDeploymentMetadataInput.resourceGroup`** added.
- **`AddRevisionInput`** — `clusterConfig` / `resourceConfig` / `image` / `modelRuntimeConfig` become nullable so preset-driven revisions can submit minimal payloads.
- **`AddRevisionInput.name` / `CreateRevisionInput.name` removed**.
- **`ModelReplica`** gains `status: ReplicaStatus!`, `trafficStatus: TrafficStatus!`, `healthStatus: ReplicaHealthStatus!`; new `ReplicaHealthStatus` enum (`NOT_CHECKED | HEALTHY | UNHEALTHY | DEGRADED`).
- **`ModelMountConfig.subpath`** and **`ExtraVFolderMountInfoGQL.subpath`** added (intentionally not surfaced in UI — deferred to a follow-up).
- **`Query.inferenceRuntimeConfigs` / `inferenceRuntimeConfig`** deprecated; **`ModelRuntimeConfigInput.inferenceRuntimeConfig` removed**. WebUI no longer surfaces these.
### UI — deployment creation / edit
- **`DeploymentSettingModal`** collects the resource group via `BAIProjectResourceGroupSelect`; edit mode renders the current RG as read-only text.
- **`DeploymentAddRevisionModal`** hides the resource group selector (revisions inherit the RG from the deployment via `hideResourceGroupFormItem` on `ResourceAllocationFormItems`). The hidden picker still drives `ResourcePresetSelect` filtering.
- **Preset mode** in `DeploymentAddRevisionModal` calls `addModelRevision(revisionPresetId, modelMountConfig, options.autoActivate)` instead of `deployVfolderV2` — the modal is only opened from an existing deployment, so it must add a revision, not create a new deployment.
- Dead `commitDeploy` / `DeploymentAddRevisionModalDeployMutation` block left over after the FR-2862 preset-mode refactor is removed; `isSubmitting` now collapses to `isAddInFlight`.
### UI — preset detail modal (architecture)
- **`DeploymentPresetDetailModal` switched to `useFragment`** — the modal now accepts `presetFrgmt: DeploymentPresetDetailModalFragment$key | null | undefined` instead of owning its own `useLazyLoadQuery`. The previous shell-vs-body split is collapsed back into a single component because `useFragment(query, null)` tolerates the null input that the close-animation lifecycle produces.
- **List-query callers (`ModelCardDeployModal`, `VFolderDeployModal`)** spread `...DeploymentPresetDetailModalFragment` on the existing `availablePresets` / `deploymentRevisionPresets` edge nodes. No extra fetch — when the user opens the detail view, the matching edge node is handed to the modal as `presetFrgmt`.
- **Paginated-select caller (`DeploymentAddRevisionModal`)** cannot list-spread because `BAIAvailablePresetSelect` paginates independently. A small inner component (`PresetDetailLoader`) fires a singular `deploymentRevisionPreset(id:)` query when invoked and forwards the fragment ref to the modal.
- This is the team-approved pattern per Seungwon's review feedback (Teams thread, FR-2862 follow-up).
### UI — deployment detail
- **Basic Information** now shows Resource Group sourced from `metadata.resourceGroupName`; Name / Deployment ID rows are split for clarity.
- **Deployment list** gains a Deployment ID column.
- **Replicas tab**:
- New **Status** column powered by `ModelReplica.status` (`PROVISIONING / RUNNING / TERMINATING / TERMINATED / FAILED_TO_START`) via `ReplicaStatusTag`. The earlier placeholder is removed.
- **Health Status** column source moved from `livenessStatus` → new `healthStatus` field.
- **Traffic Status** column (renamed from \"Active Pool\") source moved from `activenessStatus` → new `trafficStatus` field; uses `BAITag` with `success`/`default` semantic colors.
- **Replica ID** column is sortable; default sort is `-createdAt` applied at query-build time (no URL key written), following the `ComputeSessionListPage` pattern.
- Filter properties include both `status` and `trafficStatus`.
- `Session` column resolves through `sessionV2` (BA-5838 workaround); `Revision` column opens `DeploymentRevisionDetailDrawer`.
- **`ReplicaStatusTag`** extends its enum to cover `RUNNING` and `FAILED_TO_START` (with localized labels / tooltips across 22 locales).
## Test plan
- [ ] Create a new deployment from `DeploymentSettingModal`; verify the resource group selector is required and `autoSelectDefault` picks the project default.
- [ ] Open `DeploymentSettingModal` in edit mode on an existing deployment; verify the current resource group renders as read-only text.
- [ ] On a deployment detail page, open Add Revision → Custom mode; verify the resource group form item is hidden but \`ResourcePresetSelect\` still filters by the deployment's RG.
- [ ] In Add Revision → Preset mode, pick a preset and submit; verify a new revision is added to the current deployment (not a new deployment) and the modal closes without navigating away.
- [ ] Toggle \`Auto activate\` in both Preset and Custom modes; verify \`AddRevisionOptions.autoActivate\` is forwarded in both branches.
- [ ] Open the preset (i) detail modal from `ModelCardDeployModal`, `VFolderDeployModal`, and `DeploymentAddRevisionModal`; verify each shows the right preset details and closes cleanly without any \"preset not found\" flash during the close animation.
- [ ] In `DeploymentAddRevisionModal` (Preset mode), scroll the preset selector past the first page, select a preset from a later page, then open the detail modal; verify the singular `deploymentRevisionPreset(id:)` query resolves and the detail renders.
- [ ] Open Deployments list; verify the new Deployment ID column renders BAIId with copy affordance.
- [ ] On deployment detail → Replicas tab, verify the three Status / Health Status / Traffic Status columns render real values from the new schema fields.
- [ ] Open the page with no \`?rOrder=\` in the URL; verify replicas are sorted by \`createdAt\` descending and the \`Replica ID\` header has no sort arrow initially.
- [ ] Click \`Created At\` header; verify ascend → descend → none cycle works and is reflected in URL + server query.
- [ ] Click \`Replica ID\` header; verify it sorts and the URL \`?rOrder=\` updates.
- [ ] Apply the \`status\` filter and the new \`trafficStatus\` filter; verify both narrow the table.
- [ ] Open the Revision link in a replica row; verify \`DeploymentRevisionDetailDrawer\` opens with the revision detail.
- [ ] Trigger replicas in \`FAILED_TO_START\` and \`RUNNING\` states; verify \`ReplicaStatusTag\` renders the right color/label/tooltip in en/ko.
[FR-2891]: https://lablup.atlassian.net/browse/FR-2891?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
1 parent 8a298f1 commit aaff679
46 files changed
Lines changed: 2053 additions & 969 deletions
File tree
- data
- packages/backend.ai-ui/src/components
- react/src
- components
- SessionFormItems
- hooks
- pages
- resources/i18n
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
151 | 151 | | |
152 | 152 | | |
153 | 153 | | |
154 | | - | |
155 | | - | |
156 | 154 | | |
157 | 155 | | |
158 | 156 | | |
159 | 157 | | |
160 | 158 | | |
161 | | - | |
162 | | - | |
163 | | - | |
164 | | - | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
165 | 173 | | |
166 | 174 | | |
167 | 175 | | |
| |||
3843 | 3851 | | |
3844 | 3852 | | |
3845 | 3853 | | |
3846 | | - | |
3847 | | - | |
3848 | 3854 | | |
3849 | 3855 | | |
3850 | 3856 | | |
| |||
6772 | 6778 | | |
6773 | 6779 | | |
6774 | 6780 | | |
| 6781 | + | |
| 6782 | + | |
| 6783 | + | |
| 6784 | + | |
| 6785 | + | |
6775 | 6786 | | |
6776 | 6787 | | |
6777 | 6788 | | |
| |||
6780 | 6791 | | |
6781 | 6792 | | |
6782 | 6793 | | |
| 6794 | + | |
| 6795 | + | |
| 6796 | + | |
| 6797 | + | |
| 6798 | + | |
6783 | 6799 | | |
6784 | 6800 | | |
6785 | 6801 | | |
| |||
9350 | 9366 | | |
9351 | 9367 | | |
9352 | 9368 | | |
| 9369 | + | |
| 9370 | + | |
| 9371 | + | |
| 9372 | + | |
| 9373 | + | |
9353 | 9374 | | |
9354 | 9375 | | |
9355 | 9376 | | |
| |||
9370 | 9391 | | |
9371 | 9392 | | |
9372 | 9393 | | |
| 9394 | + | |
9373 | 9395 | | |
9374 | 9396 | | |
9375 | 9397 | | |
| |||
9380 | 9402 | | |
9381 | 9403 | | |
9382 | 9404 | | |
| 9405 | + | |
9383 | 9406 | | |
9384 | 9407 | | |
9385 | 9408 | | |
| |||
9550 | 9573 | | |
9551 | 9574 | | |
9552 | 9575 | | |
| 9576 | + | |
| 9577 | + | |
| 9578 | + | |
| 9579 | + | |
| 9580 | + | |
9553 | 9581 | | |
9554 | 9582 | | |
9555 | 9583 | | |
| |||
9559 | 9587 | | |
9560 | 9588 | | |
9561 | 9589 | | |
| 9590 | + | |
| 9591 | + | |
| 9592 | + | |
| 9593 | + | |
| 9594 | + | |
9562 | 9595 | | |
9563 | 9596 | | |
9564 | 9597 | | |
| |||
9582 | 9615 | | |
9583 | 9616 | | |
9584 | 9617 | | |
| 9618 | + | |
| 9619 | + | |
| 9620 | + | |
| 9621 | + | |
| 9622 | + | |
| 9623 | + | |
| 9624 | + | |
| 9625 | + | |
| 9626 | + | |
| 9627 | + | |
| 9628 | + | |
9585 | 9629 | | |
9586 | 9630 | | |
9587 | 9631 | | |
| |||
9771 | 9815 | | |
9772 | 9816 | | |
9773 | 9817 | | |
9774 | | - | |
9775 | 9818 | | |
9776 | 9819 | | |
9777 | 9820 | | |
| |||
14049 | 14092 | | |
14050 | 14093 | | |
14051 | 14094 | | |
14052 | | - | |
| 14095 | + | |
14053 | 14096 | | |
14054 | 14097 | | |
14055 | | - | |
| 14098 | + | |
14056 | 14099 | | |
14057 | 14100 | | |
14058 | 14101 | | |
| |||
14729 | 14772 | | |
14730 | 14773 | | |
14731 | 14774 | | |
| 14775 | + | |
| 14776 | + | |
| 14777 | + | |
| 14778 | + | |
| 14779 | + | |
| 14780 | + | |
| 14781 | + | |
| 14782 | + | |
| 14783 | + | |
| 14784 | + | |
| 14785 | + | |
| 14786 | + | |
14732 | 14787 | | |
14733 | 14788 | | |
14734 | 14789 | | |
| |||
14893 | 14948 | | |
14894 | 14949 | | |
14895 | 14950 | | |
14896 | | - | |
14897 | | - | |
14898 | 14951 | | |
14899 | 14952 | | |
14900 | 14953 | | |
| |||
14998 | 15051 | | |
14999 | 15052 | | |
15000 | 15053 | | |
15001 | | - | |
15002 | | - | |
15003 | | - | |
15004 | | - | |
15005 | | - | |
15006 | | - | |
15007 | | - | |
15008 | 15054 | | |
15009 | 15055 | | |
15010 | 15056 | | |
| |||
17066 | 17112 | | |
17067 | 17113 | | |
17068 | 17114 | | |
| 17115 | + | |
| 17116 | + | |
| 17117 | + | |
| 17118 | + | |
| 17119 | + | |
17069 | 17120 | | |
17070 | 17121 | | |
17071 | 17122 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
108 | 108 | | |
109 | 109 | | |
110 | 110 | | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | 111 | | |
117 | 112 | | |
118 | 113 | | |
| |||
128 | 123 | | |
129 | 124 | | |
130 | 125 | | |
131 | | - | |
132 | 126 | | |
133 | 127 | | |
134 | 128 | | |
| |||
202 | 196 | | |
203 | 197 | | |
204 | 198 | | |
205 | | - | |
206 | 199 | | |
207 | 200 | | |
208 | 201 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
94 | | - | |
95 | 94 | | |
96 | 95 | | |
97 | 96 | | |
| |||
Lines changed: 10 additions & 48 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | 15 | | |
53 | 16 | | |
54 | 17 | | |
| |||
85 | 48 | | |
86 | 49 | | |
87 | 50 | | |
| 51 | + | |
88 | 52 | | |
89 | 53 | | |
90 | 54 | | |
| |||
145 | 109 | | |
146 | 110 | | |
147 | 111 | | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
154 | | - | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
155 | 117 | | |
156 | | - | |
157 | | - | |
| 118 | + | |
| 119 | + | |
158 | 120 | | |
159 | 121 | | |
160 | 122 | | |
| |||
Lines changed: 17 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| 37 | + | |
37 | 38 | | |
38 | 39 | | |
39 | 40 | | |
| |||
794 | 795 | | |
795 | 796 | | |
796 | 797 | | |
| 798 | + | |
797 | 799 | | |
798 | 800 | | |
799 | 801 | | |
| |||
806 | 808 | | |
807 | 809 | | |
808 | 810 | | |
| 811 | + | |
809 | 812 | | |
810 | 813 | | |
811 | 814 | | |
| |||
817 | 820 | | |
818 | 821 | | |
819 | 822 | | |
820 | | - | |
| 823 | + | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
821 | 828 | | |
822 | 829 | | |
823 | 830 | | |
| |||
828 | 835 | | |
829 | 836 | | |
830 | 837 | | |
831 | | - | |
832 | | - | |
833 | | - | |
834 | | - | |
835 | | - | |
836 | | - | |
837 | | - | |
| 838 | + | |
| 839 | + | |
| 840 | + | |
| 841 | + | |
| 842 | + | |
| 843 | + | |
| 844 | + | |
| 845 | + | |
| 846 | + | |
838 | 847 | | |
839 | 848 | | |
840 | 849 | | |
| |||
0 commit comments