influxdata / influxdata/influxdb

"Manually start a task run, overriding the current schedule" API request inconsisten behaviour

Open
#20,446 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
31.7k
Forks
3.7k
Avg merge
13h 37m
Merged PRs (30d)
8

Description

I'm on Version 2.0.2 (84496e5) and I'm pretty sure this API request didn't behave like this in 2.0.1 or something.
First of all, on the docs it says https://docs.influxdata.com/influxdb/v2.0/api/#operation/PostTasksIDRuns that the returning JSON has the `log` field which I'm very much not getting:
![image](https://user-images.githubusercontent.com/6378638/103652760-de029580-4f63-11eb-8a8c-0dd11e32549f.png)

second and important: is the request supposed to wait for the task to finish and return the result or not? How can the request return status `scheduled` for a task which has no `scheduledFor` parameter and hence should run immediately? The task in question fails.

1. fix the response JSON type to show "logs" is optional
2. clarify whether the request waits for the task to finish if it's supposed to run immediately
3. fix returning "scheduled" if the task failed

Contributor guide

Open the contributing guide

Research direction

Start with the PostTasksIDRuns endpoint and compare its documented response with the behavior reported against version 2.0.2. Trace how an immediate task run is scheduled and how its status and logs are represented. Done means the response schema, waiting behavior, and failed-task status are clarified or corrected consistently.

Written by the indexing model from the issue text.

Assessment

Domain
api, backend, documentation
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.