use of com.microsoft.azure.plugin.functions.gradle.handler.DeployHandler in project azure-gradle-plugins by microsoft.
the class DeployTask method deploy.
@TaskAction
@AzureOperation(name = "functionapp.deploy_app", type = AzureOperation.Type.ACTION)
public void deploy() throws GradleException {
try {
ProxyManager.getInstance().applyProxy();
TelemetryAgent.getInstance().addDefaultProperty(PROXY, String.valueOf(ProxyManager.getInstance().isProxyEnabled()));
TelemetryAgent.getInstance().trackTaskStart(this.getClass());
final GradleFunctionContext ctx = new GradleFunctionContext(getProject(), this.getFunctionsExtension());
TelemetryAgent.getInstance().addDefaultProperties(ctx.getTelemetryProperties());
final DeployHandler deployHandler = new DeployHandler(ctx);
deployHandler.execute();
TelemetryAgent.getInstance().trackTaskSuccess(this.getClass());
} catch (final Exception e) {
AzureMessager.getMessager().error(e);
TelemetryAgent.getInstance().traceException(this.getClass(), e);
throw new GradleException(DEPLOY_FAILURE + e.getMessage(), e);
}
}
Aggregations