public RunStrategy getRunStrategy(String workflowId) {
    PropertiesSnapshot properties = getCurrentPropertiesSnapshot(workflowId);
    LOG.debug("Properties for workflow [{}] are {}", workflowId, properties);
    return ObjectHelper.valueOrDefault(properties.getRunStrategy(), Defaults.DEFAULT_RUN_STRATEGY);
  }
@Test
  public void testGetNewProperties() throws Exception {
    WorkflowDefinition wfd = loadWorkflow(TEST_WORKFLOW_ID1);
    Properties newProps = new Properties();
    newProps.setAlerting(null);
    PropertiesSnapshot ps = wfd.getPropertiesSnapshot();

    // properties will not get reset when it's update_properties path
    Properties resetNotAllowed = PROPERTIES_UPDATE.getNewProperties(newProps, ps);
    assertNotNull(resetNotAllowed.getAlerting());
    assertNotNull(resetNotAllowed.getRunStrategy());
    assertNotNull(resetNotAllowed.getStepConcurrency());
    assertNotNull(resetNotAllowed.getOwner());

    // alerting, run strategy, step concurrency will get reset when it's add_workflow path
    Properties resetAllowed =
        new PropertiesUpdate(Type.ADD_WORKFLOW_DEFINITION).getNewProperties(newProps, ps);
    assertNull(resetAllowed.getAlerting());
    assertNull(resetAllowed.getRunStrategy());
    assertNull(resetAllowed.getStepConcurrency());

    // owner will not get reset when it's add_workflow path
    assertNotNull(resetAllowed.getOwner());

    // properties explicitly reset will be reset when it's update_properties path
    PropertiesUpdate update = new PropertiesUpdate(Type.UPDATE_PROPERTIES);
    update.setResetRunStrategyRule(true);
    update.setResetStepConcurrency(true);
    Properties reset = update.getNewProperties(newProps, ps);

    assertNull(reset.getRunStrategy());
    assertNull(reset.getStepConcurrency());
  }