Mady356 commented on code in PR #69007:
URL: https://github.com/apache/airflow/pull/69007#discussion_r3480109283


##########
airflow-core/src/airflow/config_templates/config.yml:
##########
@@ -2743,6 +2743,24 @@ scheduler:
       type: integer
       default: "20"
       see_also: ":ref:`scheduler:ha:tunables`"
+    dag_cache_size:
+      description: |
+        Size of the LRU cache for SerializedDAG objects in the scheduler.
+        Set to 0 to use an unbounded dict with no eviction.
+        The cache is keyed by Dag version ID.
+      version_added: 3.3.0
+      type: integer
+      example: ~
+      default: "1024"
+    dag_cache_ttl:
+      description: |
+        Time-to-live in seconds for cached SerializedDAG objects in the 
scheduler.
+        After this time, cached DAGs will be re-fetched from the database on 
next access.
+        Set to 0 to disable TTL, so entries will only be evicted by the LRU 
policy.
+      version_added: 3.3.0
+      type: integer
+      example: ~
+      default: "3600"

Review Comment:
   Thanks, good point. I updated DBDagBag to accept a stats_prefix and pass 
scheduler.dag_bag from the scheduler path, so scheduler cache metrics are no 
longer emitted under the API server prefix. I also changed the scheduler cache 
TTL default to 10800 seconds.



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