use of com.google.cloud.tools.intellij.appengine.sdk.CloudSdkValidationResult in project google-cloud-intellij by GoogleCloudPlatform.
the class AppEngineDeploymentConfiguration method checkCommonConfig.
private void checkCommonConfig(AppEngineDeployable deployable) throws RuntimeConfigurationError {
// do not check SDK if it supports dynamic install - the deployment runner will block itself
// until installation is done.
CloudSdkService cloudSdkService = CloudSdkService.getInstance();
SdkStatus sdkStatus = cloudSdkService.getStatus();
if (sdkStatus != SdkStatus.READY && !cloudSdkService.isInstallSupported()) {
Set<CloudSdkValidationResult> sdkValidationResult = CloudSdkValidator.getInstance().validateCloudSdk();
if (!sdkValidationResult.isEmpty()) {
CloudSdkValidationResult result = Iterables.getFirst(sdkValidationResult, null);
throw new RuntimeConfigurationError(GctBundle.message("appengine.flex.config.server.error", result.getMessage()));
}
}
check(deployable instanceof UserSpecifiedPathDeploymentSource || deployable.isValid(), "appengine.config.deployment.source.error");
check(StringUtils.isNotBlank(cloudProjectName), "appengine.flex.config.project.missing.message");
}
Aggregations