Uploaded image for project: 'Ruby Driver'
  1. Ruby Driver
  2. RUBY-296

Timestamp with bson_ext

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.4.0
    • Component/s: None
    • Labels:
      None

      Description

      From a user:

      Hello, I have the following problem with bson_ext:

      I'm trying to poll oplog with tailable cursor. To skip already processed records in case when everything fails (cursor need to be re-queried), I have to persist last processed record's timestamp somewhere (obviously, in mongo). When bson_ext is not used, everything works fine.

      When I use bson_ext, starting from some value some strange things happens with the seconds of the timestamp I save into database using native serializer.
      Here are sympthoms:
      beginning from some value near 10^6-7 (which makes me think there is something about integer overflow) seconds field values begin to differ for native serialization and Ruby one. What is fancier, that on Linux (Debian) and Windows
      overflown
      values for bson_ext are different.

      Can someone tell me, what can be done about that and can something be done at all? For now speed of Ruby serialization is sufficient, but it would be nice to have maximum performance.

      I can provide more information and tests code if required.

        Attachments

          Activity

            People

            • Assignee:
              kbanker Kyle Banker
              Reporter:
              kbanker Kyle Banker
              Participants:
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: