Example usage for com.amazonaws.services.elasticbeanstalk.model UpdateConfigurationTemplateRequest UpdateConfigurationTemplateRequest

List of usage examples for com.amazonaws.services.elasticbeanstalk.model UpdateConfigurationTemplateRequest UpdateConfigurationTemplateRequest

Introduction

In this page you can find the example usage for com.amazonaws.services.elasticbeanstalk.model UpdateConfigurationTemplateRequest UpdateConfigurationTemplateRequest.

Prototype

public UpdateConfigurationTemplateRequest(String applicationName, String templateName) 

Source Link

Document

Constructs a new UpdateConfigurationTemplateRequest object.

Usage

From source file:br.com.ingenieux.mojo.beanstalk.config.UpdateConfigurationTemplateMojo.java

License:Apache License

UpdateConfigurationTemplateResult updateConfiguration(String templateName) throws MojoFailureException {
    ConfigurationTemplate template = getConfigurationTemplate(templateName);

    if (null == template) {
        throw new MojoFailureException(String.format("templateName ('%s') not found", templateName));
    }//from  w  w  w.  j  a  v  a 2  s.  c  o m

    if (isBlank(template.getSolutionStack())) {
        throw new MojoFailureException(
                String.format("Please define solutionStack/ in template %s", templateName));
    }

    UpdateConfigurationTemplateRequest req = new UpdateConfigurationTemplateRequest(applicationName,
            templateName);

    req.setOptionSettings(Arrays.asList(template.getOptionSettings()));

    return getService().updateConfigurationTemplate(req);
}