git commit: AMBARI-5819. Slider UI should initialize the view name, instance, version from URL. (onechiporenko)
Repository: ambari Updated Branches: refs/heads/trunk b6c56e807 - 07193440d AMBARI-5819. Slider UI should initialize the view name, instance, version from URL. (onechiporenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/07193440 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/07193440 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/07193440 Branch: refs/heads/trunk Commit: 07193440d619c359bb5a21ec0644f015a6cd19fd Parents: b6c56e8 Author: Oleg Nechiporenko onechipore...@apache.org Authored: Tue May 20 14:12:24 2014 +0300 Committer: Oleg Nechiporenko onechipore...@apache.org Committed: Tue May 20 14:12:24 2014 +0300 -- .../src/main/resources/ui/app/config/app.js | 6 ++--- .../src/main/resources/ui/app/initialize.js | 27 2 files changed, 30 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/07193440/contrib/views/slider/src/main/resources/ui/app/config/app.js -- diff --git a/contrib/views/slider/src/main/resources/ui/app/config/app.js b/contrib/views/slider/src/main/resources/ui/app/config/app.js index 74d6d33..9e19d56 100755 --- a/contrib/views/slider/src/main/resources/ui/app/config/app.js +++ b/contrib/views/slider/src/main/resources/ui/app/config/app.js @@ -19,8 +19,8 @@ 'use strict'; var config = { -LOG_TRANSITIONS: true, -LOG_TRANSITIONS_INTERNAL: false - }; + LOG_TRANSITIONS: true, + LOG_TRANSITIONS_INTERNAL: false +}; module.exports = Ember.Application.create(config); http://git-wip-us.apache.org/repos/asf/ambari/blob/07193440/contrib/views/slider/src/main/resources/ui/app/initialize.js -- diff --git a/contrib/views/slider/src/main/resources/ui/app/initialize.js b/contrib/views/slider/src/main/resources/ui/app/initialize.js index 63edecf..0e9541a 100755 --- a/contrib/views/slider/src/main/resources/ui/app/initialize.js +++ b/contrib/views/slider/src/main/resources/ui/app/initialize.js @@ -23,6 +23,33 @@ require('config/router'); require('config/store'); require('translations'); +App.reopen({ + /** + * @type {string} + */ + name: 'SLIDER', + + /** + * @type {string} + */ + version: '1.0.0', + + /** + * @type {string} + */ + instance: 'SLIDER_1', + + /** + * API url for Slider + * Format: + * code/api/v1/views/[VIEW_NAME]/versions/[VERSION]/instances/[INSTANCE_NAME]//code + * @type {string} + */ + urlPrefix: function() { +return '/api/v1/views/%@1/versions/%@2/instances/%@3/'.fmt(this.get('name'), this.get('version'), this.get('instance')); + }.property('name', 'version', 'instance') +}); + // Load all modules in order automagically. Ember likes things to work this // way so everything is in the App.* namespace. var folderOrder = [
[3/4] AMBARI-5822. Add unit tests for models. (Max Shepel via akovalenko)
http://git-wip-us.apache.org/repos/asf/ambari/blob/82ffda43/ambari-web/test/models/user_test.js -- diff --git a/ambari-web/test/models/user_test.js b/ambari-web/test/models/user_test.js new file mode 100644 index 000..d844472 --- /dev/null +++ b/ambari-web/test/models/user_test.js @@ -0,0 +1,227 @@ +/** + * 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. + */ + +var App = require('app'); + +var modelSetup = require('test/init_model_test'); +require('models/user'); + +var user, + form, + userNameField, + userData = { +id: 'user' + }, + objectData = Em.Object.create({ +userName: 'name', +isLdap: true + }); + +describe('App.User', function () { + + beforeEach(function () { +user = App.User.createRecord(userData); + }); + + afterEach(function () { +modelSetup.deleteRecord(user); + }); + + describe('#id', function () { +it('should take value from userName', function () { + user.set('userName', 'name'); + expect(user.get('id')).to.equal('name'); +}); + }); + + describe('#type', function () { +it('should be LDAP', function () { + user.set('isLdap', true); + expect(user.get('type')).to.equal('LDAP'); +}); +it('should be Local', function () { + user.set('isLdap', false); + expect(user.get('type')).to.equal('Local'); +}); + }); + +}); + +describe('App.EditUserForm', function () { + + beforeEach(function () { +form = App.EditUserForm.create(); + }); + + describe('#object', function () { + +before(function () { + sinon.stub(App.router, 'get', function (k) { +if (k === 'mainAdminUserEditController.content') return userData; +return Em.get(App.router, k); + }); +}); + +after(function () { + App.router.get.restore(); +}); + +it('should take data from controller', function () { + expect(form.get('object')).to.eql(userData); +}); + + }); + + describe('#disableUsername', function () { +it('should update userName field', function () { + form.set('object', userData); + expect(form.get('field.userName.disabled')).to.equal('disabled'); +}); + }); + + describe('#disableAdminCheckbox', function () { + +before(function () { + sinon.stub(App, 'get', function(k) { +switch (k) { + case 'router': +return { + getLoginName: Em.K +}; + case 'supports.ldapGroupMapping': +return true; + default: +return Em.get(App, k); +} + }); + sinon.stub(App.router, 'get', function (k) { +if (k === 'mainAdminUserEditController.content') return objectData; +return Em.get(App.router, k); + }); +}); + +after(function () { + App.get.restore(); + App.router.get.restore(); +}); + +it('should not disable', function () { + expect(form.get('field.admin.disabled')).to.be.false; +}); + +it('should disable', function () { + form.set('object', objectData); + expect(form.get('field.admin.disabled')).to.be.true; +}); + + }); + + describe('#isValid', function () { +it('should be true as default', function () { + expect(form.isValid()).to.be.true; +}); +it('should be false', function () { + form.set('field.new_password.isRequired', true); + expect(form.isValid()).to.be.false; +}); + }); + + describe('#save', function () { + +before(function () { + sinon.stub(App.router, 'get', function (k) { +if (k === 'mainAdminUserEditController.content') return objectData; +return Em.get(App.router, k); + }); +}); + +after(function () { + App.router.get.restore(); +}); + +it('should record form values to object', function () { + form.set('field.userName.value', 'name'); + form.save(); + expect(form.get('object.userName')).to.equal('name'); +}); + }); + +}); + +describe('App.CreateUserForm', function () { + + beforeEach(function () { +form = App.CreateUserForm.create(); + }); + + describe('#object', function () { + +before(function () { + sinon.stub(App.router, 'get', function (k) {
git commit: AMBARI-5823 - Views: Centos 5 build is failing (Roman Rader via tbeerbower)
Repository: ambari Updated Branches: refs/heads/branch-1.6.0 63e133893 - 271626d23 AMBARI-5823 - Views: Centos 5 build is failing (Roman Rader via tbeerbower) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/271626d2 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/271626d2 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/271626d2 Branch: refs/heads/branch-1.6.0 Commit: 271626d23ccd0b6cb41b9a3fa6a975d773d8aa00 Parents: 63e1338 Author: tbeerbower tbeerbo...@hortonworks.com Authored: Tue May 20 08:55:27 2014 -0400 Committer: tbeerbower tbeerbo...@hortonworks.com Committed: Tue May 20 08:59:17 2014 -0400 -- contrib/views/files/pom.xml | 2 +- contrib/views/pig/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/271626d2/contrib/views/files/pom.xml -- diff --git a/contrib/views/files/pom.xml b/contrib/views/files/pom.xml index 7f53258..7a243a6 100644 --- a/contrib/views/files/pom.xml +++ b/contrib/views/files/pom.xml @@ -155,7 +155,7 @@ !-- optional: The default argument is actually install, so unless you need to run some other npm command, you can remove this whole configuration section. -- -argumentsinstall --unsafe-perm --registry=http://registry.npmjs.eu/arguments + argumentsinstall --python=python2.6 --unsafe-perm --registry=http://registry.npmjs.eu/arguments /configuration /execution /executions http://git-wip-us.apache.org/repos/asf/ambari/blob/271626d2/contrib/views/pig/pom.xml -- diff --git a/contrib/views/pig/pom.xml b/contrib/views/pig/pom.xml index 9404d44..f8ffc04 100644 --- a/contrib/views/pig/pom.xml +++ b/contrib/views/pig/pom.xml @@ -147,7 +147,7 @@ goalnpm/goal /goals configuration - argumentsinstall --unsafe-perm/arguments + argumentsinstall --python=python2.6 --unsafe-perm/arguments /configuration /execution /executions
git commit: AMBARI-5823 - Views: Centos 5 build is failing (Roman Rader via tbeerbower)
Repository: ambari Updated Branches: refs/heads/trunk 9e92faa56 - 30fc629c8 AMBARI-5823 - Views: Centos 5 build is failing (Roman Rader via tbeerbower) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/30fc629c Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/30fc629c Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/30fc629c Branch: refs/heads/trunk Commit: 30fc629c85267486a35ce172d2053370dff33305 Parents: 9e92faa Author: tbeerbower tbeerbo...@hortonworks.com Authored: Tue May 20 09:06:21 2014 -0400 Committer: tbeerbower tbeerbo...@hortonworks.com Committed: Tue May 20 09:06:53 2014 -0400 -- contrib/views/files/pom.xml | 2 +- contrib/views/pig/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/30fc629c/contrib/views/files/pom.xml -- diff --git a/contrib/views/files/pom.xml b/contrib/views/files/pom.xml index 7f53258..7a243a6 100644 --- a/contrib/views/files/pom.xml +++ b/contrib/views/files/pom.xml @@ -155,7 +155,7 @@ !-- optional: The default argument is actually install, so unless you need to run some other npm command, you can remove this whole configuration section. -- -argumentsinstall --unsafe-perm --registry=http://registry.npmjs.eu/arguments + argumentsinstall --python=python2.6 --unsafe-perm --registry=http://registry.npmjs.eu/arguments /configuration /execution /executions http://git-wip-us.apache.org/repos/asf/ambari/blob/30fc629c/contrib/views/pig/pom.xml -- diff --git a/contrib/views/pig/pom.xml b/contrib/views/pig/pom.xml index 9404d44..f8ffc04 100644 --- a/contrib/views/pig/pom.xml +++ b/contrib/views/pig/pom.xml @@ -147,7 +147,7 @@ goalnpm/goal /goals configuration - argumentsinstall --unsafe-perm/arguments + argumentsinstall --python=python2.6 --unsafe-perm/arguments /configuration /execution /executions
git commit: AMBARI-5824 Expose component counts via API (dsen)
Repository: ambari Updated Branches: refs/heads/trunk 30fc629c8 - fa6fa2842 AMBARI-5824 Expose component counts via API (dsen) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/fa6fa284 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/fa6fa284 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/fa6fa284 Branch: refs/heads/trunk Commit: fa6fa284280a6158908505b47336bdbc7f165d49 Parents: 30fc629 Author: Dmitry Sen d...@hortonworks.com Authored: Tue May 20 16:07:25 2014 +0300 Committer: Dmitry Sen d...@hortonworks.com Committed: Tue May 20 16:26:26 2014 +0300 -- .../controller/ServiceComponentResponse.java| 62 +++- .../internal/ComponentResourceProvider.java | 6 ++ .../server/state/ServiceComponentImpl.java | 29 +++-- .../src/main/resources/properties.json | 3 + .../internal/ComponentResourceProviderTest.java | 27 +++-- .../server/state/ServiceComponentTest.java | 15 + 6 files changed, 131 insertions(+), 11 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/fa6fa284/ambari-server/src/main/java/org/apache/ambari/server/controller/ServiceComponentResponse.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/ServiceComponentResponse.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/ServiceComponentResponse.java index f577255..f7dd301 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/controller/ServiceComponentResponse.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/ServiceComponentResponse.java @@ -35,11 +35,20 @@ public class ServiceComponentResponse { private String category; + private int totalCount; + + private int startedCount; + + private int installedCount; + public ServiceComponentResponse(Long clusterId, String clusterName, String serviceName, String componentName, String desiredStackVersion, - String desiredState) { + String desiredState, + int totalCount, + int startedCount, + int installedCount) { super(); this.clusterId = clusterId; this.clusterName = clusterName; @@ -47,6 +56,9 @@ public class ServiceComponentResponse { this.componentName = componentName; this.desiredStackVersion = desiredStackVersion; this.desiredState = desiredState; +this.totalCount = totalCount; +this.startedCount = startedCount; +this.installedCount = installedCount; } /** @@ -151,6 +163,54 @@ public class ServiceComponentResponse { this.category = category; } + /** + * Get the number of started SCH's + * @return number of started SCH's + */ + public int getStartedCount() { +return startedCount; + } + + /** + * Set the number of started SCH's + * @param startedCount + */ + public void setStartedCount(int startedCount) { +this.startedCount = startedCount; + } + + /** + * Get the number of installed SCH's + * @return number of installed SCH's + */ + public int getInstalledCount() { +return installedCount; + } + + /** + * Set the number of installed SCH's + * @param installedCount + */ + public void setInstalledCount(int installedCount) { +this.installedCount = installedCount; + } + + /** + * Get the total number of SCH's + * @return + */ + public int getTotalCount() { +return totalCount; + } + + /** + * Set the total number of SCH's + * @param totalCount + */ + public void setTotalCount(int totalCount) { +this.totalCount = totalCount; + } + @Override public boolean equals(Object o) { if (this == o) return true; http://git-wip-us.apache.org/repos/asf/ambari/blob/fa6fa284/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ComponentResourceProvider.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ComponentResourceProvider.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ComponentResourceProvider.java index d6739c7..c1ddcd3 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ComponentResourceProvider.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ComponentResourceProvider.java @@ -75,6 +75,9 @@ public class ComponentResourceProvider extends AbstractControllerResourceProvide protected static final
git commit: AMBARI-5828. Slider Apps view UI should show warning messages for invalid environments. (onechiporenko)
Repository: ambari Updated Branches: refs/heads/trunk fa6fa2842 - 67c507014 AMBARI-5828. Slider Apps view UI should show warning messages for invalid environments. (onechiporenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/67c50701 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/67c50701 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/67c50701 Branch: refs/heads/trunk Commit: 67c5070149b73c2867b5344687345a275bdb49b2 Parents: fa6fa28 Author: Oleg Nechiporenko onechipore...@apache.org Authored: Tue May 20 16:27:11 2014 +0300 Committer: Oleg Nechiporenko onechipore...@apache.org Committed: Tue May 20 16:30:40 2014 +0300 -- .../resources/ui/app/assets/data/resource/status_false.json | 3 ++- contrib/views/slider/src/main/resources/ui/app/initialize.js | 2 +- .../src/main/resources/ui/app/templates/application.hbs | 8 +++- 3 files changed, 10 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/67c50701/contrib/views/slider/src/main/resources/ui/app/assets/data/resource/status_false.json -- diff --git a/contrib/views/slider/src/main/resources/ui/app/assets/data/resource/status_false.json b/contrib/views/slider/src/main/resources/ui/app/assets/data/resource/status_false.json index 2fc22dc..62a4354 100644 --- a/contrib/views/slider/src/main/resources/ui/app/assets/data/resource/status_false.json +++ b/contrib/views/slider/src/main/resources/ui/app/assets/data/resource/status_false.json @@ -2,6 +2,7 @@ version: 0.0.1-SNAPSHOT, viewEnabled: false, viewErrors: [ -Slider applications view requires HDFS service to be started +Slider applications view requires HDFS service to be started, +Slider applications view requires YARN, HDFS and ZooKeeper services to bestarted. ] } \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ambari/blob/67c50701/contrib/views/slider/src/main/resources/ui/app/initialize.js -- diff --git a/contrib/views/slider/src/main/resources/ui/app/initialize.js b/contrib/views/slider/src/main/resources/ui/app/initialize.js index 1d67664..4df4dfc 100755 --- a/contrib/views/slider/src/main/resources/ui/app/initialize.js +++ b/contrib/views/slider/src/main/resources/ui/app/initialize.js @@ -72,7 +72,7 @@ App.initializer({ * Should Slider View be enabled * @type {bool} */ - viewEnabled: true, + viewEnabled: false, /** * List of errors http://git-wip-us.apache.org/repos/asf/ambari/blob/67c50701/contrib/views/slider/src/main/resources/ui/app/templates/application.hbs -- diff --git a/contrib/views/slider/src/main/resources/ui/app/templates/application.hbs b/contrib/views/slider/src/main/resources/ui/app/templates/application.hbs index b776fd2..8285573 100755 --- a/contrib/views/slider/src/main/resources/ui/app/templates/application.hbs +++ b/contrib/views/slider/src/main/resources/ui/app/templates/application.hbs @@ -16,4 +16,10 @@ * limitations under the License. }} -{{outlet}} +{{#if App.viewEnabled}} + {{outlet}} +{{else}} + {{#each error in App.viewErrors}} +h3{{error}}/h3 + {{/each}} +{{/if}}
git commit: AMBARI-5795 - Add Favorite views example (Jeff Sposetti via tbeerbower)
Repository: ambari Updated Branches: refs/heads/trunk 67c507014 - ad3ff7ed6 AMBARI-5795 - Add Favorite views example (Jeff Sposetti via tbeerbower) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/ad3ff7ed Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/ad3ff7ed Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/ad3ff7ed Branch: refs/heads/trunk Commit: ad3ff7ed62a6ffb87af041593dcb30918b24db56 Parents: 67c5070 Author: tbeerbower tbeerbo...@hortonworks.com Authored: Tue May 20 10:17:14 2014 -0400 Committer: tbeerbower tbeerbo...@hortonworks.com Committed: Tue May 20 10:17:49 2014 -0400 -- ambari-views/examples/README.md | 2 + .../examples/favorite-view/docs/index.md| 27 ambari-views/examples/favorite-view/pom.xml | 89 + .../ambari/view/favorite/FavoriteService.java | 131 +++ .../favorite-view/src/main/resources/view.xml | 38 ++ ambari-views/examples/pom.xml | 1 + 6 files changed, 288 insertions(+) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/ad3ff7ed/ambari-views/examples/README.md -- diff --git a/ambari-views/examples/README.md b/ambari-views/examples/README.md index 8773c4d..4b65216 100644 --- a/ambari-views/examples/README.md +++ b/ambari-views/examples/README.md @@ -23,7 +23,9 @@ See the documentation pages for the view examples. * [Hello World View](helloworld-view/docs/index.md) : Demonstrates the very basics of how to write and deploy a view in Ambari. * [Hello Servlet View](hello-servlet-view/docs/index.md) : Includes instance parameters and a servlet for a dynamic UI. +* [Favorite view](favorite-view/docs/index.md) : Exposes a simple resource to work with instance parameters and data * [Calculator View](calculator-view/docs/index.md) : Includes a simple resource. +* [Phone List View](phone-list-view/docs/index.md) : Demonstrates simple view persistence. * [Weather view](weather-view/docs/index.md) Please also visit the [Apache Ambari Project](http://ambari.apache.org/) page for more information. http://git-wip-us.apache.org/repos/asf/ambari/blob/ad3ff7ed/ambari-views/examples/favorite-view/docs/index.md -- diff --git a/ambari-views/examples/favorite-view/docs/index.md b/ambari-views/examples/favorite-view/docs/index.md new file mode 100644 index 000..a3990d7 --- /dev/null +++ b/ambari-views/examples/favorite-view/docs/index.md @@ -0,0 +1,27 @@ +!--- +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](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. +-- + +Favorite View Example +== + +Description +- +The Favoriate View is a very simple view example. It demonstrates the very basics of how +to write and expose a REST service which works with instance parameters and instance data. + +Package +- +All views are packaged as a view archive. The view archive contains the configuration +file and various optional components of the view. http://git-wip-us.apache.org/repos/asf/ambari/blob/ad3ff7ed/ambari-views/examples/favorite-view/pom.xml -- diff --git a/ambari-views/examples/favorite-view/pom.xml b/ambari-views/examples/favorite-view/pom.xml new file mode 100644 index 000..2d64dd9 --- /dev/null +++ b/ambari-views/examples/favorite-view/pom.xml @@ -0,0 +1,89 @@ +!-- + 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
git commit: AMBARI-5830. add deb packaging for ganglia addons nagios add ons ambari-log4j (aonishuk)
Repository: ambari Updated Branches: refs/heads/trunk ad3ff7ed6 - 836691a65 AMBARI-5830. add deb packaging for ganglia addons nagios add ons ambari-log4j (aonishuk) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/836691a6 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/836691a6 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/836691a6 Branch: refs/heads/trunk Commit: 836691a65b16e2eb3cad1d8a1979444ad9e532f8 Parents: ad3ff7e Author: Andrew Onishuk aonis...@hortonworks.com Authored: Tue May 20 18:31:59 2014 +0300 Committer: Andrew Onishuk aonis...@hortonworks.com Committed: Tue May 20 18:31:59 2014 +0300 -- .../package/deb/create_nagios_addon_deb.sh | 71 .../addons/package/deb/nagios_addon_deb_control | 8 +++ .../nagios/conf.d/hdp_mon_nagios_addons.conf| 7 ++ 3 files changed, 86 insertions(+) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/836691a6/contrib/addons/package/deb/create_nagios_addon_deb.sh -- diff --git a/contrib/addons/package/deb/create_nagios_addon_deb.sh b/contrib/addons/package/deb/create_nagios_addon_deb.sh new file mode 100644 index 000..bd81748 --- /dev/null +++ b/contrib/addons/package/deb/create_nagios_addon_deb.sh @@ -0,0 +1,71 @@ +#!/bin/bash +# +#/* +# * 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. +# */ + +CUR_DIR=`pwd` + +BASEDIR=$( cd $( dirname $0 ) pwd ) + +if [[ -z ${BUILD_DIR} ]]; then + BUILD_DIR=${BASEDIR}/build/ +fi + +if [[ -z ${VERSION} ]]; then + VERSION=${VERSION:-1.7.0} +fi + +if [[ -z ${RELEASE} ]]; then + RELEASE=${RELEASE:-1} +fi + +rm -rf ${BUILD_DIR}/* + +PKG_NAME=hdp_mon_nagios_addons +PKG_FULL_NAME=${PKG_NAME}-$VERSION + +MON_TAR_DIR=${BUILD_DIR}/${PKG_FULL_NAME}/ +SRC_DIR=${BASEDIR}/../../src/addOns/nagios/ + + + Mapping + +mkdir -p ${MON_TAR_DIR}/usr/lib64/nagios +cp -r ${SRC_DIR}/plugins ${MON_TAR_DIR}/usr/lib64/nagios + +mkdir -p ${MON_TAR_DIR}/etc/httpd +cp -r ${SRC_DIR}/conf.d ${MON_TAR_DIR}/etc/httpd + +mkdir -p ${MON_TAR_DIR}/usr/share/hdp/nagios +cp -r ${SRC_DIR}/scripts/* ${MON_TAR_DIR}/usr/share/hdp/nagios + + Create data tar + +cd ${BUILD_DIR} +tar -zcvf data.tar.gz -C $PKG_FULL_NAME . + + Create control archive +cp ${BASEDIR}/nagios_addon_deb_control ${BUILD_DIR}/control + +TAR_CONTROL_DEST=${BUILD_DIR}/control.tar.gz +tar -czf ${TAR_CONTROL_DEST} control + Create debian-binary +echo 2.0 debian-binary + + Pack to deb package +ar rcv $PKG_FULL_NAME.deb debian-binary control.tar.gz data.tar.gz http://git-wip-us.apache.org/repos/asf/ambari/blob/836691a6/contrib/addons/package/deb/nagios_addon_deb_control -- diff --git a/contrib/addons/package/deb/nagios_addon_deb_control b/contrib/addons/package/deb/nagios_addon_deb_control new file mode 100644 index 000..6f558f9 --- /dev/null +++ b/contrib/addons/package/deb/nagios_addon_deb_control @@ -0,0 +1,8 @@ +Package: hdp_mon_nagios_addons +Version: 1.7.0 +Section: universe/admin +Priority: extra +Depends: nagios-plugins-standard +Architecture: all +Description: This package provides add-on helper scripts and plugins for nagios for monitoring of a Hadoop Cluster +Maintainer: Hortonworks http://git-wip-us.apache.org/repos/asf/ambari/blob/836691a6/contrib/addons/src/addOns/nagios/conf.d/hdp_mon_nagios_addons.conf -- diff --git a/contrib/addons/src/addOns/nagios/conf.d/hdp_mon_nagios_addons.conf b/contrib/addons/src/addOns/nagios/conf.d/hdp_mon_nagios_addons.conf new file mode 100644 index 000..fbaeb2a --- /dev/null +++ b/contrib/addons/src/addOns/nagios/conf.d/hdp_mon_nagios_addons.conf @@ -0,0 +1,7 @@ +Alias /ambarinagios /usr/share/hdp +Directory /usr/share/hdp + Options None + AllowOverride None + Order allow,deny + Allow from all +/Directory
git commit: AMBARI-5832. service_name field unavailable from Hosts API (dlysnichenko)
Repository: ambari Updated Branches: refs/heads/trunk 836691a65 - 2bd7b1a09 AMBARI-5832. service_name field unavailable from Hosts API (dlysnichenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/2bd7b1a0 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/2bd7b1a0 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/2bd7b1a0 Branch: refs/heads/trunk Commit: 2bd7b1a09d2d4c5444fa344c2091370cd6258ddb Parents: 836691a Author: Lisnichenko Dmitro dlysniche...@hortonworks.com Authored: Tue May 20 20:34:20 2014 +0300 Committer: Lisnichenko Dmitro dlysniche...@hortonworks.com Committed: Tue May 20 20:35:51 2014 +0300 -- ambari-server/src/main/resources/properties.json | 1 + .../controller/internal/HostComponentResourceProviderTest.java | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/2bd7b1a0/ambari-server/src/main/resources/properties.json -- diff --git a/ambari-server/src/main/resources/properties.json b/ambari-server/src/main/resources/properties.json index 3d2a036..0cb32e7 100644 --- a/ambari-server/src/main/resources/properties.json +++ b/ambari-server/src/main/resources/properties.json @@ -72,6 +72,7 @@ HostRoles/stale_configs, HostRoles/desired_admin_state, HostRoles/maintenance_state, +HostRoles/service_name, _ ], Configuration:[ http://git-wip-us.apache.org/repos/asf/ambari/blob/2bd7b1a0/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java -- diff --git a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java index bd31b7e..08a72bb 100644 --- a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java +++ b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java @@ -254,7 +254,7 @@ public class HostComponentResourceProviderTest { EasyMock.SetServiceComponentHostRequestanyObject())).andReturn(nameResponse).once(); expect(managementController.updateHostComponents( AbstractResourceProviderTest.Matcher.getHostComponentRequestSet( -Cluster102, null, Component100, Host100, null, STARTED), +Cluster102, Service100, Component100, Host100, null, STARTED), eq(mapRequestProps), eq(false))).andReturn(response).once(); expect(resourceProviderFactory.getHostComponentResourceProvider(anyObject(Set.class),
Git Push Summary
Repository: ambari Updated Tags: refs/tags/release-1.6.0-rc0 [created] 6eab6477f