com.netflix.spinnaker.orca.pipeline.model.Execution.setBuildTime()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(2.5k)|赞(0)|评价(0)|浏览(103)

本文整理了Java中com.netflix.spinnaker.orca.pipeline.model.Execution.setBuildTime()方法的一些代码示例,展示了Execution.setBuildTime()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Execution.setBuildTime()方法的具体详情如下:
包路径:com.netflix.spinnaker.orca.pipeline.model.Execution
类名称:Execution
方法名:setBuildTime

Execution.setBuildTime介绍

暂无

代码示例

代码示例来源:origin: com.netflix.spinnaker.orca/orca-core

public Execution build() {
 pipeline.setBuildTime(System.currentTimeMillis());
 pipeline.setAuthentication(Execution.AuthenticationDetails.build().orElse(new Execution.AuthenticationDetails()));
 return pipeline;
}

代码示例来源:origin: com.netflix.spinnaker.orca/orca-core

private Execution parseOrchestration(String configJson) throws IOException {
 @SuppressWarnings("unchecked")
 Map<String, Serializable> config = objectMapper.readValue(configJson, Map.class);
 Execution orchestration = Execution.newOrchestration(getString(config, "application"));
 if (config.containsKey("name")) {
  orchestration.setDescription(getString(config, "name"));
 }
 if (config.containsKey("description")) {
  orchestration.setDescription(getString(config, "description"));
 }
 for (Map<String, Object> context : getList(config, "stages")) {
  String type = context.remove("type").toString();
  String providerType = getString(context, "providerType");
  if (providerType != null && !providerType.equals("aws") && !providerType.equals("titus")) {
   type += format("_%s", providerType);
  }
  // TODO: need to check it's valid?
  Stage stage = new Stage(orchestration, type, context);
  orchestration.getStages().add(stage);
 }
 if (config.get("trigger") != null) {
  orchestration.setTrigger(objectMapper.convertValue(config.get("trigger"), Trigger.class));
 }
 orchestration.setBuildTime(clock.millis());
 orchestration.setAuthentication(AuthenticationDetails.build().orElse(new AuthenticationDetails()));
 orchestration.setOrigin((String) config.getOrDefault("origin", "unknown"));
 orchestration.setStartTimeExpiry((Long) config.get("startTimeExpiry"));
 return orchestration;
}

代码示例来源:origin: com.netflix.spinnaker.orca/orca-redis

execution.setCancellationReason(map.get("cancellationReason"));
execution.setLimitConcurrent(Boolean.parseBoolean(map.get("limitConcurrent")));
execution.setBuildTime(NumberUtils.createLong(map.get("buildTime")));
execution.setStartTime(NumberUtils.createLong(map.get("startTime")));
if (map.get("startTimeExpiry") != null) {

相关文章