diff --git a/src/kibana/components/config/config.js b/src/kibana/components/config/config.js index 9ca6fe0be8cad..af3d36891f148 100644 --- a/src/kibana/components/config/config.js +++ b/src/kibana/components/config/config.js @@ -33,7 +33,7 @@ define(function (require) { var DocSource = Private(require('components/courier/data_source/doc_source')); var doc = (new DocSource()) - .index(configFile.kibanaIndex) + .index(configFile.kibana_index) .type('config') .id(kbnVersion); diff --git a/src/kibana/components/courier/saved_object/saved_object.js b/src/kibana/components/courier/saved_object/saved_object.js index d2a122301003a..e3de5d6fa7178 100644 --- a/src/kibana/components/courier/saved_object/saved_object.js +++ b/src/kibana/components/courier/saved_object/saved_object.js @@ -57,7 +57,7 @@ define(function (require) { // tell the docSource where to find the doc docSource - .index(configFile.kibanaIndex) + .index(configFile.kibana_index) .type(type) .id(self.id); @@ -217,7 +217,7 @@ define(function (require) { }) .then(function () { return es.indices.refresh({ - index: configFile.kibanaIndex + index: configFile.kibana_index }); }) .then(function () { @@ -242,12 +242,12 @@ define(function (require) { */ self.delete = function () { return es.delete({ - index: configFile.kibanaIndex, + index: configFile.kibana_index, type: type, id: this.id }).then(function () { return es.indices.refresh({ - index: configFile.kibanaIndex + index: configFile.kibana_index }); }); }; diff --git a/src/kibana/components/index_patterns/_get_ids.js b/src/kibana/components/index_patterns/_get_ids.js index b40241dd571a8..757ecdb705679 100644 --- a/src/kibana/components/index_patterns/_get_ids.js +++ b/src/kibana/components/index_patterns/_get_ids.js @@ -15,7 +15,7 @@ define(function (require) { } cachedPromise = es.search({ - index: configFile.kibanaIndex, + index: configFile.kibana_index, type: 'index-pattern', fields: [], body: { @@ -39,4 +39,4 @@ define(function (require) { return getIds; }; -}); \ No newline at end of file +}); diff --git a/src/kibana/components/index_patterns/_index_pattern.js b/src/kibana/components/index_patterns/_index_pattern.js index d17e0b419f5ee..06c6dcc68e742 100644 --- a/src/kibana/components/index_patterns/_index_pattern.js +++ b/src/kibana/components/index_patterns/_index_pattern.js @@ -39,7 +39,7 @@ define(function (require) { self.init = function () { // tell the docSource where to find the doc docSource - .index(configFile.kibanaIndex) + .index(configFile.kibana_index) .type(type) .id(self.id); diff --git a/src/kibana/components/index_patterns/_mapper.js b/src/kibana/components/index_patterns/_mapper.js index d3858f24aa2a7..458944f90ee8d 100644 --- a/src/kibana/components/index_patterns/_mapper.js +++ b/src/kibana/components/index_patterns/_mapper.js @@ -32,7 +32,7 @@ define(function (require) { if (!skipIndexPatternCache) { return es.get({ - index: configFile.kibanaIndex, + index: configFile.kibana_index, type: 'index-pattern', id: id, _sourceInclude: ['fields'] @@ -83,4 +83,4 @@ define(function (require) { return new Mapper(); }; -}); \ No newline at end of file +}); diff --git a/src/kibana/components/index_patterns/_transform_mapping_into_fields.js b/src/kibana/components/index_patterns/_transform_mapping_into_fields.js index d810e0e939f5f..7119367eb77a8 100644 --- a/src/kibana/components/index_patterns/_transform_mapping_into_fields.js +++ b/src/kibana/components/index_patterns/_transform_mapping_into_fields.js @@ -18,7 +18,7 @@ define(function (require) { return function (response) { var fields = {}; _.each(response, function (index, indexName) { - if (indexName === configFile.kibanaIndex) return; + if (indexName === configFile.kibana_index) return; _.each(index.mappings, function (mappings, typeName) { _.each(mappings, function (field, name) { var keys = Object.keys(field.mapping); @@ -46,4 +46,4 @@ define(function (require) { }); }; }; -}); \ No newline at end of file +}); diff --git a/src/kibana/components/index_patterns/index_patterns.js b/src/kibana/components/index_patterns/index_patterns.js index bb87d02a71925..facad694a4060 100644 --- a/src/kibana/components/index_patterns/index_patterns.js +++ b/src/kibana/components/index_patterns/index_patterns.js @@ -27,7 +27,7 @@ define(function (require) { self.getIds.clearCache(); patternCache.delete(pattern.id); return es.delete({ - index: configFile.kibanaIndex, + index: configFile.kibana_index, type: 'index-pattern', id: pattern.id }); @@ -45,4 +45,4 @@ define(function (require) { self.fieldFormats = Private(require('components/index_patterns/_field_formats')); self.IndexPattern = IndexPattern; }); -}); \ No newline at end of file +}); diff --git a/src/kibana/components/setup/steps/check_for_kibana_index.js b/src/kibana/components/setup/steps/check_for_kibana_index.js index 31e40b303593e..ca962e372cd59 100644 --- a/src/kibana/components/setup/steps/check_for_kibana_index.js +++ b/src/kibana/components/setup/steps/check_for_kibana_index.js @@ -6,12 +6,12 @@ define(function (require) { return function checkForKibana() { var complete = notify.lifecycle('kibana index check'); return es.indices.exists({ - index: configFile.kibanaIndex + index: configFile.kibana_index }) .catch(function (err) { - throw new SetupError('Unable to check for Kibana index "<%= configFile.kibanaIndex %>"', err); + throw new SetupError('Unable to check for Kibana index "<%= configFile.kibana_index %>"', err); }) .then(complete, complete.failure); }; }; -}); \ No newline at end of file +}); diff --git a/src/kibana/components/setup/steps/create_kibana_index.js b/src/kibana/components/setup/steps/create_kibana_index.js index e6ae9304ad363..79249e06f49d8 100644 --- a/src/kibana/components/setup/steps/create_kibana_index.js +++ b/src/kibana/components/setup/steps/create_kibana_index.js @@ -6,7 +6,7 @@ define(function (require) { var SetupError = Private(require('components/setup/_setup_error')); return es.indices.create({ - index: configFile.kibanaIndex, + index: configFile.kibana_index, body: { settings: { number_of_shards : 1, @@ -15,18 +15,18 @@ define(function (require) { } }) .catch(function (err) { - throw new SetupError('Unable to create Kibana index "<%= configFile.kibanaIndex %>"', err); + throw new SetupError('Unable to create Kibana index "<%= configFile.kibana_index %>"', err); }) .then(function () { return es.cluster.health({ waitForStatus: 'yellow', - index: configFile.kibanaIndex + index: configFile.kibana_index }) .catch(function (err) { - throw new SetupError('Waiting for Kibana index "<%= configFile.kibanaIndex %>" to come online failed', err); + throw new SetupError('Waiting for Kibana index "<%= configFile.kibana_index %>" to come online failed', err); }); }) .then(complete, complete.failure); }; }; -}); \ No newline at end of file +}); diff --git a/src/kibana/components/validate_query/validate_query.js b/src/kibana/components/validate_query/validate_query.js index ce4a329c743f6..4c8b8e2cfb7f1 100644 --- a/src/kibana/components/validate_query/validate_query.js +++ b/src/kibana/components/validate_query/validate_query.js @@ -55,7 +55,7 @@ define(function (require) { } function useDefaults() { - index = configFile.kibanaIndex; + index = configFile.kibana_index; type = '__kibanaQueryValidator'; } @@ -122,4 +122,4 @@ define(function (require) { } }; }); -}); \ No newline at end of file +}); diff --git a/src/kibana/index.js b/src/kibana/index.js index fbbdb3196b6f6..0f86ce44ef3e7 100644 --- a/src/kibana/index.js +++ b/src/kibana/index.js @@ -45,7 +45,7 @@ define(function (require) { // setup routes routes .otherwise({ - redirectTo: '/' + configFile.defaultAppId + redirectTo: '/' + configFile.default_app_id }); // tell the modules util to add it's modules as requirements for kibana diff --git a/src/kibana/plugins/dashboard/services/_saved_dashboard.js b/src/kibana/plugins/dashboard/services/_saved_dashboard.js index a5339aadded1b..fc6f8dd135b71 100644 --- a/src/kibana/plugins/dashboard/services/_saved_dashboard.js +++ b/src/kibana/plugins/dashboard/services/_saved_dashboard.js @@ -12,7 +12,7 @@ define(function (require) { function SavedDashboard(id) { // Gives our SavedDashboard the properties of a SavedObject courier.SavedObject.call(this, { - // this object will be saved at {{configFile.kibanaIndex}}/dashboard/{{id}} + // this object will be saved at {{configFile.kibana_index}}/dashboard/{{id}} type: SavedDashboard.type, // if this is null/undefined then the SavedObject will be assigned the defaults diff --git a/src/kibana/plugins/dashboard/services/saved_dashboards.js b/src/kibana/plugins/dashboard/services/saved_dashboards.js index dc90d11a338af..a2c0cdac68845 100644 --- a/src/kibana/plugins/dashboard/services/saved_dashboards.js +++ b/src/kibana/plugins/dashboard/services/saved_dashboards.js @@ -47,7 +47,7 @@ define(function (require) { } }: { query: {match_all: {}}}; return es.search({ - index: config.file.kibanaIndex, + index: config.file.kibana_index, type: 'dashboard', body: body, size: 100 diff --git a/src/kibana/plugins/discover/saved_searches/saved_searches.js b/src/kibana/plugins/discover/saved_searches/saved_searches.js index 4cb3325c8db48..003d674bf84c1 100644 --- a/src/kibana/plugins/discover/saved_searches/saved_searches.js +++ b/src/kibana/plugins/discover/saved_searches/saved_searches.js @@ -51,7 +51,7 @@ define(function (require) { } }: { query: {match_all: {}}}; return es.search({ - index: configFile.kibanaIndex, + index: configFile.kibana_index, type: 'search', body: body, size: 100 diff --git a/src/kibana/plugins/settings/sections/indices/_refresh_kibana_index.js b/src/kibana/plugins/settings/sections/indices/_refresh_kibana_index.js index 5f453f2b300ae..0c49bc9c26865 100644 --- a/src/kibana/plugins/settings/sections/indices/_refresh_kibana_index.js +++ b/src/kibana/plugins/settings/sections/indices/_refresh_kibana_index.js @@ -2,8 +2,8 @@ define(function (require) { return function RefreshKibanaIndexFn(es, configFile) { return function () { return es.indices.refresh({ - index: configFile.kibanaIndex + index: configFile.kibana_index }); }; }; -}); \ No newline at end of file +}); diff --git a/src/kibana/plugins/settings/sections/objects/_view.js b/src/kibana/plugins/settings/sections/objects/_view.js index 9029164242c1b..98bf9353cae29 100644 --- a/src/kibana/plugins/settings/sections/objects/_view.js +++ b/src/kibana/plugins/settings/sections/objects/_view.js @@ -74,7 +74,7 @@ define(function (require) { $scope.title = inflection.singularize(serviceObj.title); es.get({ - index: config.file.kibanaIndex, + index: config.file.kibana_index, type: service.type, id: $routeParams.id }) @@ -127,7 +127,7 @@ define(function (require) { */ $scope.delete = function () { es.delete({ - index: config.file.kibanaIndex, + index: config.file.kibana_index, type: service.type, id: $routeParams.id }) @@ -156,7 +156,7 @@ define(function (require) { }); es.index({ - index: config.file.kibanaIndex, + index: config.file.kibana_index, type: service.type, id: $routeParams.id, body: source @@ -169,7 +169,7 @@ define(function (require) { function redirectHandler(action) { return es.indices.refresh({ - index: config.file.kibanaIndex + index: config.file.kibana_index }) .then(function (resp) { var msg = 'You successfully ' + action + ' the "' + $scope.obj._source.title + '" ' + $scope.title.toLowerCase() + ' object'; diff --git a/src/kibana/plugins/visualize/saved_visualizations/saved_visualizations.js b/src/kibana/plugins/visualize/saved_visualizations/saved_visualizations.js index acaaea807a1e0..8ae73ef3a5df1 100644 --- a/src/kibana/plugins/visualize/saved_visualizations/saved_visualizations.js +++ b/src/kibana/plugins/visualize/saved_visualizations/saved_visualizations.js @@ -46,7 +46,7 @@ define(function (require) { } }: { query: {match_all: {}}}; return es.search({ - index: config.file.kibanaIndex, + index: config.file.kibana_index, type: 'visualization', body: body, size: 100, diff --git a/src/kibana/utils/mapping_setup.js b/src/kibana/utils/mapping_setup.js index bf40ecac8ace7..d4473224e8ce8 100644 --- a/src/kibana/utils/mapping_setup.js +++ b/src/kibana/utils/mapping_setup.js @@ -23,7 +23,7 @@ define(function () { * @return {[type]} [description] */ var getKnownKibanaTypes = _.once(function () { - var indexName = configFile.kibanaIndex; + var indexName = configFile.kibana_index; return es.indices.getFieldMapping({ // only concerned with types in this kibana index index: indexName, @@ -82,7 +82,7 @@ define(function () { }; return es.indices.putMapping({ - index: configFile.kibanaIndex, + index: configFile.kibana_index, type: type, body: body }).then(function (resp) { @@ -105,4 +105,4 @@ define(function () { }; }; -}); \ No newline at end of file +}); diff --git a/src/server/config/kibana.yml b/src/server/config/kibana.yml index c4e1d83459739..8c422b24dcd9c 100644 --- a/src/server/config/kibana.yml +++ b/src/server/config/kibana.yml @@ -9,10 +9,10 @@ elasticsearch: "http://localhost:9200" # Kibana uses an index in Elasticsearch to store saved searches, visualizations # and dashboards. It will create a new index if it doesn't already exist. -kibanaIndex: ".kibana" +kibana_index: ".kibana" # The default application to load. -defaultAppId: "discover" +default_app_id: "discover" # Time in seconds to wait for responses from the back end or elasticsearch. # Note this should always be higher than "shard_timeout". @@ -26,4 +26,4 @@ shard_timeout: 30000 # Set to false to have a complete disregard for the validity of the SSL # certificate. -verifySSL: true +verify_ssl: true diff --git a/src/server/routes/proxy.rb b/src/server/routes/proxy.rb index f9fb1090db197..757a43073fb35 100644 --- a/src/server/routes/proxy.rb +++ b/src/server/routes/proxy.rb @@ -8,7 +8,7 @@ class Proxy < Base config = settings.config use Rack::ReverseProxy do reverse_proxy_options timeout: config["request_timeout"] - @global_options[:verify_ssl] = config["verifySSL"].nil? ? true : config["verifySSL"] + @global_options[:verify_ssl] = config["verify_ssl"].nil? ? true : config["verify_ssl"] reverse_proxy(/^\/elasticsearch(.*)$/, "#{config["elasticsearch"]}$1") end end diff --git a/test/unit/specs/directives/validate_query.js b/test/unit/specs/directives/validate_query.js index c847b1cff5fae..c8ef8592fbe3c 100644 --- a/test/unit/specs/directives/validate_query.js +++ b/test/unit/specs/directives/validate_query.js @@ -42,7 +42,7 @@ define(function (require) { }); $provide.constant('configFile', { - kibanaIndex: 'test-index' + kibana_index: 'test-index' }); });