use of com.google.cloud.tools.appengine.api.versions.DefaultVersionsSelectionConfiguration in project google-cloud-intellij by GoogleCloudPlatform.
the class AppEngineStop method stop.
/**
* Stops the given module / version of an App Engine application.
*/
public void stop(@NotNull String module, @NotNull String version, @NotNull ProcessStartListener startListener) {
ProcessOutputLineListener outputListener = new ProcessOutputLineListener() {
@Override
public void onOutputLine(String line) {
loggingHandler.print(line + "\n");
}
};
ProcessExitListener stopExitListener = new StopExitListener();
CloudSdk sdk = helper.createSdk(loggingHandler, startListener, outputListener, outputListener, stopExitListener);
DefaultVersionsSelectionConfiguration configuration = new DefaultVersionsSelectionConfiguration();
configuration.setVersions(Collections.singletonList(version));
configuration.setService(module);
configuration.setProject(deploymentConfiguration.getCloudProjectName());
CloudSdkAppEngineVersions command = new CloudSdkAppEngineVersions(sdk);
command.stop(configuration);
}
Aggregations