-
Notifications
You must be signed in to change notification settings - Fork 29
Sample - Workflow2 #65
Comments
hey @andreatosato, you need to set up a Service Bus and State Store with Dapr. These are covered in the Dapr docs here: https://github.com/dapr/docs/tree/master/howto/setup-state-store#reference |
deploy.yaml apiVersion: apps/v1
kind: Deployment
metadata:
name: dapr-workflows-host
labels:
app: dapr-workflows-host
spec:
replicas: 1
selector:
matchLabels:
app: dapr-workflows-host
template:
metadata:
labels:
app: dapr-workflows-host
annotations:
dapr.io/id: "workflows"
dapr.io/enabled: "true"
dapr.io/port: "50003"
dapr.io/protocol: "grpc"
spec:
containers:
- name: host
image: daprio/workflows:0.2.2
env:
- name: STORAGE_ACCOUNT_KEY
valueFrom:
secretKeyRef:
name: dapr-workflows
key: accountKey
- name: STORAGE_ACCOUNT_NAME
valueFrom:
secretKeyRef:
name: dapr-workflows
key: accountName
command: ["dotnet"]
args: ["app/Dapr.Workflows.dll", "--workflows-path", "/workflows"]
ports:
- containerPort: 50003
imagePullPolicy: Always
volumeMounts:
- name: workflows
mountPath: /workflows
volumes:
- name: workflows
configMap:
name: workflows cosmos.yaml apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
name: statestore
spec:
type: state.azure.cosmosdb
metadata:
- name: url
value: https://daprstatetosato.documents.azure.com:443
- name: masterKey
value: eEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE==
- name: database
value: state
- name: collection
value: dapr azuresb.yaml apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
name: pubsub
namespace: default
spec:
type: pubsub.azure.servicebus
metadata:
- name: connectionString
value: Endpoint=sb://daprbustosato.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=e44444444444444444444444= # Required. Error:
My commands:
Where is my error? @yaron2 |
maybe? time="2020-10-18T17:01:17.5400839Z" level=warning msg="failed to init actors: state store does not support transactions which actors require to save state - please see https://github.com/dapr/docs" app_id=workflows instance=dapr-workflows-host-6f9bb59f5f-gtpl4 scope=dapr.runtime type=log ver=0.11.2 |
Now i configure redis:
Or But not work! |
Full container log:
|
After re-create redis, I have this error:
I have changed my yaml redis like this, but there is error either no actor state store or multiple actor state stores are specified in the configuration, actor stores specified: 0: apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
name: statestore
namespace: default
spec:
type: state.redis
metadata:
- name: redisHost
value: redis-master.default.svc.cluster.local:6379
- name: redisPassword
value: OxfY3mNISM
- name: enableTLS
value: false
- name: actorStateStore
value: "true" |
That error is safe to ignore for this scenario, unless you are using actors. So if you're still getting an error, it's not because of the actor state store. Can you remove the enableTLS field entirely from the YAML, restart the pod and try again? |
I have already tried, but not work. |
What error are you getting when invoking the workflow? |
{
"error": {
"code": "NoResponse",
"message": "The server did not received a response from an upstream server. Request tracking id '08585995089540340895731183776CU00'."
}
} |
I'll look into it this week. |
Ok, thanks, friday I have an community event 🙏 |
@yaron2 do you have any news? |
Is there an example that can be run locally without using any Azure services? |
Hi,
I run successfull workflow1 but workflow2 report this error:
How can I run workflow2?
I must create servicebus and store container but there isn't in deploy file o in docs. Could this be the mistake?
Thanks a lot
The text was updated successfully, but these errors were encountered: