-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add test scripts to the tools folder #74
base: main
Are you sure you want to change the base?
Conversation
I have added |
The methods can be used on the The following command will analyse the log file which is saved in
When run for the first time it will copy the maintenance scripts inside 60177ad#diff-3e5af57bb465c1a51df3b132974d8cfda29bc937fe791761c142a4309c96c038 |
@khaledk2 typo in the file name. It should be |
@jburel I have fixed the typo and renamed the script to complex_queries. |
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
…the most searched term) and create an endpoint so it will be accessed online.
I have added two endpoints to access some stats: Each returns an Excel file which contains three sheets (image, project and screen).
It has been deployed on the idr-testing.
https://idr-testing.openmicroscopy.org/searchengine/api/stats/metadata
https://idr-testing.openmicroscopy.org/searchengine/api/stats/searchterms |
…and the search terms
…to the buckets for metadata and return excel files inteads of csv
tools/instructions.rst
Outdated
|
||
* The searchEngine functions can be tested using the ``check_searchengine_health.sh`` script. The script takes about 15 minutes to run. The script output is saved to a text file check_report.txt in the``/data/searchengine/searchengine/`` folder. | ||
|
||
* It is possible to stop an elasticsearch cluster node using this script:: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* It is possible to stop an elasticsearch cluster node using this script:: | |
* It is possible to stop an elasticsearch cluster node using this script (replace n with an integer, e.g. 1,2,3):: |
tools/instructions.rst
Outdated
* It is possible to stop an elasticsearch cluster node using this script:: | ||
|
||
bash stop_node.sh n | ||
where n is an integer, e.g. 1,2, 3. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
where n is an integer, e.g. 1,2, 3. |
|
||
* The ``check_cluster_health.sh`` script is used to check the cluster status at any time. | ||
|
||
* The searchEngine functions can be tested using the ``check_searchengine_health.sh`` script. The script takes about 15 minutes to run. The script output is saved to a text file check_report.txt in the``/data/searchengine/searchengine/`` folder. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* The searchEngine functions can be tested using the ``check_searchengine_health.sh`` script. The script takes about 15 minutes to run. The script output is saved to a text file check_report.txt in the``/data/searchengine/searchengine/`` folder. | |
* The searchEngine functions can be tested using the ``check_searchengine_health.sh`` script. The script takes about 15 minutes to run. The script output is saved to a text file check_report.txt in the ``/data/searchengine/searchengine/`` folder. | |
The added space will hopefully fix the formatting issue |
tools/instructions.rst
Outdated
where n is an integer, e.g. 1,2, 3. | ||
* backup_elasticsearch_data.sh script is used to backup the Elasticsearch data. | ||
|
||
* It is possible to index or re-index the data using this bash ``scrpt index_data.sh``. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* It is possible to index or re-index the data using this bash ``scrpt index_data.sh``. | |
* It is possible to index or re-index the data using the ``index_data.sh`` script. |
tools/instructions.rst
Outdated
|
||
* It is possible to index or re-index the data using this bash ``scrpt index_data.sh``. | ||
|
||
* It is possible to restore the Elasticsearch data from the backup (snapshot) using the following command:: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* It is possible to restore the Elasticsearch data from the backup (snapshot) using the following command:: | |
* Restore the Elasticsearch data from the backup (snapshot) using the following command:: |
tools/instructions.rst
Outdated
|
||
bash restore_elasticsearch_data.sh | ||
|
||
* It may take up to 15 minutes to restore the data. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should not be a new bullet point. It is an explanation for the previous bullet point.
tools/instructions.rst
Outdated
|
||
* It may take up to 15 minutes to restore the data. | ||
|
||
* The ``check_indexing_process.sh`` script is used to check the indexing data progress. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* The ``check_indexing_process.sh`` script is used to check the indexing data progress. | |
* Check the progress of the data indexing using the ``check_indexing_process.sh`` script. |
Studied the two produced excel sheets. I found both of them very useful.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some text formatting suggestions made. Also, please improve the layout of the resulting excel sheets as per #74 (comment)
I have implemented the suggested modifications. It has been deployed on the |
Co-authored-by: pwalczysko <[email protected]>
Thank you @khaledk2 . Imho, this is very helpful. Lgtm. |
The endpoints of stats (search terms and metadata) have been secured. So It is required now username and password to access them. |
I have added the script which we used to test the elasticsearch cluster to the tools folder, I have added some instructions to guide the user.
I have modified the code to copy them automatically to the host machine (
searchengine/searchengine/maintenance_scripts/
).It includes a script for indexing or reindexing the data (
index_data.sh
). There is also a script to check the progress of the indexing process (check_indexing_process.sh
)