Rename sql-cli
This commit renames sql-cli to elasticsearch-sql-cli.
This commit is contained in:
parent
6dbb7be067
commit
8a8a1dfc2e
|
@ -6,7 +6,7 @@ X-Pack ships with a script to run the SQL CLI in its bin directory:
|
|||
|
||||
[source,bash]
|
||||
--------------------------------------------------
|
||||
$ ./bin/x-pack/sql-cli
|
||||
$ ./bin/elasticsearch-sql-cli
|
||||
--------------------------------------------------
|
||||
|
||||
The jar containing the SQL CLI is a stand alone Java application and
|
||||
|
@ -18,7 +18,7 @@ the first parameter:
|
|||
|
||||
[source,bash]
|
||||
--------------------------------------------------
|
||||
$ ./bin/x-pack/sql-cli https://some.server:9200
|
||||
$ ./bin/elasticsearch-sql-cli https://some.server:9200
|
||||
--------------------------------------------------
|
||||
|
||||
Once the CLI is running you can use any <<sql-spec,query>> that
|
||||
|
|
|
@ -45,7 +45,7 @@ shipped in x-pack's bin directory:
|
|||
|
||||
[source,bash]
|
||||
--------------------------------------------------
|
||||
$ ./bin/x-pack/sql-cli
|
||||
$ ./bin/elasticsearch-sql-cli
|
||||
--------------------------------------------------
|
||||
|
||||
From there you can run the same query:
|
||||
|
|
|
@ -10,6 +10,8 @@ apply plugin: 'elasticsearch.build'
|
|||
/* We don't use the 'application' plugin because it builds a zip and tgz which
|
||||
* we don't want. */
|
||||
|
||||
archivesBaseName = 'elasticsearch-sql-cli'
|
||||
|
||||
description = 'Command line interface to Elasticsearch that speaks SQL'
|
||||
|
||||
dependencies {
|
||||
|
|
|
@ -8,7 +8,7 @@ source "`dirname "$0"`"/elasticsearch-env
|
|||
|
||||
source "`dirname "$0"`"/x-pack-env
|
||||
|
||||
CLI_JAR=$(ls $ES_HOME/bin/sql-cli-*.jar)
|
||||
CLI_JAR=$(ls $ES_HOME/bin/elasticsearch-sql-cli-*.jar)
|
||||
|
||||
exec \
|
||||
"$JAVA" \
|
|
@ -17,6 +17,6 @@ set CLI_JAR=%ES_HOME%/plugins/bin/*
|
|||
-cp "%CLI_JAR%" ^
|
||||
org.elasticsearch.xpack.sql.cli.Cli ^
|
||||
%*
|
||||
|
||||
|
||||
endlocal
|
||||
endlocal
|
|
@ -125,7 +125,7 @@ SETUP_OK
|
|||
set -H
|
||||
}
|
||||
|
||||
@test "[$GROUP] test sql-cli" {
|
||||
@test "[$GROUP] test elasticsearch-sql-cli" {
|
||||
password=$(grep "PASSWORD elastic = " /tmp/setup-passwords-output-with-bootstrap | sed "s/PASSWORD elastic = //")
|
||||
curl -s -u "elastic:$password" -H "Content-Type: application/json" -XPUT 'localhost:9200/library/book/1?refresh&pretty' -d'{
|
||||
"name": "Ender'"'"'s Game",
|
||||
|
@ -136,7 +136,7 @@ SETUP_OK
|
|||
|
||||
password=$(grep "PASSWORD elastic = " /tmp/setup-passwords-output-with-bootstrap | sed "s/PASSWORD elastic = //")
|
||||
|
||||
run $ESHOME/bin/sql-cli --debug "http://elastic@127.0.0.1:9200" <<SQL
|
||||
run $ESHOME/bin/elasticsearch-sql-cli --debug "http://elastic@127.0.0.1:9200" <<SQL
|
||||
$password
|
||||
SELECT * FROM library;
|
||||
SQL
|
||||
|
@ -150,9 +150,9 @@ SQL
|
|||
}
|
||||
}
|
||||
|
||||
@test "[$GROUP] test sql-cli when user refuses password" {
|
||||
@test "[$GROUP] test elasticsearch-sql-cli when user refuses password" {
|
||||
# Run with empty stdin
|
||||
run $ESHOME/bin/sql-cli --debug "http://elastic@127.0.0.1:9200" <<SQL
|
||||
run $ESHOME/bin/elasticsearch-sql-cli --debug "http://elastic@127.0.0.1:9200" <<SQL
|
||||
SQL
|
||||
[ "$status" -eq 77 ] || { #NOPERM
|
||||
echo "SQL cli failed:\n$output"
|
||||
|
|
|
@ -26,9 +26,9 @@ verify_xpack_installation() {
|
|||
'saml-metadata.bat'
|
||||
'elasticsearch-setup-passwords'
|
||||
'elasticsearch-setup-passwords.bat'
|
||||
'sql-cli'
|
||||
'sql-cli.bat'
|
||||
"sql-cli-$(cat version).jar" # This jar is executable so we pitch it in bin so folks will find it
|
||||
'elasticsearch-sql-cli'
|
||||
'elasticsearch-sql-cli.bat'
|
||||
"elasticsearch-sql-cli-$(cat version).jar" # This jar is executable so we pitch it in bin so folks will find it
|
||||
'syskeygen'
|
||||
'syskeygen.bat'
|
||||
'users'
|
||||
|
|
Loading…
Reference in New Issue