question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

example 4 not working

See original GitHub issue

I’ve tried to set up example 4 with a local redis, but it isn’t working. Here’s what I’ve done:

  1. Everything is running in minikube. If used the “non-helm” setup, so everything is in the default namespace in my minikube cluster.
  2. Added a redis deployment/service like so:
kind: Service
apiVersion: v1
metadata:
  name: redis-service
  labels:
    app: redis-service
spec:
  selector:
    app: redis-service
  ports:
  - protocol: TCP
    port: 6379
    targetPort: 6379
  type: NodePort

---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: redis-service
  labels:
    app: redis-service
spec:
  replicas: 1
  selector:
    matchLabels:
      app: redis-service
  template:
    metadata:
      labels:
        app: redis-service
    spec:
      containers:
      - name: redis-service
        image: redis
        command: ["redis-server", "--requirepass", "yourpassword"]
        ports:
        - containerPort: 6379
        imagePullPolicy: Always

configured the redis.yml file:

apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
  name: messagebus
spec:
  type: pubsub.redis
  metadata:
  - name: "redisHost"
    value: "redis-service.default.svc.cluster.local:6379"
  - name: "redisPassword"
    value: "yourpassword"

I’ve used kubectl port-forward to verify that the redis instance is indeed working using the specified password.

The react-app has problems when starting (output from the daprd sidecar):

time="2019-11-14T20:05:34Z" level=error msg="error getting topics from app: invalid character '<' looking for beginning of value"
time="2019-11-14T20:05:34Z" level=warning msg="failed to init actors: actors: state store must be present to initialize the actor runtime"

The other pods also log errors (output from the daprd sidecars):

time="2019-11-14T20:04:57Z" level=warning msg="failed to init actors: actors: state store must be present to initialize the actor runtime"
time="2019-11-14T20:04:57Z" level=info msg="http server is running on port 3500"
time="2019-11-14T20:04:57Z" level=info msg="gRPC server is running on port 50001"
time="2019-11-14T20:04:57Z" level=info msg="dapr initialized. Status: Running. Init Elapsed 38.008444000000004ms"

as far as I can see there’s very little health checking going on here (both in the apps and in dapr itself), giving the impression that everything is running as it should when in fact nothing is working.

I just cloned the samples repo just to see what dapr is about, apart from it looking like an interesting thing.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:8 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
WhoAteDaCakecommented, Feb 20, 2021

Still having this problem

error getting topics from app: invalid character ‘<’ looking for beginning of value

with the dapr release 1.0.0. Only happens on react-form, if I attempt to publish via cli:

dapr publish --publish-app-id react-form --pubsub pubsub --topic A --data '{ "message": "This is a test" }'

I receive:

Error publishing topic A: couldn’t find a running Dapr instance

Even though everything is running:

(base) ubuntu@ubuntu-7876-0224A:~/projects/dapr/quickstarts/pub-sub/react-form$ dapr list
  APP ID             HTTP PORT  GRPC PORT  APP PORT  COMMAND         AGE  CREATED              PID      
  python-subscriber  43245      40879      5000      python3 app.py  44m  2021-02-20 11:43.07  2073726  
  node-subscriber    41183      43375      3000      node app.js     18m  2021-02-20 12:09.46  2087706 

(base) ubuntu@ubuntu-7876-0224A:~/projects/dapr/quickstarts/pub-sub/react-form$ docker ps
CONTAINER ID        IMAGE                   COMMAND                  CREATED             STATUS                  PORTS                              NAMES
957b95d7bde7        daprio/dapr             "./placement"            2 minutes ago       Up 2 minutes            0.0.0.0:50005->50005/tcp           dapr_placement
94e5b8b9ed1d        redis                   "docker-entrypoint.s…"   23 hours ago        Up 2 minutes            0.0.0.0:6379->6379/tcp             dapr_redis
8ab252fdd0e2        openzipkin/zipkin       "start-zipkin"           23 hours ago        Up 13 hours (healthy)   9410/tcp, 0.0.0.0:9411->9411/tcp   dapr_zipkin

Checked the redis version inside the container, it’s v=6.0.10

0reactions
drmcgheecommented, Feb 27, 2020

Yep… docker pull redis:latest and with Redis 5.0.7 works. I guess the key is in the documentation " enabled in Redis versions => 5". Realistically the DAPR init should get the correct docker image! 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Material Angular expansion-panel example not working
Go to app.modules.js and change in imports: remove NoopAnimationsModule; add BrowserAnimationsModule. In app.modules.js.
Read more >
Not sure why this code doesn't work - simplest example I ...
After testing your code line by line, it comes down to the default case. For some reason the SCT is seeing the word...
Read more >
Troubleshooting - What to do when it won't work! - YouTube
And, many times, when I ask for more details it becomes obvious that they ... But, by using a systematic approach to troubleshooting...
Read more >
What is troubleshooting and why is it important?
Troubleshooting is systematic approach to problem-solving. Learn how it works, the seven steps troubleshooters often use and other helpful resources.
Read more >
Excel VLOOKUP not working - fixing #N/A and #VALUE ...
Is your VLOOKUP pulling wrong data or you cannot get it to work at all? This tutorial shows how you can quickly fix...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found