opensearch-project / opensearch-migrations

Migrate, upgrade, compare, and replicate OpenSearch clusters with ease.
https://aws.amazon.com/solutions/implementations/migration-assistant-for-amazon-opensearch-service/
Apache License 2.0
39 stars 28 forks source link

Update logging for cluster tools #1126

Closed AndreKurait closed 1 week ago

AndreKurait commented 1 week ago

Description

Update logging for cluster tools

Issues Resolved

Is this a backport? If so, please add backport PR # and/or commits #

Testing

Output (save file when running locally, in shared_logs_output in aws):

(.venv) bash-5.2# cluster_tools
Available tools:
  - enable_compatibility_mode
  - disable_compatibility_mode
  - create_index
  - change_shards

Run `cluster_tools <tool>` to use a tool.
(.venv) bash-5.2# cluster_tools enable_compatibility_mode 
Enabling compatibility mode on the OpenSearch cluster.
Response: {'acknowledged': True, 'persistent': {'compatibility': {'override_main_response_version': 'true'}}, 'transient': {}}
Logs saved to /root/logs/d57615ab9aa3/cluster_tools/20241108_213501_enable_compatibility_mode_log_49.log

Check List

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. For more information on following Developer Certificate of Origin and signing off your commits, please check here.

codecov[bot] commented 1 week ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 80.67%. Comparing base (66ae561) to head (787b94f). Report is 7 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1126 +/- ## ============================================ + Coverage 80.63% 80.67% +0.03% Complexity 2910 2910 ============================================ Files 399 399 Lines 14829 14828 -1 Branches 1007 1007 ============================================ + Hits 11958 11962 +4 + Misses 2260 2255 -5 Partials 611 611 ``` | [Flag](https://app.codecov.io/gh/opensearch-project/opensearch-migrations/pull/1126/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=opensearch-project) | Coverage Δ | | |---|---|---| | [gradle-test](https://app.codecov.io/gh/opensearch-project/opensearch-migrations/pull/1126/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=opensearch-project) | `78.66% <ø> (ø)` | | | [python-test](https://app.codecov.io/gh/opensearch-project/opensearch-migrations/pull/1126/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=opensearch-project) | `89.93% <100.00%> (+0.18%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=opensearch-project#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.