kaxil commented on code in PR #73722:
URL: https://github.com/apache/airflow/pull/73722#discussion_r4109608019


##########
airflow-core/src/airflow/config_templates/config.yml:
##########
@@ -759,7 +759,8 @@ database:
       default: ~
     max_db_retries:
       description: |
-        Number of times the code should be retried in case of DB Operational 
Errors.
+        Total number of attempts (including the initial attempt) the code 
should make
+        in case of DB Operational Errors, before giving up.
         Not all transactions will be retried as it can cause undesired state.
         Currently it is only used in ``DagFileProcessor.process_file`` to 
retry ``dagbag.sync_to_db``.

Review Comment:
   Thanks for picking this up. Since you're already editing this description, 
can you drop the last sentence too? It stopped being true a long time ago: 
`max_db_retries` is now used by the scheduler, `DagRun`, `Trigger`, 
`TaskInstance`, `RenderedTaskInstanceFields`, `DagWarning` and the dag 
processor manager, not only `DagFileProcessor.process_file`.
   
   I'd also spell out what the default means, since "attempts ... in case of DB 
Operational Errors" reads as if the attempts only start after an error:
   
   ```suggestion
           Maximum number of attempts, including the first one, for operations 
retried on DB
           operational errors. The default of 3 means one initial attempt plus 
up to 2 retries.
           Not all transactions are retried, since retrying some of them can 
leave undesired state.
   ```



-- 
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