File tree Expand file tree Collapse file tree 1 file changed +7
-25
lines changed
packages/pynumaflow-lite/manifests/sink Expand file tree Collapse file tree 1 file changed +7
-25
lines changed Original file line number Diff line number Diff line change @@ -6,41 +6,23 @@ To create the `wheel` file, refer [root](../../README.md)
66docker build . -t quay.io/numaio/numaflow/pynumaflow-lite-sink-log:v1 --load
77```
88
9+ ### ` k3d `
10+
911Load it now to ` k3d `
1012
1113``` bash
1214k3d image import quay.io/numaio/numaflow/pynumaflow-lite-sink-log:v1
1315```
1416
15- ## Run the pipeline
17+ ### Minikube
1618
1719``` bash
18- kubectl apply -f pipeline.yaml
20+ minikube image load quay.io/numaio/numaflow/pynumaflow-lite-sink-log:v1
1921```
2022
21- ## Example: Using different response types
22-
23- The sink implementation supports all 5 response types:
24-
25- ``` python
26- # Success - write was successful
27- responses.append(sinker.Response.as_success(msg.id))
28-
29- # Failure - write failed with error message
30- responses.append(sinker.Response.as_failure(msg.id, " Database connection failed" ))
31-
32- # Fallback - forward to fallback sink
33- responses.append(sinker.Response.as_fallback(msg.id))
34-
35- # Serve - write to serving store with payload
36- responses.append(sinker.Response.as_serve(msg.id, b " serving data" ))
23+ ## Run the pipeline
3724
38- # OnSuccess - forward to onSuccess store with optional message
39- message = sinker.Message(
40- value = b " processed data" ,
41- keys = [" key1" , " key2" ],
42- user_metadata = {" meta" : sinker.KeyValueGroup.from_dict({" k" : b " v" })}
43- )
44- responses.append(sinker.Response.as_on_success(msg.id, message))
25+ ``` bash
26+ kubectl apply -f pipeline.yaml
4527```
4628
You can’t perform that action at this time.
0 commit comments