Skip to content

[Doc] Usage Types update #10813

@sureshanaparti

Description

@sureshanaparti

problem

Usage types in the docs is not in sync with the list usagetypes API response / code.

Check / Update the usage types in the doc here: https://docs.cloudstack.apache.org/en/latest/adminguide/usage.html#usage-types.

list usagetypes API response =>

(usageenv) 🐱 > list usagetypes 
{
  "count": 25,
  "usagetype": [
    {
      "description": "Running Vm Usage",
      "usagetypeid": 1
    },
    {
      "description": "Allocated Vm Usage",
      "usagetypeid": 2
    },
    {
      "description": "IP Address Usage",
      "usagetypeid": 3
    },
    {
      "description": "Network Usage (Bytes Sent)",
      "usagetypeid": 4
    },
    {
      "description": "Network Usage (Bytes Received)",
      "usagetypeid": 5
    },
    {
      "description": "Volume Usage",
      "usagetypeid": 6
    },
    {
      "description": "Template Usage",
      "usagetypeid": 7
    },
    {
      "description": "ISO Usage",
      "usagetypeid": 8
    },
    {
      "description": "Snapshot Usage",
      "usagetypeid": 9
    },
    {
      "description": "Security Group Usage",
      "usagetypeid": 10
    },
    {
      "description": "Load Balancer Usage",
      "usagetypeid": 11
    },
    {
      "description": "Port Forwarding Usage",
      "usagetypeid": 12
    },
    {
      "description": "Network Offering Usage",
      "usagetypeid": 13
    },
    {
      "description": "VPN users usage",
      "usagetypeid": 14
    },
    {
      "description": "VM Disk usage(I/O Read)",
      "usagetypeid": 21
    },
    {
      "description": "VM Disk usage(I/O Write)",
      "usagetypeid": 22
    },
    {
      "description": "VM Disk usage(Bytes Read)",
      "usagetypeid": 23
    },
    {
      "description": "VM Disk usage(Bytes Write)",
      "usagetypeid": 24
    },
    {
      "description": "VM Snapshot storage usage",
      "usagetypeid": 25
    },
    {
      "description": "Volume on secondary storage usage",
      "usagetypeid": 26
    },
    {
      "description": "VM Snapshot on primary storage usage",
      "usagetypeid": 27
    },
    {
      "description": "Backup storage usage",
      "usagetypeid": 28
    },
    {
      "description": "Bucket storage usage",
      "usagetypeid": 29
    },
    {
      "description": "Network usage",
      "usagetypeid": 30
    },
    {
      "description": "VPC usage",
      "usagetypeid": 31
    }
  ]
}
(usageenv) 🐱 > 

public class UsageTypes {
/* Any changes here should also reflect in cloud_usage.quota_mapping table */
public static final int RUNNING_VM = 1;
public static final int ALLOCATED_VM = 2; // used for tracking how long storage has been allocated for a VM
public static final int IP_ADDRESS = 3;
public static final int NETWORK_BYTES_SENT = 4;
public static final int NETWORK_BYTES_RECEIVED = 5;
public static final int VOLUME = 6;
public static final int TEMPLATE = 7;
public static final int ISO = 8;
public static final int SNAPSHOT = 9;
public static final int SECURITY_GROUP = 10;
public static final int LOAD_BALANCER_POLICY = 11;
public static final int PORT_FORWARDING_RULE = 12;
public static final int NETWORK_OFFERING = 13;
public static final int VPN_USERS = 14;
public static final int VM_DISK_IO_READ = 21;
public static final int VM_DISK_IO_WRITE = 22;
public static final int VM_DISK_BYTES_READ = 23;
public static final int VM_DISK_BYTES_WRITE = 24;
public static final int VM_SNAPSHOT = 25;
public static final int VOLUME_SECONDARY = 26;
public static final int VM_SNAPSHOT_ON_PRIMARY = 27;
public static final int BACKUP = 28;
public static final int BUCKET = 29;
public static final int NETWORK = 30;
public static final int VPC = 31;

versions

4.19.1 / 4.20.0

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    Status

    In Review

    Status

    In Progress

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions