Skip to content

Commit

Permalink
Merge pull request #163 from dmwm/update_es_aliases
Browse files Browse the repository at this point in the history
Update es-cms alias for wma_agent_count
  • Loading branch information
nikodemas authored Sep 13, 2024
2 parents 23ac8ff + 7be2467 commit 08a37ae
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions bin/cron4wma_agent_count.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
set -e
##H cron4wma_agent_count.sh
##H Weekly cron job of wma_agent_count_to_opensearch.py
##H This cron job calculates daily agent count per host and send to OpenSearch es-cms test tenant WEEKLY
##H This cron job calculates daily agent count per host and send to OpenSearch os-cms test tenant WEEKLY
##H
##H Example: cron4wma_agent_count.sh --keytab ./keytab --conf ./secret_opensearch.txt --p1 32000 --p2 32001 --host $MY_NODE_NAME --wdir $WDIR
##H Arguments:
Expand Down Expand Up @@ -50,7 +50,7 @@ spark_submit_args=(
_start_date=$(date -d "10 days ago" +%Y-%m-%d)
_end_date=$(date -d "3 days ago" +%Y-%m-%d)
ES_INDEX="test-wmarchive-agent-count"
ES_HOST="es-cms1.cern.ch/es"
ES_HOST="os-cms.cern.ch/os"

util4logi "${myname} Spark Job is starting... between input dates of ${_start_date} - ${_end_date}"
# ---------------------------------------------------------------------------------------------------------------------
Expand Down
4 changes: 2 additions & 2 deletions src/python/CMSSpark/wma_agent_count_to_opensearch.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"""
File : wma_agent_count_to_opensearch.py
Author : Ceyhun Uzunoglu <ceyhunuzngl AT gmail [DOT] com>
Description : Sends historical hourly aggregated WMArchive data to es-cms test tenant for debugging purpose
Description : Sends historical hourly aggregated WMArchive data to os-cms test tenant for debugging purpose
Hourly aggregated agent count per host with following fields:
"wmats_midday": aggregation is daily, so we use midday timestamp of wmats
"day": string yyyy-mm-dd
Expand Down Expand Up @@ -112,7 +112,7 @@ def send(part, opensearch_host, es_secret_file, es_index_template):
@click.option("--start_date", required=False, type=click.DateTime(_VALID_DATE_FORMATS))
@click.option("--end_date", required=False, type=click.DateTime(_VALID_DATE_FORMATS))
@click.option('--es_host', required=True, default=None, type=str,
help='OpenSearch host name without port: es-cms1.cern.ch/es')
help='OpenSearch host name without port: os-cms.cern.ch/os')
@click.option('--es_secret_file', required=True, default=None, type=str,
help='OpenSearch secret file that contains "user:pass" only')
@click.option('--es_index', required=True, default=None, type=str,
Expand Down

0 comments on commit 08a37ae

Please sign in to comment.