Skip to content
Snippets Groups Projects
  • Russell Bryant's avatar
    9fbbdfb2
    Merged revisions 295711 via svnmerge from · 9fbbdfb2
    Russell Bryant authored
    https://origsvn.digium.com/svn/asterisk/branches/1.8
    
    ................
      r295711 | russell | 2010-11-19 18:50:00 -0600 (Fri, 19 Nov 2010) | 36 lines
      
      Merged revisions 295710 via svnmerge from 
      https://origsvn.digium.com/svn/asterisk/branches/1.6.2
      
      ........
        r295710 | russell | 2010-11-19 18:45:51 -0600 (Fri, 19 Nov 2010) | 29 lines
        
        Fix cache of device state changes for multiple servers.
        
        This patch addresses a regression where device states across multiple servers
        were not being processing completely correctly.  The code works to determine
        the overall state by looking at the last known state of a device on each
        server.  However, there was a regression due to some invasive rewrites of how
        the cache works that led to the cache only storing the last device state change
        for a device, regardless of which server it was on.
        
        The code is set up to cache device state change events by ensuring that each
        event in the cache has a unique device name + entity ID (server ID).  The code
        that was responsible for comparing raw information elements (which EID is)
        always returned a match due to a memcmp() with a length of 0.
        
        There isn't much code to fix the actual bug.  This patch also introduces a new
        CLI command that was very useful for debugging this problem.  The command
        allows you to dump the contents of the event cache.
        
        (closes issue #18284)
        Reported by: klaus3000
        Patches:
              issue18284.rev1.txt uploaded by russell (license 2)
        Tested by: russell, klaus3000
        
        (closes issue #18280)
        Reported by: klaus3000
        
        Review: https://reviewboard.asterisk.org/r/1012/
      ........
    ................
    
    
    git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@295712 65c4cc65-6c06-0410-ace0-fbb531ad65f3
    9fbbdfb2
    History
    Merged revisions 295711 via svnmerge from
    Russell Bryant authored
    https://origsvn.digium.com/svn/asterisk/branches/1.8
    
    ................
      r295711 | russell | 2010-11-19 18:50:00 -0600 (Fri, 19 Nov 2010) | 36 lines
      
      Merged revisions 295710 via svnmerge from 
      https://origsvn.digium.com/svn/asterisk/branches/1.6.2
      
      ........
        r295710 | russell | 2010-11-19 18:45:51 -0600 (Fri, 19 Nov 2010) | 29 lines
        
        Fix cache of device state changes for multiple servers.
        
        This patch addresses a regression where device states across multiple servers
        were not being processing completely correctly.  The code works to determine
        the overall state by looking at the last known state of a device on each
        server.  However, there was a regression due to some invasive rewrites of how
        the cache works that led to the cache only storing the last device state change
        for a device, regardless of which server it was on.
        
        The code is set up to cache device state change events by ensuring that each
        event in the cache has a unique device name + entity ID (server ID).  The code
        that was responsible for comparing raw information elements (which EID is)
        always returned a match due to a memcmp() with a length of 0.
        
        There isn't much code to fix the actual bug.  This patch also introduces a new
        CLI command that was very useful for debugging this problem.  The command
        allows you to dump the contents of the event cache.
        
        (closes issue #18284)
        Reported by: klaus3000
        Patches:
              issue18284.rev1.txt uploaded by russell (license 2)
        Tested by: russell, klaus3000
        
        (closes issue #18280)
        Reported by: klaus3000
        
        Review: https://reviewboard.asterisk.org/r/1012/
      ........
    ................
    
    
    git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@295712 65c4cc65-6c06-0410-ace0-fbb531ad65f3