msumit commented on code in PR #71220:
URL: https://github.com/apache/airflow/pull/71220#discussion_r3872741953


##########
airflow-core/src/airflow/models/pool.py:
##########
@@ -92,6 +92,26 @@ class Pool(Base):
     def __repr__(self):
         return str(self.pool)
 
+    @staticmethod
+    def get_include_deferred_override() -> bool | None:
+        """
+        Get the cluster-wide ``include_deferred`` value fixed via config, if 
any.
+
+        When ``[core] pool_include_deferred`` is set, its value applies to 
every pool and takes
+        precedence over the per-pool ``include_deferred`` column. Returns None 
when unset.
+        """
+        from airflow.configuration import conf
+
+        if conf.get("core", "pool_include_deferred", fallback=""):
+            return conf.getboolean("core", "pool_include_deferred")
+        return None
+
+    @property
+    def effective_include_deferred(self) -> bool:

Review Comment:
   yeah, but it means we've to keep option open in UI, API, and CLI, accepting 
the values but not honoring it eventually. It's better to not accept it and 
model their usage around the value set by the admin only. Also, there won't be 
any right or wrong behaviour is possible, ideally I don't expect admins to play 
around with this setting, for e.g. it'll always be set to true in our usecase. 



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