You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,16 +9,16 @@
9
9
New methods let an entry point process a Data Lake Object's Change Data Feed continuously instead of reading a bounded snapshot:
10
10
11
11
-`read_dlo_deltas(name)` / `read_dmo_deltas(name)` – return a streaming DataFrame over the object's change feed.
12
-
-`write_dlo_deltas(name, dataframe, write_mode)` – start a streaming query that writes each micro-batch to the target DLO and return the `StreamingQuery` handle.
12
+
-`write_dlo_deltas(name, dataframe)` – start a streaming query that writes each micro-batch to the target DLO and return the `StreamingQuery` handle.
Supported streaming write modes are `WriteMode.APPEND`, `WriteMode.OVERWRITE`, and `WriteMode.MERGE_UPSERT_DELETE`. These methods run only inside the Data Cloud streaming (`DELTA_SYNC`) runtime; locally they raise `NotImplementedError`. See the `examples/streaming_deltas/entrypoint.py` example and the "Streaming (delta) transforms" section of the README.
21
+
These methods run only inside the Data Cloud streaming (`DELTA_SYNC`) runtime; locally they raise `NotImplementedError`. See the `examples/streaming_deltas/entrypoint.py` example and the "Streaming (delta) transforms" section of the README.
Copy file name to clipboardExpand all lines: README.md
+5-9Lines changed: 5 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -157,7 +157,7 @@ You should only need the following methods:
157
157
For streaming (delta) transforms, the streaming counterparts are:
158
158
*`read_dlo_deltas(name)` – Read the streaming change feed (deltas) of a Data Lake Object as a streaming DataFrame
159
159
*`read_dmo_deltas(name)` – Read the streaming change feed (deltas) of a Data Model Object as a streaming DataFrame
160
-
*`write_dlo_deltas(name, spark_dataframe, write_mode)` – Write a streaming DataFrame of deltas to a Data Lake Object; returns the started `StreamingQuery`
160
+
*`write_dlo_deltas(name, spark_dataframe)` – Write a streaming DataFrame of deltas to a Data Lake Object; returns the started `StreamingQuery`
161
161
162
162
For example:
163
163
```python
@@ -182,28 +182,24 @@ Streaming BYOC transforms process a Data Lake Object's Change Data Feed continuo
182
182
from pyspark.sql.functions import col, upper
183
183
184
184
from datacustomcode import Client
185
-
from datacustomcode.io.writer.base import WriteMode
186
185
187
186
client = Client()
188
187
189
188
# read_dlo_deltas returns a *streaming* DataFrame over the change feed.
190
189
deltas = client.read_dlo_deltas("Input__dll")
191
190
192
-
# Ordinary PySpark transform. Keep the change-feed metadata columns
193
-
# (those starting with "_") — the streaming sink needs them to apply
194
-
# inserts, updates, and deletes to the target DLO.
- Supported streaming write modes are `WriteMode.APPEND`, `WriteMode.OVERWRITE`, and `WriteMode.MERGE_UPSERT_DELETE`.
207
203
- These methods only run inside the Data Cloud streaming (`DELTA_SYNC`) runtime. Locally (`datacustomcode run`) they raise `NotImplementedError`, since there is no change feed to stream.
208
204
- A complete runnable entry point is provided in [`examples/streaming_deltas/entrypoint.py`](src/datacustomcode/templates/script/examples/streaming_deltas/entrypoint.py).
0 commit comments