Skip to main content

Get

Returns the specified placement group.

import { cloudApi, serviceClients, Session } from "@yandex-cloud/nodejs-sdk";

const GetDiskPlacementGroupRequest =
cloudApi.compute.disk_placement_group_service.GetDiskPlacementGroupRequest;

(async () => {
const authToken = process.env["YC_OAUTH_TOKEN"];
const session = new Session({ oauthToken: authToken });
const client = session.client(serviceClients.DiskPlacementGroupServiceClient);

const result = await client.get(
GetDiskPlacementGroupRequest.fromPartial({
diskPlacementGroupId: "diskPlacementGroupId",
})
);
console.log(result);
})();

GetDiskPlacementGroupRequest

diskPlacementGroupId : string

ID of the placement group to return. To get the placement group ID, use DiskPlacementGroupService.List request.

DiskPlacementGroup

Status

  • STATUS_UNSPECIFIED

  • CREATING

  • READY

  • DELETING

id : string

ID of the placement group.

folderId : string

ID of the folder that the placement group belongs to.

createdAt : google.protobuf.Timestamp

Creation timestamp in RFC3339 text format.

name : string

Name of the placement group. The name is unique within the folder.

description : string

Description of the placement group.

labels : string

Resource labels as key:value pairs.

zoneId : string

ID of the availability zone where the placement group resides.

status : Status

Current status of the placement group

One of placementStrategy

Placement strategy.

  • spreadPlacementStrategy : DiskSpreadPlacementStrategy

    Distribute disks over distinct failure domains.

  • partitionPlacementStrategy : DiskPartitionPlacementStrategy

    Distribute disks over partitions.

DiskSpreadPlacementStrategy

DiskPartitionPlacementStrategy

partitions : int64