jkinkead commented on PR #24499:
URL: https://github.com/apache/airflow/pull/24499#issuecomment-1164621596

   The `cache_ok` flag is confusing: It doesn't describe whether you can cache 
_prepared_ values (the return values of `process_bind_param`), it describes 
whether you can use the _instance of the type itself_ in caching the SQL 
statement the type is referenced in. Since these types are stateless and have 
static configuration, they're fine to use in the statement cache (they all 
prepare bind params identically).
   
   See [this section of the SQLAlchemy 
docs](https://docs.sqlalchemy.org/en/14/core/connections.html#cache-key-generation)
 on how cache keys are generated.
   
   Using a `False` here would exclude any statements with these columns from 
the SQLAlchemy statement cache, so it would have some performance implications.


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