commit | 6b8ff3f1ab7be8e83f7293496d672a19bc76d13f | [log] [tgz] |
---|---|---|
author | Jiwei Guo <technoboy@apache.org> | Wed Apr 12 15:39:31 2023 +0800 |
committer | GitHub <noreply@github.com> | Wed Apr 12 15:39:31 2023 +0800 |
tree | a994bc554064f2bf2af82cf2b0cbb5dd202e60ff | |
parent | 728554d08755b86ac3090504d0121adf6de79520 [diff] |
[improve][doc] Improve Pulsar function document (#20073)
diff --git a/distribution/server/src/assemble/bin.xml b/distribution/server/src/assemble/bin.xml index 12c443d..92aef62 100644 --- a/distribution/server/src/assemble/bin.xml +++ b/distribution/server/src/assemble/bin.xml
@@ -116,6 +116,11 @@ <destName>example-window-function-config.yaml</destName> <outputDirectory>examples</outputDirectory> </file> + <file> + <source>${basedir}/../../pulsar-functions/java-examples/src/main/resources/example-stateful-function-config.yaml</source> + <destName>example-stateful-function-config.yaml</destName> + <outputDirectory>examples</outputDirectory> + </file> </files> <dependencySets> <dependencySet>
diff --git a/pulsar-functions/java-examples/src/main/resources/example-function-config.yaml b/pulsar-functions/java-examples/src/main/resources/example-function-config.yaml index a66b75f..1f185a2 100644 --- a/pulsar-functions/java-examples/src/main/resources/example-function-config.yaml +++ b/pulsar-functions/java-examples/src/main/resources/example-function-config.yaml
@@ -22,9 +22,6 @@ name: "example" className: "org.apache.pulsar.functions.api.examples.ExclamationFunction" inputs: ["test_src"] -userConfig: - "PublishTopic": "test_result" - output: "test_result" autoAck: true parallelism: 1
diff --git a/pulsar-functions/java-examples/src/main/resources/example-stateful-function-config.yaml b/pulsar-functions/java-examples/src/main/resources/example-stateful-function-config.yaml index 605b6b0d..5a6827a 100644 --- a/pulsar-functions/java-examples/src/main/resources/example-stateful-function-config.yaml +++ b/pulsar-functions/java-examples/src/main/resources/example-stateful-function-config.yaml
@@ -19,12 +19,10 @@ tenant: "test" namespace: "test-namespace" -name: "stateful-example" +name: "word_count" className: "org.apache.pulsar.functions.api.examples.WordCountFunction" inputs: ["test_stateful_src"] -userConfig: - "PublishTopic": "test_stateful_result" - -output: "test_stateful_result" +inputs: ["test_wordcount_src"] +output: "test_wordcount_result" autoAck: true parallelism: 1
diff --git a/pulsar-functions/java-examples/src/main/resources/example-window-function-config.yaml b/pulsar-functions/java-examples/src/main/resources/example-window-function-config.yaml index e0faf6f..3edba31 100644 --- a/pulsar-functions/java-examples/src/main/resources/example-window-function-config.yaml +++ b/pulsar-functions/java-examples/src/main/resources/example-window-function-config.yaml
@@ -22,9 +22,6 @@ name: "example" className: "org.apache.pulsar.functions.api.examples.AddWindowFunction" inputs: ["test_src"] -userConfig: - "PublishTopic": "test_result" - output: "test_result" autoAck: true parallelism: 1