Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrations as replicas refactor #814

Merged
merged 41 commits into from
Dec 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
c5f368c
Add naive copy of Migration components as Deployments.
aznashwan Apr 11, 2024
2e64d2c
Hook 'Deployments' tab into sidebar.
aznashwan Apr 11, 2024
026b635
Update Replicas list page for Deployments.
aznashwan Apr 12, 2024
e898735
Update Replicas details page for Deployments.
aznashwan Apr 12, 2024
1ba8b1c
Update Replicas details page for Replica scenarios.
aznashwan Apr 12, 2024
350b8c2
Add appropriate scenario icon to Replicas/Deployments List pages.
aznashwan Apr 12, 2024
48d1fc8
Make Replica/Deployment Details content header pill scenario-appropri…
aznashwan Apr 12, 2024
bab869d
Make DeploymentDetails content header pill text scenario-appropriate.
aznashwan Apr 12, 2024
d5a6d43
Make DeploymentDetails header icon replica-scenario-appropriate.
aznashwan Apr 12, 2024
24710e5
testing
aznashwan Apr 12, 2024
0354753
Fix DeploymentDetails page.
aznashwan Apr 18, 2024
0bb010e
Debug RHEV Migration Recreation options issues.
aznashwan Apr 19, 2024
41dddf3
MainMultiFilterList skeleton.
aznashwan May 29, 2024
b59d3f5
Update licensing panel nomenclature.
aznashwan May 30, 2024
593f690
Completely disable migrations view/routes.
aznashwan May 30, 2024
ed58c04
Patch API source for scenario field passed form Wizard.
aznashwan May 30, 2024
2c3daf2
Make wizard display Execute Now options for Live Migrations too.
aznashwan May 30, 2024
518367a
Update Dashboard widgets with Deployments.
aznashwan Jun 3, 2024
95d70e5
Update Enpoint Details transfer list.
aznashwan Jun 4, 2024
2c3481d
Update Minion Pool Details page transfer list.
aznashwan Jun 4, 2024
e29f0bb
Fix dashboard transfer creation button text.
aznashwan Jun 4, 2024
1bbeda1
Update Dashboard widgets with Deployments.
aznashwan Jun 3, 2024
77668fb
Update Transfer Wizard operation descriptions.
aznashwan Jun 4, 2024
591caa0
Update all '/replicas' paths to '/transfers'.
aznashwan Jun 4, 2024
b199e61
Update nomeclature in Schedules page from Replicas to Transfers.
aznashwan Jun 4, 2024
85b2115
Update notifications dropdown for new nomenclature.
aznashwan Jun 4, 2024
b1b591e
Update EndpointsPage with Live Migration scenario actions
Dany9966 Aug 19, 2024
9243104
Fix Dashboard Recent Activity entries
Dany9966 Aug 20, 2024
899e54e
Fix some Transfer labels
Dany9966 Aug 21, 2024
4b08468
Fix empty Deployments list page
Dany9966 Aug 21, 2024
f9e9928
Update Replica Delete modal
Dany9966 Aug 21, 2024
fdd3356
Fix Transfers sidebar mini icon not being displayed
Dany9966 Oct 9, 2024
ea40652
Fix deployment's transfer link
Dany9966 Oct 16, 2024
91e11fb
Fix diagnostics deployments download URL
Dany9966 Oct 16, 2024
1ed8bcd
Fix minion pool usage href
Dany9966 Oct 16, 2024
cbd19b0
Revert to referring to reserved licences as "Used"
Dany9966 Oct 22, 2024
b9bbf88
Remove `Replica` nomenclature from Transfer Edit window
Dany9966 Oct 22, 2024
f4415c0
Fix execution erorr handling
Dany9966 Oct 24, 2024
3d94d5c
Fully Refactor transfer/deployment nomenclature
Dany9966 Nov 22, 2024
9d680df
Adds descritpion for `shutdown_instances` option and updates some oth…
Dany9966 Dec 4, 2024
310da86
Remove unused modules
Dany9966 Dec 4, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ const conf: Config = {
],

// The number of items per page applicable to main lists:
// replicas, migrations, endpoints, users etc.
// transfers, deployments, endpoints, users etc.
mainListItemsPerPage: 20,

maxMinionPoolEventsPerPage: 50,
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/dashboard/dashboard.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ describe("Dashboard", () => {

cy.get("*[class^='DashboardLicence__ChartHeaderCurrent']").should(
"contain.text",
`${applianceStatus.appliance_licence_status.current_performed_replicas} Used Replica ${applianceStatus.appliance_licence_status.current_performed_migrations} Used Migrations`
`${applianceStatus.appliance_licence_status.current_performed_replicas} Fulfilled Replica ${applianceStatus.appliance_licence_status.current_performed_migrations} Fulfilled Migrations`
);
});

Expand Down
1 change: 0 additions & 1 deletion jest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ export default {
// An array of glob patterns indicating a set of files for which coverage information should be collected
collectCoverageFrom: [
"**/*.tsx", // Include all .tsx files
"!**/AssessmentModule/**", // Exclude files within the AssessmentModule directory (this is a module that is not used in the app)
"!**/story.tsx", // Exclude all storybook files
"!**/test.tsx", // Exclude old test files
"!**/plugins/**", // Exclude files within the plugins directory
Expand Down
78 changes: 0 additions & 78 deletions src/@types/Assessment.ts

This file was deleted.

8 changes: 4 additions & 4 deletions src/@types/Execution.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ export type Execution = {
updated_at: string;
deleted_at?: string;
type:
| "replica_execution"
| "replica_disks_delete"
| "replica_deploy"
| "replica_update";
| "transfer_execution"
| "transfer_disks_delete"
| "transfer_deploy"
| "transfer_update";
};

export type ExecutionTasks = Execution & {
Expand Down
26 changes: 14 additions & 12 deletions src/@types/MainItem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ type BaseItem = {
destination_environment: { [prop: string]: any };
source_environment: { [prop: string]: any };
transfer_result: { [prop: string]: Instance } | null;
replication_count?: number;
// replication_count?: number;
storage_mappings?: StorageMapping | null;
network_map?: TransferNetworkMap;
last_execution_status: string;
Expand All @@ -92,8 +92,9 @@ type BaseItem = {
user_scripts?: UserScriptData;
};

export type ReplicaItem = BaseItem & {
type: "replica";
export type TransferItem = BaseItem & {
type: "transfer";
scenario: string;
};

export type UserScriptData = {
Expand All @@ -106,29 +107,30 @@ export type UserScriptData = {
};
};

export type MigrationItem = BaseItem & {
type: "migration";
replica_id?: string;
export type DeploymentItem = BaseItem & {
type: "deployment";
transfer_id: string;
transfer_scenario: string;
};

export type MigrationItemOptions = MigrationItem & {
export type DeploymentItemOptions = DeploymentItem & {
skip_os_morphing: boolean;
shutdown_instances: boolean;
};

export type TransferItem = ReplicaItem | MigrationItem;
export type ActionItem = TransferItem | DeploymentItem;

export type ReplicaItemDetails = ReplicaItem & {
export type TransferItemDetails = TransferItem & {
executions: Execution[];
};

export type MigrationItemDetails = MigrationItem & {
export type DeploymentItemDetails = DeploymentItem & {
tasks: Task[];
};

export type TransferItemDetails = ReplicaItemDetails | MigrationItemDetails;
export type ActionItemDetails = TransferItemDetails | DeploymentItemDetails;

export const getTransferItemTitle = (item: TransferItem | null) => {
export const getTransferItemTitle = (item: ActionItem | null) => {
if (!item) {
return null;
}
Expand Down
2 changes: 1 addition & 1 deletion src/@types/Schedule.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,6 @@ export type Schedule = {
};

export type ScheduleBulkItem = {
replicaId: string;
transferId: string;
schedules: Schedule[];
};
31 changes: 10 additions & 21 deletions src/components/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,14 @@ import { observe } from "mobx";
import Fonts from "@src/components/ui/Fonts";
import NotificationsModule from "@src/components/modules/NotificationsModule";
import LoginPage from "@src/components/smart/LoginPage";
import ReplicasPage from "@src/components/smart/ReplicasPage";
import TransfersPage from "@src/components/smart/TransfersPage/TransfersPage";
import MessagePage from "@src/components/smart/MessagePage";
import ReplicaDetailsPage from "@src/components/smart/ReplicaDetailsPage";
import MigrationsPage from "@src/components/smart/MigrationsPage";
import MigrationDetailsPage from "@src/components/smart/MigrationDetailsPage";
import TransferDetailsPage from "@src/components/smart/TransferDetailsPage/TransferDetailsPage";
import DeploymentsPage from "@src/components/smart/DeploymentsPage";
import DeploymentDetailsPage from "@src/components/smart/DeploymentDetailsPage";
import MetalHubServersPage from "@src/components/smart/MetalHubServersPage";
import EndpointsPage from "@src/components/smart/EndpointsPage";
import EndpointDetailsPage from "@src/components/smart/EndpointDetailsPage";
import AssessmentsPage from "@src/components/smart/AssessmentsPage";
import AssessmentDetailsPage from "@src/components/smart/AssessmentDetailsPage";
import UsersPage from "@src/components/smart/UsersPage";
import UserDetailsPage from "@src/components/smart/UserDetailsPage";
import ProjectsPage from "@src/components/smart/ProjectsPage";
Expand Down Expand Up @@ -211,12 +209,12 @@ class App extends React.Component<Record<string, unknown>, State> {
<Route path="/login" component={LoginPage} />
}
{renderRoute("/dashboard", DashboardPage)}
{renderRoute("/replicas", ReplicasPage, true)}
{renderRoute("/replicas/:id", ReplicaDetailsPage, true)}
{renderRoute("/replicas/:id/:page", ReplicaDetailsPage)}
{renderRoute("/migrations", MigrationsPage, true)}
{renderRoute("/migrations/:id", MigrationDetailsPage, true)}
{renderRoute("/migrations/:id/:page", MigrationDetailsPage)}
{renderRoute("/transfers", TransfersPage, true)}
{renderRoute("/transfers/:id", TransferDetailsPage, true)}
{renderRoute("/transfers/:id/:page", TransferDetailsPage)}
{renderRoute("/deployments", DeploymentsPage, true)}
{renderRoute("/deployments/:id", DeploymentDetailsPage, true)}
{renderRoute("/deployments/:id/:page", DeploymentDetailsPage)}
{renderRoute("/endpoints", EndpointsPage, true)}
{renderRoute("/endpoints/:id", EndpointDetailsPage)}
{renderRoute("/minion-pools", MinionPoolsPage, true)}
Expand All @@ -225,15 +223,6 @@ class App extends React.Component<Record<string, unknown>, State> {
{renderRoute("/bare-metal-servers", MetalHubServersPage, true)}
{renderRoute("/bare-metal-servers/:id", MetalHubServerDetailsPage)}
{renderRoute("/wizard/:type", WizardPage)}
{renderOptionalRoute({
name: "planning",
component: AssessmentsPage,
})}
{renderOptionalRoute({
name: "planning",
component: AssessmentDetailsPage,
path: "/assessment/:info",
})}
{renderOptionalRoute({
name: "users",
component: UsersPage,
Expand Down

This file was deleted.

Loading
Loading