* Adds support for Tribe nodes
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* @spalger review feedback
* Close create{Admin,Data}Cluster handles closing the connection
* Remove callAsKibanaUser argument from tests
* ClientLogger uses ES6 properties for tags and logQueries
* Ensure were destructuring cluster to access callAsKibanaUser
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* [tribe] Use class syntax on new data sources
* [tribe] Use includes instead of indexOf in call_client
* [tribe] DocRequest --> AbstractDocRequest
* [tribe] Fix AbstractDoc test rename
* Removes factory objects and adds addClientPlugin to Cluster (#9467)
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Resolves eslint error
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Use properties on the instance instead of class properties
Class properties are still in the very eary stages and not widely supported.
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* [tribe] Remove disabled dev tools app, do not bundle console when tribe is enabled
* [tribe] Use destructuring, don't reassign args
* [tribe] Use class syntax for client request wrapper
* [tribe] callAsKibanaUser -> callWithInternalUser
* [tribe] Remove clients from module context, service is a singleton
* [tribe] Use instance property shorthand for admin and data DocRequests
* Removes questions
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Fixes typo in tests
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Correctly names test case
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Revert "Use properties on the instance instead of class properties"
This reverts commit ebd06ae591
.
* Adds tests for create_{admin,data}_cluster
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Persists clusters to server
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* [tribe] Move cluster config requests to distinct getters
* Adds getClient and removes addClientPlugin
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Expose createClient, consolidate config parsing
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Removes createClients from Cluster
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Prevent status change from red to red
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Updates esvm:tribe ports to be consistant with dev
9200 is admin
9201:9202 are both data clusters
9203 is a tribe node connecting to both data clusters
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* [tribe] Get ssl.ca from serverConfig
* [tribe/esvm] Remove plugin configuration
* Removes unused variable
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* [tribe] Named exports for creating clusters
* [tribe] Named exports for client logger, cluster
* [tribe] Named exports for health check
* Remove invalid comment
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* [tribe] Comment explaining difference between admin and data browser clients
* Rename ES checks to be consistant with functionality
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Organize NOOP functions
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Removing function comments
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
* Explicitly check for presence of url in tribe
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
173 lines
3.9 KiB
JavaScript
173 lines
3.9 KiB
JavaScript
module.exports = function (grunt) {
|
|
const resolve = require('path').resolve;
|
|
const directory = resolve(__dirname, '../../esvm');
|
|
const dataDir = resolve(directory, 'data_dir');
|
|
const serverConfig = require('../../test/server_config');
|
|
|
|
return {
|
|
options: {
|
|
branch: 'master',
|
|
fresh: !grunt.option('esvm-no-fresh'),
|
|
config: {
|
|
http: {
|
|
port: 9200
|
|
}
|
|
}
|
|
},
|
|
|
|
dev: {
|
|
options: {
|
|
directory: resolve(directory, 'dev'),
|
|
config: {
|
|
path: {
|
|
data: dataDir
|
|
},
|
|
cluster: {
|
|
name: 'esvm-dev'
|
|
}
|
|
}
|
|
}
|
|
},
|
|
|
|
tribe: {
|
|
options: {
|
|
directory: resolve(directory, 'tribe'),
|
|
config: {
|
|
path: {
|
|
data: dataDir
|
|
}
|
|
},
|
|
nodes: [{
|
|
cluster: { name: 'data-01' },
|
|
http: { port: 9201 },
|
|
node: { name: 'node-01', data: true, master: true, max_local_storage_nodes: 5 }
|
|
}, {
|
|
cluster: { name: 'data-02' },
|
|
http: { port: 9202 },
|
|
node: { name: 'node-02', data: true, master: true, max_local_storage_nodes: 5 }
|
|
}, {
|
|
cluster: { name: 'admin' },
|
|
http: { port: 9200 },
|
|
node: { name: 'node-03', data: true, master: true, max_local_storage_nodes: 5 }
|
|
}, {
|
|
cluster: { name: 'tribe' },
|
|
http: { port: 9203 },
|
|
node: { name: 'node-04', max_local_storage_nodes: 5 },
|
|
tribe: {
|
|
c1: {
|
|
cluster: {
|
|
name: 'data-01'
|
|
}
|
|
},
|
|
c2: {
|
|
cluster: {
|
|
name: 'data-02'
|
|
}
|
|
},
|
|
on_conflict: 'prefer_c1',
|
|
blocks: {
|
|
write: true
|
|
}
|
|
},
|
|
discovery: {
|
|
zen: {
|
|
ping: {
|
|
unicast: {
|
|
hosts: [ 'localhost:9201', 'localhost:9202' ]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}]
|
|
},
|
|
},
|
|
|
|
test: {
|
|
options: {
|
|
directory: resolve(directory, 'test'),
|
|
purge: true,
|
|
config: {
|
|
http: {
|
|
port: serverConfig.servers.elasticsearch.port
|
|
},
|
|
cluster: {
|
|
name: 'esvm-test'
|
|
},
|
|
discovery: {
|
|
zen: {
|
|
ping: {
|
|
unicast: {
|
|
hosts: [ `localhost:${serverConfig.servers.elasticsearch.port}` ]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
|
|
ui: {
|
|
options: {
|
|
directory: resolve(directory, 'test'),
|
|
purge: true,
|
|
config: {
|
|
http: {
|
|
port: serverConfig.servers.elasticsearch.port
|
|
},
|
|
cluster: {
|
|
name: 'esvm-ui'
|
|
},
|
|
discovery: {
|
|
zen: {
|
|
ping: {
|
|
unicast: {
|
|
hosts: [ `localhost:${serverConfig.servers.elasticsearch.port}` ]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
|
|
withPlugins: {
|
|
options: {
|
|
version: '2.1.0',
|
|
directory: resolve(directory, 'withPlugins'),
|
|
plugins: [
|
|
'license',
|
|
'shield',
|
|
'marvel-agent',
|
|
'watcher'
|
|
],
|
|
shield: {
|
|
users: [
|
|
{
|
|
username: 'kibana',
|
|
password: 'notsecure',
|
|
roles: ['kibana4_server']
|
|
},
|
|
{
|
|
username: 'user',
|
|
password: 'notsecure',
|
|
roles: ['kibana4', 'marvel']
|
|
},
|
|
{
|
|
username: 'admin',
|
|
password: 'notsecure',
|
|
roles: ['admin']
|
|
}
|
|
]
|
|
},
|
|
config: {
|
|
marvel: {
|
|
agent: {
|
|
interval: '60s'
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
};
|
|
};
|