kruize / autotune

Autonomous Performance Tuning for Kubernetes!
Apache License 2.0
165 stars 54 forks source link

time_range fix #1378

Closed msvinaykumar closed 2 days ago

msvinaykumar commented 2 days ago

Description

The latest MVP code is encountering this issue: #1377.

The problem occurs because query_range is being called with start=0, end=0, and step=0 when the request payload is empty, resulting in a 400 error.

The proposed fix is to avoid using query_range in PromQL if the time_range is not provided. Instead, use the query parameter.

Fixes # (issue)

Type of change

How has this been tested?

Please describe the tests that were run to verify your changes and steps to reproduce. Please specify any test configuration required.

Test Configuration

Checklist :dart:

Additional information

Include any additional information such as links, test results, screenshots here

dinogun commented 2 days ago

@msvinaykumar How has this been tested?

msvinaykumar commented 2 days ago

@msvinaykumar How has this been tested?

I used

./bulk_service_demo.sh -c openshift -i quay.io/vinakuma/autotune_operator:shk

it ran successfully