Examples of BootLocalResourcesSelector


Examples of org.springframework.yarn.boot.support.BootLocalResourcesSelector

    private SpringYarnClientLocalizerProperties syclp;

    @Bean
    @ConditionalOnMissingBean(LocalResourcesSelector.class)
    public LocalResourcesSelector localResourcesSelector() {
      BootLocalResourcesSelector selector = new BootLocalResourcesSelector(Mode.APPMASTER);
      if (StringUtils.hasText(syclp.getZipPattern())) {
        selector.setZipArchivePattern(syclp.getZipPattern());
      }
      if (syclp.getPropertiesNames() != null) {
        selector.setPropertiesNames(syclp.getPropertiesNames());
      }
      if (syclp.getPropertiesSuffixes() != null) {
        selector.setPropertiesSuffixes(syclp.getPropertiesSuffixes());
      }
      selector.addPatterns(syclp.getPatterns());
      return selector;
    }
View Full Code Here

Examples of org.springframework.yarn.boot.support.BootLocalResourcesSelector

        for (java.util.Map.Entry<String, ContainerClustersProperties> entry : syap.getContainercluster().getClusters().entrySet()) {
          SpringYarnAppmasterLocalizerProperties props = entry.getValue().getLocalizer();
          if (props == null) {
            continue;
          }
          BootLocalResourcesSelector selector = new BootLocalResourcesSelector(Mode.CONTAINER);
          if (StringUtils.hasText(props.getZipPattern())) {
            selector.setZipArchivePattern(props.getZipPattern());
          }
          if (props.getPropertiesNames() != null) {
            selector.setPropertiesNames(props.getPropertiesNames());
          }
          if (props.getPropertiesSuffixes() != null) {
            selector.setPropertiesSuffixes(props.getPropertiesSuffixes());
          }
          selector.addPatterns(props.getPatterns());
          selectors.put(entry.getKey(), selector);
        }
      }

      BootLocalResourcesSelector selector = new BootLocalResourcesSelector(Mode.CONTAINER);
      if (StringUtils.hasText(syalp.getZipPattern())) {
        selector.setZipArchivePattern(syalp.getZipPattern());
      }
      if (syalp.getPropertiesNames() != null) {
        selector.setPropertiesNames(syalp.getPropertiesNames());
      }
      if (syalp.getPropertiesSuffixes() != null) {
        selector.setPropertiesSuffixes(syalp.getPropertiesSuffixes());
      }
      selector.addPatterns(syalp.getPatterns());
      return new BootMultiLocalResourcesSelector(selector, selectors);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.