Copyright | (c) 2015-2016 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Creates an instance and begins preparing it to begin serving. The returned long-running operation can be used to track the progress of preparing the new instance. The instance name is assigned by the caller. If the named instance already exists, `CreateInstance` returns `ALREADY_EXISTS`. Immediately upon completion of this request: * The instance is readable via the API, with all requested attributes but no allocated resources. Its state is `CREATING`. Until completion of the returned operation: * Cancelling the operation renders the instance immediately unreadable via the API. * The instance can be deleted. * All other attempts to modify the instance are rejected. Upon completion of the returned operation: * Billing for all successfully-allocated resources begins (some types may have lower than the requested levels). * Databases can be created in the instance. * The instance's allocated resource levels are readable via the API. * The instance's state becomes `READY`. The returned long-running operation will have a name of the format `/operations/` and can be used to track creation of the instance. The metadata field type is CreateInstanceMetadata. The response field type is Instance, if successful.
See: Cloud Spanner API Reference for spanner.projects.instances.create
.
Synopsis
- type ProjectsInstancesCreateResource = "v1" :> (Capture "parent" Text :> ("instances" :> (QueryParam "$.xgafv" Xgafv :> (QueryParam "upload_protocol" Text :> (QueryParam "access_token" Text :> (QueryParam "uploadType" Text :> (QueryParam "callback" Text :> (QueryParam "alt" AltJSON :> (ReqBody '[JSON] CreateInstanceRequest :> Post '[JSON] Operation)))))))))
- projectsInstancesCreate :: Text -> CreateInstanceRequest -> ProjectsInstancesCreate
- data ProjectsInstancesCreate
- picParent :: Lens' ProjectsInstancesCreate Text
- picXgafv :: Lens' ProjectsInstancesCreate (Maybe Xgafv)
- picUploadProtocol :: Lens' ProjectsInstancesCreate (Maybe Text)
- picAccessToken :: Lens' ProjectsInstancesCreate (Maybe Text)
- picUploadType :: Lens' ProjectsInstancesCreate (Maybe Text)
- picPayload :: Lens' ProjectsInstancesCreate CreateInstanceRequest
- picCallback :: Lens' ProjectsInstancesCreate (Maybe Text)
REST Resource
type ProjectsInstancesCreateResource = "v1" :> (Capture "parent" Text :> ("instances" :> (QueryParam "$.xgafv" Xgafv :> (QueryParam "upload_protocol" Text :> (QueryParam "access_token" Text :> (QueryParam "uploadType" Text :> (QueryParam "callback" Text :> (QueryParam "alt" AltJSON :> (ReqBody '[JSON] CreateInstanceRequest :> Post '[JSON] Operation))))))))) Source #
A resource alias for spanner.projects.instances.create
method which the
ProjectsInstancesCreate
request conforms to.
Creating a Request
projectsInstancesCreate Source #
Creates a value of ProjectsInstancesCreate
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
data ProjectsInstancesCreate Source #
Creates an instance and begins preparing it to begin serving. The returned long-running operation can be used to track the progress of preparing the new instance. The instance name is assigned by the caller. If the named instance already exists, `CreateInstance` returns `ALREADY_EXISTS`. Immediately upon completion of this request: * The instance is readable via the API, with all requested attributes but no allocated resources. Its state is `CREATING`. Until completion of the returned operation: * Cancelling the operation renders the instance immediately unreadable via the API. * The instance can be deleted. * All other attempts to modify the instance are rejected. Upon completion of the returned operation: * Billing for all successfully-allocated resources begins (some types may have lower than the requested levels). * Databases can be created in the instance. * The instance's allocated resource levels are readable via the API. * The instance's state becomes `READY`. The returned long-running operation will have a name of the format `/operations/` and can be used to track creation of the instance. The metadata field type is CreateInstanceMetadata. The response field type is Instance, if successful.
See: projectsInstancesCreate
smart constructor.
Instances
Request Lenses
picParent :: Lens' ProjectsInstancesCreate Text Source #
Required. The name of the project in which to create the instance. Values are of the form `projects/`.
picUploadProtocol :: Lens' ProjectsInstancesCreate (Maybe Text) Source #
Upload protocol for media (e.g. "raw", "multipart").
picAccessToken :: Lens' ProjectsInstancesCreate (Maybe Text) Source #
OAuth access token.
picUploadType :: Lens' ProjectsInstancesCreate (Maybe Text) Source #
Legacy upload protocol for media (e.g. "media", "multipart").
picPayload :: Lens' ProjectsInstancesCreate CreateInstanceRequest Source #
Multipart request metadata.
picCallback :: Lens' ProjectsInstancesCreate (Maybe Text) Source #
JSONP