From 8f027c74517e1cf2c8fc13f86da80e8e8f1c0148 Mon Sep 17 00:00:00 2001 From: Trygve Laugstøl Date: Wed, 9 Jan 2013 17:03:20 +0100 Subject: o Preventing duplicates when inserting build participants. --- .../trygvis/esper/testing/core/jenkins/JenkinsBuildPoller.java | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src') diff --git a/src/main/java/io/trygvis/esper/testing/core/jenkins/JenkinsBuildPoller.java b/src/main/java/io/trygvis/esper/testing/core/jenkins/JenkinsBuildPoller.java index 38152e0..6a7e1b4 100755 --- a/src/main/java/io/trygvis/esper/testing/core/jenkins/JenkinsBuildPoller.java +++ b/src/main/java/io/trygvis/esper/testing/core/jenkins/JenkinsBuildPoller.java @@ -15,6 +15,8 @@ import org.slf4j.*; import java.io.*; import java.sql.*; import java.util.*; +import java.util.HashSet; +import java.util.Set; import static fj.data.Option.*; import static io.trygvis.esper.testing.Config.*; @@ -98,6 +100,8 @@ public class JenkinsBuildPoller implements TablePoller.NewRowCallback insertedParticipants = new HashSet<>(); + for (UUID user : jenkinsBuild.users) { SqlOption personO = daos.personDao.selectPersonByJenkinsUuid(user); @@ -111,6 +115,12 @@ public class JenkinsBuildPoller implements TablePoller.NewRowCallback