Skip to content
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

chore: add debugging logs #289

Merged
merged 1 commit into from
Sep 26, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions src/spaceone/cost_analysis/service/job_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,10 @@ def get_cost_data(self, params):
count = 0
is_canceled = False

_LOGGER.debug(
f"[get_cost_data] start job ({job_task_id}): {task_options}"
)

for costs_data in self.ds_plugin_mgr.get_cost_data(
options, secret_data, schema, task_options, domain_id
):
Expand Down Expand Up @@ -288,7 +292,7 @@ def get_cost_data(self, params):

if not is_canceled:
end_dt = datetime.utcnow()
_LOGGER.debug(f"[get_cost_data] end job ({job_task_id}): {end_dt}")
_LOGGER.debug(f"[get_cost_data] end job ({job_task_id}): {count}")
_LOGGER.debug(
f"[get_cost_data] total job time ({job_task_id}): {end_dt - start_dt}"
)
Expand Down Expand Up @@ -981,7 +985,7 @@ def _aggregate_monthly_cost_data(
row_count += 1

_LOGGER.debug(
f"[_aggregate_monthly_cost_data] create monthly costs ({billed_month}): {job_id}, {job_task} (count = {row_count})"
f"[_aggregate_monthly_cost_data] create monthly costs ({billed_month}): {job_id}, {job_task_id} (count = {row_count})"
)

def _get_all_data_sources(self):
Expand Down
Loading