use of com.sequenceiq.cloudbreak.orchestrator.salt.poller.SaltUploadWithPermission in project cloudbreak by hortonworks.
the class SaltTelemetryOrchestrator method uploadFileToTargetsWithContentAndPermission.
private void uploadFileToTargetsWithContentAndPermission(SaltConnector saltConnector, Set<String> targets, ExitCriteriaModel exitCriteriaModel, byte[] content, String remoteFolder, String fileName, String permission) throws CloudbreakOrchestratorFailedException {
try {
OrchestratorBootstrap saltUpload = new SaltUploadWithPermission(saltConnector, targets, remoteFolder, fileName, permission, content);
Callable<Boolean> saltUploadRunner = saltRunner.runner(saltUpload, exitCriteria, exitCriteriaModel);
saltUploadRunner.call();
} catch (Exception e) {
LOGGER.info("Error occurred during file distribute to gateway nodes", e);
throw new CloudbreakOrchestratorFailedException(e.getMessage(), e);
}
}
use of com.sequenceiq.cloudbreak.orchestrator.salt.poller.SaltUploadWithPermission in project cloudbreak by hortonworks.
the class SaltOrchestrator method uploadFileToTargetsWithPermission.
private void uploadFileToTargetsWithPermission(SaltConnector saltConnector, Set<String> targets, ExitCriteriaModel exitCriteriaModel, String path, String fileName, byte[] content) throws CloudbreakOrchestratorFailedException {
try {
OrchestratorBootstrap saltUpload = new SaltUploadWithPermission(saltConnector, targets, path, fileName, PERMISSION, content);
Callable<Boolean> saltUploadRunner = saltRunner.runner(saltUpload, exitCriteria, exitCriteriaModel);
saltUploadRunner.call();
} catch (Exception e) {
LOGGER.info("Error occurred during file distribute to gateway nodes", e);
throw new CloudbreakOrchestratorFailedException(e.getMessage(), e);
}
}
Aggregations