tirkarthi commented on PR #35863:
URL: https://github.com/apache/airflow/pull/35863#issuecomment-1894981925

   echarts also provides a mechanism to mark a line with average value. Below 
is code and a sample with average run duration and average queued duration of 
the series marked.
   
   
![image](https://github.com/apache/airflow/assets/3972343/58b20d80-b14a-42ac-9b82-8acfd158ca37)
   
   
   ```diff
   diff --git a/airflow/www/static/js/dag/details/task/TaskDuration.tsx 
b/airflow/www/static/js/dag/details/task/TaskDuration.tsx
   index 1f99f39e4d..7ce2e8aed9 100644
   --- a/airflow/www/static/js/dag/details/task/TaskDuration.tsx
   +++ b/airflow/www/static/js/dag/details/task/TaskDuration.tsx
   @@ -155,6 +155,9 @@ const TaskDuration = () => {
              opacity: 0.6,
            },
            stack: "x",
   +        markLine: {
   +          data: [{ type: "average", name: "Avg" }],
   +        },
          },
          {
            type: "bar",
   @@ -164,6 +167,9 @@ const TaskDuration = () => {
              color: (params) => stateColors[params.data.state],
            },
            stack: "x",
   +        markLine: {
   +          data: [{ type: "average", name: "Avg" }],
   +        },
          },
        ],
        // @ts-ignore
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to