Bug #24657
openDatasource initial request timeout is zero and has confusing error
Description
When creating a new datasource and set the update trigger to "Update when a policy generation starts", the datasource will cause a policy generation error unless we fill HTTP request timeout
, a hidden parameter under Advanced option
, with a non-zero value.
The policy generation error is not very informative : ERROR policy.generation.manager - Policy update error for process '69' at 2024-04-03 14:25:02: Unexpected: Inconsistency: Timeout error after 0 ns
.
But in the webapp logs we can find out that this is due to an error when fetching datasources, but it is still not clear that 0
is the default value under Advanced options
and that it needs to be changed for it to work :
2024-04-03 14:24:52+0200 ERROR datasources - Error when fetching data from data source 'new_datasource_test_update' (new_datasource_test_update) for all nodes; cause was: Inconsistency: Timeout error after 0 ns
2024-04-03 14:24:52+0200 INFO policy.generation.timing - Policy generation failed after:
2024-04-03 14:24:52+0200 ERROR policy.generation.manager - Error when updating policy, reason was: Unexpected: Inconsistency: Timeout error after 0 ns
Also (probably deserves its own ticket), when the parameter below, Data source update max duration
, is 0
, it causes the same problem (and the same error logs), even with other kinds of update trigger
.
We should have different default values, or consider the 0 timeout to be "infinite"
No data to display