You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "danielpina-hei (via GitHub)" <gi...@apache.org> on 2023/05/10 08:06:18 UTC

[GitHub] [pulsar-helm-chart] danielpina-hei opened a new issue, #362: Stateful functions don't work

danielpina-hei opened a new issue, #362:
URL: https://github.com/apache/pulsar-helm-chart/issues/362

   **Describe the bug**
   Stateful functions do not work with the helm chart deployments.  There are no options to enable this feature and set the state store in the bookkeepers as per the pulsar docs (non-kubernetes deployment) https://pulsar.apache.org/docs/2.10.x/functions-worker/#configure-stateful-functions-to-run-with-broker (v2.10) & https://pulsar.apache.org/docs/2.11.x/functions-worker-stateful/ (v2.11 onwards)
   
   **To Reproduce**
   Steps to reproduce the behavior:
   1. Deploy pulsar into eks via helm charts using `defaultPulsarImageTag:` set to  `2.10.4` in values.yaml or any other later version such as `2.11.1` and `3.0.0`
   2. Create stateful functions
   3. Send messages to the topic the function is listening to
   4. See error
   ```
   2023-05-09T15:53:01,852+0000 [public/tracking/playStartFunction-0] ERROR function-playStartFunction - Failed to process multi-cam message
   java.lang.IllegalStateException: State public/tracking/playStartFunction is not enabled.
   	at com.google.common.base.Preconditions.checkState(Preconditions.java:840) ~[java-instance.jar:?]
   	at org.apache.pulsar.functions.instance.ContextImpl.ensureStateEnabled(ContextImpl.java:377) ~[?:?]
   	at org.apache.pulsar.functions.instance.ContextImpl.getState(ContextImpl.java:439) ~[?:?]
   	at com.hawkeyeinnovations.baseball.functions.PlayStartFunction.process(PlayStartFunction.java:72) ~[functions10786300416485873108.tmp:?]
   	at com.hawkeyeinnovations.baseball.functions.PlayStartFunction.process(PlayStartFunction.java:25) ~[functions10786300416485873108.tmp:?]
   	at org.apache.pulsar.functions.instance.JavaInstance.handleMessage(JavaInstance.java:94) ~[?:?]
   	at org.apache.pulsar.functions.instance.JavaInstanceRunnable.run(JavaInstanceRunnable.java:290) ~[?:?]
   	at java.lang.Thread.run(Thread.java:829) ~[?:?]
   ```
   
   **Expected behavior**
   Function should process messages as normal.
   
   **Desktop (please complete the following information):**
    - k8s: v1.25
    - helm charts: master branch
    - pulsar version: v2.10.4 (also 2.11 and 3.0.0)
    - helm version: v3.11.0
   
   **Additional context**
   Did some search and found and abandoned PR that addresses this however doesn't seem to work : https://github.com/apache/pulsar-helm-chart/pull/171 . This is applicable to v2.10
   Attempted to continue this by making it more complete. 
   values.yaml
   ```
   bookkeeper:
     ports:
       statestore: 4181
   ```
   then added to bookkeeper-configmap.yml
   `extraServerComponents: "org.apache.bookkeeper.stream.server.StreamStorageLifecycleComponent"`
   to bookkeeper-service.yml (in order to open port)
   ```
     - name: "{{ .Values.tcpPrefix }}statestore"
       port: {{ .Values.bookkeeper.ports.statestore }}
   ```      
   and broker-configmap.yml set bookies as state store:
   `PF_stateStorageServiceUrl: "bk://{{ template "pulsar.fullname" . }}-{{ .Values.bookkeeper.component }}:{{ .Values.bookkeeper.ports.statestore }}"`
   
   Then install with local charts :
   `helm install bdp-005 ./charts/pulsar --values ./charts/pulsar/values.yaml`
   
   Results in the same error.
   


-- 
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: commits-unsubscribe@pulsar.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [pulsar-helm-chart] michaeljmarshall closed issue #362: Stateful functions don't work

Posted by "michaeljmarshall (via GitHub)" <gi...@apache.org>.
michaeljmarshall closed issue #362: Stateful functions don't work
URL: https://github.com/apache/pulsar-helm-chart/issues/362


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [pulsar-helm-chart] michaeljmarshall commented on issue #362: Stateful functions don't work

Posted by "michaeljmarshall (via GitHub)" <gi...@apache.org>.
michaeljmarshall commented on issue #362:
URL: https://github.com/apache/pulsar-helm-chart/issues/362#issuecomment-1641295012

   This issue was fixed by #171


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org