conductor-oss / conductor-oss/conductor
[Bug] Http Task executed twice after COMPLETED status [read thread for workaround]
- Dominant language
- Java
- Stars
- 32.2k
- Forks
- 1k
- Avg merge
- 2d 5h
- Merged PRs (30d)
- 41
Description
### Describe the bug
When an HTTP task completes successfully and triggers a downstream HTTP task, but the upstream task simultaneously schedules another execution.
From below screenshot, I executed a time-consuming http task, when the first task has successfully executed, and downstream task also has completed. But the first task triggered another scheduling. Please help to explain the reason why will trigger this scenario. Thanks!
#### Found another bug
When executed a time-consuming http task, I found conductor request four times for one HTTP task until the first request get response from server. Screenshot attached below.
Conductor log: Execute four times on one http task
Request server log: Got four requests from conductor http request
**Details**
Conductor version: 3.21.19
Persistence implementation: Postgres
Queue implementation: Postgres
Lock: Redis
**Expected behavior**
Workflow task should execute in sequence once the upstream task has completed.
**Workflow definition**
```json
"tasks": [
{
"name": "cmp_iac_validate",
"taskReferenceName": "sleep0",
"inputParameters": {
"http_request": {
"headers": {},
"method": "POST",
"readTimeOut": 300000,
"body": {
"retryNum": "0",
"test": "false",
"param": "test",
"orderRequestTaskId": "78591038-453b-42f2-953a-0c4aa962dc0d",
"platform": "SELF",
"retrySleepTime": "299000"
},
"uri": "http://xxx.com/iac/v1/execute/xxx",
"connectionTimeOut": 3600000
},
"_executor_": "${workflow.input._executor_}"
},
"type": "HTTP",
"decisionCases": {},
"defaultCase": [],
"forkTasks": [],
"startDelay": 0,
"joinOn": [],
"optional": false,
"defaultExclusiveJoinTask": [],
"asyncComplete": false,
"loopOver": [],
"onStateChange": {},
"permissive": false
},
{
"name": "cmp_iac_validate",
"taskReferenceName": "normal",
"inputParameters": {
"http_request": {
"headers": {},
"method": "POST",
"readTimeOut": 300000,
"body": {
"retryNum": "0",
"test": "false",
"param": "SELF",
"orderRequestTaskId": "c7958c72-30cf-416b-9938-bf305f93d961",
"platform": "SELF",
"retrySleepTime": "0"
},
"uri": "http://xxx.com/iac/v1/execute/xxx",
"connectionTimeOut": 3600000
},
"_executor_": "${workflow.input._executor_}"
},
"type": "HTTP",
"decisionCases": {},
"defaultCase": [],
"forkTasks": [],
"startDelay": 0,
"joinOn": [],
"optional": false,
"defaultExclusiveJoinTask": [],
"asyncComplete": false,
"loopOver": [],
"onStateChange": {},
"permissive": false
},
...
]
```
**Configuration file**
```
# See README in the docker for configuration guide
# db.type determines the type of database used
# See various configurations below for the values
#conductor.db.type=SET_THIS
# =====================================================#
# Redis Configuration Properties
# =====================================================#
# The last part MUST be us-east-1c, it is not used and is kept for backwards compatibility
conductor.redis.hosts=xxxx.com:6379:us-east-1c:xxx
conductor.redis.workflowNamespacePrefix=conductor
conductor.redis.queueNamespacePrefix=conductor_queues
conductor.redis.taskDefCacheRefreshInterval=60
conductor.redis.availabilityZone=us-east-1c
conductor.redis.queuesNonQuorumPort=22122
conductor.redis.ssl=false
conductor.queue.type=postgres
conductor.external-payload-storage.type=postgres
# Redis cluster settings for locking module
conductor.redis-lock.server-address=redis://:xxxx@xxxx.com:6379
#conductor.app.workflow-execution-lock-enabled=true
conductor.workflow-execution-lock.type=redis
conductor.redis-lock.server-type=SINGLE
conductor.redis-lock.namespace=conductorlock
conductor.app.workflowExecutionLockEnabled=true
conductor.app.lockLeaseTime=60000ms
conductor.app.lockTimeToTry=500ms
# The interval after which a system task will be checked by the system task worker for completion. Example: 30s
conductor.app.systemTaskWorkerCallbackDuration=30s
conductor.app.systemTaskWorkerThreadCount=20
conductor.app.systemTaskMaxPollCount=20
# The interval at which system task queues will be polled by system task workers. Example: 50ms
conductor.app.systemTaskWorkerPollInterval=50ms
# =====================================================#
# Postgres Configuration Properties
# =====================================================#
conductor.db.type=postgres
spring.datasource.url=jdbc:postgresql://xxxx.com:3433/conductor_00
spring.datasource.username=xxxx
spring.datasource.password=xxxx
# When using Elasticsearch 7 for indexing, set the following
conductor.indexing.enabled=true
conductor.elasticsearch.url=xxxx:9800
conductor.elasticsearch.version=7
conductor.elasticsearch.indexName=conductor
conductor.elasticsearch.clusterHealthColor=yellow
conductor.metrics-prometheus.enabled=false
management.metrics.export.prometheus.enabled=false
loadSample=false
```
**Screenshots**
Contributor guide
Assessment
This issue has not been assessed yet.