Skip to content

Timestamp Time Zone Problem #188

@Hopding

Description

@Hopding

It looks as though Cassandra may be throwing away the RFC 822 time zone in the timestamps. For example, when I marshal a new skill review, I get this:

{
  "id": "1bcda55f-ea26-11e6-a86e-6c4008bcfa84",
  "skill_id": "59739551-ea19-11e6-9d49-6c4008bcfa84",
  "team_member_id": "57a0874f-ea19-11e6-9d48-6c4008bcfa84",
  "body": "It's the best skill ever",
  "timestamp": "2017-02-03 09:33:27-0600",
  "positive": true
}

But, after storing and retrieving it from the database, I get this:

{
  "id": "1bcda55f-ea26-11e6-a86e-6c4008bcfa84",
  "skill_id": "59739551-ea19-11e6-9d49-6c4008bcfa84",
  "team_member_id": "57a0874f-ea19-11e6-9d48-6c4008bcfa84",
  "body": "It's the best skill ever",
  "timestamp": "2017-02-03 15:33:27.000Z",
  "positive": true,
  "skill_name": "Java",
  "team_member_name": "Joe Smith"
}

Notice the timestamp before being stored in the database was -0600, but after being stored and retrieved from the database it is .000Z. It appears that Cassandra may discard timestamp data.

Note that this results in the following postman test output:

$ ./test --200
<<<<< Running 200 Suite... >>>>>
┌─────────────────────────┬──────────┬──────────┐
│                         │ executed │   failed │
├─────────────────────────┼──────────┼──────────┤
│              iterations │        1 │        0 │
├─────────────────────────┼──────────┼──────────┤
│                requests │       22 │        0 │
├─────────────────────────┼──────────┼──────────┤
│            test-scripts │       22 │        0 │
├─────────────────────────┼──────────┼──────────┤
│      prerequest-scripts │        1 │        0 │
├─────────────────────────┼──────────┼──────────┤
│              assertions │       70 │        2 │
├─────────────────────────┴──────────┴──────────┤
│ total run duration: 453ms                     │
├───────────────────────────────────────────────┤
│ total data received: 5.05KB (approx)          │
├───────────────────────────────────────────────┤
│ average response time: 8ms                    │
└───────────────────────────────────────────────┘

  #  failure            detail

 1.  AssertionFailure   Body contains previously POSTed skill review
                        at assertion:3 in test-script
                        inside "All Skill Reviews" of "2 - GET"

 2.  AssertionFailure   Body contains previously POSTed skill review
                        at assertion:2 in test-script
                        inside "A Skill Review" of "2 - GET"
<<<<< Done with 200 Suite. >>>>>

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions