Created_At parameter returned in response for create segment and get segment APIs differ
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
masakari |
Fix Released
|
High
|
Tushar Patil |
Bug Description
While writing functional tests in openstacksdk for masakari, raising mismatch error due to timestamp in created_at field. Created_at field does not store timestamp in DB but while getting any resources its appends 000000 as timestamp.
Steps to reproduce :
Created_at field while creating host :
curl -g -i -X POST http://
HTTP/1.1 201 Created
Date: Fri, 24 Aug 2018 08:44:44 GMT
Server: Apache/2.4.18 (Ubuntu)
Content-Length: 613
Content-Type: application/json
OpenStack-
Vary: OpenStack-
x-openstack-
Connection: close
{"host": {"reserved": false, "uuid": "ffef6d6f-
Created_at field while getting the host which is created above :
curl -g -i -X GET http://
HTTP/1.1 200 OK
Date: Fri, 24 Aug 2018 08:45:26 GMT
Server: Apache/2.4.18 (Ubuntu)
Content-Length: 613
Content-Type: application/json
OpenStack-
Vary: OpenStack-
x-openstack-
Connection: close
{"host": {"reserved": false, "uuid": "ffef6d6f-
Actual result :
created_at field during POST call is : 2018-08-
created_at field during GET call is : 2018-08-
Here miliseconds are differ, issue is for SEGMENT as well as for HOST.
Expected result :
created_at field during POST call is : 2018-08-24T08:44:44
created_at field during GET call is : 2018-08-24T08:44:44
Not expecting milliseconds since DB is not storing the same.
Changed in masakari: | |
assignee: | nobody → Pooja Jadhav (poojajadhav) |
summary: |
- Timestamp (miliseconds) in created_at field raising issue while - asserting objects in functional tests + Created_At parameter returned in response for create segment and get + segment APIs differ |
Changed in masakari: | |
importance: | Undecided → High |
Fix proposed to branch: master /review. openstack. org/616068
Review: https:/