From 6734f0ab741db9fa9583d31ccc78eaabb4534a15 Mon Sep 17 00:00:00 2001 From: Chaim Lev-Ari Date: Tue, 27 Apr 2021 11:12:34 +0300 Subject: [PATCH] feat(k8s): replace resource pool with name space --- .../applicationsDatatable.html | 2 +- .../applicationsStacksDatatable.html | 2 +- .../configurationsDatatable.html | 2 +- .../nodeApplicationsDatatable.html | 2 +- .../resourcePoolsDatatable.html | 4 ++-- .../volumes-datatable/volumesDatatable.html | 2 +- .../kubernetesSidebarContent.html | 2 +- .../views/applications/console/console.html | 2 +- .../create/createApplication.html | 22 +++++++++---------- .../views/applications/edit/application.html | 4 ++-- .../views/applications/logs/logs.html | 2 +- .../create/createConfiguration.html | 10 ++++----- .../configurations/edit/configuration.html | 4 ++-- app/kubernetes/views/dashboard/dashboard.html | 2 +- app/kubernetes/views/deploy/deploy.html | 2 +- .../views/deploy/deployController.js | 2 +- .../access/resourcePoolAccess.html | 6 ++--- .../access/resourcePoolAccessController.js | 2 +- .../create/createResourcePool.html | 20 ++++++++--------- .../create/createResourcePoolController.js | 10 ++++----- .../resource-pools/edit/resourcePool.html | 22 +++++++++---------- .../edit/resourcePoolController.js | 10 ++++----- .../views/resource-pools/resourcePools.html | 4 ++-- .../resource-pools/resourcePoolsController.js | 8 +++---- app/kubernetes/views/stacks/logs/logs.html | 2 +- app/kubernetes/views/volumes/edit/volume.html | 4 ++-- .../views/volumes/volumesController.js | 2 +- 27 files changed, 78 insertions(+), 78 deletions(-) diff --git a/app/kubernetes/components/datatables/applications-datatable/applicationsDatatable.html b/app/kubernetes/components/datatables/applications-datatable/applicationsDatatable.html index e90ef8362..447ba3408 100644 --- a/app/kubernetes/components/datatables/applications-datatable/applicationsDatatable.html +++ b/app/kubernetes/components/datatables/applications-datatable/applicationsDatatable.html @@ -94,7 +94,7 @@ - Resource pool + Namespace diff --git a/app/kubernetes/components/datatables/applications-stacks-datatable/applicationsStacksDatatable.html b/app/kubernetes/components/datatables/applications-stacks-datatable/applicationsStacksDatatable.html index af6192325..d49c972c8 100644 --- a/app/kubernetes/components/datatables/applications-stacks-datatable/applicationsStacksDatatable.html +++ b/app/kubernetes/components/datatables/applications-stacks-datatable/applicationsStacksDatatable.html @@ -89,7 +89,7 @@ - Resource pool + Namespace diff --git a/app/kubernetes/components/datatables/configurations-datatable/configurationsDatatable.html b/app/kubernetes/components/datatables/configurations-datatable/configurationsDatatable.html index daedca169..4050525dd 100644 --- a/app/kubernetes/components/datatables/configurations-datatable/configurationsDatatable.html +++ b/app/kubernetes/components/datatables/configurations-datatable/configurationsDatatable.html @@ -87,7 +87,7 @@ - Resource Pool + Namespace diff --git a/app/kubernetes/components/datatables/node-applications-datatable/nodeApplicationsDatatable.html b/app/kubernetes/components/datatables/node-applications-datatable/nodeApplicationsDatatable.html index f6f2e66ea..98a30b6a2 100644 --- a/app/kubernetes/components/datatables/node-applications-datatable/nodeApplicationsDatatable.html +++ b/app/kubernetes/components/datatables/node-applications-datatable/nodeApplicationsDatatable.html @@ -77,7 +77,7 @@ - Resource pool + Namespace diff --git a/app/kubernetes/components/datatables/resource-pools-datatable/resourcePoolsDatatable.html b/app/kubernetes/components/datatables/resource-pools-datatable/resourcePoolsDatatable.html index 30ccd126f..602fd779c 100644 --- a/app/kubernetes/components/datatables/resource-pools-datatable/resourcePoolsDatatable.html +++ b/app/kubernetes/components/datatables/resource-pools-datatable/resourcePoolsDatatable.html @@ -55,7 +55,7 @@ Remove

An application with the same name already exists inside the selected resource pool.

An application with the same name already exists inside the selected namespace.

@@ -84,11 +84,11 @@
- Resource pool + Namespace
- +
- +
- This resource pool has exhausted its resource capacity and you will not be able to deploy the configuration. Contact your administrator to expand the capacity of - the resource pool. + This namespace has exhausted its resource capacity and you will not be able to deploy the configuration. Contact your administrator to expand the capacity of the + namespace.
diff --git a/app/kubernetes/views/configurations/edit/configuration.html b/app/kubernetes/views/configurations/edit/configuration.html index f574802b8..d278a663f 100644 --- a/app/kubernetes/views/configurations/edit/configuration.html +++ b/app/kubernetes/views/configurations/edit/configuration.html @@ -1,5 +1,5 @@ - Resource pools > + Namespaces > {{ ctrl.configuration.Namespace }} > Configurations > {{ ctrl.configuration.Name }} @@ -24,7 +24,7 @@ - Resource Pool + Namespace {{ ctrl.configuration.Namespace }} system diff --git a/app/kubernetes/views/dashboard/dashboard.html b/app/kubernetes/views/dashboard/dashboard.html index 7c007788f..d96ad6a43 100644 --- a/app/kubernetes/views/dashboard/dashboard.html +++ b/app/kubernetes/views/dashboard/dashboard.html @@ -42,7 +42,7 @@
{{ ctrl.pools.length }}
-
{{ ctrl.pools.length === 1 ? 'Resource pool' : 'Resource pools' }}
+
{{ ctrl.pools.length === 1 ? 'Namespace' : 'Namespaces' }}
diff --git a/app/kubernetes/views/deploy/deploy.html b/app/kubernetes/views/deploy/deploy.html index ceed8c17e..fb3844cc4 100644 --- a/app/kubernetes/views/deploy/deploy.html +++ b/app/kubernetes/views/deploy/deploy.html @@ -17,7 +17,7 @@
- +
diff --git a/app/kubernetes/views/deploy/deployController.js b/app/kubernetes/views/deploy/deployController.js index b2695399e..67564909b 100644 --- a/app/kubernetes/views/deploy/deployController.js +++ b/app/kubernetes/views/deploy/deployController.js @@ -79,7 +79,7 @@ class KubernetesDeployController { this.namespaces = namespaces; this.formValues.Namespace = this.namespaces[0].Name; } catch (err) { - this.Notifications.error('Failure', err, 'Unable to load resource pools data'); + this.Notifications.error('Failure', err, 'Unable to load namespaces data'); } } diff --git a/app/kubernetes/views/resource-pools/access/resourcePoolAccess.html b/app/kubernetes/views/resource-pools/access/resourcePoolAccess.html index 6b6b0f862..7a34c74c0 100644 --- a/app/kubernetes/views/resource-pools/access/resourcePoolAccess.html +++ b/app/kubernetes/views/resource-pools/access/resourcePoolAccess.html @@ -1,5 +1,5 @@ - - Resource pools > + + Namespaces > {{ ctrl.pool.Namespace.Name }} > Access management @@ -9,7 +9,7 @@
- + diff --git a/app/kubernetes/views/resource-pools/access/resourcePoolAccessController.js b/app/kubernetes/views/resource-pools/access/resourcePoolAccessController.js index aef2a497d..daed229d5 100644 --- a/app/kubernetes/views/resource-pools/access/resourcePoolAccessController.js +++ b/app/kubernetes/views/resource-pools/access/resourcePoolAccessController.js @@ -78,7 +78,7 @@ class KubernetesResourcePoolAccessController { } this.availableUsersAndTeams = _.without(endpointAccesses.authorizedUsersAndTeams, ...this.authorizedUsersAndTeams); } catch (err) { - this.Notifications.error('Failure', err, 'Unable to retrieve resource pool information'); + this.Notifications.error('Failure', err, 'Unable to retrieve namespace information'); } finally { this.state.viewReady = true; } diff --git a/app/kubernetes/views/resource-pools/create/createResourcePool.html b/app/kubernetes/views/resource-pools/create/createResourcePool.html index 95d7bb94e..81189f5a3 100644 --- a/app/kubernetes/views/resource-pools/create/createResourcePool.html +++ b/app/kubernetes/views/resource-pools/create/createResourcePool.html @@ -1,5 +1,5 @@ - - Resource pools > Create a resource pool + + Namespaces > Create a namespace @@ -36,7 +36,7 @@ with an alphanumeric character.

-

A resource pool with the same name already exists.

+

A namespace with the same name already exists.

@@ -50,7 +50,7 @@

- A resource pool segments the underyling physical Kubernetes cluster into smaller virtual clusters. You should assign a capped limit of resources to this pool or + A namespace segments the underyling physical Kubernetes cluster into smaller virtual clusters. You should assign a capped limit of resources to this pool or disable for the safe operation of your platform.

@@ -137,8 +137,8 @@
- You can set a quota on the amount of external load balancers that can be created inside this resource pool. Set this quota to 0 to effectively disable the use of - load balancers in this resource pool. + You can set a quota on the amount of external load balancers that can be created inside this namespace. Set this quota to 0 to effectively disable the use of load + balancers in this namespace.
@@ -164,7 +164,7 @@ Quotas can be set on each storage option to prevent users from exceeding a specific threshold when deploying applications. You can set a quota to 0 to effectively - prevent the usage of a specific storage option inside this resource pool. + prevent the usage of a specific storage option inside this namespace.
@@ -195,7 +195,7 @@
The ingress feature must be enabled in the endpoint configuration view to be able to register ingresses inside this - resource pool. + namespace.
@@ -230,7 +230,7 @@ Hostnames @@ -351,7 +351,7 @@ ng-click="ctrl.createResourcePool()" button-spinner="ctrl.state.actionInProgress" > - Create resource pool + Create namespace Creation in progress... diff --git a/app/kubernetes/views/resource-pools/create/createResourcePoolController.js b/app/kubernetes/views/resource-pools/create/createResourcePoolController.js index 4a823dcd2..41e36bdbf 100644 --- a/app/kubernetes/views/resource-pools/create/createResourcePoolController.js +++ b/app/kubernetes/views/resource-pools/create/createResourcePoolController.js @@ -115,7 +115,7 @@ class KubernetesCreateResourcePoolController { } } - /* #region CREATE RESOURCE POOL */ + /* #region CREATE NAMESPACE */ async createResourcePoolAsync() { this.state.actionInProgress = true; try { @@ -123,10 +123,10 @@ class KubernetesCreateResourcePoolController { const owner = this.Authentication.getUserDetails().username; this.formValues.Owner = owner; await this.KubernetesResourcePoolService.create(this.formValues); - this.Notifications.success('Resource pool successfully created', this.formValues.Name); + this.Notifications.success('Namespace successfully created', this.formValues.Name); this.$state.go('kubernetes.resourcePools'); } catch (err) { - this.Notifications.error('Failure', err, 'Unable to create resource pool'); + this.Notifications.error('Failure', err, 'Unable to create namespace'); } finally { this.state.actionInProgress = false; } @@ -151,12 +151,12 @@ class KubernetesCreateResourcePoolController { } /* #endregion */ - /* #region GET RESOURCE POOLS */ + /* #region GET NAMESPACES */ async getResourcePoolsAsync() { try { this.resourcePools = await this.KubernetesResourcePoolService.get(); } catch (err) { - this.Notifications.error('Failure', err, 'Unable to retrieve resource pools'); + this.Notifications.error('Failure', err, 'Unable to retrieve namespaces'); } } diff --git a/app/kubernetes/views/resource-pools/edit/resourcePool.html b/app/kubernetes/views/resource-pools/edit/resourcePool.html index ec1337013..1dc64330f 100644 --- a/app/kubernetes/views/resource-pools/edit/resourcePool.html +++ b/app/kubernetes/views/resource-pools/edit/resourcePool.html @@ -1,5 +1,5 @@ - - Resource pools > {{ ctrl.pool.Namespace.Name }} + + Namespaces > {{ ctrl.pool.Namespace.Name }} @@ -11,7 +11,7 @@ - Resource pool + Namespace
@@ -39,7 +39,7 @@
- You can set a quota on the amount of external load balancers that can be created inside this resource pool. Set this quota to 0 to effectively disable the use - of load balancers in this resource pool. + You can set a quota on the amount of external load balancers that can be created inside this namespace. Set this quota to 0 to effectively disable the use of + load balancers in this namespace.
@@ -154,7 +154,7 @@
The ingress feature must be enabled in the endpoint configuration view to be able to register ingresses inside - this resource pool. + this namespace.
@@ -189,7 +189,7 @@ Hostnames @@ -307,7 +307,7 @@ Quotas can be set on each storage option to prevent users from exceeding a specific threshold when deploying applications. You can set a quota to 0 to - effectively prevent the usage of a specific storage option inside this resource pool. + effectively prevent the usage of a specific storage option inside this namespace.
@@ -342,7 +342,7 @@ ng-click="ctrl.updateResourcePool()" button-spinner="ctrl.state.actionInProgress" > - Update resource pool + Update namespace Update in progress...
@@ -389,7 +389,7 @@ order-by="Name" refresh-callback="ctrl.getApplications" loading="ctrl.state.applicationsLoading" - title-text="Applications running in this resource pool" + title-text="Applications running in this namespace" title-icon="fa-laptop-code" > diff --git a/app/kubernetes/views/resource-pools/edit/resourcePoolController.js b/app/kubernetes/views/resource-pools/edit/resourcePoolController.js index 051dc1fc9..ee12da091 100644 --- a/app/kubernetes/views/resource-pools/edit/resourcePoolController.js +++ b/app/kubernetes/views/resource-pools/edit/resourcePoolController.js @@ -179,16 +179,16 @@ class KubernetesResourcePoolController { return false; } - /* #region UPDATE RESOURCE POOL */ + /* #region UPDATE NAMESPACE */ async updateResourcePoolAsync() { this.state.actionInProgress = true; try { this.checkDefaults(); await this.KubernetesResourcePoolService.patch(this.savedFormValues, this.formValues); - this.Notifications.success('Resource pool successfully updated', this.pool.Namespace.Name); + this.Notifications.success('Namespace successfully updated', this.pool.Namespace.Name); this.$state.reload(); } catch (err) { - this.Notifications.error('Failure', err, 'Unable to create resource pool'); + this.Notifications.error('Failure', err, 'Unable to create namespace'); } finally { this.state.actionInProgress = false; } @@ -204,7 +204,7 @@ class KubernetesResourcePoolController { if (warnings.quota || warnings.ingress) { const messages = { quota: - 'Reducing the quota assigned to an "in-use" resource pool may have unintended consequences, including preventing running applications from functioning correctly and potentially even blocking them from running at all.', + 'Reducing the quota assigned to an "in-use" namespace may have unintended consequences, including preventing running applications from functioning correctly and potentially even blocking them from running at all.', ingress: 'Deactivating ingresses may cause applications to be unaccessible. All ingress configurations from affected applications will be removed.', }; const displayedMessage = `${warnings.quota ? messages.quota : ''}${warnings.quota && warnings.ingress ? '

' : ''} @@ -232,7 +232,7 @@ class KubernetesResourcePoolController { this.events = await this.KubernetesEventService.get(this.pool.Namespace.Name); this.state.eventWarningCount = KubernetesEventHelper.warningCount(this.events); } catch (err) { - this.Notifications.error('Failure', err, 'Unable to retrieve resource pool related events'); + this.Notifications.error('Failure', err, 'Unable to retrieve namespace related events'); } finally { this.state.eventsLoading = false; } diff --git a/app/kubernetes/views/resource-pools/resourcePools.html b/app/kubernetes/views/resource-pools/resourcePools.html index 1c6dce94d..c1ec578e4 100644 --- a/app/kubernetes/views/resource-pools/resourcePools.html +++ b/app/kubernetes/views/resource-pools/resourcePools.html @@ -1,5 +1,5 @@ - - Resource pools + + Namespaces diff --git a/app/kubernetes/views/resource-pools/resourcePoolsController.js b/app/kubernetes/views/resource-pools/resourcePoolsController.js index 0f3de973a..2ff466800 100644 --- a/app/kubernetes/views/resource-pools/resourcePoolsController.js +++ b/app/kubernetes/views/resource-pools/resourcePoolsController.js @@ -21,11 +21,11 @@ class KubernetesResourcePoolsController { for (const pool of selectedItems) { try { await this.KubernetesResourcePoolService.delete(pool); - this.Notifications.success('Resource pool successfully removed', pool.Namespace.Name); + this.Notifications.success('Namespace successfully removed', pool.Namespace.Name); const index = this.resourcePools.indexOf(pool); this.resourcePools.splice(index, 1); } catch (err) { - this.Notifications.error('Failure', err, 'Unable to remove resource pool'); + this.Notifications.error('Failure', err, 'Unable to remove namespace'); } finally { --actionCount; if (actionCount === 0) { @@ -37,7 +37,7 @@ class KubernetesResourcePoolsController { removeAction(selectedItems) { this.ModalService.confirmDeletion( - 'Do you want to remove the selected resource pool(s)? All the resources associated to the selected resource pool(s) will be removed too.', + 'Do you want to remove the selected namespace(s)? All the resources associated to the selected namespace(s) will be removed too.', (confirmed) => { if (confirmed) { return this.$async(this.removeActionAsync, selectedItems); @@ -50,7 +50,7 @@ class KubernetesResourcePoolsController { try { this.resourcePools = await this.KubernetesResourcePoolService.get(); } catch (err) { - this.Notifications.error('Failure', err, 'Unable to retreive resource pools'); + this.Notifications.error('Failure', err, 'Unable to retreive namespaces'); } } diff --git a/app/kubernetes/views/stacks/logs/logs.html b/app/kubernetes/views/stacks/logs/logs.html index 0717a63d6..7c3aa81a0 100644 --- a/app/kubernetes/views/stacks/logs/logs.html +++ b/app/kubernetes/views/stacks/logs/logs.html @@ -1,5 +1,5 @@ - Resource pools + Namespaces > {{ ctrl.state.transition.namespace }} > Applications > Stacks > {{ ctrl.state.transition.name }} > Logs diff --git a/app/kubernetes/views/volumes/edit/volume.html b/app/kubernetes/views/volumes/edit/volume.html index da4040d98..2753a8291 100644 --- a/app/kubernetes/views/volumes/edit/volume.html +++ b/app/kubernetes/views/volumes/edit/volume.html @@ -1,5 +1,5 @@ - Resource pools > + Namespaces > {{ ctrl.volume.ResourcePool.Namespace.Name }} > Volumes > {{ ctrl.volume.PersistentVolumeClaim.Name }} @@ -27,7 +27,7 @@
- +
Resource poolNamespace {{ ctrl.volume.ResourcePool.Namespace.Name }} system diff --git a/app/kubernetes/views/volumes/volumesController.js b/app/kubernetes/views/volumes/volumesController.js index 252df28cd..0c55f2db2 100644 --- a/app/kubernetes/views/volumes/volumesController.js +++ b/app/kubernetes/views/volumes/volumesController.js @@ -98,7 +98,7 @@ class KubernetesVolumesController { }); this.storages = buildStorages(storages, volumes); } catch (err) { - this.Notifications.error('Failure', err, 'Unable to retreive resource pools'); + this.Notifications.error('Failure', err, 'Unable to retreive namespaces'); } }