public class CloudBuildClient extends Object
Modifier and Type | Method and Description |
---|---|
String |
sendBuildRequest(String request,
com.google.api.services.cloudbuild.v1.model.Source source,
Map<String,String> substitutions)
Sends a build request to Cloud Build.
|
void |
waitForSuccess(String buildId)
Waits for the cloud build operation to complete successfully or throws an exception if the
operation fails.
|
public String sendBuildRequest(String request, com.google.api.services.cloudbuild.v1.model.Source source, Map<String,String> substitutions) throws IOException
request
- the YAML or JSON request to sendsource
- the Source
to use for the build requestsubstitutions
- the custom substitutions to applyIOException
- if an I/O error occurs in processing the requestpublic void waitForSuccess(String buildId) throws InterruptedException, IOException
buildId
- the ID of the build to wait forInterruptedException
- if polling was interruptedIOException
- if an I/O error occurs while polling for build completionCopyright © 2017–2021 Google. All rights reserved.