Patch storage component configuration

Content Platform for Cloud Scale Management API Reference

Version
2.4.x
Audience
anonymous
Part Number
MK-HCPCS007-07

You can update the configuration of specific storage component settings. Use the method /storage_component/list to verify existing settings or changes. Use the method /storage_component/update to update all settings.

HTTP request syntax (URI)

PATCH https://host_ip:9099/mapi/v1/storage_component/update

Request structure

The full request body is:

{
  "id": "uuid",
  "storageType": "type",
  "storageComponentConfig": {
    "label": "[label]",
    "host": "url",
    "https": {true|false},
    "port": [nnnnn],
    "bucket": "bucket_name",
    "region": "[region_name]",
    "authType": "[V2|V4]",
    "siteAffiliation": {
      "id": "uuid"
    },
    "accessKey": "key",
    "secretKey": "key",
    "useProxy": [true|false],
    "proxyHost": "[host_name]",
    "proxyPort": [nnnnn],
    "proxyUserName": "[user_name]",
    "proxyPassword": "[password]",
    "proxyDomain": "[domain_name]",
    "usePathStyleAlways": [true|false],
    "connectionTimeout": [ms],
    "socketTimeout": [ms],
    "connectionTTL": [ms],
    "maxConnections": [nnnnnnn],
    "userAgentPrefix": "[prefix]",
    "socketSendBufferSizeHint": [nnnnnnn],
    "socketRecvBufferSizeHint": [nnnnnnn],
    "managementProtocol": [http|https],
    "managementHost": "[host_name]",
    "managementUser": "[user_name]",
    "managementPassword": "[password]",
    "readOnly": 
  }
}
Parameter Required Type Description
id Yes UUID The ID of the storage component.
storageType No String The type of storage component:
  • AMAZON_S3: An Amazon Web Services S3-compatible node
  • HCP_S3: A Hitachi Content Platform node
  • HCPS_S3: An HCP S Series Node
  • GENERIC_S3: An S3-compatible node
storageComponent​Config No List The following storage component configuration values as needed:
label No String The name of the storage component.
host No String The URL of the storage component back-end host domain.
https No Boolean If true, use an HTTPS connection to the back-end system. If false, use an HTTP connection.
port No 32-bit integer HTTP port of back-end system.
bucket No String The name of the bucket. The bucket must already exist.
region No String The S3 region.
authType No String The AWS Signature Version for authenticating all interactions with Amazon S3:
  • V2
  • V4
siteAffiliation No UUID For id, the UUID representing the storage component or the user.
accessKey No String The access key of the S3 credentials for access to the bucket.
secretKey No String The secret key of the S3 credentials for access to the bucket.
useProxy No Boolean If true, a proxy server is defined. If false, a proxy server is not defined. If true, then you must provide values for proxyHost and proxyHost.
proxyHost No String The proxy host, if used.
proxyPort No 32-bit integer The proxy port number, if used.
proxyUserName No String The proxy domain user name, if used.
proxyPassword No String The proxy domain password, if used.
proxyDomain No String The proxy domain. This is not supported.
usePathStyleAlways No Boolean If true, use path-style syntax to send requests to the back-end system. If false, use virtual-hosted style.
connectionTimeout No 32-bit integer The amount of time, in milliseconds, that the HTTP connection waits to establish a connection before timing out.
socketTimeout No 32-bit integer The timeout value for reading from a connected socket.
connectionTTL No 64-bit integer The connection time to live (TTL) for a request.
maxConnections No 32-bit integer The maximum number of open HTTP connections to a storage component.
userAgentPrefix No String The HTTP user agent prefix header, used in requests to a storage component.
socketSendBuffer​Size​Hint No 32-bit integer The size hint, in bytes, for the low-level TCP send buffer. If specified, you must also specify socketRecvBufferSizeHint.
socketRecvBuffer​Size​Hint No 32-bit integer The size hint, in bytes, for the low-level TCP receive buffer. If specified, you must also specify socketSendBufferSizeHint.
managementProtocol Yes (for HCP S Series Node) String Required for an HCP S Series Node storage component; do not provide for other storage component types. The communication protocol for MAPI requests:
  • http
  • https

There is no default; if you use the parameter you must specify a value.

managementHost Yes (for HCP S Series Node) String Required for an HCP S Series Node storage component; do not provide for other storage component types. Type the management system IP address or fully qualified domain name.
managementUser Yes (for HCP S Series Node) String Required for an HCP S Series Node storage component; do not provide for other storage component types. The administrative user name credential. The account must have permissions to execute MAPI methods on the storage component.
managementPassword Yes (for HCP S Series Node) String Required for an HCP S Series Node storage component; do not provide for other storage component types. The password credential. The account must have permissions to execute MAPI methods on the storage component.
readOnly No Boolean If true, objects can be read and deleted but writes aren't allowed. If false, writes are allowed.

Response structure

The response returns the same parameters as the request with the following additions. The response body structure is:

[
  {
    "id": "uuid",
    "storageType": "",
    "storageComponentConfig": {
      "label": "",
      "host": "",
      "https": ,
      "port": ,
      "bucket": "",
      "region": "",
      "authType": "",
      "siteAffiliation": {
        "id": ""
      },
      "useProxy": ,
      "proxyHost": "",
      "proxyPort": ,
      "proxyUserName": "",
      "proxyPassword": "",
      "proxyDomain": "",
      "usePathStyleAlways": ,
      "connectionTimeout": ,
      "socketTimeout": ,
      "connectionTTL": ,
      "maxConnections": ,
      "userAgentPrefix": "",
      "socketSendBufferSizeHint": ,
      "socketRecvBufferSizeHint": ,
      "managementProtocol": ,
      "managementHost": ,
      "readOnly": ,
      "state": "state"
    }
  }
]

Parameter

Type

Description

id UUID The ID of the storage component.
state Enum The state of the storage component, indicating its availability to serve requests:
  • ACTIVE: The storage component is ready for requests.
  • INACTIVE: The storage component is on an administrative pause.
  • INACCESSIBLE: The storage component is not accessible. This condition can be caused by network, authentication, or certificate errors.
  • UNVERIFIED: The storage component has not been activated or has failed to activate.

Return codes

Status code

HTTP name

Description

200 OK The request was executed successfully.
400 Bad Request The request is missing a valid storage component or parameter.
401 Unauthorized Access was denied because credentials are not valid.
404 Not Found The specified storage component was not found.
405 Method Not Allowed The specified HTTP method is not allowed for a storage component. Resend using POST.

Example

Request example:

PATCH https://10.10.24.195:9099/mapi/v1/storage_component/update

JSON request:

{
  "id": "3fa85f64-1024-4562-b3fc-2c963f66afa6",
  "storageComponentConfig": {
    "label": "Test cloud"
  }
}

JSON response:

[
  {
    "id": "3fa85f64-1024-4562-b3fc-2c963f66afa6",
    "storageType": "AMAZON_S3",
    "storageComponentConfig": {
      "label": "Test cloud",
      "host": "172.19.54.102",
      "https": false,
      "port": 9000,
      "bucket": "testbucket",
      "region": "us-west-2",
      "authType": null,
      "siteAffiliation": {
        "id": "19546ae2-38dd-4686-b298-b5beb9173e96"
      },
      "useProxy": false,
      "proxyHost": null,
      "proxyPort": null,
      "proxyUserName": null,
      "proxyPassword": null,
      "proxyDomain": null,
      "usePathStyleAlways": true,
      "connectionTimeout": null,
      "socketTimeout": null,
      "connectionTTL": null,
      "maxConnections": null,
      "userAgentPrefix": null,
      "socketSendBufferSizeHint": null,
      "socketRecvBufferSizeHint": null,
      "readOnly": false,
      "state": "ACTIVE"
    }
  }
]