Details
-
Bug
-
Resolution: Done
-
Critical
-
6.0.1
Description
Description of problem:
Valid rest calls are always successful (HTTP 200) and return jobId with status ACCEPTED. The job status can then be repeatedly checked until the job is completed (status SUCCESS) or it fails.
In 6.0.0.GA and 6.0.1.ER1 it seems the REST call is blocked until the job is completed but the response contains ACCEPTED job. Next job status query returns SUCCESS.
In 6.0.1.ER2 ACCEPTED job is returned immediately and no real work is done. All following queries for the job status will return ACCEPTED.
Version-Release number of selected component (if applicable):
6.0.1.ER2
How reproducible:
-
Steps to Reproduce:
1. submit a valid rest call
2. copy jobId (e.g. "jobId":"1393849999894-5")
3. check jobId status
Actual results:
The requested job is ACCEPTED and never executed. It stays ACCEPTED forever.
Expected results:
After receiving jobId in the REST call response, the next check for the job status should return SUCCESS.
Additional info:
Valid REST calls
curl -u 'user:password' -H 'Accept: application/json' -H 'Content-Type: application/json' -X POST -d '
{"name":"orgunit","description":"","owner":"jlocker@redhat.com","repositories":[]}' 'http://localhost:8080/business-central/rest/organizationalunits/'
curl -u 'user:password' -H 'Accept: application/json' -H 'Content-Type: application/json' -X POST -d '
{"name":"emptyRepo","description":"","userName":"","password":"","requestType":"new","gitURL":""}' 'http://localhost:8080/business-central/rest/repositories/'
Job status check:
curl -u 'user:password' -H 'Accept: application/json' -H 'Content-Type: application/json' -X GET 'http://localhost:8080/business-central/rest/jobs/<jobId>'