HWBOT
  1. HWBOT
  2. HWBOT-1061

Team points recalculate locks team table

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: hwbot v5.8.0
    • Labels:
      None

      Description

      I think it's because I added "where t.pro_oc_team = 'N' " to the query

        Activity

        Hide
        Build Server added a comment -
        Integrated in HWBOT v4 #2860 (See [http://dev.hwbot.org/job/HWBOT%20v4/2860/])
            HWBOT-1061

        Team points recalculate locks team table

        dennis :
        Files :
        * /hwbot/trunk/src/main/resources/META-INF/ranking-queries.xml
        Show
        Build Server added a comment - Integrated in HWBOT v4 #2860 (See [ http://dev.hwbot.org/job/HWBOT%20v4/2860/ ])      HWBOT-1061 Team points recalculate locks team table dennis : Files : * /hwbot/trunk/src/main/resources/META-INF/ranking-queries.xml
        Hide
        Build Server added a comment -
        Integrated in HWBOT v4 #2861 (See [http://dev.hwbot.org/job/HWBOT%20v4/2861/])
            HWBOT-1061

        Team points recalculate locks team table

        dennis :
        Files :
        * /hwbot/trunk/src/main/resources/META-INF/ranking-queries.xml
        Show
        Build Server added a comment - Integrated in HWBOT v4 #2861 (See [ http://dev.hwbot.org/job/HWBOT%20v4/2861/ ])      HWBOT-1061 Team points recalculate locks team table dennis : Files : * /hwbot/trunk/src/main/resources/META-INF/ranking-queries.xml
        Hide
        Dennis Devriendt added a comment -
        I was wrong, the where part has nothing to do with it. The team_points has always been locked if the team ranking is recalculated. InnoDB is the logical solution imo, I've tested it and it seems to work just fine, there's no longer a table lock and updating the ranking takes just as much time.
        Show
        Dennis Devriendt added a comment - I was wrong, the where part has nothing to do with it. The team_points has always been locked if the team ranking is recalculated. InnoDB is the logical solution imo, I've tested it and it seems to work just fine, there's no longer a table lock and updating the ranking takes just as much time.
        Hide
        Build Server added a comment -
        Integrated in HWBOT v4 #2862 (See [http://dev.hwbot.org/job/HWBOT%20v4/2862/])
            HWBOT-1061

        Team points recalculate locks team table

        delayed keyword is not supported by InnoDB, so I removed it from the replace delayed into member_points/team_points queries

        dennis :
        Files :
        * /hwbot/trunk/src/main/java/org/hwbot/facade/RankingFacadeImpl.java
        * /hwbot/trunk/src/main/resources/META-INF/ranking-queries.xml
        Show
        Build Server added a comment - Integrated in HWBOT v4 #2862 (See [ http://dev.hwbot.org/job/HWBOT%20v4/2862/ ])      HWBOT-1061 Team points recalculate locks team table delayed keyword is not supported by InnoDB, so I removed it from the replace delayed into member_points/team_points queries dennis : Files : * /hwbot/trunk/src/main/java/org/hwbot/facade/RankingFacadeImpl.java * /hwbot/trunk/src/main/resources/META-INF/ranking-queries.xml
        Hide
        Build Server added a comment -
        Integrated in HWBOT v4 #2863 (See [http://dev.hwbot.org/job/HWBOT%20v4/2863/])
            HWBOT-1061

        Team points recalculate locks team table

        update user rankings didn't work on UAT because not all results are in the db. This should fix it and doesn't make any difference on production

        dennis :
        Files :
        * /hwbot/trunk/src/main/resources/META-INF/ranking-queries.xml
        Show
        Build Server added a comment - Integrated in HWBOT v4 #2863 (See [ http://dev.hwbot.org/job/HWBOT%20v4/2863/ ])      HWBOT-1061 Team points recalculate locks team table update user rankings didn't work on UAT because not all results are in the db. This should fix it and doesn't make any difference on production dennis : Files : * /hwbot/trunk/src/main/resources/META-INF/ranking-queries.xml
        Hide
        Dennis Devriendt added a comment -
        I went ahead and made team_points and member_points InnoDB anyway. My theory is that we didn't notice this in the past because the rankings were usually cached. But now with the new cache, it happens more often that the cache is flushed, and thus that for the main page to load, it had to wait on the db table to become open.

        This was probably why Frederik noticed some downtime in recent days in the middle of the night (team points were recalculated at 4 am).
        Show
        Dennis Devriendt added a comment - I went ahead and made team_points and member_points InnoDB anyway. My theory is that we didn't notice this in the past because the rankings were usually cached. But now with the new cache, it happens more often that the cache is flushed, and thus that for the main page to load, it had to wait on the db table to become open. This was probably why Frederik noticed some downtime in recent days in the middle of the night (team points were recalculated at 4 am).

          People

          • Assignee:
            Dennis Devriendt
            Reporter:
            Dennis Devriendt
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: