Uploaded image for project: 'Grouper'
  1. Grouper
  2. GRP-3125

config refresh doesnt work, casts to int when should be long

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • 2.5.42
    • None
    • None
    • None

    Description

      Jonathan (Jj!) Johnson 5:15 PM
      need to either fix the casting or the parentheses on this line: https://github.com/Internet2/grouper/blob/GROUPER_2_5_BRANCH/grouper-misc/grouperC[…]et2/middleware/grouperClient/config/db/ConfigDatabaseLogic.java
      grouper-misc/grouperClient/src/java/edu/internet2/middleware/grouperClient/config/db/ConfigDatabaseLogic.java:259
      int secondsSinceLastRefresh = (int)(System.currentTimeMillis() - currentDatabaseConfigCache) / 1000;
      <https://github.com/Internet2/grouper|Internet2/grouper>Internet2/grouper | Added by GitHub
      likely best to use longs

      Chris Hyzer 5:23 PM
      i think the case is going to the wrong place anyways... should be (int)((System.currentTimeMillis() - currentDatabaseConfigCache) / 1000)
      5:24
      but yeah, that will run out in a few decades too :slightly_smiling_face: (if currentDatabaseConfigCache is 0
      5:24
      anyways, yeah, longs better
      5:24
      which is i think what you said

      Attachments

        Activity

          People

            chris.hyzer@at.internet2.edu Chris Hyzer (upenn.edu)
            chris.hyzer@at.internet2.edu Chris Hyzer (upenn.edu)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: