diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/adapters/yarn-conf.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/adapters/yarn-conf.js
new file mode 100644
index 0000000000..662197216f
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/adapters/yarn-conf.js
@@ -0,0 +1,79 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+ import DS from 'ember-data';
+ import Ember from 'ember';
+ import Converter from 'yarn-ui/utils/converter';
+ import AbstractAdapter from './abstract';
+
+ export default AbstractAdapter.extend({
+
+ address: 'rmWebAddress',
+
+ headers: {
+ Accept: 'text/plain'
+ },
+
+ host: Ember.computed("address", function () {
+ let address = this.get("address");
+ return this.get(`hosts.${address}`);
+ }),
+
+ pathForType(type) {
+ return 'conf';
+ },
+
+ urlForFindRecord(id, modelName, snapshot) {
+ var extension = this.get("host").split('/').pop();
+ if (extension != id) {
+ this.host = this.get("host") + id;
+ }
+ var url = this._buildURL();
+ return url;
+ },
+
+ ajax(url, method, hash) {
+ hash = hash || {};
+ hash.crossDomain = true;
+ hash.xhrFields = {withCredentials: true};
+ hash.targetServer = "RM";
+ return this._super(url, method, hash);
+ },
+
+ /**
+ * Override options so that result is not expected to be JSON
+ */
+ ajaxOptions: function (url, type, options) {
+ var hash = options || {};
+ hash.url = url;
+ hash.type = type;
+ // Make sure jQuery does not try to convert response to JSON.
+ hash.dataType = 'text';
+ hash.context = this;
+
+ var headers = Ember.get(this, 'headers');
+ if (headers != undefined) {
+ hash.beforeSend = function (xhr) {
+ Object.keys(headers).forEach(function (key) {
+ return xhr.setRequestHeader(key, headers[key]);
+ });
+ };
+ }
+ return hash;
+ },
+ });
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/adapters/yarn-metrics.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/adapters/yarn-metrics.js
new file mode 100644
index 0000000000..d26de2819e
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/adapters/yarn-metrics.js
@@ -0,0 +1,76 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import DS from 'ember-data';
+import Ember from 'ember';
+import Converter from 'yarn-ui/utils/converter';
+
+export default DS.RESTAdapter.extend({
+ address: 'rmWebAddress',
+
+ headers: {
+ Accept: 'text/plain'
+ },
+
+ host: Ember.computed("address", function() {
+ let address = this.get("address");
+ return this.get(`hosts.${address}`);
+ }),
+
+ pathForType(type) {
+ return 'jmx';
+ },
+
+ urlForFindRecord(id, modelName, snapshot) {
+ var extension = this.get("host").split('/').pop();
+ if (extension != id) {
+ this.host = this.get("host") + id;
+ }
+ var url = this._buildURL();
+ return url;
+ },
+
+ ajax(url, method, hash) {
+ hash = hash || {};
+ hash.crossDomain = true;
+ hash.xhrFields = {withCredentials: true};
+ hash.targetServer = "RM";
+ return this._super(url, method, hash);
+ },
+
+ /**
+ * Override options so that result is not expected to be JSON
+ */
+ ajaxOptions: function (url, type, options) {
+ var hash = options || {};
+ hash.url = url;
+ hash.type = type;
+ // Make sure jQuery does not try to convert response to JSON.
+ hash.dataType = 'text';
+ hash.context = this;
+ var headers = Ember.get(this, 'headers');
+ if (headers != undefined) {
+ hash.beforeSend = function (xhr) {
+ Object.keys(headers).forEach(function (key) {
+ return xhr.setRequestHeader(key, headers[key]);
+ });
+ };
+ }
+ return hash;
+ },
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/adapters/yarn-rm-log.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/adapters/yarn-rm-log.js
new file mode 100644
index 0000000000..a912ffeaab
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/adapters/yarn-rm-log.js
@@ -0,0 +1,76 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import DS from 'ember-data';
+import Ember from 'ember';
+import Converter from 'yarn-ui/utils/converter';
+
+export default DS.RESTAdapter.extend({
+ address: 'rmWebAddress',
+ headers: {
+ Accept: 'text/plain'
+ },
+
+ host: Ember.computed("address", function() {
+ let address = this.get("address");
+ return this.get(`hosts.${address}`);
+ }),
+
+ pathForType(type) {
+ return 'logs';
+ },
+
+ buildURL (modelName, id, snapshot, requestType, query) {
+ return this._super(modelName, id, snapshot, requestType, query) + '/';
+ },
+
+ urlForFindRecord(id, modelName, snapshot) {
+ this.host = this.get('host');
+ let url = this.host + id;
+ return url;
+ },
+
+ ajax(url, method, hash) {
+ hash = hash || {};
+ hash.crossDomain = true;
+ hash.xhrFields = {withCredentials: true};
+ hash.targetServer = "RM";
+ return this._super(url, method, hash);
+ },
+
+ /**
+ * Override options so that result is not expected to be JSON
+ */
+ ajaxOptions: function (url, type, options) {
+ var hash = options || {};
+ hash.url = url;
+ hash.type = type;
+ // Make sure jQuery does not try to convert response to JSON.
+ hash.dataType = 'text';
+ hash.context = this;
+ var headers = Ember.get(this, 'headers');
+ if (headers != undefined) {
+ hash.beforeSend = function (xhr) {
+ Object.keys(headers).forEach(function (key) {
+ return xhr.setRequestHeader(key, headers[key]);
+ });
+ };
+ }
+ return hash;
+ },
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-tools.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-tools.js
new file mode 100644
index 0000000000..b36098b341
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-tools.js
@@ -0,0 +1,29 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import Ember from 'ember';
+
+export default Ember.Controller.extend({
+ breadcrumbs: [{
+ text: "Home",
+ routeName: 'application'
+ }, {
+ text: "Yarn Tools",
+ routeName: 'yarn-tools',
+ }],
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-tools/yarn-conf.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-tools/yarn-conf.js
new file mode 100644
index 0000000000..86b4177a1a
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-tools/yarn-conf.js
@@ -0,0 +1,48 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import Ember from 'ember';
+
+import TableDef from 'em-table/utils/table-definition';
+import ColumnDef from 'em-table/utils/column-definition';
+
+import YarnConf from '../../models/yarn-conf';
+
+export default Ember.Controller.extend({
+ init: function () {
+ var that = this;
+ this.get('store').query('yarn-conf', {})
+ .then(function(conf) {
+ let coreProps = conf.filter(function(o) {
+ return o.get('source') == 'core-default.xml';
+ });
+ that.set('rowsForCoreColumnsFromModel', coreProps);
+ let mapredProps = conf.filter(function(o) {
+ return o.get('source') == 'mapred-default.xml';
+ });
+ that.set('rowsForMapredColumnsFromModel', mapredProps);
+ let yarnProps = conf.filter(function(o) {
+ return o.get('source') == 'yarn-default.xml';
+ });
+ that.set('rowsForYarnColumnsFromModel', yarnProps);
+ });
+ },
+
+ columnsFromModel: ColumnDef.makeFromModel(YarnConf),
+
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-tools/yarn-rm-log.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-tools/yarn-rm-log.js
new file mode 100644
index 0000000000..a5e0eb5744
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/controllers/yarn-tools/yarn-rm-log.js
@@ -0,0 +1,24 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import Ember from 'ember';
+
+export default Ember.Controller.extend({
+ queryParams: ['filename'],
+ filename: null
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/helpers/json-pretty.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/helpers/json-pretty.js
new file mode 100644
index 0000000000..a820c38778
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/helpers/json-pretty.js
@@ -0,0 +1,25 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+import Ember from 'ember';
+
+export function jsonPretty(params/*, hash*/) {
+ let j = params[0];
+ return j;
+}
+
+export default Ember.Helper.helper(jsonPretty);
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/models/yarn-conf.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/models/yarn-conf.js
new file mode 100644
index 0000000000..9846ea18ae
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/models/yarn-conf.js
@@ -0,0 +1,25 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import DS from 'ember-data';
+
+export default DS.Model.extend({
+ name: DS.attr(),
+ source: DS.attr(),
+ value: DS.attr()
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/models/yarn-metrics.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/models/yarn-metrics.js
new file mode 100644
index 0000000000..5ed217d9ee
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/models/yarn-metrics.js
@@ -0,0 +1,23 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import DS from 'ember-data';
+
+export default DS.Model.extend({
+ metrics: DS.attr()
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/models/yarn-rm-log.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/models/yarn-rm-log.js
new file mode 100644
index 0000000000..2b6febf350
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/models/yarn-rm-log.js
@@ -0,0 +1,23 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import DS from 'ember-data';
+
+export default DS.Model.extend({
+ logfileName: DS.attr()
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/router.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/router.js
index 901314289f..77189e6ecc 100644
--- hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/router.js
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/router.js
@@ -58,6 +58,12 @@ Router.map(function() {
this.route('error');
this.route('notfound', { path: '*:' });
this.route('yarn-queues', { path: '/yarn-queues/:queue_name' });
+ this.route('yarn-queue-apps', { path: '/yarn-queue-apps/:queue_name' });
+ this.route('yarn-tools', function() {
+ this.route('yarn-conf');
+ this.route('yarn-metrics');
+ this.route('yarn-rm-log');
+ });
this.route('yarn-flow-activity');
this.route('yarn-flow', { path: '/yarn-flow/:flow_uid'}, function() {
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools.js
new file mode 100644
index 0000000000..871917068f
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools.js
@@ -0,0 +1,22 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import Ember from 'ember';
+
+export default Ember.Route.extend({
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools/yarn-conf.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools/yarn-conf.js
new file mode 100644
index 0000000000..871917068f
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools/yarn-conf.js
@@ -0,0 +1,22 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import Ember from 'ember';
+
+export default Ember.Route.extend({
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools/yarn-metrics.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools/yarn-metrics.js
new file mode 100644
index 0000000000..cca2a5346b
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools/yarn-metrics.js
@@ -0,0 +1,43 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+ import Ember from 'ember';
+ import Constants from 'yarn-ui/constants';
+
+ import AbstractRoute from '../abstract';
+
+ export default AbstractRoute.extend({
+ model() {
+ return Ember.RSVP.hash({jmx: this.store.findAll('yarn-metrics')});
+ },
+
+ afterModel(model) {
+ // Handle errors and redirect if promise is rejected.
+ if (model.errors && model.errors[0]) {
+ if (model.errors[0].status == 404) {
+ this.replaceWith('/notfound');
+ } else {
+ this.replaceWith('/error');
+ }
+ }
+ },
+
+ unloadAll() {
+ this.store.unloadAll('yarn-metrics');
+ }
+ });
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools/yarn-rm-log.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools/yarn-rm-log.js
new file mode 100644
index 0000000000..a12c2803fb
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/routes/yarn-tools/yarn-rm-log.js
@@ -0,0 +1,36 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import Ember from 'ember';
+
+export default Ember.Route.extend({
+ queryParams: {
+ filename: {
+ refreshModel: true
+ }
+ },
+
+ model(param) {
+ if (param.filename == null) {
+ return Ember.RSVP.hash({logs: this.store.findAll('yarn-rm-log')});
+ } else {
+ // TODO: Loading log file is disallowed for cross-origin requests that require preflight
+ window.open(this.get('hosts.rmWebAddress') + param.filename);
+ }
+ }
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-conf.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-conf.js
new file mode 100644
index 0000000000..dc9c64f4be
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-conf.js
@@ -0,0 +1,43 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import Ember from 'ember';
+import DS from 'ember-data';
+import Converter from 'yarn-ui/utils/converter';
+
+export default DS.JSONAPISerializer.extend({
+ normalizeResponse(store, primaryModelClass, payload, id, requestType) {
+ var x2js = new X2JS();
+ let props = x2js.xml_str2json(payload);
+ let properties = props.configuration.property;
+ var convertedPayload = [];
+ for (var i = 0; i < properties.length; i++) {
+ var row = {
+ id: i,
+ type: primaryModelClass.modelName,
+ attributes: {
+ name: properties[i].name,
+ source: properties[i].source,
+ value: properties[i].value
+ }
+ };
+ convertedPayload.push(row);
+ }
+ return { data: convertedPayload };
+ },
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-metrics.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-metrics.js
new file mode 100644
index 0000000000..70c9ca0d95
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-metrics.js
@@ -0,0 +1,33 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import DS from 'ember-data';
+
+export default DS.JSONAPISerializer.extend({
+ normalizeResponse(store, primaryModelClass, payload, id, requestType) {
+ var ret =
+ {
+ id: 0,
+ type: primaryModelClass.modelName,
+ attributes: {
+ metrics: payload
+ }
+ };
+ return { data : ret };
+ },
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-rm-log.js hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-rm-log.js
new file mode 100644
index 0000000000..da834f1ca9
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/serializers/yarn-rm-log.js
@@ -0,0 +1,45 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import DS from 'ember-data';
+
+export default DS.JSONAPISerializer.extend({
+ normalizeResponse(store, primaryModelClass, payload, id, requestType) {
+ const pattern = new RegExp('', 'g');
+ let fileNames = payload.match(pattern);
+
+ if (fileNames == null) {
+ return {data : []};
+ }
+
+ let logfileNames = [];
+ for (var i = 0; i < fileNames.length; i++) {
+ var fileName = fileNames[i].match(//);
+ if (fileName.length != null) {
+ logfileNames.push({
+ id: i,
+ type: primaryModelClass.modelName,
+ attributes: {
+ logfileName: fileName[1]
+ }
+ });
+ }
+ }
+ return { data : logfileNames };
+ },
+});
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/styles/app.css hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/styles/app.css
index 8b8ea56625..2a2dc4c267 100644
--- hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/styles/app.css
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/styles/app.css
@@ -397,3 +397,9 @@ div.attempt-info-panel table > tbody > tr > td:last-of-type {
width: 14px;
display: inline-block;
}
+
+.yarn-metrics-json {
+ white-space: pre-wrap;
+ word-wrap: nowrap;
+ overflow: scroll;
+}
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/application.hbs hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/application.hbs
index e988e0c993..3613adc6cc 100644
--- hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/application.hbs
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/application.hbs
@@ -66,6 +66,11 @@
(current)
{{/link-to}}
{{/link-to}}
+ {{#link-to 'yarn-tools.yarn-conf' tagName="li"}}
+ {{#link-to 'yarn-tools.yarn-conf' class="navigation-link"}}Tools
+ (current)
+ {{/link-to}}
+ {{/link-to}}
diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/yarn-tools.hbs hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/yarn-tools.hbs
new file mode 100644
index 0000000000..301d2d578b
--- /dev/null
+++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-ui/src/main/webapp/app/templates/yarn-tools.hbs
@@ -0,0 +1,112 @@
+{{!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+--}}
+
+{{!
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+}}
+
+{{breadcrumb-bar breadcrumbs=breadcrumbs}}
+
+