project¶
Contents¶
-
Services
-
Messages
ProjectService¶
Project service provides APIs to interact with the Project entity.
CreateProject¶
rpc CreateProject(CreateProjectRequest) Project
Create project api creates a project under a given Tenant (Organization).
UpdateProject¶
rpc UpdateProject(UpdateProjectRequest) Project
Update project api updates a project meta.
GetProject¶
rpc GetProject(GetProjectRequest) Project
Get project apis returns a requested project.
ListProjects¶
rpc ListProjects(ListProjectsRequest) ListProjectsResponse
(-- api-linter: core::0132::http-body=disabled api-linter: core::0132::http-method=disabled aip.dev/not-precedent: We need to do this because we can't have advance filters as query params. --) List Projects API lists the projects visible to the caller for the provided Tenant (Organization).
DeleteProject¶
rpc DeleteProject(DeleteProjectRequest) .google.protobuf.Empty
Deletes a project and its associated resources.
AssociateResources¶
rpc AssociateResources(AssociateResourcesRequest) Project
AssociateResources will append the supplied resources to existing infra resources of a given project config. (-- api-linter: core::0136::http-method=disabled aip.dev/not-precedent: We need to do this because renaming creating issues with other apis)
DisassociateResources¶
rpc DisassociateResources(DisassociateResourcesRequest) Project
DisassociateResource will remove the infra resources supplied in the request from the project config. (-- api-linter: core::0136::http-method=disabled aip.dev/not-precedent: We need to do this because renaming creating issues with other apis)
Messages¶
ApplicationResources¶
ApplicationsResources clubs applications and their generated resources.
Field | Type | Description |
---|---|---|
pds_resources | PDSResources | PDS application and its generated resources supported by the platform. |
AssociateResourcesRequest¶
Request for updating a project with infra resource.
Field | Type | Description |
---|---|---|
project_id | string | ID of the project. |
infra_resource | Resources | Infra resource configuration to be associated to the project. The resources in the request will be appended to existing resource config of the project. |
Config¶
Configuration represents the associated resource details for project.
Field | Type | Description |
---|---|---|
infra_resources | Resources | Infra resources access ownership to the project. |
applications_resources | ApplicationResources | Application resources access ownership to the project. |
CreateProjectRequest¶
Request to create a project.
Field | Type | Description |
---|---|---|
tenant_id | string | The parent Tenant (Organization) under which project will be created (-- api-linter: core::0133::request-unknown-fields=disabled aip.dev/not-precedent: We need this field for to support creation of the resource in the Tenant (Organization) context. --) |
project | Project | Details of the project supplied by the user. |
DeleteProjectRequest¶
Request for deleting a project.
Field | Type | Description |
---|---|---|
project_id | string | ID of the project which needs to be deleted. |
DisassociateResourcesRequest¶
Request to disassociate infra resource from the project configuration.
Field | Type | Description |
---|---|---|
project_id | string | ID of the project from which infra resources to be disassociated. |
infra_resource | Resources | Infra resource configuration to be disassociated from the project. The resources in the request will be disassociated from the existing resource config of the project. |
Filter¶
Filter clubs the infra and application resource details, to filter the requested list of projects.
Field | Type | Description |
---|---|---|
oneof resource_type.app_resource | public.portworx.common.v1.ApplicationResource.Type | Type of the application managed resource for which projects to be listed. |
oneof resource_type.infra_resource | public.portworx.common.v1.InfraResource.Type | Type of the infra resource for which projects to be listed. |
resource_id | string | ID of the resource for which projects to be listed. |
GetProjectRequest¶
Request to fetch a project.
Field | Type | Description |
---|---|---|
project_id | string | Project id. |
ListProjectsRequest¶
ListProjectsRequest is the request message to the ListProjects API and it takes the multiple selector details for which the projects visible to the caller will be returned.
Field | Type | Description |
---|---|---|
tenant_id | string | Tenant (Organization) id for which projects to be listed. |
infra_resource_selector | public.portworx.common.v1.ResourceSelector | Filtering list of projects based on the provided resource details.. |
label_selector | public.portworx.common.v1.Selector | Provides the key in labels and associated values for which projects need to be listed. |
field_selector | public.portworx.common.v1.Selector | Field selector is used to filter projects based on the fields in the project's proto message. |
resp_data | public.portworx.common.v1.RespData | Response data flags for listing projects. |
pagination | public.portworx.common.v1.PageBasedPaginationRequest | Pagination parameters for listing projects. |
sort | public.portworx.common.v1.Sort | Sorting details using which requested list of projects to be sorted. |
ListProjectsResponse¶
ListProjectsResponse is the response message to the ListProjects API and contains the list of projects visible to the caller.
Field | Type | Description |
---|---|---|
projects | repeated Project | Requested projects. |
pagination | public.portworx.common.v1.PageBasedPaginationResponse | Pagination metadata for this response. (-- api-linter: core::0132::response-unknown-fields=disabled aip.dev/not-precedent: We need this field for pagination. --) |
PDSResources¶
PDSResource clubs resources generated by pds application.
Field | Type | Description |
---|---|---|
data_service_deployments | repeated string | Resource ids of deployments. |
backup_configs | repeated string | Resource ids of backup configs. |
restores | repeated string | Resource ids of restores. |
Phase¶
Phase represents the current status of the project.
Project¶
Project is a logical collection of objects and/or services that users can access.
Field | Type | Description |
---|---|---|
meta | public.portworx.common.v1.Meta | Metadata of the project. |
config | Config | Configuration represents details of associated resources to the project. |
status | Status | Status information of the project. |
Resources¶
Infra resource are platform managed resources, used by associated applications.
Field | Type | Description |
---|---|---|
clusters | repeated string | Clusters represents the target k8s clusters. |
namespaces | repeated string | Namespaces created in k8s cluster to provide the logical isolation. |
credentials | repeated string | Credentials required to connect to a backup target. |
backup_locations | repeated string | Backup locations where backups can be placed. |
templates | repeated string | Templates can be used by applications to manage its resources. |
backup_policies | repeated string | Backup Policies where the schedules are defined. |
Status¶
Status represents the current state of the project.
Field | Type | Description |
---|---|---|
reason | string | Textual information for the current state of the project. |
phase | Phase.Type | Current phase of the project. |
associated_resources | map Status.AssociatedResourcesEntry | Map of infra resources and their count, associated to the project. ie. |
Status.AssociatedResourcesEntry¶
Field | Type | Description |
---|---|---|
key | string | none |
value | int32 | none |
UpdateProjectRequest¶
Request to update a project meta. (-- api-linter: core::0134::request-resource-required=disabled aip.dev/not-precedent: We need to do this because reasons. we are only updating project meta--)
Field | Type | Description |
---|---|---|
meta | public.portworx.common.v1.Meta | Metadata of the project. |
Enums¶
Phase.Type¶
Type of phase the project is in currently should be one of the below.
Name | Number | Description |
---|---|---|
TYPE_UNSPECIFIED | 0 | Unspecified, do not use. |
ACTIVE | 1 | The project is in use and active. |
DELETE_PENDING | 2 | Deletion of project has not started. |
DELETE_IN_PROGRESS | 3 | Deletion of the project is scheduled and in progress. |