Skip to content

Instantly share code, notes, and snippets.

@alq666
Created July 18, 2012 17:25

Revisions

  1. alq666 revised this gist Jul 18, 2012. 1 changed file with 20 additions and 20 deletions.
    40 changes: 20 additions & 20 deletions build.py.diff
    Original file line number Diff line number Diff line change
    @@ -1,20 +1,20 @@
    diff --git a/checks/build.py b/checks/build.py
    index 8563722..dbb75f8 100644
    --- a/checks/build.py
    +++ b/checks/build.py
    @@ -38,6 +38,7 @@ class Hudson(object):
    except ValueError:
    raise Continue("Skipping non-timestamp dir: %s" % (dir_name))
    else:
    + self.logger.debug("JENKINS path %s / ts %s / watermark %s" % (dir_name, timestamp, self.high_watermarks[job_name]))
    # Check if it's a build we've seen already
    if timestamp <= self.high_watermarks[job_name]:
    raise Continue("Skipping old build: %s at %s" % (job_name, timestamp))
    @@ -94,6 +95,7 @@ class Hudson(object):
    def check(self, logger, agentConfig):
    + self.logger = logger
    if self.high_watermarks is None:
    # On the first run of check(), prime the high_watermarks dict
    # so that we only send events that occured after the agent
    diff --git a/checks/build.py b/checks/build.py
    index 8563722..dbb75f8 100644
    --- a/checks/build.py
    +++ b/checks/build.py
    @@ -38,6 +38,7 @@ class Hudson(object):
    except ValueError:
    raise Continue("Skipping non-timestamp dir: %s" % (dir_name))
    else:
    + self.logger.debug("JENKINS path %s / ts %s / watermark %s" % (dir_name, timestamp, self.high_watermarks[job_name]))
    # Check if it's a build we've seen already
    if timestamp <= self.high_watermarks[job_name]:
    raise Continue("Skipping old build: %s at %s" % (job_name, timestamp))
    @@ -94,6 +95,7 @@ class Hudson(object):


    def check(self, logger, agentConfig):
    + self.logger = logger
    if self.high_watermarks is None:
    # On the first run of check(), prime the high_watermarks dict
    # so that we only send events that occured after the agent
  2. alq666 created this gist Jul 18, 2012.
    20 changes: 20 additions & 0 deletions build.py.diff
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,20 @@
    diff --git a/checks/build.py b/checks/build.py
    index 8563722..dbb75f8 100644
    --- a/checks/build.py
    +++ b/checks/build.py
    @@ -38,6 +38,7 @@ class Hudson(object):
    except ValueError:
    raise Continue("Skipping non-timestamp dir: %s" % (dir_name))
    else:
    + self.logger.debug("JENKINS path %s / ts %s / watermark %s" % (dir_name, timestamp, self.high_watermarks[job_name]))
    # Check if it's a build we've seen already
    if timestamp <= self.high_watermarks[job_name]:
    raise Continue("Skipping old build: %s at %s" % (job_name, timestamp))
    @@ -94,6 +95,7 @@ class Hudson(object):


    def check(self, logger, agentConfig):
    + self.logger = logger
    if self.high_watermarks is None:
    # On the first run of check(), prime the high_watermarks dict
    # so that we only send events that occured after the agent