How to use the yarn.timeline-service.leveldb-timeline-store.path function in yarn

To help you get started, we’ve selected a few yarn examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github apache / ambari / ambari-web / app / views / main / service / reassign / step5_view.js View on Github external
atsDir = App.StackService.find('YARN').compareCurrentVersion('2.7') > -1 ? "timeline-state-store.ldb" : "leveldb-timeline-store.ldb",
      componentDir = this.get('controller.content.componentDir') || '',
      componentDirCmd = componentDir.replace(/,/g, ' '),
      sourceHost = this.get('controller.content.reassignHosts.source'),
      targetHost = this.get('controller.content.reassignHosts.target'),
      ha = '',
      user = this.get('controller.content.hdfsUser'), path;

    if (componentName === 'NAMENODE' && App.get('isHaEnabled')) {
      ha = '_ha';
      var nnStartedHost = this.get('controller.content.masterComponentHosts').filterProperty('component', 'NAMENODE').mapProperty('hostName').without(sourceHost).without(targetHost);
    }

    if (this.get('controller.content.reassign.component_name') === 'APP_TIMELINE_SERVER') {
      user = this.get('controller.content.configs.yarn-env.yarn_user');
      path = this.get('controller.content.configs.yarn-site')['yarn.timeline-service.leveldb-timeline-store.path'];
    }

    return Em.I18n.t('services.reassign.step5.body.' + this.get('controller.content.reassign.component_name').toLowerCase() + ha).
      format(componentDir, sourceHost, targetHost, user, nnStartedHost,this.get('controller.content.group'), componentDirCmd, path, atsDir);
  }.property('controller.content.reassign.component_name', 'controller.content.componentDir', 'controller.content.masterComponentHosts', 'controller.content.reassign.host_id', 'controller.content.hdfsUser'),