This is an automated email from the ASF dual-hosted git repository.
amoghdesai pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push:
new 23965c4aa5c Nuke orm_deserialize_value refs in docs and docstring
(#49220)
23965c4aa5c is described below
commit 23965c4aa5ca38e6a0e234f3fa215ab84e3b800d
Author: Amogh Desai <[email protected]>
AuthorDate: Mon Apr 14 21:14:45 2025 +0530
Nuke orm_deserialize_value refs in docs and docstring (#49220)
---
airflow-core/docs/core-concepts/xcoms.rst | 2 --
task-sdk/src/airflow/sdk/bases/xcom.py | 9 +++------
2 files changed, 3 insertions(+), 8 deletions(-)
diff --git a/airflow-core/docs/core-concepts/xcoms.rst
b/airflow-core/docs/core-concepts/xcoms.rst
index 67f87f32fb6..b5259887376 100644
--- a/airflow-core/docs/core-concepts/xcoms.rst
+++ b/airflow-core/docs/core-concepts/xcoms.rst
@@ -93,8 +93,6 @@ The XCom system has interchangeable backends, and you can set
which backend is b
If you want to implement your own backend, you should subclass
:class:`~airflow.models.xcom.BaseXCom`, and override the ``serialize_value``
and ``deserialize_value`` methods.
-There is also an ``orm_deserialize_value`` method that is called whenever the
XCom objects are rendered for UI or reporting purposes; if you have large or
expensive-to-retrieve values in your XComs, you should override this method to
avoid calling that code (and instead return a lighter, incomplete
representation) so the UI remains responsive.
-
You can also override the ``clear`` method and use it when clearing results
for given dags and tasks. This allows the custom XCom backend to process the
data lifecycle easier.
Verifying Custom XCom Backend usage in Containers
diff --git a/task-sdk/src/airflow/sdk/bases/xcom.py
b/task-sdk/src/airflow/sdk/bases/xcom.py
index 4129f265462..b8b301e1511 100644
--- a/task-sdk/src/airflow/sdk/bases/xcom.py
+++ b/task-sdk/src/airflow/sdk/bases/xcom.py
@@ -130,8 +130,7 @@ class BaseXCom:
Retrieve an XCom value for a task instance.
This method returns "full" XCom values (i.e. uses ``deserialize_value``
- from the XCom backend). Use :meth:`get_many` if you want the
"shortened"
- value via ``orm_deserialize_value``.
+ from the XCom backend).
If there are no results, *None* is returned. If multiple XCom entries
match the criteria, an arbitrary one is returned.
@@ -162,8 +161,7 @@ class BaseXCom:
Retrieve an XCom value, optionally meeting certain criteria.
This method returns "full" XCom values (i.e. uses ``deserialize_value``
- from the XCom backend). Use :meth:`get_many` if you want the
"shortened"
- value via ``orm_deserialize_value``.
+ from the XCom backend).
If there are no results, *None* is returned. If multiple XCom entries
match the criteria, an arbitrary one is returned.
@@ -220,8 +218,7 @@ class BaseXCom:
Retrieve an XCom value, optionally meeting certain criteria.
This method returns "full" XCom values (i.e. uses ``deserialize_value``
- from the XCom backend). Use :meth:`get_many` if you want the
"shortened"
- value via ``orm_deserialize_value``.
+ from the XCom backend).
If there are no results, *None* is returned. If multiple XCom entries
match the criteria, an arbitrary one is returned.