use of org.gradle.initialization.DefaultBuildRequestMetaData in project gradle by gradle.
the class ProviderConnection method run.
private Object run(BuildAction action, BuildCancellationToken cancellationToken, ProgressListenerConfiguration progressListenerConfiguration, ProviderOperationParameters providerParameters, Parameters parameters) {
try {
BuildActionExecuter<ProviderOperationParameters> executer = createExecuter(providerParameters, parameters);
BuildRequestContext buildRequestContext = new DefaultBuildRequestContext(new DefaultBuildRequestMetaData(providerParameters.getStartTime()), cancellationToken, progressListenerConfiguration.buildEventConsumer);
BuildActionResult result = (BuildActionResult) executer.execute(action, buildRequestContext, providerParameters, sharedServices);
if (result.failure != null) {
throw (RuntimeException) payloadSerializer.deserialize(result.failure);
}
return payloadSerializer.deserialize(result.result);
} finally {
progressListenerConfiguration.failsafeWrapper.rethrowErrors();
}
}
Aggregations