Skip to content

Commit

Permalink
[M2]Remove xpack API and non-oss contents (#99)
Browse files Browse the repository at this point in the history
* Remove xpack API and non-oss contents

This PR removes xpack APIs according to elastic docs.
Here is the list of APIs which are removed:
async_search, autoscaling, cat (ml related functions),
ccr, close_point_in_time, data frame, enrich, eql, fleet,
graph, ilm, part of indices, license, logstash, ml,
monitoring, open_point_in_time, rollup, searchable_snapshots,
security, slm, sql, ssl, text_structure, transform, watcher,
xpack.

It also cleans out non-oss contents, like xpack and
platinum code and tests.

Issue Resolved:
#4

Signed-off-by: Anan Zhuang <[email protected]>

* replace word free to oss

Signed-off-by: Anan Zhuang <[email protected]>
  • Loading branch information
ananzh authored Aug 6, 2021
1 parent 47cdb28 commit 0e76e24
Show file tree
Hide file tree
Showing 52 changed files with 1,011 additions and 19,147 deletions.
5 changes: 1 addition & 4 deletions .ci/functions/imports.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,7 @@ if [[ -z $es_node_name ]]; then
export es_node_name=instance
export elastic_password=changeme
export elasticsearch_image=elasticsearch
export elasticsearch_url=https://elastic:${elastic_password}@${es_node_name}:9200
if [[ $TEST_SUITE != "platinum" ]]; then
export elasticsearch_url=http://${es_node_name}:9200
fi
export elasticsearch_url=http://${es_node_name}:9200
export external_elasticsearch_url=${elasticsearch_url/$es_node_name/localhost}
export elasticsearch_container="${elasticsearch_image}:${STACK_VERSION}"

Expand Down
24 changes: 2 additions & 22 deletions .ci/run-elasticsearch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# to form a cluster suitable for running the REST API tests.
#
# Export the STACK_VERSION variable, eg. '8.0.0-SNAPSHOT'.
# Export the TEST_SUITE variable, eg. 'free' or 'platinum' defaults to 'free'.
# Export the TEST_SUITE variable.
# Export the NUMBER_OF_NODES variable to start more than 1 node

# Version 1.4.0
Expand Down Expand Up @@ -43,23 +43,6 @@ environment=($(cat <<-END
--env action.destructive_requires_name=false
--env ingest.geoip.downloader.enabled=false
END
))
if [[ "$TEST_SUITE" == "platinum" ]]; then
environment+=($(cat <<-END
--env ELASTIC_PASSWORD=$elastic_password
--env xpack.license.self_generated.type=trial
--env xpack.security.enabled=true
--env xpack.security.http.ssl.enabled=true
--env xpack.security.http.ssl.verification_mode=certificate
--env xpack.security.http.ssl.key=certs/testnode.key
--env xpack.security.http.ssl.certificate=certs/testnode.crt
--env xpack.security.http.ssl.certificate_authorities=certs/ca.crt
--env xpack.security.transport.ssl.enabled=true
--env xpack.security.transport.ssl.verification_mode=certificate
--env xpack.security.transport.ssl.key=certs/testnode.key
--env xpack.security.transport.ssl.certificate=certs/testnode.crt
--env xpack.security.transport.ssl.certificate_authorities=certs/ca.crt
END
))
volumes+=($(cat <<-END
--volume $ssl_cert:/usr/share/elasticsearch/config/certs/testnode.crt
Expand All @@ -70,9 +53,6 @@ END
fi

cert_validation_flags=""
if [[ "$TEST_SUITE" == "platinum" ]]; then
cert_validation_flags="--insecure --cacert /usr/share/elasticsearch/config/certs/ca.crt --resolve ${es_node_name}:443:127.0.0.1"
fi

# Pull the container, retry on failures up to 5 times with
# short delays between each attempt. Fixes most transient network errors.
Expand Down Expand Up @@ -110,7 +90,7 @@ END
docker run \
--name "$node_name" \
--network "$network_name" \
--env "ES_JAVA_OPTS=-Xms1g -Xmx1g -da:org.elasticsearch.xpack.ccr.index.engine.FollowingEngineAssertions" \
--env "ES_JAVA_OPTS=-Xms1g -Xmx1g" \
"${environment[@]}" \
"${volumes[@]}" \
--publish "$http_port":9200 \
Expand Down
2 changes: 1 addition & 1 deletion .ci/run-repository.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# parameters are available to this script

# STACK_VERSION -- version e.g Major.Minor.Patch(-Prelease)
# TEST_SUITE -- which test suite to run: free or platinum
# TEST_SUITE -- the test suite to run
# ELASTICSEARCH_URL -- The url at which elasticsearch is reachable, a default is composed based on STACK_VERSION and TEST_SUITE
# NODE_JS_VERSION -- node js version (defined in test-matrix.yml, a default is hardcoded here)
script_path=$(dirname $(realpath -s $0))
Expand Down
5 changes: 2 additions & 3 deletions .ci/test-matrix.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
---
STACK_VERSION:
- 7.x-SNAPSHOT
- 7.10.2

NODE_JS_VERSION:
- 16
- 14
- 12

TEST_SUITE:
- free
- platinum
- oss

exclude: ~
141 changes: 0 additions & 141 deletions api/api/async_search.js

This file was deleted.

147 changes: 0 additions & 147 deletions api/api/autoscaling.js

This file was deleted.

Loading

0 comments on commit 0e76e24

Please sign in to comment.