3. Resource plans

3.1. Introduction

This document aims to explain the Resource plans used in the Exastro Suite.
Resource plans can only be configured by the System administrator (Organizations cannot be accessed by users).

3.2. Resource plan

Resource plans decide the amount of resources usable per organization.
Users can control the resources available by setting multiple resource limits to plans and applying them to organizations.
表 3.8 Resource plan setting example

Organization

Resource plan

Workspace number

User number

Role number

org1

Standard plan

Max 20

Max 30

Max 30

org2

Premium plan

Max 50

Max 100

Max 100

3.2.1. Configuring resource plans

In order to apply resource plans to organizations, the user must first register resource plans.
For more information on how to apply registered resource plans, see Create Organization.

3.2.2. System behaviour

Example) Up until January, use Resource plan with max workspace number = 5. Then from February, use Resource plan with max workspace number = 3.
System behaviour
  1. If a user asks to change the max amount to workspaces to 3, the system administrator will get a warning that the value will exceed the limit from February since the registered data says "Workspace number =4"
  2. Since the registered data says "Workspace number = 4", the user will be able to add workspaces without exceeding the resource plan limit ("Workspace number =5").
  3. Since the registered data says "Workspace number = 5", the user will not be able to add more workspaces since the Maximum Workspace number =5 (an error will occur).
  4. The amount of workspaces will exceed the Maximum workspace number (3), but it will not restrict the user from using the system
  5. Since the registered data says "Workspace number = 5",the user will not be able to add workspaces exceeding the resource plan's Maximum workspace number (3) (an error will occur).
  6. Users can delete workspaces so the registered data changes from "Workspace number = 5" to "Workspace number = 2".
  7. Since the Registered data says "Workspace number = 2", the user can create a new workspace since the resource plan's maximum workspace number is 3.

3.3. Configure Resource plan

3.3.1. Pre-requisites

The workflow in this document uses the following commands. Make sure that they are installed.
  • Operation client required applications

    • curl

    • git

    • jq

注釈

These commands are not required the user is creating resource plans from the webUI.

3.3.2. Preparation

Execute the shell script from the files fetched from the GitHub repository and create an Organization.
The conf file is used by the settings and the fetch shell.
  1. Fetch the Organization creation shell script from the repository using git clone.
    # Acquire Exastro Platform files
    git clone https://github.com/exastro-suite/exastro-platform.git
    
  2. Move the fetched files to the tools folder and change the API execution destination URL within the Organization creation shell script to the System administrator's site address.
    vi api-auth.conf
    
    Changes
    • api-auth.conf

      CONF_BASE_URL={Site address for System admin}
      CURL_OPT=-svk
      

    Tip

    If the user is using a self-signed certificate, a certificate error will occur.
    Changing the CURL_OPT=-sv within the setting file to CURL_OPT=-svk prevents the error from occuring, but it is recommended that the user installs a valid certificate.

注釈

These commands are not required the user is creating resource plans from the webUI.

3.3.3. Resource plan configuration

The steps for register resource plans are as following.

※For more information regarding applying resource plans, see Creating/Editing Organizations.

3.3.4. Confirming current resource plan items

There are 3 methods for confirming resource plan items.
There is no web UI for confirming resource plan items.
When creating resource plans, the items that requires configuration are displayed.

3.3.5. Register resource plan

There are 3 methods for registering resource plans.
From the menu, select Resource plan management.
../../_images/plan_menu.png
This will display the Resource plan list. Press the Create button and register a new resource plan.
../../_images/plan_list_0_v1_9.png
  • Register resource plan
    • Configure json file for the resource plan
      Copy and use the add-plan.sample.json under the fetched tools folder.
    ../../_images/plan_create_v1_9.png
    表 3.9 Item description

    Item name

    Description

    Resource plan ID

    Specify an unique ID for the resource plan.
    This ID is used to link the resource plan to Organizations.

    Resource plan name

    Specify a name for the resource plan.

    Decription

    Write a description for the resource plan.

    Resource plan limit value settings

    Specify limit for the organization resources.
    The maximum and default values for the different items are as following.
    ita.organization.ansible.execution_limit:【Max:1000】【Default:25】
    ita.organization.common.upload_file_size_limit:【Max:107374182400】【Default:104857600】
    platform.roles:【Max:1000】【Default:1000】
    platform.users:【Max:10000】【Default:10000】
    platform.workspaces:【Max:1000】【Default:100】

注釈

ita.organization.ansible.execution_limit

"ita.organization.ansible.execution_limit" is the max amount of Movements that can be executed by IT Automation's Ansible driver at once (per organization).
The max amount of executions that can happen simultaneously per organization depends on the configured settings. Note that the Exastro system also have a limit of how many executions can happen at once, so the absolute max limit will be the max value set to the system settings.
As a result, executing more Movements than the configured limit will start a queue and execute movements when there is space.

注釈

ita.organization.common.upload_file_size_limit

The ita.organization.common.upload_file_size_limit is the maximum size of files that can be uploaded to IT Automation (in bytes).

3.3.6. Confirm resource plan

There are 3 methods for checking the resource plans.
From the menu, select Resource plan management.
../../_images/plan_menu.png
This will display the Resource plan list where users can check registered resource plans.
../../_images/plan_list_1.png

Tip

Curent resource plans cannot be edited or deleted.

注釈

For more information regarding applying created resource plans, see Create/Edit organizations.

3.3.7. Confirm use status

Users can check the resource usage statuses for each organization (number of workspaces, users and roles).
There are 2 methods for checking resource usage statuses.

Tip

There is no Web UI for checking the usage statuses.
Use either "Script and setting file" or "Rest API".

Follow the steps below.

  • Check usage status per organization
    • Command
      ./get-usage-list.sh
      
    • Input information after executing command (input example)
      organization id : Input the ID of the organization that will be fetched (If left blank, all organizations will be specified)
      
      your username : Input the System admin's username
      your password : Input the System admin's password
      
    • Results when process succeeds
      "result": "000-00000" means that the process succeeded
      < HTTP/1.1 200 OK
      < Date: Mon, 30 Jan 2023 08:18:57 GMT
      < Server: Apache/2.4.37 (Red Hat Enterprise Linux) mod_wsgi/4.7.1 Python/3.9
      < Content-Length: 432
      < Content-Type: application/json
      <
      { [432 bytes data]
      * Connection #0 to host platform-auth left intact
      {
        "data": [
          {
            "organization_id": "org1",
            "usages": [
              {
                "current_value": 0,
                "id": "platform.workspaces"
              },
              {
                "current_value": 1,
                "id": "platform.users"
              },
              {
                "current_value": 0,
                "id": "platform.roles"
              }
            ]
          }
        ],
        "message": "SUCCESS",
        "result": "000-00000",
        "ts": "2023-01-30T08:18:57.887Z"
      }