step4_controller.js 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640
  1. /**
  2. * Licensed to the Apache Software Foundation (ASF) under one
  3. * or more contributor license agreements. See the NOTICE file
  4. * distributed with this work for additional information
  5. * regarding copyright ownership. The ASF licenses this file
  6. * to you under the Apache License, Version 2.0 (the
  7. * "License"); you may not use this file except in compliance
  8. * with the License. You may obtain a copy of the License at
  9. *
  10. * http://www.apache.org/licenses/LICENSE-2.0
  11. *
  12. * Unless required by applicable law or agreed to in writing, software
  13. * distributed under the License is distributed on an "AS IS" BASIS,
  14. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. * See the License for the specific language governing permissions and
  16. * limitations under the License.
  17. */
  18. var App = require('app');
  19. App.ReassignMasterWizardStep4Controller = App.HighAvailabilityProgressPageController.extend({
  20. isReassign: true,
  21. commands: ['stopServices', 'createHostComponents', 'putHostComponentsInMaintenanceMode', 'reconfigure', 'installHostComponents', 'startZooKeeperServers', 'startNameNode', 'deleteHostComponents', 'startServices'],
  22. clusterDeployState: 'REASSIGN_MASTER_INSTALLING',
  23. multiTaskCounter: 0,
  24. hostComponents: [],
  25. /**
  26. * Map with lists of unrelated services.
  27. * Used to define list of services to stop/start.
  28. */
  29. unrelatedServicesMap: {
  30. 'JOBTRACKER': ['HDFS', 'ZOOKEEPER', 'HBASE', 'FLUME', 'SQOOP', 'STORM'],
  31. 'RESOURCEMANAGER': ['HDFS', 'ZOOKEEPER', 'HBASE', 'FLUME', 'SQOOP', 'STORM']
  32. },
  33. /**
  34. * additional configs with template values
  35. * Part of value to substitute has following format: "<replace-value>"
  36. */
  37. additionalConfigsMap: [
  38. {
  39. componentName: 'RESOURCEMANAGER',
  40. configs: {
  41. 'yarn-site': {
  42. 'yarn.resourcemanager.address': '<replace-value>:8050',
  43. 'yarn.resourcemanager.admin.address': '<replace-value>:8141',
  44. 'yarn.resourcemanager.resource-tracker.address': '<replace-value>:8025',
  45. 'yarn.resourcemanager.scheduler.address': '<replace-value>:8030',
  46. 'yarn.resourcemanager.webapp.address': '<replace-value>:8088',
  47. 'yarn.resourcemanager.hostname': '<replace-value>'
  48. }
  49. }
  50. },
  51. {
  52. componentName: 'JOBTRACKER',
  53. configs: {
  54. 'mapred-site': {
  55. 'mapred.job.tracker.http.address': '<replace-value>:50030',
  56. 'mapred.job.tracker': '<replace-value>:50300'
  57. }
  58. }
  59. },
  60. {
  61. componentName: 'SECONDARY_NAMENODE',
  62. configs: {
  63. 'hdfs-site': {
  64. 'dfs.secondary.http.address': '<replace-value>:50090'
  65. }
  66. },
  67. configs_Hadoop2: {
  68. 'hdfs-site': {
  69. 'dfs.namenode.secondary.http-address': '<replace-value>:50090'
  70. }
  71. }
  72. },
  73. {
  74. componentName: 'NAMENODE',
  75. configs: {
  76. 'hdfs-site': {
  77. 'dfs.http.address': '<replace-value>:50070',
  78. 'dfs.https.address': '<replace-value>:50470'
  79. },
  80. 'core-site': {
  81. 'fs.default.name': 'hdfs://<replace-value>:8020'
  82. }
  83. },
  84. configs_Hadoop2: {
  85. 'hdfs-site': {
  86. 'dfs.namenode.http-address': '<replace-value>:50070',
  87. 'dfs.namenode.https-address': '<replace-value>:50470'
  88. },
  89. 'core-site': {
  90. 'fs.defaultFS': 'hdfs://<replace-value>:8020'
  91. }
  92. }
  93. }
  94. ],
  95. secureConfigsMap: [
  96. {
  97. componentName: 'NAMENODE',
  98. configs: [
  99. {
  100. site: 'hdfs-site',
  101. keytab: 'dfs.namenode.keytab.file',
  102. principal: 'dfs.namenode.kerberos.principal'
  103. },
  104. {
  105. site: 'hdfs-site',
  106. keytab: 'dfs.web.authentication.kerberos.keytab',
  107. principal: 'dfs.web.authentication.kerberos.principal'
  108. }
  109. ]
  110. },
  111. {
  112. componentName: 'SECONDARY_NAMENODE',
  113. configs: [
  114. {
  115. site: 'hdfs-site',
  116. keytab: 'dfs.secondary.namenode.keytab.file',
  117. principal: 'dfs.secondary.namenode.kerberos.principal'
  118. },
  119. {
  120. site: 'hdfs-site',
  121. keytab: 'dfs.web.authentication.kerberos.keytab',
  122. principal: 'dfs.web.authentication.kerberos.principal'
  123. }
  124. ]
  125. },
  126. {
  127. componentName: 'RESOURCEMANAGER',
  128. configs: [
  129. {
  130. site: 'yarn-site',
  131. keytab: 'yarn.resourcemanager.keytab',
  132. principal: 'yarn.resourcemanager.principal'
  133. },
  134. {
  135. site: 'yarn-site',
  136. keytab: 'yarn.resourcemanager.webapp.spnego-keytab-file',
  137. principal: 'yarn.resourcemanager.webapp.spnego-principal'
  138. }
  139. ]
  140. },
  141. {
  142. componentName: 'JOBTRACKER',
  143. configs: [
  144. {
  145. site: 'mapred-site',
  146. keytab: 'mapreduce.jobtracker.keytab.file',
  147. principal: 'mapreduce.jobtracker.kerberos.principal'
  148. }
  149. ]
  150. }
  151. ],
  152. /**
  153. * set additional configs
  154. * configs_Hadoop2 - configs which belongs to Hadoop 2 stack only
  155. * @param configs
  156. * @param componentName
  157. * @param replaceValue
  158. * @return {Boolean}
  159. */
  160. setAdditionalConfigs: function (configs, componentName, replaceValue) {
  161. var isHadoop2Stack = App.get('isHadoop2Stack');
  162. var component = this.get('additionalConfigsMap').findProperty('componentName', componentName);
  163. if (Em.isNone(component)) return false;
  164. var additionalConfigs = (component.configs_Hadoop2 && isHadoop2Stack) ? component.configs_Hadoop2 : component.configs;
  165. for (var site in additionalConfigs) {
  166. for (var property in additionalConfigs[site]) {
  167. configs[site][property] = additionalConfigs[site][property].replace('<replace-value>', replaceValue);
  168. }
  169. }
  170. return true;
  171. },
  172. /**
  173. * load step info
  174. */
  175. loadStep: function () {
  176. if (this.get('content.reassign.component_name') === 'NAMENODE' && App.get('isHaEnabled')) {
  177. this.set('hostComponents', ['NAMENODE', 'ZKFC']);
  178. } else {
  179. this.set('hostComponents', [this.get('content.reassign.component_name')]);
  180. }
  181. this.set('serviceName', [this.get('content.reassign.service_id')]);
  182. this._super();
  183. },
  184. /**
  185. * concat host-component names into string
  186. * @return {String}
  187. */
  188. getHostComponentsNames: function () {
  189. var hostComponentsNames = '';
  190. this.get('hostComponents').forEach(function (comp, index) {
  191. hostComponentsNames += index ? '+' : '';
  192. hostComponentsNames += comp === 'ZKFC' ? comp : App.format.role(comp);
  193. }, this);
  194. return hostComponentsNames;
  195. },
  196. /**
  197. * remove unneeded tasks
  198. */
  199. removeUnneededTasks: function () {
  200. if (this.get('content.hasManualSteps')) {
  201. if (this.get('content.reassign.component_name') === 'NAMENODE' && App.get('isHaEnabled')) {
  202. // Only for reassign NameNode with HA enabled
  203. this.get('tasks').splice(7, 2);
  204. } else {
  205. this.get('tasks').splice(5, 4);
  206. }
  207. } else {
  208. this.get('tasks').splice(5, 2);
  209. }
  210. },
  211. /**
  212. * initialize tasks
  213. */
  214. initializeTasks: function () {
  215. var commands = this.get('commands');
  216. var currentStep = App.router.get('reassignMasterController.currentStep');
  217. var hostComponentsNames = this.getHostComponentsNames();
  218. for (var i = 0; i < commands.length; i++) {
  219. var TaskLabel = i === 3 ? this.get('serviceName') : hostComponentsNames; //For Reconfigure task, show serviceName
  220. var title = Em.I18n.t('services.reassign.step4.task' + i + '.title').format(TaskLabel);
  221. this.get('tasks').pushObject(Ember.Object.create({
  222. title: title,
  223. status: 'PENDING',
  224. id: i,
  225. command: commands[i],
  226. showRetry: false,
  227. showRollback: false,
  228. name: title,
  229. displayName: title,
  230. progress: 0,
  231. isRunning: false,
  232. hosts: []
  233. }));
  234. }
  235. this.removeUnneededTasks();
  236. },
  237. hideRollbackButton: function () {
  238. var failedTask = this.get('tasks').findProperty('showRollback');
  239. if (failedTask) {
  240. failedTask.set('showRollback', false);
  241. }
  242. }.observes('tasks.@each.showRollback'),
  243. onComponentsTasksSuccess: function () {
  244. this.incrementProperty('multiTaskCounter');
  245. if (this.get('multiTaskCounter') >= this.get('hostComponents').length) {
  246. this.onTaskCompleted();
  247. }
  248. },
  249. /**
  250. * compute data for call to stop services
  251. */
  252. getStopServicesData: function () {
  253. var data = {
  254. "ServiceInfo": {
  255. "state": "INSTALLED"
  256. }
  257. };
  258. var unrelatedServices = this.get('unrelatedServicesMap')[this.get('content.reassign.component_name')];
  259. if (unrelatedServices) {
  260. var list = App.Service.find().mapProperty("serviceName").filter(function(s){return !unrelatedServices.contains(s)}).join(',');
  261. data.context = "Stop required services";
  262. data.urlParams = "ServiceInfo/service_name.in(" + list + ")";
  263. } else {
  264. data.context = "Stop all services";
  265. }
  266. return data;
  267. },
  268. /**
  269. * make server call to stop services
  270. */
  271. stopServices: function () {
  272. App.ajax.send({
  273. name: 'common.services.update',
  274. sender: this,
  275. data: this.getStopServicesData(),
  276. success: 'startPolling',
  277. error: 'onTaskError'
  278. });
  279. },
  280. createHostComponents: function () {
  281. this.set('multiTaskCounter', 0);
  282. var hostComponents = this.get('hostComponents');
  283. var hostName = this.get('content.reassignHosts.target');
  284. for (var i = 0; i < hostComponents.length; i++) {
  285. this.createComponent(hostComponents[i], hostName, this.get('content.reassign.service_id'));
  286. }
  287. },
  288. onCreateComponent: function () {
  289. this.onComponentsTasksSuccess();
  290. },
  291. putHostComponentsInMaintenanceMode: function () {
  292. this.set('multiTaskCounter', 0);
  293. var hostComponents = this.get('hostComponents');
  294. var hostName = this.get('content.reassignHosts.source');
  295. for (var i = 0; i < hostComponents.length; i++) {
  296. App.ajax.send({
  297. name: 'common.host.host_component.passive',
  298. sender: this,
  299. data: {
  300. hostName: hostName,
  301. passive_state: "ON",
  302. componentName: hostComponents[i]
  303. },
  304. success: 'onComponentsTasksSuccess',
  305. error: 'onTaskError'
  306. });
  307. }
  308. },
  309. installHostComponents: function () {
  310. this.set('multiTaskCounter', 0);
  311. var hostComponents = this.get('hostComponents');
  312. var hostName = this.get('content.reassignHosts.target');
  313. for (var i = 0; i < hostComponents.length; i++) {
  314. this.updateComponent(hostComponents[i], hostName, this.get('content.reassign.service_id'), "Install", hostComponents.length);
  315. }
  316. },
  317. reconfigure: function () {
  318. this.loadConfigsTags();
  319. },
  320. loadConfigsTags: function () {
  321. App.ajax.send({
  322. name: 'config.tags',
  323. sender: this,
  324. success: 'onLoadConfigsTags',
  325. error: 'onTaskError'
  326. });
  327. },
  328. /**
  329. * construct URL parameters for config call
  330. * @param componentName
  331. * @param data
  332. * @return {Array}
  333. */
  334. getConfigUrlParams: function (componentName, data) {
  335. var urlParams = [];
  336. switch (componentName) {
  337. case 'NAMENODE':
  338. urlParams.push('(type=hdfs-site&tag=' + data.Clusters.desired_configs['hdfs-site'].tag + ')');
  339. urlParams.push('(type=core-site&tag=' + data.Clusters.desired_configs['core-site'].tag + ')');
  340. if (App.Service.find().someProperty('serviceName', 'HBASE')) {
  341. urlParams.push('(type=hbase-site&tag=' + data.Clusters.desired_configs['hbase-site'].tag + ')');
  342. }
  343. break;
  344. case 'SECONDARY_NAMENODE':
  345. urlParams.push('(type=hdfs-site&tag=' + data.Clusters.desired_configs['hdfs-site'].tag + ')');
  346. urlParams.push('(type=core-site&tag=' + data.Clusters.desired_configs['core-site'].tag + ')');
  347. break;
  348. case 'JOBTRACKER':
  349. urlParams.push('(type=mapred-site&tag=' + data.Clusters.desired_configs['mapred-site'].tag + ')');
  350. break;
  351. case 'RESOURCEMANAGER':
  352. urlParams.push('(type=yarn-site&tag=' + data.Clusters.desired_configs['yarn-site'].tag + ')');
  353. break;
  354. }
  355. return urlParams;
  356. },
  357. onLoadConfigsTags: function (data) {
  358. var urlParams = this.getConfigUrlParams(this.get('content.reassign.component_name'), data);
  359. App.ajax.send({
  360. name: 'reassign.load_configs',
  361. sender: this,
  362. data: {
  363. urlParams: urlParams.join('|')
  364. },
  365. success: 'onLoadConfigs',
  366. error: 'onTaskError'
  367. });
  368. },
  369. configsSitesCount: null,
  370. configsSitesNumber: null,
  371. onLoadConfigs: function (data) {
  372. var componentName = this.get('content.reassign.component_name');
  373. var targetHostName = this.get('content.reassignHosts.target');
  374. var configs = {};
  375. var secureConfigs = [];
  376. this.set('configsSitesNumber', data.items.length);
  377. this.set('configsSitesCount', 0);
  378. data.items.forEach(function (item) {
  379. configs[item.type] = item.properties;
  380. }, this);
  381. this.setAdditionalConfigs(configs, componentName, targetHostName);
  382. this.setSecureConfigs(secureConfigs, configs, componentName);
  383. if (componentName === 'NAMENODE') {
  384. this.setSpecificNamenodeConfigs(configs, targetHostName);
  385. }
  386. if (componentName === 'RESOURCEMANAGER') {
  387. this.setSpecificResourceMangerConfigs(configs, targetHostName);
  388. }
  389. this.saveClusterStatus(secureConfigs, this.getComponentDir(configs, componentName));
  390. this.saveConfigsToServer(configs);
  391. },
  392. /**
  393. * make PUT call to save configs to server
  394. * @param configs
  395. */
  396. saveConfigsToServer: function (configs) {
  397. for (var site in configs) {
  398. App.ajax.send({
  399. name: 'reassign.save_configs',
  400. sender: this,
  401. data: {
  402. siteName: site,
  403. properties: configs[site]
  404. },
  405. success: 'onSaveConfigs',
  406. error: 'onTaskError'
  407. });
  408. }
  409. },
  410. /**
  411. * set specific configs which applies only to NameNode component
  412. * @param configs
  413. * @param targetHostName
  414. */
  415. setSpecificNamenodeConfigs: function (configs, targetHostName) {
  416. var sourceHostName = this.get('content.reassignHosts.source');
  417. if (App.get('isHadoop2Stack') && App.get('isHaEnabled')) {
  418. var nameServices = configs['hdfs-site']['dfs.nameservices'];
  419. if (configs['hdfs-site']['dfs.namenode.http-address.' + nameServices + '.nn1'] === sourceHostName + ':50070') {
  420. configs['hdfs-site']['dfs.namenode.http-address.' + nameServices + '.nn1'] = targetHostName + ':50070';
  421. configs['hdfs-site']['dfs.namenode.https-address.' + nameServices + '.nn1'] = targetHostName + ':50470';
  422. configs['hdfs-site']['dfs.namenode.rpc-address.' + nameServices + '.nn1'] = targetHostName + ':8020';
  423. } else {
  424. configs['hdfs-site']['dfs.namenode.http-address.' + nameServices + '.nn2'] = targetHostName + ':50070';
  425. configs['hdfs-site']['dfs.namenode.https-address.' + nameServices + '.nn2'] = targetHostName + ':50470';
  426. configs['hdfs-site']['dfs.namenode.rpc-address.' + nameServices + '.nn2'] = targetHostName + ':8020';
  427. }
  428. }
  429. if (!App.get('isHaEnabled') && App.Service.find('HBASE').get('isLoaded')) {
  430. configs['hbase-site']['hbase.rootdir'] = configs['hbase-site']['hbase.rootdir'].replace(/\/\/[^\/]*/, '//' + targetHostName + ':8020');
  431. }
  432. },
  433. /**
  434. * set specific configs which applies only to ResourceManager component
  435. * @param configs
  436. * @param targetHostName
  437. */
  438. setSpecificResourceMangerConfigs: function (configs, targetHostName) {
  439. var sourceHostName = this.get('content.reassignHosts.source');
  440. if (App.get('isHadoop2Stack') && App.get('isRMHaEnabled')) {
  441. if (configs['yarn-site']['yarn.resourcemanager.hostname.rm1'] === sourceHostName) {
  442. configs['yarn-site']['yarn.resourcemanager.hostname.rm1'] = targetHostName;
  443. } else {
  444. configs['yarn-site']['yarn.resourcemanager.hostname.rm2'] = targetHostName;
  445. }
  446. }
  447. },
  448. /**
  449. * set secure configs for component
  450. * @param secureConfigs
  451. * @param configs
  452. * @param componentName
  453. * @return {Boolean}
  454. */
  455. setSecureConfigs: function (secureConfigs, configs, componentName) {
  456. var securityEnabled = this.get('content.securityEnabled');
  457. var component = this.get('secureConfigsMap').findProperty('componentName', componentName);
  458. if (Em.isNone(component) || !securityEnabled) return false;
  459. component.configs.forEach(function (config) {
  460. secureConfigs.push({
  461. keytab: configs[config.site][config.keytab],
  462. principal: configs[config.site][config.principal]
  463. });
  464. });
  465. return true;
  466. },
  467. /**
  468. * derive component directory from configurations
  469. * @param configs
  470. * @param componentName
  471. * @return {String}
  472. */
  473. getComponentDir: function (configs, componentName) {
  474. if (componentName === 'NAMENODE') {
  475. return (App.get('isHadoop2Stack')) ? configs['hdfs-site']['dfs.namenode.name.dir'] : configs['hdfs-site']['dfs.name.dir'];
  476. }
  477. else if (componentName === 'SECONDARY_NAMENODE') {
  478. return (App.get('isHadoop2Stack')) ? configs['hdfs-site']['dfs.namenode.checkpoint.dir'] : configs['core-site']['fs.checkpoint.dir'];
  479. }
  480. return '';
  481. },
  482. /**
  483. * save cluster status to server
  484. *
  485. * @param secureConfigs
  486. * @param componentDir
  487. * @return {Boolean}
  488. */
  489. saveClusterStatus: function (secureConfigs, componentDir) {
  490. if (componentDir || secureConfigs.length) {
  491. App.router.get(this.get('content.controllerName')).saveComponentDir(componentDir);
  492. App.router.get(this.get('content.controllerName')).saveSecureConfigs(secureConfigs);
  493. App.clusterStatus.setClusterStatus({
  494. clusterName: this.get('content.cluster.name'),
  495. clusterState: this.get('clusterDeployState'),
  496. wizardControllerName: this.get('content.controllerName'),
  497. localdb: App.db.data
  498. });
  499. return true;
  500. }
  501. return false;
  502. },
  503. onSaveConfigs: function () {
  504. this.set('configsSitesCount', this.get('configsSitesCount') + 1);
  505. if (this.get('configsSitesCount') === this.get('configsSitesNumber')) {
  506. this.onTaskCompleted();
  507. }
  508. },
  509. startZooKeeperServers: function () {
  510. var components = this.get('content.masterComponentHosts').filterProperty('component', 'ZOOKEEPER_SERVER');
  511. this.updateComponent('ZOOKEEPER_SERVER', components.mapProperty('hostName'), "ZOOKEEPER", "Start");
  512. },
  513. startNameNode: function () {
  514. var components = this.get('content.masterComponentHosts').filterProperty('component', 'NAMENODE');
  515. this.updateComponent('NAMENODE', components.mapProperty('hostName').without(this.get('content.reassignHosts.source')), "HDFS", "Start");
  516. },
  517. startServices: function () {
  518. var unrelatedServices = this.get('unrelatedServicesMap')[this.get('content.reassign.component_name')];
  519. if (unrelatedServices) {
  520. var list = App.Service.find().mapProperty("serviceName").filter(function(s){return !unrelatedServices.contains(s)}).join(',');
  521. var conf = {
  522. name: 'common.services.update',
  523. sender: this,
  524. data: {
  525. "context": "Start required services",
  526. "ServiceInfo": {
  527. "state": "STARTED"
  528. },
  529. urlParams: "ServiceInfo/service_name.in("+list+")"},
  530. success: 'startPolling',
  531. error: 'onTaskError'
  532. };
  533. App.ajax.send(conf);
  534. } else {
  535. App.ajax.send({
  536. name: 'common.services.update',
  537. sender: this,
  538. data: {
  539. "context": "Start all services",
  540. "ServiceInfo": {
  541. "state": "STARTED"
  542. },
  543. urlParams: "params/run_smoke_test=true"
  544. },
  545. success: 'startPolling',
  546. error: 'onTaskError'
  547. });
  548. }
  549. },
  550. deleteHostComponents: function () {
  551. this.set('multiTaskCounter', 0);
  552. var hostComponents = this.get('hostComponents');
  553. var hostName = this.get('content.reassignHosts.source');
  554. for (var i = 0; i < hostComponents.length; i++) {
  555. App.ajax.send({
  556. name: 'common.delete.host_component',
  557. sender: this,
  558. data: {
  559. hostName: hostName,
  560. componentName: hostComponents[i]
  561. },
  562. success: 'onComponentsTasksSuccess',
  563. error: 'onDeleteHostComponentsError'
  564. });
  565. }
  566. },
  567. onDeleteHostComponentsError: function (error) {
  568. if (error.responseText.indexOf('org.apache.ambari.server.controller.spi.NoSuchResourceException') !== -1) {
  569. this.onComponentsTasksSuccess();
  570. } else {
  571. this.onTaskError();
  572. }
  573. },
  574. done: function () {
  575. if (!this.get('isSubmitDisabled')) {
  576. this.removeObserver('tasks.@each.status', this, 'onTaskStatusChange');
  577. if (this.get('content.hasManualSteps')) {
  578. App.router.send('next');
  579. } else {
  580. App.router.send('complete');
  581. }
  582. }
  583. }
  584. });